diff options
| author | ruki <[email protected]> | 2015-06-24 14:24:08 +0800 |
|---|---|---|
| committer | ruki <[email protected]> | 2015-06-24 14:24:08 +0800 |
| commit | d9ee17f8892ee0537b5bbc461e760b4a5cb0a763 (patch) | |
| tree | 8ae97724e5ec13011d463fbc5ed46d345da89da4 /xmake/scripts/platform/android/android.lua | |
| parent | fd42ceb8e86322924d82aced97ad89accadb7592 (diff) | |
modify platform and makefile
Diffstat (limited to 'xmake/scripts/platform/android/android.lua')
| -rw-r--r-- | xmake/scripts/platform/android/android.lua | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/xmake/scripts/platform/android/android.lua b/xmake/scripts/platform/android/android.lua index 62c862970..1b4974b73 100644 --- a/xmake/scripts/platform/android/android.lua +++ b/xmake/scripts/platform/android/android.lua @@ -62,9 +62,10 @@ function android.make(configs) configs.shflags = { "-march=" .. config.get("arch"), "-llog" } -- add flags for the sdk directory of ndk - local ndk_sdkdir = config.get("__ndk_sdkdir") - if ndk_sdkdir then - ndk_sdkdir = path.translate(ndk_sdkdir) + local ndk = config.get("ndk") + local ndk_sdkver = config.get("ndk_sdkver") + if ndk and ndk_sdkver then + local ndk_sdkdir = path.translate(string.format("%s/platforms/android-%d", ndk, ndk_sdkver)) table.insert(configs.cxflags, string.format("--sysroot=%s/arch-arm", ndk_sdkdir)) table.insert(configs.asflags, string.format("--sysroot=%s/arch-arm", ndk_sdkdir)) table.insert(configs.ldflags, string.format("--sysroot=%s/arch-arm", ndk_sdkdir)) |
