diff options
| author | ruki <[email protected]> | 2015-06-12 14:39:38 +0800 |
|---|---|---|
| committer | ruki <[email protected]> | 2015-06-12 14:39:38 +0800 |
| commit | eb0e6fe79d8e49d82bb600529028fcf28767a2d8 (patch) | |
| tree | 47d565fb521efebf5919ddaef495e026517a1179 /xmake/scripts/platform/macosx | |
| parent | 3c4c1616be193d5146e2ddd9f8dcc706baf1f8f5 (diff) | |
modify arch name
Diffstat (limited to 'xmake/scripts/platform/macosx')
| -rw-r--r-- | xmake/scripts/platform/macosx/macosx.lua | 16 |
1 files changed, 6 insertions, 10 deletions
diff --git a/xmake/scripts/platform/macosx/macosx.lua b/xmake/scripts/platform/macosx/macosx.lua index 5adeb0e6a..f413fd759 100644 --- a/xmake/scripts/platform/macosx/macosx.lua +++ b/xmake/scripts/platform/macosx/macosx.lua @@ -30,7 +30,7 @@ local config = require("base/config") macosx._HOST = "macosx" -- init architectures -macosx._ARCHS = {"x86", "x64"} +macosx._ARCHS = {"i386", "x86_64"} -- make configure function macosx.make(configs) @@ -56,16 +56,12 @@ function macosx.make(configs) -- init flags for architecture local archflags = nil local arch = config.get("arch") - if arch then - if arch == "x64" then archflags = "-m64" - elseif arch == "x86" then archflags = "-m32" - end - end - configs.cxflags = { archflags } - configs.mxflags = { archflags } + if arch then archflags = "-arch " .. arch end + configs.cxflags = { archflags, "-fpascal-strings", "-fmessage-length=0" } + configs.mxflags = { archflags, "-fpascal-strings", "-fmessage-length=0" } configs.asflags = { archflags } - configs.ldflags = { archflags } - configs.shflags = { archflags } + configs.ldflags = { archflags, "-mmacosx-version-min=10.7", "-stdlib=libc++", "-lz" } + configs.shflags = { archflags, "-mmacosx-version-min=10.7", "-stdlib=libc++", "-lz" } -- init flags for the xcode sdk directory local xcode_sdkdir = config.get("__xcode_sdkdir") |
