diff options
author | 2016-03-30 21:56:03 +0000 | |
---|---|---|
committer | 2016-03-30 21:56:03 +0000 | |
commit | 001d49c5b7fd684c6e7287c6c4e75535e9a8d7aa (patch) | |
tree | 9a55aff2e8b5c5331730f5a62a8ad054d694fe1f /scripts/genie.lua | |
parent | e0294a8ec30c168a2bc072a995127ac1a32b82e9 (diff) |
support build without optimize flag (nw)
OPTIMIZE= to disable the current default value 3
Also allow ARCHOPTS to be set regardless of OPTIMIZE, useful for
debug flags.
Diffstat (limited to 'scripts/genie.lua')
-rw-r--r-- | scripts/genie.lua | 35 |
1 files changed, 16 insertions, 19 deletions
diff --git a/scripts/genie.lua b/scripts/genie.lua index 2277bbcd62a..08cf0aa381d 100644 --- a/scripts/genie.lua +++ b/scripts/genie.lua @@ -748,17 +748,6 @@ if _OPTIONS["SYMBOLS"]~=nil and _OPTIONS["SYMBOLS"]~="0" then } end ---# add the optimization flag - buildoptions { - "-O".. _OPTIONS["OPTIMIZE"], - "-fno-strict-aliasing" - } -configuration { "mingw-clang" } - buildoptions { - "-O1", -- without this executable crash often - } -configuration { } - -- add the error warning flag if _OPTIONS["NOWERROR"]==nil then buildoptions { @@ -769,16 +758,9 @@ end -- if we are optimizing, include optimization options if _OPTIONS["OPTIMIZE"] then buildoptions { + "-O".. _OPTIONS["OPTIMIZE"], "-fno-strict-aliasing" } - if _OPTIONS["ARCHOPTS"] then - buildoptions { - _OPTIONS["ARCHOPTS"] - } - linkoptions { - _OPTIONS["ARCHOPTS"] - } - end if _OPTIONS["OPT_FLAGS"] then buildoptions { _OPTIONS["OPT_FLAGS"] @@ -831,6 +813,21 @@ if _OPTIONS["OPTIMIZE"] then end end +configuration { "mingw-clang" } + buildoptions { + "-O1", -- without this executable crash often + } +configuration { } + +if _OPTIONS["ARCHOPTS"] then + buildoptions { + _OPTIONS["ARCHOPTS"] + } + linkoptions { + _OPTIONS["ARCHOPTS"] + } +end + if _OPTIONS["SHLIB"] then buildoptions { "-fPIC" |