diff options
| author | ruki <[email protected]> | 2022-08-17 22:40:11 +0800 |
|---|---|---|
| committer | ruki <[email protected]> | 2022-08-17 22:40:11 +0800 |
| commit | c2e6fba79fc6ae2a1529ac571e8cce7d50ed7cfc (patch) | |
| tree | 625d0b8562718b371fd1745cc053dd5b53836a4d /xmake/rules/c++/modules/modules_support/common.lua | |
| parent | f005c69ec9a1e3f15c8d3368290cc85f5ca1fb52 (diff) | |
add build.c++.modules policy
Diffstat (limited to 'xmake/rules/c++/modules/modules_support/common.lua')
| -rw-r--r-- | xmake/rules/c++/modules/modules_support/common.lua | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/xmake/rules/c++/modules/modules_support/common.lua b/xmake/rules/c++/modules/modules_support/common.lua index aa7c0fb59..138c8e36f 100644 --- a/xmake/rules/c++/modules/modules_support/common.lua +++ b/xmake/rules/c++/modules/modules_support/common.lua @@ -140,6 +140,9 @@ function contains_modules(target) -- we can not use `"c++.build.modules.builder"`, because it contains sourcekind/cxx. local target_with_modules = target:sourcebatches()["c++.build.modules"] and true or false if not target_with_modules then + target_with_modules = target:policy("build.c++.modules") + end + if not target_with_modules then for _, dep in ipairs(target:orderdeps()) do local sourcebatches = dep:sourcebatches() if sourcebatches["c++.build.modules"] then |
