(address . guix-patches@gnu.org)(name . Denis 'GNUtoo' Carikli)(address . GNUtoo@cyberdimension.org)
./pre-inst-env is supposed to use only the packages definitions that are in
the guix source tree and not the host packages.
However if GUIX_PACKAGE_PATH is set, it will use host packages as well.
In addition, when packages are defined in both the guix source tree and in
GUIX_PACKAGE_PATH, GUIX_PACKAGE_PATH will take the precedence and guix
will print warnings like that:
guix build: warning: ambiguous package specification `libsamsung-ipc'
guix build: warning: choosing libsamsung-ipc@0.1 from
/home/[...]/.config/guix/local/replicant.scm:31:2
That situation can happen when working in a new package in
GUIX_PACKAGE_PATH and then importing the package in the guix source tree to
add it upstream.
Signed-off-by: Denis 'GNUtoo' Carikli <GNUtoo@cyberdimension.org>
---
build-aux/pre-inst-env.in | 4 ++++
1 file changed, 4 insertions(+)
Toggle diff (15 lines)
diff --git a/build-aux/pre-inst-env.in b/build-aux/pre-inst-env.in
index e0aa7fe868..698a7994fb 100644
--- a/build-aux/pre-inst-env.in
+++ b/build-aux/pre-inst-env.in
@@ -59,4 +59,8 @@ export NIX_HASH
GUIX_UNINSTALLED=1
export GUIX_UNINSTALLED
+# Make sure we don't use local package definitions
+GUIX_PACKAGE_PATH=""
+export GUIX_PACKAGE_PATH
+
exec "$@"
--
2.28.0