24 pname = "bcachefs-tools";
25 version = "unstable-2022-09-28";
27 src = fetchFromGitHub {
28 owner = "koverstreet";
29 repo = "bcachefs-tools";
30 rev = "99caca2c70f312c4a2504a7e7a9c92a91426d885";
31 sha256 = "sha256-9bFTBFkQq8SvhYa9K4+MH2zvKZviNaq0sFWoeGgch7g=";
36 substituteInPlace Makefile \
37 --replace "pytest-3" "pytest --verbose" \
38 --replace "INITRAMFS_DIR=/etc/initramfs-tools" \
39 "INITRAMFS_DIR=${placeholder "out"}/etc/initramfs-tools"
42 nativeBuildInputs = [ pkg-config docutils python3Packages.python ];
45 libuuid libscrypt libsodium keyutils liburcu zlib libaio
46 zstd lz4 python3Packages.pytest udev valgrind
47 ] ++ lib.optional fuseSupport fuse3;
49 doCheck = false; # needs bcachefs module loaded on builder
50 checkFlags = [ "BCACHEFS_TEST_USE_VALGRIND=no" ];
51 checkInputs = [ valgrind ];
53 preCheck = lib.optionalString fuseSupport ''
57 installFlags = [ "PREFIX=${placeholder "out"}" ];
60 smoke-test = nixosTests.bcachefs;
61 inherit (nixosTests.installer) bcachefsSimple bcachefsEncrypted bcachefsMulti;
64 enableParallelBuilding = true;
67 description = "Tool for managing bcachefs filesystems";
68 homepage = "https://bcachefs.org/";
69 license = licenses.gpl2;
70 maintainers = with maintainers; [ davidak Madouura ];
71 platforms = platforms.linux;