repo/gentoo:master commit in: sys-fs/bcachefs-tools/

"Florian Schmaus" <[email protected]>
Newsgroups gmane.linux.gentoo.cvs
Message-ID <1786612223.ec8bef01613fdd3d059d4f495dfc9bbcade87eda.flow@gentoo>
commit:     ec8bef01613fdd3d059d4f495dfc9bbcade87eda
Author:     Florian Schmaus <flow <AT> gentoo <DOT> org>
AuthorDate: Thu Aug 13 09:08:28 2026 +0000
Commit:     Florian Schmaus <flow <AT> gentoo <DOT> org>
CommitDate: Thu Aug 13 09:10:23 2026 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=ec8bef01

sys-fs/bcachefs-tools: add 1.39.1

Signed-off-by: Florian Schmaus <flow <AT> gentoo.org>

 sys-fs/bcachefs-tools/Manifest                     |   2 +
 sys-fs/bcachefs-tools/bcachefs-tools-1.39.1.ebuild | 382 +++++++++++++++++++++
 2 files changed, 384 insertions(+)

diff --git a/sys-fs/bcachefs-tools/Manifest b/sys-fs/bcachefs-tools/Manifest
index 8523fa7438d7..ae1422738fc8 100644
--- a/sys-fs/bcachefs-tools/Manifest
+++ b/sys-fs/bcachefs-tools/Manifest
@@ -31,6 +31,8 @@ DIST bcachefs-tools-1.38.8.tar.sign 833 BLAKE2B 437da08e8f7583fd5a24eb78a49c5348
 DIST bcachefs-tools-1.38.8.tar.zst 2881506 BLAKE2B 64b56e9f2fbb90392c19b1b826153ca23a0ec75e94853d503638680afbc620422835123f0e34f046e4f8c0833e75dec048ee848d602b0eb294ba81d5682f6ccb SHA512 b17df097e4ca2fea22a3b7e943f25d2fc54cc9bf06fd19028e7e23ba2923218874f682a8c4d3bb58da0002712033010aec82469dc310a2d3110c4017094bdbde
 DIST bcachefs-tools-1.39.0.tar.sign 833 BLAKE2B 782e2eff6ac716764885da0be7a5c2300cf6ca045361f9f7ffa3fbcc276d53a163ce947540d17b607e5932a2abf76da38d00eab6a200b0b557048be3362ce5c1 SHA512 d4b8091e5c11576d0c9d38be14138b92d7514e33b1847729602fe3242c9ae731eed7eb09bccffdc8ed6085de77e301243caa9708cefcb1333ae270749f70a89e
 DIST bcachefs-tools-1.39.0.tar.zst 3064489 BLAKE2B b99eea18c4b9e95b9198f37a3d25b79ce74f34ac039def598dbc0b4dd95a48562cd66fb35da93512c1a5d9477724f8fd75aa1450a60f3eba310079c013fed0f3 SHA512 8dbcaa1bdcfe0346be18f008b7891061766dec7c7f9b738bdcd9687e3f992148288ad58896cdda67fcfdc30adf9e630c0a9e29d42044b81a14c050c942f38f5c
+DIST bcachefs-tools-1.39.1.tar.sign 833 BLAKE2B f55c85dbdcf8a4ae2b5b0ad7a3e7b7bac2d8073ce65c8b5a8e62d95f54fd880c036ae7745272d24bb8019e3bed484455524865223200f5f245da4f3fb914c7e5 SHA512 a472b946ad5961ae0484b5957f5b1480b0e50148c4ac84f5bf0e962c534c817f9e136c4b1df5ee45c7c71e11c08a2fbafc7bb0ad3d2ffddd3c4fea0f2c09b4ab
+DIST bcachefs-tools-1.39.1.tar.zst 3083008 BLAKE2B d75a9bab36b243a8c54af0a3771fe813b657ad71124bf73b800cd22544e8395b34f0967226e03d2fee97b62818f05c840089291d0d9745b12fc00efea903f1e4 SHA512 62a4ce9e52a61a0b929c09b2d68c67533dfa5d3ac1aa775e8d45e96a5740e76025a1b0fa59d93def1b1a92fb50358ac560488ecb141d495ff34a70afaa237f71
 DIST bindgen-0.69.5.crate 221128 BLAKE2B b89edbf883e1bc11a074c2f37f84bb966749823a6408b9765d6a61ee1179451d67dadde41d27838e8ddc6172dee9c342429f42fbe6959ff9fd7dcbc73d7506ea SHA512 b232b906af7535f8b87198f0a4037a0f09af367e0c913575f3d16453a2c272e7d76033cb3fd12d4223ebda4a0f8130629e67c5883e026a2422db3e0659ed3c3f
 DIST bindgen-0.72.1.crate 246071 BLAKE2B b6db53ca86fa3b5f71abbf6d2fd5f83553e167507db2e869ed7f3acf8865478e49430eddce8c255a8fabf8f6e408e7dcc78a9088201cdeea1e48bc387f8a6f28 SHA512 14f4277b62cfc91661400ed1bacb82a9f28b7e6caa17dd4bb4dbeedd5784299d5915c2235af9da42a8a216fa0b14b49f1e38eaa530f1e906bcd74f864ae8a7e2
 DIST bitfield-0.14.0.crate 16776 BLAKE2B abca546581d912133e7344f049d93b8d793de323eba7780fab162c53a244b845582ec2bd14b529b9491c363c2da6228b7de58407afc554cc718a9df8370f5535 SHA512 703d534f0684b19af68a18048ecff37367ccbe5a52a3e8d987f2420b980e4a20da9640019ca610b1a73841cbe45dbf4d6a1cfb10cf0e7d09f53199b1fcd141fe

