summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--core/xmake.lua3
1 files changed, 3 insertions, 0 deletions
diff --git a/core/xmake.lua b/core/xmake.lua
index 25009801e..3e3a92acd 100644
--- a/core/xmake.lua
+++ b/core/xmake.lua
@@ -15,6 +15,9 @@ set_languages("c99", "cxx11")
-- add release and debug modes
add_rules("mode.release", "mode.debug")
+if is_mode("release") then
+ set_optimize("smallest")
+end
-- disable some compiler errors
add_cxflags("-Wno-error=deprecated-declarations", "-fno-strict-aliasing", "-Wno-error=nullability-completeness", "-Wno-error=parentheses-equality")