mirror of
https://codeberg.org/guix/guix.git
synced 2025-10-02 02:15:12 +00:00
store-copy: Canonicalize the mtime and permissions of the store copy.
Fixes a bug whereby directories in the output of 'guix pack -f tarball' would not be read-only. * guix/build/store-copy.scm (reset-permissions): New procedure. (populate-store): Pass #:keep-mtime? #t to 'copy-recursively'. Call 'reset-permissions'. * tests/pack.scm ("self-contained-tarball"): In CHECK, define 'canonical?' and use it to check that every file has an mtime of 1 and is read-only. * tests/guix-pack.sh: Invoke "chmod -Rf +w" before "rm -rf" in trap.
This commit is contained in:
parent
1ff53787db
commit
72dc64f8f7
3 changed files with 65 additions and 13 deletions
|
@ -49,7 +49,7 @@ the_pack="`guix pack --bootstrap -S /opt/gnu/bin=bin guile-bootstrap`"
|
|||
# exists because /opt/gnu/bin may be an absolute symlink to a store item that
|
||||
# has been GC'd.
|
||||
test_directory="`mktemp -d`"
|
||||
trap 'rm -rf "$test_directory"' EXIT
|
||||
trap 'chmod -Rf +w "$test_directory"; rm -rf "$test_directory"' EXIT
|
||||
cd "$test_directory"
|
||||
tar -xf "$the_pack"
|
||||
test -L opt/gnu/bin
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue