diff options
| author | ruki <[email protected]> | 2015-05-28 10:17:32 +0800 |
|---|---|---|
| committer | ruki <[email protected]> | 2015-05-28 10:17:32 +0800 |
| commit | 6292b0f0938625902da6e3deec4877e409007708 (patch) | |
| tree | 4f6c7477e3901e0c63acd7a8cc2449d9d51344df /xmake/scripts/base | |
| parent | 3aab30fc254ae7e9bd138aff2bb263af0d447017 (diff) | |
add some compiler options for macosx
Diffstat (limited to 'xmake/scripts/base')
| -rw-r--r-- | xmake/scripts/base/config.lua | 8 | ||||
| -rw-r--r-- | xmake/scripts/base/global.lua | 8 | ||||
| -rw-r--r-- | xmake/scripts/base/main.lua | 9 |
3 files changed, 18 insertions, 7 deletions
diff --git a/xmake/scripts/base/config.lua b/xmake/scripts/base/config.lua index bf201db4b..6eb0b242c 100644 --- a/xmake/scripts/base/config.lua +++ b/xmake/scripts/base/config.lua @@ -203,8 +203,14 @@ function config.get(name) -- check assert(config._CURRENT) + -- the value + local value = config._CURRENT[name] + if value and value == "auto" then + value = nil + end + -- get it - return config._CURRENT[name] + return value end -- set the given configure to the current diff --git a/xmake/scripts/base/global.lua b/xmake/scripts/base/global.lua index 0a6b93042..095d49adb 100644 --- a/xmake/scripts/base/global.lua +++ b/xmake/scripts/base/global.lua @@ -132,8 +132,14 @@ function global.get(name) -- check assert(global._CURRENT) + -- the value + local value = global._CURRENT[name] + if value and value == "auto" then + value = nil + end + -- get it - return global._CURRENT[name] + return value end -- set the given configure to the current diff --git a/xmake/scripts/base/main.lua b/xmake/scripts/base/main.lua index 7418a625a..9767010e2 100644 --- a/xmake/scripts/base/main.lua +++ b/xmake/scripts/base/main.lua @@ -190,19 +190,18 @@ local menu = , {nil, "toolchains", "kv", nil, "The cross toolchains directory" } , {} - , {nil, "cc", "kv", "gcc", "The C Compiler" } - , {nil, "cx", "kv", "gcc", "The C/C++ Compiler" } - , {nil, "cxx", "kv", "gcc", "The C++ Compiler" } + , {nil, "cc", "kv", nil, "The C Compiler" } + , {nil, "cxx", "kv", nil, "The C++ Compiler" } , {nil, "cflags", "kv", nil, "The C Compiler Flags" } , {nil, "cxflags", "kv", nil, "The C/C++ compiler Flags" } , {nil, "cxxflags", "kv", nil, "The C++ Compiler Flags" } , {} - , {nil, "ld", "kv", "ld", "The Linker" } + , {nil, "ld", "kv", nil, "The Linker" } , {nil, "ldflags", "kv", nil, "The Linker Flags" } , {} - , {nil, "as", "kv", "as", "The Assembler" } + , {nil, "as", "kv", nil, "The Assembler" } , {nil, "asflags", "kv", nil, "The Assembler Flags" } -- the options for all platforms |
