diff options
| author | ruki <[email protected]> | 2021-03-19 00:39:25 +0800 |
|---|---|---|
| committer | ruki <[email protected]> | 2021-03-19 00:39:25 +0800 |
| commit | 66a47b5aa01fc5ccd4897f6d81da4f9b6baab428 (patch) | |
| tree | 6b3b6e2a68817a88f5eec8aee3a2983258e12926 | |
| parent | 7adbba0c3b57e0a58eaf00b8ab21db5bcffdf1fc (diff) | |
add some TODO comments
| -rw-r--r-- | xmake/actions/config/main.lua | 10 | ||||
| -rw-r--r-- | xmake/modules/package/tools/autoconf.lua | 2 | ||||
| -rw-r--r-- | xmake/toolchains/ndk/check.lua | 5 |
3 files changed, 15 insertions, 2 deletions
diff --git a/xmake/actions/config/main.lua b/xmake/actions/config/main.lua index d17b93c15..9d56baac4 100644 --- a/xmake/actions/config/main.lua +++ b/xmake/actions/config/main.lua @@ -148,6 +148,16 @@ function _check_target_toolchains() raise(errors) end end + else + -- we only abort it when we know that toolchains of platform and target do not found + local toolchain_found + for _, toolchain_inst in pairs(target:toolchains()) do + print(toolchain_inst:name()) + if toolchain_inst:is_standalone() then + toolchain_found = true + end + end + assert(toolchain_found, "target(%s): toolchain not found!", target:name()) end end end diff --git a/xmake/modules/package/tools/autoconf.lua b/xmake/modules/package/tools/autoconf.lua index 3bfa23181..dbc7e2140 100644 --- a/xmake/modules/package/tools/autoconf.lua +++ b/xmake/modules/package/tools/autoconf.lua @@ -142,7 +142,7 @@ function buildenvs(package, opt) table.join2(asflags, opt.asflags) table.join2(ldflags, opt.ldflags) table.join2(shflags, opt.shflags) - table.join2(cflags, compiler.map_flags("c", "define", defines)) + table.join2(cflags, compiler.map_flags("c", "define", defines)) -- TODO we need use package/toolchains table.join2(cflags, compiler.map_flags("c", "includedir", includedirs)) table.join2(cflags, compiler.map_flags("c", "sysincludedir", sysincludedirs)) table.join2(asflags, compiler.map_flags("as", "define", defines)) diff --git a/xmake/toolchains/ndk/check.lua b/xmake/toolchains/ndk/check.lua index d7ecb4113..907d652c6 100644 --- a/xmake/toolchains/ndk/check.lua +++ b/xmake/toolchains/ndk/check.lua @@ -48,8 +48,9 @@ function _check_ndk(toolchain) toolchain:config_set("ndk_toolchains_ver", ndk.toolchains_ver) toolchain:config_set("ndk_sysroot", ndk.sysroot) toolchain:configs_save() + return true else - --[[TODO + --[[TODO we need also add this tips when use remote ndk toolchain -- failed cprint("${bright color.error}please run:") cprint(" - xmake config --ndk=xxx") @@ -72,5 +73,7 @@ end function main(toolchain) _check_android_sdk(toolchain) _check_ndk(toolchain) + -- TODO we should return the check result, but we need support builder with package first + -- so we need improve remote ndk toolchain return true end |
