summaryrefslogtreecommitdiff
path: root/xmake/rules/c++/modules/modules_support/common.lua
diff options
context:
space:
mode:
Diffstat (limited to 'xmake/rules/c++/modules/modules_support/common.lua')
-rw-r--r--xmake/rules/c++/modules/modules_support/common.lua3
1 files changed, 2 insertions, 1 deletions
diff --git a/xmake/rules/c++/modules/modules_support/common.lua b/xmake/rules/c++/modules/modules_support/common.lua
index 31ab47a81..96468456f 100644
--- a/xmake/rules/c++/modules/modules_support/common.lua
+++ b/xmake/rules/c++/modules/modules_support/common.lua
@@ -523,7 +523,8 @@ end
-- append headerunits objectfiles to link
function append_headerunits_objectfiles(target)
- local cache = localcache():get("headerunit_objectfiles") or {}
+ local cachekey = target:name() .. "headerunit_objectfiles"
+ local cache = localcache():get(cachekey) or {}
if target:is_binary() then
target:add("ldflags", cache, {force = true})
elseif target:is_static() == "static" then