[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#18689: guix-register test fails
From: |
Ludovic Courtès |
Subject: |
bug#18689: guix-register test fails |
Date: |
Sun, 12 Oct 2014 00:29:20 +0200 |
User-agent: |
Gnus/5.130011 (Ma Gnus v0.11) Emacs/24.3 (gnu/linux) |
Philip Woods <address@hidden> skribis:
> + guix-register -p /home/elzair/Development/scheme/guix/t-register-4387
> error: creating directory `/gnu': Permission denied
Here ‘guix-register’ attempts to create /gnu/store if it doesn’t exist
yet, hence this error (I don’t have this error on my machine because
/gnu/store already exists.)
Could you apply the patch below (with ‘patch -p1 < foo.patch’), and then
run “make check TESTS=tests/guix-register.sh”, making sure that /gnu
does *not* already exist?
diff --git a/nix/guix-register/guix-register.cc
b/nix/guix-register/guix-register.cc
index 92eedab..f5c610f 100644
--- a/nix/guix-register/guix-register.cc
+++ b/nix/guix-register/guix-register.cc
@@ -224,16 +224,16 @@ main (int argc, char *argv[])
{
argp_parse (&argp, argc, argv, 0, 0, 0);
+ /* Instantiate the store. This creates any missing directories among
+ 'settings.nixStore', 'settings.nixDBPath', etc. */
+ LocalStore store;
+
if (!prefix.empty ())
/* Under the --prefix tree, the final name of the store will be
NIX_STORE_DIR. Set it here so that the database uses file names
prefixed by NIX_STORE_DIR and not PREFIX + NIX_STORE_DIR. */
settings.nixStore = NIX_STORE_DIR;
- /* Instantiate the store. This creates any missing directories among
- 'settings.nixStore', 'settings.nixDBPath', etc. */
- LocalStore store;
-
register_validity (&store, *input, deduplication);
}
catch (std::exception &e)
Thanks in advance,
Ludo’.