diff options
author | Sam James <sam@gentoo.org> | 2023-03-07 15:43:32 +0000 |
---|---|---|
committer | Sam James <sam@gentoo.org> | 2023-03-07 15:43:46 +0000 |
commit | de2ae2e9c4a1525ddf806a24e081e075655e5be7 (patch) | |
tree | 844afe06285aa5a0dda7d2322b914bd1c60805e3 /sys-fs | |
parent | profiles/arch/sparc: mask dev-python/nbdime[webtools] (diff) | |
download | gentoo-de2ae2e9c4a1525ddf806a24e081e075655e5be7.tar.gz gentoo-de2ae2e9c4a1525ddf806a24e081e075655e5be7.tar.bz2 gentoo-de2ae2e9c4a1525ddf806a24e081e075655e5be7.zip |
sys-fs/btrfs-progs: add 6.2.1
Signed-off-by: Sam James <sam@gentoo.org>
Diffstat (limited to 'sys-fs')
-rw-r--r-- | sys-fs/btrfs-progs/Manifest | 1 | ||||
-rw-r--r-- | sys-fs/btrfs-progs/btrfs-progs-6.2.1.ebuild | 165 | ||||
-rw-r--r-- | sys-fs/btrfs-progs/files/btrfs-progs-6.2.1-blake2-simd.patch | 44 |
3 files changed, 210 insertions, 0 deletions
diff --git a/sys-fs/btrfs-progs/Manifest b/sys-fs/btrfs-progs/Manifest index 7fcf3715e6cb..14940f3e52ec 100644 --- a/sys-fs/btrfs-progs/Manifest +++ b/sys-fs/btrfs-progs/Manifest @@ -3,3 +3,4 @@ DIST btrfs-progs-v6.0.2.tar.xz 2321220 BLAKE2B 391bd9dcc7ae2d40c339eb9b7fb466624 DIST btrfs-progs-v6.1.1.tar.xz 2329864 BLAKE2B f3f15829af88f83cdabca30b61dd0e53fc0913615028eac9501204adec5a5beb8654b037617a73bac96c901835a83e8c08d478b8b496518512fea3714e604cfc SHA512 996045bebc441eba269eb5159d6d13c7b1471ba88039389ef221f57d03c535647a5716e23e7a17a20efb4012003f58b4b768f66af633abbdc1fe481192ca1ace DIST btrfs-progs-v6.1.2.tar.xz 2329940 BLAKE2B d2c86b0077e0269353ac70d948b948dd2984beec0e4225529adb0099a9cfe5d778a893bedc822168141ce29679f66500e32bdf3af8973bef5696657685ebf712 SHA512 0b02502f9f0902b7db04817fcfbaa4f6155035d47dd908c4c1faa86e4677e302d069756bb0935db7c88f0859c0f9ef87975b2777be7ad7f4d2389d2e95c1ff82 DIST btrfs-progs-v6.1.3.tar.xz 2333984 BLAKE2B 71543f5be282a289fbc92f78b89b25e4162c3cbd2d3cf2e8564791f86c6f933f61c03ba93aeca029689be6284988ff35a47f25a6523f15be47f3e7ce9b5c0c4b SHA512 7c40d8bc3fcef0b2a7bf4be7d52923015b5b11c3f14bfc550ffa95a47d673f640b7deb840fee22fb7cc2743b6098fb12b5caea586fbf0972a1bc9a7606f3f375 +DIST btrfs-progs-v6.2.1.tar.xz 2415064 BLAKE2B 8ea7d9815e34c569dd82e53dc1f982c820265521708c7c41dc587646362b300edf938e940b52508e301874269ea5ebb96605f4a1046d096678257463ced53b03 SHA512 2a485d8c8b3091af27e91751cabe61306388526de3c1c51543708888ddee1bb26ebfe70c3b4cd6686b173d313c98c30168fee18723dadc7b4c00e10c502da169 diff --git a/sys-fs/btrfs-progs/btrfs-progs-6.2.1.ebuild b/sys-fs/btrfs-progs/btrfs-progs-6.2.1.ebuild new file mode 100644 index 000000000000..f89547b3aa45 --- /dev/null +++ b/sys-fs/btrfs-progs/btrfs-progs-6.2.1.ebuild @@ -0,0 +1,165 @@ +# Copyright 2008-2023 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +PYTHON_COMPAT=( python3_{9..11} ) + +inherit bash-completion-r1 python-single-r1 udev + +libbtrfs_soname=0 + +if [[ ${PV} != 9999 ]]; then + MY_PV="v${PV/_/-}" + SRC_URI="https://www.kernel.org/pub/linux/kernel/people/kdave/${PN}/${PN}-${MY_PV}.tar.xz" + + if [[ ${PV} != *_rc* ]] ; then + KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~ia64 ~loong ~mips ~ppc ~ppc64 ~riscv ~sparc ~x86" + fi + + S="${WORKDIR}"/${PN}-${MY_PV} +else + EGIT_REPO_URI="https://github.com/kdave/btrfs-progs.git" + EGIT_BRANCH="devel" + WANT_LIBTOOL="none" + inherit autotools git-r3 +fi + +DESCRIPTION="Btrfs filesystem utilities" +HOMEPAGE="https://btrfs.wiki.kernel.org https://btrfs.readthedocs.io/en/latest/" + +LICENSE="GPL-2" +SLOT="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 )" + +# 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 )" + +if [[ ${PV} == 9999 ]]; then + BDEPEND+=" sys-devel/gnuconfig" +fi + +REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )" + +PATCHES=( + "${FILESDIR}"/${PN}-6.2.1-blake2-simd.patch +) + +pkg_setup() { + use python && python-single-r1_pkg_setup +} + +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 + --with-crypto=builtin + --with-convert=ext2$(usex reiserfs ',reiserfs' '') + ) + + econf "${myeconfargs[@]}" +} + +src_compile() { + emake V=1 all $(usev static) +} + +src_test() { + default + + 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 + fi +} + +src_install() { + local makeargs=( + $(usex python install_python '') + $(usex 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/files/btrfs-progs-6.2.1-blake2-simd.patch b/sys-fs/btrfs-progs/files/btrfs-progs-6.2.1-blake2-simd.patch new file mode 100644 index 000000000000..f2531135c5c4 --- /dev/null +++ b/sys-fs/btrfs-progs/files/btrfs-progs-6.2.1-blake2-simd.patch @@ -0,0 +1,44 @@ +https://github.com/kdave/btrfs-progs/issues/589 +https://github.com/kdave/btrfs-progs/pull/591 + +From c7e7e2568b073b6a501eef515f3a4b6402a71211 Mon Sep 17 00:00:00 2001 +From: Tino Mai <mai.tino@gmail.com> +Date: Sun, 5 Mar 2023 18:15:52 +0100 +Subject: [PATCH] btrfs-progs: crypto: fix SSE2/SSE4.1 implementation of BLAKE2 + +--- a/crypto/blake2b-round.h ++++ b/crypto/blake2b-round.h +@@ -136,12 +136,6 @@ + + #endif + +-#if defined(HAVE_SSE41) +-#include "blake2b-load-sse41.h" +-#else +-#include "blake2b-load-sse2.h" +-#endif +- + #define ROUND(r) \ + LOAD_MSG_ ##r ##_1(b0, b1); \ + G1(row1l,row2l,row3l,row4l,row1h,row2h,row3h,row4h,b0,b1); \ +--- a/crypto/blake2b-sse2.c ++++ b/crypto/blake2b-sse2.c +@@ -30,6 +30,7 @@ + #include <x86intrin.h> + #endif + ++#include "blake2b-load-sse2.h" + #include "blake2b-round.h" + + static const uint64_t blake2b_IV[8] = +--- a/crypto/blake2b-sse41.c ++++ b/crypto/blake2b-sse41.c +@@ -34,6 +34,7 @@ + #include <x86intrin.h> + #endif + ++#include "blake2b-load-sse41.h" + #include "blake2b-round.h" + + static const uint64_t blake2b_IV[8] = + |