Alex Kost skribis: > Ludovic Courtès (2014-07-05 13:42 +0400) wrote: >> >> [...] >> >>> So I think the problem with the patch is that “@GUIX_TEST_ROOT@/store” >>> directory does not exist when “`cd "@GUIX_TEST_ROOT@/store"; pwd -P`” is >>> being invoked. >> >> Oops, indeed. Could you try this version, again from a directory with >> symlinks? >> >> diff --git a/test-env.in b/test-env.in >> index a3b3536..9d0c8cc 100644 >> --- a/test-env.in >> +++ b/test-env.in >> @@ -27,8 +27,15 @@ >> if [ -x "@abs_top_builddir@/guix-daemon" ] >> then >> NIX_SETUID_HELPER="@abs_top_builddir@/nix-setuid-helper" # normally unused >> - NIX_IGNORE_SYMLINK_STORE=1 # in case the store is a symlink >> NIX_STORE_DIR="@GUIX_TEST_ROOT@/store" >> + >> + # Do that because store.scm calls `canonicalize-path' on it. >> + mkdir -p "$NIX_STORE_DIR" >> + >> + # Canonicalize the store directory name in an attempt to avoid symlinks in >> + # it or its parent directories. See . >> + NIX_STORE_DIR="`cd "@GUIX_TEST_ROOT@/store"; pwd -P`" >> + >> NIX_LOCALSTATE_DIR="@GUIX_TEST_ROOT@/var" >> NIX_LOG_DIR="@GUIX_TEST_ROOT@/var/log/guix" >> NIX_DB_DIR="@GUIX_TEST_ROOT@/db" >> @@ -71,9 +78,6 @@ then >> GUIX_ALLOW_UNAUTHENTICATED_SUBSTITUTES \ >> NIX_CONF_DIR XDG_CACHE_HOME >> >> - # Do that because store.scm calls `canonicalize-path' on it. >> - mkdir -p "$NIX_STORE_DIR" >> - >> # Launch the daemon without chroot support because is may be >> # unavailable, for instance if we're not running as root. >> "@abs_top_builddir@/pre-inst-env" \ >> >> Thanks in advance, >> Ludo’. > > I have tried that. Unfortunately 2 tests failed. OK, we’re making progress. ;-) > Also I think > NIX_STORE_DIR="`cd "@GUIX_TEST_ROOT@/store"; pwd -P`" > may be replaced with: > NIX_STORE_DIR="`realpath "@GUIX_TEST_ROOT@/store"`" This is virtually equivalent, but probably less portable. > FAIL: tests/guix-register > ========================= [...] > + guix-register -p /home/alexx/src/guix/t-register-7895 > error: the path `/home/alexx/src' is a symlink; this is not allowed for the Nix store and its parent directories Can you check whether the patch below (in addition to the previous one) solves the problem?