summaryrefslogtreecommitdiff
path: root/xmake/modules/private/action/require/impl/package.lua
diff options
context:
space:
mode:
authorruki <[email protected]>2021-08-21 15:50:39 +0800
committerruki <[email protected]>2021-08-21 15:50:39 +0800
commit03edbeb91a3b4e5d6d113949d433424497431613 (patch)
treec28135ebfa884a45c2c1118aaf114d904a5a915f /xmake/modules/private/action/require/impl/package.lua
parente8facd596d72db42a0a20233cde0d543d9384e9c (diff)
improve requireslock format
Diffstat (limited to 'xmake/modules/private/action/require/impl/package.lua')
-rw-r--r--xmake/modules/private/action/require/impl/package.lua7
1 files changed, 6 insertions, 1 deletions
diff --git a/xmake/modules/private/action/require/impl/package.lua b/xmake/modules/private/action/require/impl/package.lua
index 95a54a008..d5d893658 100644
--- a/xmake/modules/private/action/require/impl/package.lua
+++ b/xmake/modules/private/action/require/impl/package.lua
@@ -224,7 +224,12 @@ function _get_locked_requires(requirekey)
_memcache():set("requireslock", requireslock or false)
end
if requireslock then
- return requireslock[requirekey], requireslock.__meta__.version
+ local plat = config.plat() or os.subhost()
+ local arch = config.arch() or so.subarch()
+ local key = plat .. "|" .. arch
+ if requireslock[key] then
+ return requireslock[key][requirekey], requireslock.__meta__.version
+ end
end
end