diff --git a/sys-fs/bcachefs-tools/bcachefs-tools-1.39.1.ebuild b/sys-fs/bcachefs-tools/bcachefs-tools-1.39.1.ebuild
new file mode 100644
index 000000000000..e7f5525662d2
--- /dev/null
+++ b/sys-fs/bcachefs-tools/bcachefs-tools-1.39.1.ebuild
@@ -0,0 +1,382 @@
+# Copyright 1999-2026 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+CRATES="
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]+spec-1.1.0
+	[email protected]+spec-1.1.0
+	[email protected]+spec-1.1.0
+	[email protected]+spec-1.1.0
+	[email protected]+spec-1.1.0
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]+wasi-snapshot-preview1
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+	[email protected]
+"
+
+LLVM_COMPAT=( {17..21} )
+MODULES_INITRAMFS_IUSE=+initramfs
+MODULES_KERNEL_MIN=6.16
+MODULES_OPTIONAL_IUSE=+modules
+PYTHON_COMPAT=( python3_{11..14} )
+RUST_MIN_VER="1.85.0"
+VERIFY_SIG_OPENPGP_KEY_PATH=/usr/share/openpgp-keys/kentoverstreet.asc
+
+inherit cargo flag-o-matic linux-mod-r1 llvm-r2 python-any-r1
+inherit shell-completion sysroot toolchain-funcs unpacker verify-sig
+
+DESCRIPTION="Tools for bcachefs"
+HOMEPAGE="https://bcachefs.org/"
+if [[ ${PV} == "9999" ]]; then
+	inherit git-r3
+	EGIT_REPO_URI="https://evilpiepirate.org/git/bcachefs-tools.git"
+else
+	SRC_URI="https://evilpiepirate.org/bcachefs-tools/bcachefs-tools-${PV}.tar.zst
+		${CARGO_CRATE_URIS}
+	"
+	SRC_URI+=" verify-sig? ( https://evilpiepirate.org/bcachefs-tools/bcachefs-tools-${PV}.tar.sign )"
+	S="${WORKDIR}/${P}"
+	KEYWORDS="~amd64 ~arm64"
+fi
+
+LICENSE="GPL-2"
+# Dependent crate licenses
+LICENSE+=" Apache-2.0 BSD ISC MIT Unicode-DFS-2016"
+SLOT="0"
+IUSE="debug llvm-libunwind verify-sig"
+RESTRICT="test"
+
+DEPEND="
+	app-arch/lz4:=
+	app-arch/zstd:=
+	dev-libs/libaio
+	dev-libs/libsodium:=
+	dev-libs/userspace-rcu:=
+	sys-apps/keyutils:=
+	sys-apps/util-linux
+	llvm-libunwind? ( llvm-runtimes/libunwind:= )
+	!llvm-libunwind? ( sys-libs/libunwind:= )
+	virtual/udev
+	virtual/zlib:=
+"
+
+RDEPEND="${DEPEND}"
+
+# Clang is required for bindgen
+BDEPEND="
+	${PYTHON_DEPS}
+	$(python_gen_any_dep '
+		dev-python/docutils[${PYTHON_USEDEP}]
+	')
+	$(unpacker_src_uri_depends)
+	$(llvm_gen_dep '
+		llvm-core/clang:${LLVM_SLOT}
+	')
+	elibc_musl? ( >=sys-libs/musl-1.2.5 )
+	virtual/pkgconfig
+	modules? ( >=sys-kernel/linux-headers-6.16.0 )
+	verify-sig? ( >=sec-keys/openpgp-keys-kentoverstreet-20241012 )
+"
+
+QA_FLAGS_IGNORED="/sbin/bcachefs"
+
+python_check_deps() {
+	python_has_version "dev-python/docutils[${PYTHON_USEDEP}]"
+}
+
+pkg_setup() {
+	llvm-r2_pkg_setup
+	python-any-r1_pkg_setup
+	rust_pkg_setup
+	if use modules; then
+		# grep -r 'depends on\|select ' ${S}/libbcachefs/Kconfig | grep -v '^#'
+		local CONFIG_CHECK="
+			!BCACHEFS_FS
+			BLOCK
+			EXPORTFS
+			CRC32
+			CRC64
+			FS_POSIX_ACL
+			LZ4_COMPRESS
+			LZ4_DECOMPRESS
+			LZ4HC_COMPRESS
+			ZLIB_DEFLATE
+			ZLIB_INFLATE
+			ZSTD_COMPRESS
+			ZSTD_DECOMPRESS
+			CRYPTO_LIB_SHA256
+			CRYPTO_LIB_CHACHA
+			CRYPTO_LIB_POLY1305
+			KEYS
+			RAID6_PQ
+			RUST
+			XOR_BLOCKS
+			XXHASH
+			SYMBOLIC_ERRNAME
+		"
+		use debug && CONFIG_CHECK+="
+			DEBUG_INFO
+			FRAME_POINTER
+			!DEBUG_INFO_REDUCED
+		"
+		linux-mod-r1_pkg_setup
+	fi
+}
+
+src_unpack() {
+	if [[ ${PV} == "9999" ]]; then
+		git-r3_src_unpack
+		S="${S}/src" cargo_live_src_unpack
+	else
+		# Upstream signs the uncompressed tarball
+		if use verify-sig; then
+			einfo "Unpacking ${P}.tar.zst ..."
+			verify-sig_verify_detached - "${DISTDIR}"/${P}.tar.sign \
+				< <(zstd -fdc "${DISTDIR}"/${P}.tar.zst | tee >(tar -xf -))
+			assert "Unpack failed"
+		fi
+		unpacker ${P}.tar.zst
+		cargo_src_unpack
+	fi
+
+}
+
+src_prepare() {
+	default
+	tc-export CC
+
+	echo "${PV}" > .version || die
+	sed \
+		-e '/^CFLAGS/s:-O2::' \
+		-e '/^CFLAGS/s:-g::' \
+		-i Makefile || die
+
+	if use llvm-libunwind; then
+		sed -i s/libunwind// Makefile || die
+	fi
+
+	append-lfs-flags
+}
+
+src_configure() {
+	cargo_src_configure
+
+	MODULE_SRC="module/${PN%-*}-${PV}"
+	use modules && emake DESTDIR="${WORKDIR}" DKMSDIR="/${MODULE_SRC}" install_dkms
+}
+
+src_compile() {
+	export BUILD_VERBOSE=1
+	export VERSION=${PV}
+
+	local modlist=( "bcachefs=:../${MODULE_SRC}:../${MODULE_SRC}/src/fs/bcachefs" )
+	local modargs=(
+		KDIR=${KV_OUT_DIR}
+	)
+
+	# Makefile calls `cargo` directly, so make sure we set our rustflags (etc)
+	cargo_env emake bcachefs || die
+	use modules && linux-mod-r1_src_compile
+
+	# Recent versions mangle the 'bcachefs' symbolic link, work around it.
+	[[ -e bcachefs ]] && die "bcachefs symlink is valid, please remove workaround"
+	ln -rsf target/release/bcachefs bcachefs || die
+
+	local shell
+	for shell in bash fish zsh; do
+		sysroot_try_run_prefixed ./bcachefs completions ${shell} > ${shell}.completion || die
+	done
+}
+
+src_install() {
+	into /
+	dosbin bcachefs
+
+	dosym bcachefs /sbin/fsck.bcachefs
+	dosym bcachefs /sbin/mkfs.bcachefs
+	dosym bcachefs /sbin/mount.bcachefs
+
+	# Uses a crate-based implementation of FUSE, no dependency on sys-fs/fuse and unconditionally included.
+	dosym bcachefs /sbin/fsck.fuse.bcachefs
+	dosym bcachefs /sbin/mkfs.fuse.bcachefs
+	dosym bcachefs /sbin/mount.fuse.bcachefs
+
+	newbashcomp bash.completion bcachefs
+	newfishcomp fish.completion bcachefs.fish
+	newzshcomp zsh.completion _bcachefs
+
+	doman bcachefs.8
+
+	use modules && linux-mod-r1_src_install
+}
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.