summaryrefslogtreecommitdiff
path: root/sys-fs
diff options
context:
space:
mode:
authorSam James <sam@gentoo.org>2024-02-02 01:27:49 +0000
committerSam James <sam@gentoo.org>2024-02-02 01:51:15 +0000
commite83797504d4a7b1490c576417b151875b7ed6653 (patch)
tree609cdaba9bac954c89cdf295aeec04af784b97b8 /sys-fs
parentdev-util/ruff: add 0.2.0, drop 0.1.14 (diff)
downloadgentoo-e83797504d4a7b1490c576417b151875b7ed6653.tar.gz
gentoo-e83797504d4a7b1490c576417b151875b7ed6653.tar.bz2
gentoo-e83797504d4a7b1490c576417b151875b7ed6653.zip
sys-fs/btrfs-progs: add 6.7
Signed-off-by: Sam James <sam@gentoo.org>
Diffstat (limited to 'sys-fs')
-rw-r--r--sys-fs/btrfs-progs/Manifest2
-rw-r--r--sys-fs/btrfs-progs/btrfs-progs-6.7.ebuild198
-rw-r--r--sys-fs/btrfs-progs/btrfs-progs-9999.ebuild2
3 files changed, 201 insertions, 1 deletions
diff --git a/sys-fs/btrfs-progs/Manifest b/sys-fs/btrfs-progs/Manifest
index 62f8ce882dd2..f84fac02736a 100644
--- a/sys-fs/btrfs-progs/Manifest
+++ b/sys-fs/btrfs-progs/Manifest
@@ -1,3 +1,5 @@
DIST btrfs-progs-v6.6.2.tar.xz 2550624 BLAKE2B c4901b14c1555a62ec5fdc9c744b48678427c52250d368d2f3e9b82e300bd0f2c1bcbae12169ab0376fdf0aff5ccf41139ae83d8851555ce4b2d671e82d116a3 SHA512 23878cdd6f16a7ddba55321169bf7dd565719dd5d16a5a47fb7879aa0e04bd9008dc436cdbb712cee286b3a9b97ac3a4f6ea22213286a5025b5371d7975a2fa8
DIST btrfs-progs-v6.6.3.tar.sign 566 BLAKE2B 9f8a14405f78c8eb5a92d59f9ca776cd15bfd43bc323a0f5a98cc2d9a6f782e999a792ddb266fef4dfe189e1cb8eebbd021a12b615e22bdd4097a74bf3b277a9 SHA512 07f062cf66c0e5f0bd833f0a1c9901ec06ac4eb258acec8e96ffbb0b85007a67bdc992492b25f6039fcf603352131fca8c57162fa61007e8ccf1f4edf71dab97
DIST btrfs-progs-v6.6.3.tar.xz 2557216 BLAKE2B 274fad52bcab45bd0f6496c1bc10e1736e7b766f53b712790996a8a38f74eedcc570783599bed62cd4f84e5629f2216340a66941d9fbe0c7890f1c56ed66df8a SHA512 93e1defacf0f280fc02e10a20fd2bc3775c52956a0339e30b829cc3bef85629d565cf3f6a9af126e38bbb73e8e9b9a0069abbe0e57957a56ca1a8826f5de624a
+DIST btrfs-progs-v6.7.tar.sign 566 BLAKE2B 227146a66ef60b6ecc6dadcb5a6d91f93f2ca5cce2ef808016978e610da6eb65c34b5831e558bc4d3907de027a54068aacf4122c7be0ba3a0bbbf74edff721a9 SHA512 13638ebc79b05a91ed1588e999c37fbdf8bde9bc8ab9c8821720ff6d1b98334af354ee5de7ca13897c94dbcf036d09c122768ea7350e86829ddfb03be45761c3
+DIST btrfs-progs-v6.7.tar.xz 2560468 BLAKE2B fd9805bcd9519ffd4d98316b657d3c9444633feef6d7dcd031036a4c7268de359049c8231dfe27a29853047d50e9b7aeb020ba33e66f7d051ac8d3b6d030065b SHA512 2f60fad3b8e12d549cc032935e35d73228034506f0a6687c0b678e12d791d658605f9918f59c0e9d4a4d43c6a7b26713d1d31f0b6bafc9e77c4acfd8cc9bbb68
diff --git a/sys-fs/btrfs-progs/btrfs-progs-6.7.ebuild b/sys-fs/btrfs-progs/btrfs-progs-6.7.ebuild
new file mode 100644
index 000000000000..c9770f5998ae
--- /dev/null
+++ b/sys-fs/btrfs-progs/btrfs-progs-6.7.ebuild
@@ -0,0 +1,198 @@
+# Copyright 2008-2024 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+PYTHON_COMPAT=( python3_{10..12} )
+inherit bash-completion-r1 python-single-r1 udev
+
+if [[ ${PV} == 9999 ]]; then
+ EGIT_REPO_URI="https://github.com/kdave/btrfs-progs.git"
+ EGIT_BRANCH="devel"
+ WANT_LIBTOOL="none"
+ inherit autotools git-r3
+else
+ VERIFY_SIG_OPENPGP_KEY_PATH=/usr/share/openpgp-keys/dsterba.asc
+ inherit verify-sig
+
+ MY_PV="v${PV/_/-}"
+ MY_P="${PN}-${MY_PV}"
+ SRC_URI="
+ https://www.kernel.org/pub/linux/kernel/people/kdave/${PN}/${MY_P}.tar.xz
+ verify-sig? ( https://www.kernel.org/pub/linux/kernel/people/kdave/${PN}/${MY_P}.tar.sign )
+ "
+ S="${WORKDIR}"/${PN}-${MY_PV}
+
+ if [[ ${PV} != *_rc* ]] ; then
+ KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~ia64 ~loong ~mips ~ppc ~ppc64 ~riscv ~sparc ~x86"
+ fi
+fi
+
+DESCRIPTION="Btrfs filesystem utilities"
+HOMEPAGE="https://btrfs.readthedocs.io/en/latest/"
+
+LICENSE="GPL-2"
+SLOT="0/0" # libbtrfs soname
+IUSE="+convert python +man reiserfs static static-libs udev +zstd"
+# Could support it with just !systemd => eudev, see mdadm, but let's
+# see if someone asks for it first.
+REQUIRED_USE="static? ( !udev ) python? ( ${PYTHON_REQUIRED_USE} )"
+
+# Tries to mount repaired filesystems
+RESTRICT="test"
+
+RDEPEND="
+ dev-libs/lzo:2=
+ sys-apps/util-linux:=[static-libs(+)?]
+ sys-libs/zlib:=
+ convert? (
+ sys-fs/e2fsprogs:=
+ reiserfs? (
+ >=sys-fs/reiserfsprogs-3.6.27
+ )
+ )
+ python? ( ${PYTHON_DEPS} )
+ udev? ( virtual/libudev:= )
+ zstd? ( app-arch/zstd:= )
+"
+DEPEND="
+ ${RDEPEND}
+ >=sys-kernel/linux-headers-5.10
+ convert? ( sys-apps/acl )
+ python? (
+ $(python_gen_cond_dep '
+ dev-python/setuptools[${PYTHON_USEDEP}]
+ ')
+ )
+ static? (
+ dev-libs/lzo:2[static-libs(+)]
+ sys-apps/util-linux:0[static-libs(+)]
+ sys-libs/zlib:0[static-libs(+)]
+ convert? (
+ sys-fs/e2fsprogs[static-libs(+)]
+ reiserfs? (
+ >=sys-fs/reiserfsprogs-3.6.27[static-libs(+)]
+ )
+ )
+ zstd? ( app-arch/zstd[static-libs(+)] )
+ )
+"
+BDEPEND="
+ virtual/pkgconfig
+ man? (
+ dev-python/sphinx
+ dev-python/sphinx-rtd-theme
+ )
+"
+
+if [[ ${PV} == 9999 ]]; then
+ BDEPEND+=" sys-devel/gnuconfig"
+else
+ BDEPEND+=" verify-sig? ( sec-keys/openpgp-keys-dsterba )"
+fi
+
+pkg_setup() {
+ use python && python-single-r1_pkg_setup
+}
+
+src_unpack() {
+ if [[ ${PV} == 9999 ]] ; then
+ git-r3_src_unpack
+ return
+ fi
+
+ if in_iuse verify-sig && use verify-sig ; then
+ mkdir "${T}"/verify-sig || die
+ pushd "${T}"/verify-sig &>/dev/null || die
+
+ # Upstream sign the decompressed .tar
+ # Let's do it separately in ${T} then cleanup to avoid external
+ # effects on normal unpack.
+ cp "${DISTDIR}"/${MY_P}.tar.xz . || die
+ xz -d ${MY_P}.tar.xz || die
+ verify-sig_verify_detached ${MY_P}.tar "${DISTDIR}"/${MY_P}.tar.sign
+
+ popd &>/dev/null || die
+ rm -r "${T}"/verify-sig || die
+ fi
+
+ default
+}
+
+src_prepare() {
+ default
+
+ if [[ ${PV} == 9999 ]]; then
+ AT_M4DIR="m4" eautoreconf
+
+ mkdir config || die
+ local automakedir="$(autotools_run_tool --at-output automake --print-libdir)"
+ [[ -e ${automakedir} ]] || die "Could not locate automake directory"
+
+ ln -s "${automakedir}"/install-sh config/install-sh || die
+ ln -s "${BROOT}"/usr/share/gnuconfig/config.guess config/config.guess || die
+ ln -s "${BROOT}"/usr/share/gnuconfig/config.sub config/config.sub || die
+ fi
+}
+
+src_configure() {
+ local myeconfargs=(
+ --bindir="${EPREFIX}"/sbin
+
+ --enable-lzo
+ --disable-experimental
+ $(use_enable convert)
+ $(use_enable man documentation)
+ $(use_enable elibc_glibc backtrace)
+ $(use_enable python)
+ $(use_enable static-libs static)
+ $(use_enable udev libudev)
+ $(use_enable zstd)
+
+ # Could support libgcrypt, libsodium, libkcapi, openssl, botan
+ --with-crypto=builtin
+ --with-convert=ext2$(usev reiserfs ',reiserfs')
+ )
+
+ export EXTRA_PYTHON_CFLAGS="${CFLAGS}"
+ export EXTRA_PYTHON_LDFLAGS="${LDFLAGS}"
+
+ # bash as a tepmorary workaround for https://github.com/kdave/btrfs-progs/pull/721
+ CONFIG_SHELL="${BROOT}"/bin/bash econf "${myeconfargs[@]}"
+}
+
+src_compile() {
+ emake V=1 all $(usev static)
+}
+
+src_test() {
+ emake V=1 -j1 -C tests test
+
+ if use python ; then
+ cd libbtrfsutil/python || die
+
+ local -x LD_LIBRARY_PATH="${S}:libbtrfsutil/python:${LD_LIBRARY_PATH}"
+ ${EPYTHON} -m unittest tests/test_*.py || die "Tests failed with ${EPYTHON}"
+ fi
+}
+
+src_install() {
+ local makeargs=(
+ $(usev python install_python)
+ $(usev static install-static)
+ )
+
+ emake V=1 DESTDIR="${D}" install "${makeargs[@]}"
+
+ newbashcomp btrfs-completion btrfs
+
+ use python && python_optimize
+}
+
+pkg_postinst() {
+ udev_reload
+}
+
+pkg_postrm() {
+ udev_reload
+}
diff --git a/sys-fs/btrfs-progs/btrfs-progs-9999.ebuild b/sys-fs/btrfs-progs/btrfs-progs-9999.ebuild
index 3bf885a87641..c9770f5998ae 100644
--- a/sys-fs/btrfs-progs/btrfs-progs-9999.ebuild
+++ b/sys-fs/btrfs-progs/btrfs-progs-9999.ebuild
@@ -1,4 +1,4 @@
-# Copyright 2008-2023 Gentoo Authors
+# Copyright 2008-2024 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8