From 3c171c04336e3aebae12c218895ae73068b35ac8 Mon Sep 17 00:00:00 2001 From: V3n3RiX Date: Wed, 11 Sep 2024 19:54:53 +0100 Subject: sys-fs/zfs{,-utils} && sys-kernel/zfs-dkms : version bump --- sys-fs/zfs-utils/Manifest | 2 +- sys-fs/zfs-utils/files/2.2.2-no-USER_NS.patch | 39 +++++++++ sys-fs/zfs-utils/zfs-utils-2.2.4.ebuild | 99 ----------------------- sys-fs/zfs-utils/zfs-utils-2.2.6.ebuild | 112 ++++++++++++++++++++++++++ sys-fs/zfs/zfs-2.2.4.ebuild | 17 ---- sys-fs/zfs/zfs-2.2.6.ebuild | 17 ++++ 6 files changed, 169 insertions(+), 117 deletions(-) create mode 100644 sys-fs/zfs-utils/files/2.2.2-no-USER_NS.patch delete mode 100644 sys-fs/zfs-utils/zfs-utils-2.2.4.ebuild create mode 100644 sys-fs/zfs-utils/zfs-utils-2.2.6.ebuild delete mode 100644 sys-fs/zfs/zfs-2.2.4.ebuild create mode 100644 sys-fs/zfs/zfs-2.2.6.ebuild (limited to 'sys-fs') diff --git a/sys-fs/zfs-utils/Manifest b/sys-fs/zfs-utils/Manifest index f9b51cff..c17ea78f 100644 --- a/sys-fs/zfs-utils/Manifest +++ b/sys-fs/zfs-utils/Manifest @@ -1 +1 @@ -DIST zfs-2.2.4.tar.gz 33882933 BLAKE2B f0026a12b7c1252bf8941e39f23d3e165750034707dfddf034d8aac942a749cb7f0108478797ca978704a22743d9928240b29cf78fe89eda9f873f40102413f0 SHA512 1d17e30573d594fb5c9ea77cde104616dca362fed7530296816d1b55173594f66170fcfb23ab57c27074f85b79d3eb557b4ee9a1c420e507b2434a7902d8dcc1 +DIST zfs-2.2.6.tar.gz 33900138 BLAKE2B 0bbe36df779aaf19460a75725af9c9b13e64e77a6020974ad18d60d9fd52db2ddd6ea98b3e6c7451195bdfb347b8aab51db9b3f9a7c15c77bff47329bbd07dd2 SHA512 c217a3397b67d7239bc30bc492d58fff96bb29c9cf73e390d1787a4fb787cb297557e594a926453fed11faaab80363d40853af271f8ee18ce9a317dfde4c6745 diff --git a/sys-fs/zfs-utils/files/2.2.2-no-USER_NS.patch b/sys-fs/zfs-utils/files/2.2.2-no-USER_NS.patch new file mode 100644 index 00000000..b132db9d --- /dev/null +++ b/sys-fs/zfs-utils/files/2.2.2-no-USER_NS.patch @@ -0,0 +1,39 @@ +https://github.com/openzfs/zfs/issues/15241 +https://github.com/openzfs/zfs/pull/15560 + +From e0a7ec29d91b79adfd81073f229241351ed0ae21 Mon Sep 17 00:00:00 2001 +From: Ilkka Sovanto +Date: Wed, 22 Nov 2023 20:24:47 +0200 +Subject: [PATCH] Fix zoneid when USER_NS is disabled + +getzoneid() should return GLOBAL_ZONEID instead of 0 when USER_NS is disabled. + +Signed-off-by: Ilkka Sovanto +--- a/lib/libspl/os/linux/zone.c ++++ b/lib/libspl/os/linux/zone.c +@@ -42,20 +42,20 @@ getzoneid(void) + int c = snprintf(path, sizeof (path), "/proc/self/ns/user"); + /* This API doesn't have any error checking... */ + if (c < 0 || c >= sizeof (path)) +- return (0); ++ return (GLOBAL_ZONEID); + + ssize_t r = readlink(path, buf, sizeof (buf) - 1); + if (r < 0) +- return (0); ++ return (GLOBAL_ZONEID); + + cp = strchr(buf, '['); + if (cp == NULL) +- return (0); ++ return (GLOBAL_ZONEID); + cp++; + + unsigned long n = strtoul(cp, NULL, 10); + if (n == ULONG_MAX && errno == ERANGE) +- return (0); ++ return (GLOBAL_ZONEID); + zoneid_t z = (zoneid_t)n; + + return (z); + diff --git a/sys-fs/zfs-utils/zfs-utils-2.2.4.ebuild b/sys-fs/zfs-utils/zfs-utils-2.2.4.ebuild deleted file mode 100644 index 0545a209..00000000 --- a/sys-fs/zfs-utils/zfs-utils-2.2.4.ebuild +++ /dev/null @@ -1,99 +0,0 @@ -# Copyright 1999-2021 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=7 - -inherit bash-completion-r1 flag-o-matic pam toolchain-funcs udev - -MY_PN="zfs" -MY_P="${MY_PN}-${PV}" - -DESCRIPTION="Userland utilities for ZFS Linux kernel module" -HOMEPAGE="https://zfsonlinux.org/" - -SRC_URI="https://github.com/openzfs/${PN}/releases/download/${MY_P}/${MY_P}.tar.gz" -KEYWORDS="~amd64" -S="${WORKDIR}/${MY_P}" - -LICENSE="BSD-2 CDDL MIT" -SLOT="0" -IUSE="debug nls pam test-suite" - -DEPEND=" - net-libs/libtirpc:= - sys-apps/util-linux - sys-libs/zlib - virtual/libudev:= - dev-libs/openssl:0= - pam? ( sys-libs/pam ) -" - -BDEPEND="app-alternatives/awk - virtual/pkgconfig - nls? ( sys-devel/gettext ) -" - -RDEPEND="${DEPEND} - virtual/udev - sys-fs/udev-init-scripts - test-suite? ( - sys-apps/kmod[tools] - sys-apps/util-linux - sys-devel/bc - sys-block/parted - sys-fs/lsscsi - sys-fs/mdadm - sys-process/procps - ) -" - -RESTRICT="test" - -PATCHES=( - "${FILESDIR}"/2.1.5-dracut-zfs-missing.patch -) - -src_prepare() { - default - - # prevent errors showing up on zfs-mount stop, #647688 - # openrc will unmount all filesystems anyway. - sed -i "/^ZFS_UNMOUNT=/ s/yes/no/" "etc/default/zfs.in" || die -} - -src_configure() { - local myconf=( - --bindir="${EPREFIX}/bin" - --enable-shared - --disable-systemd - --enable-sysvinit - --localstatedir="${EPREFIX}/var" - --sbindir="${EPREFIX}/sbin" - --with-config=user - --with-dracutdir="${EPREFIX}/usr/lib/dracut" - --with-udevdir="$(get_udevdir)" - --with-pamconfigsdir="${EPREFIX}/unwanted_files" - --with-pammoduledir="$(getpam_mod_dir)" - --with-vendor=redcore - $(use_enable debug) - $(use_enable nls) - $(use_enable pam) - --disable-pyzfs - --disable-static - ) - - econf "${myconf[@]}" -} - -src_install() { - default - - gen_usr_ldscript -a nvpair uutil zfsbootenv zfs zfs_core zpool - dobashcomp contrib/bash_completion.d/zfs - bashcomp_alias zfs zpool - dodir etc/conf.d - insinto etc/conf.d - doins "${S}"/etc/default/zfs - use pam && { rm -rv "${ED}/unwanted_files" || die ; } - use test-suite || { rm -r "${ED}/usr/share/zfs" || die ; } -} diff --git a/sys-fs/zfs-utils/zfs-utils-2.2.6.ebuild b/sys-fs/zfs-utils/zfs-utils-2.2.6.ebuild new file mode 100644 index 00000000..2ef8e142 --- /dev/null +++ b/sys-fs/zfs-utils/zfs-utils-2.2.6.ebuild @@ -0,0 +1,112 @@ +# Copyright 1999-2021 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +inherit autotools bash-completion-r1 flag-o-matic pam toolchain-funcs udev usr-ldscript + +MY_PN="zfs" +MY_P="${MY_PN}-${PV}" + +DESCRIPTION="Userland utilities for ZFS Linux kernel module" +HOMEPAGE="https://zfsonlinux.org/" + +SRC_URI="https://github.com/openzfs/${PN}/releases/download/${MY_P}/${MY_P}.tar.gz" +KEYWORDS="~amd64" +S="${WORKDIR}/${MY_P}" + +LICENSE="BSD-2 CDDL MIT" +SLOT="0" +IUSE="debug nls pam test-suite unwind" + +DEPEND=" + net-libs/libtirpc:= + sys-apps/util-linux + sys-libs/zlib + virtual/libudev:= + dev-libs/openssl:= + pam? ( sys-libs/pam ) + unwind? ( sys-libs/libunwind:= ) +" + +BDEPEND="app-alternatives/awk + virtual/pkgconfig + nls? ( sys-devel/gettext ) +" + +RDEPEND="${DEPEND} + app-alternatives/awk + virtual/udev + sys-fs/udev-init-scripts + test-suite? ( + sys-apps/kmod[tools] + sys-apps/util-linux + sys-devel/bc + sys-block/parted + sys-fs/lsscsi + sys-fs/mdadm + sys-process/procps + ) +" + +RESTRICT="test" + +PATCHES=( + "${FILESDIR}"/2.1.5-dracut-zfs-missing.patch + "${FILESDIR}"/2.2.2-no-USER_NS.patch +) + +src_prepare() { + default + + # Run unconditionally (bug #792627) + eautoreconf + + # Tries to use /etc/conf.d which we reserve for OpenRC + sed -i -e '/EnvironmentFile/d' etc/systemd/system/zfs*.in || die + + # prevent errors showing up on zfs-mount stop, #647688 + # openrc will unmount all filesystems anyway. + sed -i "/^ZFS_UNMOUNT=/ s/yes/no/" "etc/default/zfs.in" || die +} + +src_configure() { + local myconf=( + --bindir="${EPREFIX}/bin" + --enable-shared + --disable-systemd + --enable-sysvinit + --localstatedir="${EPREFIX}/var" + --sbindir="${EPREFIX}/sbin" + --with-config=user + --with-dracutdir="${EPREFIX}/usr/lib/dracut" + --with-udevdir="$(get_udevdir)" + --with-pamconfigsdir="${EPREFIX}/unwanted_files" + --with-pammoduledir="$(getpam_mod_dir)" + --with-vendor=redcore + $(use_enable debug) + $(use_enable nls) + $(use_enable pam) + $(use_with unwind libunwind) + --disable-pyzfs + --disable-static + ) + + econf "${myconf[@]}" +} + +src_install() { + default + + gen_usr_ldscript -a nvpair uutil zfsbootenv zfs zfs_core zpool + dobashcomp contrib/bash_completion.d/zfs + bashcomp_alias zfs zpool + dodir etc/conf.d + insinto etc/conf.d + doins "${S}"/etc/default/zfs + use pam && { rm -rv "${ED}/unwanted_files" || die ; } + use test-suite || { rm -r "${ED}/usr/share/zfs" || die ; } + + # strip executable bit from conf.d file + fperms 0644 /etc/conf.d/zfs +} diff --git a/sys-fs/zfs/zfs-2.2.4.ebuild b/sys-fs/zfs/zfs-2.2.4.ebuild deleted file mode 100644 index bdcb914c..00000000 --- a/sys-fs/zfs/zfs-2.2.4.ebuild +++ /dev/null @@ -1,17 +0,0 @@ -# Copyright 1999-2015 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Header: $ - -EAPI=7 - -DESCRIPTION="ZFS meta-package (Gentoo compatibility ebuild)" -SRC_URI="" - -LICENSE="GPL-2" -SLOT="0" -KEYWORDS="amd64" -IUSE="" - -DEPEND="~sys-fs/zfs-utils-${PV} - ~sys-kernel/zfs-dkms-${PV}" -RDEPEND="${DEPEND}" diff --git a/sys-fs/zfs/zfs-2.2.6.ebuild b/sys-fs/zfs/zfs-2.2.6.ebuild new file mode 100644 index 00000000..bdcb914c --- /dev/null +++ b/sys-fs/zfs/zfs-2.2.6.ebuild @@ -0,0 +1,17 @@ +# Copyright 1999-2015 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: $ + +EAPI=7 + +DESCRIPTION="ZFS meta-package (Gentoo compatibility ebuild)" +SRC_URI="" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="amd64" +IUSE="" + +DEPEND="~sys-fs/zfs-utils-${PV} + ~sys-kernel/zfs-dkms-${PV}" +RDEPEND="${DEPEND}" -- cgit v1.2.3