diff options
Diffstat (limited to 'gnu/packages/file-systems.scm')
-rw-r--r-- | gnu/packages/file-systems.scm | 42 |
1 files changed, 27 insertions, 15 deletions
diff --git a/gnu/packages/file-systems.scm b/gnu/packages/file-systems.scm index e97013dce3..63de393851 100644 --- a/gnu/packages/file-systems.scm +++ b/gnu/packages/file-systems.scm @@ -575,11 +575,11 @@ from a mounted file system.") (license license:gpl2+))) (define-public bcachefs-tools - (let ((commit "c8bec83e307f28751c433ba1d3f648429fb5a34c") - (revision "17")) + (let ((commit "1e358401ecdf1963e5799de19ab69111e82e5ebc") + (revision "0")) (package (name "bcachefs-tools") - (version (git-version "0.1" revision commit)) + (version (git-version "1.2" revision commit)) (source (origin (method git-fetch) @@ -588,7 +588,7 @@ from a mounted file system.") (commit commit))) (file-name (git-file-name name version)) (sha256 - (base32 "0b1avy5mw3r3ppfs3n9cq4zb74yl45nd5l69r6hi27z9q5bc3nv8")))) + (base32 "0bflgqb3q9jikyyrv6hywv6m1fapzzn874hlhf86pn6abxrlf5fa")))) (build-system gnu-build-system) (arguments (list #:make-flags @@ -620,16 +620,23 @@ from a mounted file system.") "not test_list and " "not test_list_inodes and " "not test_list_dirent"))))) - (add-after 'install 'patch-shell-wrappers - ;; These are overcomplicated wrappers that invoke readlink(1) - ;; to exec the appropriate bcachefs(8) subcommand. We can - ;; simply patch in the latter file name directly, and do. - (lambda _ - (let ((sbin/ (string-append #$output "/sbin/"))) - (substitute* (find-files sbin/ (lambda (file stat) - (not (elf-file? file)))) - (("SDIR=.*") "") - (("\\$\\{SDIR.*}/") sbin/)))))))) + (add-after 'install 'promote-mount.bcachefs.sh + ;; The (optional) ‘mount.bcachefs’ requires rust:cargo. + ;; This shell alternative does the job well enough for now. + (lambda* (#:key inputs #:allow-other-keys) + (define (whence file) + (dirname (search-input-file inputs file))) + (let ((mount (string-append #$output + "/sbin/mount.bcachefs"))) + (delete-file mount) ; symlink to ‘bcachefs’ + (copy-file "mount.bcachefs.sh" mount) + ;; WRAP-SCRIPT causes bogus ‘Insufficient arguments’ errors. + (wrap-program mount + `("PATH" ":" prefix + ,(list (getcwd) + (whence "bin/tail") + (whence "bin/awk") + (whence "bin/mount")))))))))) (native-inputs (cons* pkg-config ;; For generating documentation with rst2man. @@ -650,7 +657,12 @@ from a mounted file system.") `(,util-linux "lib") lz4 zlib - `(,zstd "lib"))) + `(,zstd "lib") + + ;; Only for mount.bcachefs.sh. + coreutils-minimal + gawk + util-linux)) (home-page "https://bcachefs.org/") (synopsis "Tools to create and manage bcachefs file systems") (description |