Partially fixes <https://bugs.gnu.org/33848>.
* guix/build/graft.scm (replace-store-references): Add support for
finding and rewriting UTF-16 and UTF-32 store references.
* tests/grafts.scm: Add tests.
This is a follow up commit to 06eb21856f, which added QTWEBENGINEPROCESS_PATH
to the list of wrapped variables. Unfortunately it wouldn't be set, as its
value is a plain file rather than a directory, and the code only checked for
directories.
* guix/build/qt-build-system.scm (variables-for-wrapping): Define a file type
entry for each variable definition, and use it to determine if we should look
for directories versus plain files.
Fixes <https://bugs.gnu.org/47569>.
Previously the wrapper's XDG_DATA_DIRS would contain any input that had
a /share sub-directory, which is usually all build-time inputs.
* guix/build/qt-build-system.scm (variables-for-wrapping)[collect-sub-dirs]:
Add 'selectors' parameter and honor it. Change caller to handle
selectors. Add selectors for /share.
This fixes the failing test add-to-entropy-count in tests/syscalls.scm on
powerpc64le-linux.
* guix/build/syscalls.scm (RNDADDTOENTCNT): When %host-type starts with
"powerpc64le", set this to #x80045201. Otherwise, set it to #x40045201 as
before.
This makes the clone procedure work correctly and fixes some test failures on
powerpc64le-linux, including tests/containers.scm.
* guix/build/syscalls.scm (clone): Add an entry for ppc64le.
This is a backport of Guile commit
076276c4f580368b4106316a77752d69c8f1494a.
* guix/build/download.scm (tls-wrap)[read!]: Wrap 'get-bytevector-n!'
call in 'catch' and handle 'error/premature-termination' GnuTLS errors.
On some systems, the columns in /proc/self/mountinfo look like this:
23 28 0:21 / /proc rw,nosuid,nodev,noexec,relatime shared:11 - proc proc rw
Before this change, the mounts procedure was written with the assumption that
the type and source could always be found in columns 8 and 9, respectively.
However, the proc(5) man page explains that there can be zero or more optional
fields starting at column 7 (e.g., "shared:11" above), so this assumption is
false in some situations.
* guix/build/syscalls.scm (mounts): Update the match pattern to use ellipsis
to match zero or more optional fields followed by a single hyphen. Remove the
trailing ellipsis, since multiple ellipses are not allowed in the same level.
The proc(5) man page indicates that there are no additional columns, so it is
probably OK to match an exact number of columns at the end like this.
This fixes an issue where two packages share a common dependent.
* guix/build/cargo-build-system.scm (unpack-rust-crates): Only copy rust
crates into the target directory if there isn't one already there with
the same name.
Partly fixes <https://bugs.gnu.org/46967>.
* guix/build/download.scm (tls-wrap)[unbuffered]: New procedure.
Pass the result of 'make-custom-binary-input/output-port' to
'unbuffered'.
* guix/build/syscalls.scm (<mount>): New record type.
(option-string->mount-flags, mount-flags)
(octal-decode, mounts): New procedures.
(mount-points): Rewrite in terms of 'mount'.
* tests/syscalls.scm ("mounts"): New test.
This prevents generated launchers and desktop files from inadvertently
crashing if the directory name contains a space.
* gnu/build/renpy-build-system.scm (install, install-desktop-file): Use ~s
to format data directory.
* guix/scripts/package.scm (export-manifest): New procedure.
(show-help, %options): Add '--export-manifest'.
(process-query): Honor it.
* guix/build/profiles.scm (build-profile): Mention it.
* tests/guix-package.sh: Test it.
* doc/guix.texi (Invoking guix package): Document it.
Partly fixes <https://bugs.gnu.org/44760>.
* guix/build/store-copy.scm (copy-store-item): New procedure.
(populate-store): Use it instead of the inline 'copy-recursively' call.
* guix/scripts/system.scm (copy-item): Likewise.
Pass #:reset-timestamps? and #:deduplicate? to 'register-path'.
Until now deduplication was performed as an additional pass after
copying files, which involve re-traversing all the files that had just
been copied.
* guix/store/deduplication.scm (copy-file/deduplicate): New procedure.
* tests/store-deduplication.scm ("copy-file/deduplicate"): New test.
* guix/build/store-copy.scm (populate-store): Add #:deduplicate?
parameter and honor it.
* tests/gexp.scm ("gexp->derivation, store copy"): Pass #:deduplicate? #f
to 'populate-store'.
* gnu/build/image.scm (initialize-root-partition): Pass #:deduplicate?
to 'populate-store'. Pass #:deduplicate? #f to 'register-closure'.
* gnu/build/vm.scm (root-partition-initializer): Likewise.
* gnu/build/install.scm (populate-single-profile-directory): Pass
#:deduplicate? #f to 'populate-store'.
* gnu/build/linux-initrd.scm (build-initrd): Likewise.
* guix/scripts/pack.scm (self-contained-tarball)[import-module?]: New
procedure.
[build]: Pass it as an argument to 'source-module-closure'.
* guix/scripts/pack.scm (squashfs-image)[build]: Wrap in
'with-extensions'.
* gnu/system/linux-initrd.scm (expression->initrd)[import-module?]: New
procedure.
[builder]: Pass it to 'source-module-closure'.
* gnu/system/install.scm (cow-store-service-type)[import-module?]: New
procedure. Pass it to 'source-module-closure'.
Until now, 'populate-store' would reset permissions but not timestamps,
so callers would resort to going through an extra directory traversal to
reset timestamps.
* guix/build/store-copy.scm (reset-permissions): Remove.
(copy-recursively): New procedure.
(populate-store): Pass #:keep-permissions? to 'copy-recursively'.
Remove call to 'reset-permissions'.
* tests/gexp.scm ("gexp->derivation, store copy"): In BUILD-DRV, check
whether 'populate-store' canonicalizes permissions and timestamps.
* gnu/build/image.scm (initialize-root-partition): Pass #:reset-timestamps? #f
to 'register-closure'.
* gnu/build/vm.scm (root-partition-initializer): Likewise.
* guix/build/cargo-build-system.scm (configure): When gettext is
available in the build environment set the GETTEXT_SYSTEM variable.
* gnu/packages/crates-io.scm (rust-gettext-rs-0.5, rust-gettext-rs-0.4,
rust-gettext-sys-0.19)[arguments]: Remove phase to help find system gettext.
* guix/build/cargo-build-system.scm (configure): When clang is available
in the build environment set the LIBCLANG_PATH variable.
* gnu/packages/crates-graphics.scm (rust-aom-sys-0.1,
uust-dav1d-sys-0.3),
* gnu/packages/crates-io.scm (rust-bindgen-0.55, rust-bindgen-0.54,
rust-bindgen-0.53, rust-bindgen-0.52, rust-cexpr-0.4, rust-cexpr-0.3,
rust-cexpr-0.2, rust-clang-sys-1, rust-clang-sys-0.29,
rust-clang-sys-0.26, rust-clang-sys-0.22, rust-clang-sys-0.11,
rust-libpijul-0.12, rust-nettle-7, rust-nettle-sys-2,
rust-sequoia-openpgp-0.9)[arguments]: Remove phases which set an
environment variable to find clang.
[inputs]: Rename instances of libclang with clang.
* guix/build/cargo-build-system.scm (configure): When openssl is
available set the OPENSSL_DIR variable to discover its location.
* gnu/packages/crates-io.scm (rust-curl-sys-0.4, rust-libgit2-sys-0.10,
rust-libpijul-0.12, rust-libssh2-sys-0.2, rust-native-tls-0.2,
rust-openssl-sys-0.9, rust-openssl-0.7, rust-trust-dns-rustls-0.6),
* gnu/packages/rust-apps.scm (tokei, exa)[arguments]: Remove redundant
setenv for openssl.
Fixes <https://bugs.gnu.org/44692>.
* guix/build/cargo-build-system.scm (build): Default to the empty list for
FEATURES. Check whether the list is empty when building the Cargo arguments.
This reverts commit 2fb12dd1bb, which
causes the 'svn export' command to fail with:
svn: E155000: Destination directory exists; please remove the directory
or use --force to overwrite
* guix/build-system/asdf.scm (asdf-build): Remove the 'files' variable.
* guix/build/asd-build-system.scm (find-asd-files): New variable.
(build, check): Use it.