summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--xmake/core/package/package.lua11
1 files changed, 8 insertions, 3 deletions
diff --git a/xmake/core/package/package.lua b/xmake/core/package/package.lua
index 28473c2bf..fefa4eb17 100644
--- a/xmake/core/package/package.lua
+++ b/xmake/core/package/package.lua
@@ -255,12 +255,17 @@ function _instance:artifacts_set(artifacts_info)
if not manifest then
os.raise("package(%s): load manifest.txt failed when installing artifacts!", package:displayname())
end
- local vars = manifest.vars
- if vars then
- for k, v in pairs(vars) do
+ if manifest.vars then
+ for k, v in pairs(manifest.vars) do
package:set(k, v)
end
end
+ if manifest.envs then
+ local envs = self:envs()
+ for k, v in pairs(manifest.envs) do
+ envs[k] = v
+ end
+ end
end)
self._IS_PRECOMPILED = true
end