summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorruki <[email protected]>2022-07-20 23:07:46 +0800
committerGitHub <[email protected]>2022-07-20 23:07:46 +0800
commitf84814e6c98db75e538007cebd7edee34710b275 (patch)
tree95f2e7ad23404d75015d8dd5ca99f5692fd8d3bd
parent5dd962d1b0e51b839f88b580c5586ef8cfca3c60 (diff)
parent7fdf130ec0635d544bb3a33ea216e954cd635290 (diff)
Merge pull request #2582 from SirLynix/patch-11
cmake: add support of include_external_headers policy
-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