From 09c14288cfe3f0017965d503841a938116c3372b Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 16 Jul 2023 02:00:00 +0200 Subject: gnu: bcachefs-tools: Respect input rewriting. * gnu/packages/file-systems.scm (bcachefs-tools)[arguments]: Rewrite the 'promote-mount.bcachefs.sh phase to use SEARCH-INPUT-FILE. --- gnu/packages/file-systems.scm | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/gnu/packages/file-systems.scm b/gnu/packages/file-systems.scm index 007203ae12..7788acd34e 100644 --- a/gnu/packages/file-systems.scm +++ b/gnu/packages/file-systems.scm @@ -614,16 +614,18 @@ from a mounted file system.") (add-after 'install 'promote-mount.bcachefs.sh ;; XXX The (optional) ‘mount.bcachefs’ requires rust:cargo. ;; This shell alternative does the job well enough for now. - (lambda _ + (lambda* (#:key inputs #:allow-other-keys) + (define (whence file) + (dirname (search-input-file inputs file))) (with-directory-excursion (string-append #$output "/sbin") (rename-file "mount.bcachefs.sh" "mount.bcachefs") ;; WRAP-SCRIPT causes bogus ‘Insufficient arguments’ errors. (wrap-program "mount.bcachefs" `("PATH" ":" prefix - ,(list (string-append #$output "/sbin") - (string-append #$coreutils-minimal "/bin") - (string-append #$gawk "/bin") - (string-append #$util-linux "/bin")))))))))) + ,(list (getcwd) + (whence "bin/tail") + (whence "bin/awk") + (whence "bin/mount")))))))))) (native-inputs (append (list pkg-config -- cgit v1.2.3