summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--xmake/modules/private/action/require/impl/install_packages.lua4
1 files changed, 3 insertions, 1 deletions
diff --git a/xmake/modules/private/action/require/impl/install_packages.lua b/xmake/modules/private/action/require/impl/install_packages.lua
index 8757de282..096190945 100644
--- a/xmake/modules/private/action/require/impl/install_packages.lua
+++ b/xmake/modules/private/action/require/impl/install_packages.lua
@@ -398,7 +398,9 @@ function _get_package_installdeps(packages)
-- patch toolchain/packages to installdeps, because we need install toolchain package first
for _, toolchain in ipairs(instance:toolchains()) do
for _, packagename in ipairs(toolchain:config("packages")) do
- table.insert(deps, packagesmap[packagename])
+ if packagesmap[packagename] ~= instance then -- avoid loop recursion
+ table.insert(deps, packagesmap[packagename])
+ end
end
end
installdeps[tostring(instance)] = deps