diff options
| author | ruki <[email protected]> | 2021-02-21 18:18:38 +0800 |
|---|---|---|
| committer | ruki <[email protected]> | 2021-02-21 18:18:38 +0800 |
| commit | 0d918cd313d6df1a07bebaff687d744ef5522e50 (patch) | |
| tree | 000de6fbabbb00c4c502058c73f9532e25fd3e11 | |
| parent | 5e1a9ad514f20214515815e14ee7d92347d0ced4 (diff) | |
fix should install for package again
| -rw-r--r-- | xmake/modules/private/action/require/impl/install_packages.lua | 4 | ||||
| -rw-r--r-- | xmake/modules/private/action/require/install.lua | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/xmake/modules/private/action/require/impl/install_packages.lua b/xmake/modules/private/action/require/impl/install_packages.lua index 2e56ad3a4..765b71c3d 100644 --- a/xmake/modules/private/action/require/impl/install_packages.lua +++ b/xmake/modules/private/action/require/impl/install_packages.lua @@ -404,9 +404,9 @@ end -- should install? function _should_install(instance) - if instance:exists() and instance:parents() then + if instance:parents() then -- if all the packages that depend on it already exist, then there is no need to install it - for _, parent in ipairs(instance:parents()) do + for _, parent in pairs(instance:parents()) do if not parent:exists() then return true end diff --git a/xmake/modules/private/action/require/install.lua b/xmake/modules/private/action/require/install.lua index c9e24d21e..7d6ec3556 100644 --- a/xmake/modules/private/action/require/install.lua +++ b/xmake/modules/private/action/require/install.lua @@ -29,9 +29,9 @@ import("private.action.require.impl.utils.get_requires") -- should install? function _should_install(instance) - if instance:exists() and instance:parents() then + if instance:parents() then -- if all the packages that depend on it already exist, then there is no need to install it - for _, parent in ipairs(instance:parents()) do + for _, parent in pairs(instance:parents()) do if not parent:exists() then return true end |
