summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--xmake/modules/package/tools/cmake.lua3
1 files changed, 3 insertions, 0 deletions
diff --git a/xmake/modules/package/tools/cmake.lua b/xmake/modules/package/tools/cmake.lua
index dc227b89b..d31788a31 100644
--- a/xmake/modules/package/tools/cmake.lua
+++ b/xmake/modules/package/tools/cmake.lua
@@ -275,6 +275,9 @@ function _get_configs_for_generic(package, configs, opt)
if package:config("pic") ~= false then
table.insert(configs, "-DCMAKE_POSITION_INDEPENDENT_CODE=ON")
end
+ if not package:use_external_includes() then
+ table.insert(configs, "-DCMAKE_NO_SYSTEM_FROM_IMPORTED=ON")
+ end
end
-- get configs for windows