diff options
| author | ruki <[email protected]> | 2023-06-06 23:28:44 +0800 |
|---|---|---|
| committer | ruki <[email protected]> | 2023-06-06 23:28:44 +0800 |
| commit | 8d76e8be9743a661715bc8731a5be73eca49ea8c (patch) | |
| tree | 3b09e6dd3891d5ac24cddf0ba2a3dd084e7a5c88 /xmake/modules/package/tools/cmake.lua | |
| parent | 91847c92a4da59fcb1efe843e8c9ee1bc4c987df (diff) | |
improve tools.xmake
Diffstat (limited to 'xmake/modules/package/tools/cmake.lua')
| -rw-r--r-- | xmake/modules/package/tools/cmake.lua | 13 |
1 files changed, 1 insertions, 12 deletions
diff --git a/xmake/modules/package/tools/cmake.lua b/xmake/modules/package/tools/cmake.lua index ffde2f3d7..97829c36a 100644 --- a/xmake/modules/package/tools/cmake.lua +++ b/xmake/modules/package/tools/cmake.lua @@ -73,17 +73,6 @@ function _map_linkflags(package, targetkind, sourcekinds, name, values) return linker.map_flags(targetkind, sourcekinds, name, values, {target = package}) end --- is cross compilation? -function _is_cross_compilation(package) - if not package:is_plat(os.subhost()) then - return true - end - if package:is_plat("macosx") and not package:is_arch(os.subarch()) then - return true - end - return false -end - -- is the toolchain compatible with the host? function _is_toolchain_compatible_with_host(package) local toolchains = package:config("toolchains") @@ -698,7 +687,7 @@ function _get_configs(package, configs, opt) _get_configs_for_mingw(package, configs, opt) elseif package:is_plat("wasm") then _get_configs_for_wasm(package, configs, opt) - elseif _is_cross_compilation(package) then + elseif package:is_cross() then _get_configs_for_cross(package, configs, opt) elseif package:config("toolchains") then -- we still need find system libraries, |
