diff options
Diffstat (limited to 'tests/console_c++')
| -rwxr-xr-x | tests/console_c++/src/main.cpp | 9 | ||||
| -rwxr-xr-x | tests/console_c++/xmake.lua | 32 |
2 files changed, 41 insertions, 0 deletions
diff --git a/tests/console_c++/src/main.cpp b/tests/console_c++/src/main.cpp new file mode 100755 index 000000000..db2361659 --- /dev/null +++ b/tests/console_c++/src/main.cpp @@ -0,0 +1,9 @@ +#include <iostream> + +using namespace std; + +int main(int argc, char** argv) +{ + cout << "hello world!" << endl; + return 0; +} diff --git a/tests/console_c++/xmake.lua b/tests/console_c++/xmake.lua new file mode 100755 index 000000000..aaa5d9bb5 --- /dev/null +++ b/tests/console_c++/xmake.lua @@ -0,0 +1,32 @@ +-- the debug mode +if is_mode("debug") then + + -- enable the debug symbols + set_symbols("debug") + + -- disable optimization + set_optimize("none") +end + +-- the release mode +if is_mode("release") then + + -- set the symbols visibility: hidden + set_symbols("hidden") + + -- enable fastest optimization + set_optimize("fastest") + + -- strip all symbols + set_strip("all") +end + +-- add target +target("cpp_console") + + -- set kind + set_kind("binary") + + -- add files + add_files("src/*.cpp") + |
