summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorruki <[email protected]>2025-09-09 10:54:04 +0800
committerGitHub <[email protected]>2025-09-09 10:54:04 +0800
commit30f935da29e7e003b2cea2c26a4be59020fe1b47 (patch)
tree8469af6b9230c93b2dcf2dac2b718ce431d8458e
parent37b0f7c8a80def21ad5def2bfbf2ea8376774b80 (diff)
parentb5ec88d78f68fff74fd0f3d9cb61de9e2f815bf0 (diff)
Merge pull request #6783 from Arthapz/fix-stdmodule-policy
fix(C++ modules) fix build.c++.modules.std policy
-rw-r--r--xmake/rules/c++/modules/config.lua2
1 files changed, 1 insertions, 1 deletions
diff --git a/xmake/rules/c++/modules/config.lua b/xmake/rules/c++/modules/config.lua
index a0f7dcc33..30f2f2680 100644
--- a/xmake/rules/c++/modules/config.lua
+++ b/xmake/rules/c++/modules/config.lua
@@ -90,7 +90,7 @@ function main(target)
end
function insert_stdmodules(target)
- if target:data("cxx.has_modules") then
+ if target:data("cxx.has_modules") and target:policy("build.c++.modules.std") then
local sourcebatches = target:sourcebatches()
if sourcebatches and sourcebatches["c++.build.modules.scanner"] then
local sourcebatch = sourcebatches["c++.build.modules.scanner"]