summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--xmake/modules/core/tools/dmd.lua14
1 files changed, 14 insertions, 0 deletions
diff --git a/xmake/modules/core/tools/dmd.lua b/xmake/modules/core/tools/dmd.lua
index a68542be2..6dfa85695 100644
--- a/xmake/modules/core/tools/dmd.lua
+++ b/xmake/modules/core/tools/dmd.lua
@@ -57,6 +57,20 @@ function nf_optimize(self, level)
end
end
+-- make the strip flag
+function nf_strip(self, level)
+ if not self:is_plat("windows") then
+ local maps = {
+ debug = "-L-S",
+ all = {"-L-s", "-L-dead_strip"}
+ }
+ if self:is_plat("macosx", "iphoneos") then
+ maps.all = {"-L-x", "-L-dead_strip"}
+ end
+ return maps[level]
+ end
+end
+
-- make the symbol flag
function nf_symbol(self, level)
local maps = {