summaryrefslogtreecommitdiff
path: root/xmake/templates/c++/console/project/xmake.lua
diff options
context:
space:
mode:
authorruki <[email protected]>2015-06-18 16:37:58 +0800
committerruki <[email protected]>2015-06-18 16:37:58 +0800
commit379675ca870210abdde87db7dfd989855d337cd3 (patch)
tree3ffcd760864a4274944f5f575efbd31015c27d60 /xmake/templates/c++/console/project/xmake.lua
parent1cb067b57383aa65ad5500b350aca22d865e7f3c (diff)
add templates
Diffstat (limited to 'xmake/templates/c++/console/project/xmake.lua')
-rw-r--r--xmake/templates/c++/console/project/xmake.lua32
1 files changed, 32 insertions, 0 deletions
diff --git a/xmake/templates/c++/console/project/xmake.lua b/xmake/templates/c++/console/project/xmake.lua
new file mode 100644
index 000000000..7c1409763
--- /dev/null
+++ b/xmake/templates/c++/console/project/xmake.lua
@@ -0,0 +1,32 @@
+-- the debug mode
+if modes("debug") then
+
+ -- enable the debug symbols
+ set_symbols("debug")
+
+ -- disable optimization
+ set_optimize("none")
+end
+
+-- the release mode
+if modes("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
+add_target("demo")
+
+ -- set kind
+ set_kind("binary")
+
+ -- add files
+ add_files("src/*.cpp")
+