summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorruki <[email protected]>2021-03-03 22:32:29 +0800
committerruki <[email protected]>2021-03-03 22:32:29 +0800
commit5fc041587d6f683181ba754bb221336dc076e561 (patch)
treef8ababdf2f26c14babbca4f91f7cd92ea590a1b3
parentc4c51868c4bde47d3d5be1c22a71b7f4fd553f31 (diff)
fix install packages
-rw-r--r--xmake/modules/private/action/require/impl/environment.lua7
1 files changed, 3 insertions, 4 deletions
diff --git a/xmake/modules/private/action/require/impl/environment.lua b/xmake/modules/private/action/require/impl/environment.lua
index e7832d6a1..caceefb48 100644
--- a/xmake/modules/private/action/require/impl/environment.lua
+++ b/xmake/modules/private/action/require/impl/environment.lua
@@ -20,10 +20,9 @@
-- imports
import("core.project.config")
-import("core.package.package", {alias = "core_package"})
import("lib.detect.find_tool")
import("private.action.require.impl.packagenv")
-import("private.action.require.impl.package")
+import("private.action.require.impl.install_packages")
-- enter environment
--
@@ -44,12 +43,12 @@ function enter()
-- git not found? install it first
local packages = {}
if not find_tool("git") then
- table.join2(packages, package.install_packages("git"))
+ table.join2(packages, install_packages("git"))
end
-- missing the necessary unarchivers for *.gz, *.7z? install them first, e.g. gzip, 7z, tar ..
if not ((find_tool("gzip") and find_tool("tar")) or find_tool("7z")) then
- table.join2(packages, package.install_packages("7z"))
+ table.join2(packages, install_packages("7z"))
end
-- enter the environments of installed packages