summaryrefslogtreecommitdiff
path: root/xmake/scripts/platform/windows/tools/cl.lua
diff options
context:
space:
mode:
Diffstat (limited to 'xmake/scripts/platform/windows/tools/cl.lua')
-rw-r--r--xmake/scripts/platform/windows/tools/cl.lua16
1 files changed, 9 insertions, 7 deletions
diff --git a/xmake/scripts/platform/windows/tools/cl.lua b/xmake/scripts/platform/windows/tools/cl.lua
index 24c45bec3..9feda6e98 100644
--- a/xmake/scripts/platform/windows/tools/cl.lua
+++ b/xmake/scripts/platform/windows/tools/cl.lua
@@ -37,6 +37,15 @@ function cl.init(name)
-- init cxxflags
cl.cxxflags = { "-nologo" }
+ -- init flags map
+ cl.mapflags =
+ {
+ ["-O0"] = "-Od"
+ , ["-O3"] = "-Ot"
+ , ["-Ofast"] = "-Ox"
+ , ["-fomit-frame-pointer"] = "-Oy"
+ }
+
end
-- make the compiler command
@@ -60,13 +69,6 @@ function cl.flag_includedir(includedir)
return "-I" .. includedir
end
--- map gcc flag to the current compiler flag
-function cl.flag_map(flag)
-
- -- ok
- return flag
-end
-
-- the main function
function cl.main(...)