zfs: use new initramfs-regenerate trigger

This commit is contained in:
Andrew J. Hesford 2021-06-10 11:35:33 -04:00
parent 876b6ed3a4
commit d073c08d9d
2 changed files with 5 additions and 17 deletions

View file

@ -1,13 +0,0 @@
case "${ACTION}" in
post)
if [ -x usr/bin/dracut ]; then
# Include new modules in all initramfs instances when possible,
# as simultaneous updates of linux and zfs may trigger creation
# of images without modules and unable to boot from ZFS pools.
#
# See https://github.com/void-linux/void-packages/issues/22817
echo "Regenerating initramfs, please wait..."
usr/bin/dracut -f -q --regenerate-all
fi
;;
esac

View file

@ -1,14 +1,14 @@
# Template file for 'zfs'
pkgname=zfs
version=2.0.4
revision=2
revision=3
build_style=gnu-configure
configure_args="--with-config=user --with-mounthelperdir=/usr/bin
--with-udevdir=/usr/lib/udev --with-udevruledir=/usr/lib/udev/rules.d
--with-dracutdir=/usr/lib/dracut --with-tirpc"
hostmakedepends="dracut libtool pkg-config python3 automake"
makedepends="pam-devel zlib-devel libuuid-devel libblkid-devel libtirpc-devel attr-devel"
depends="dkms>=2.2.0.3_9 perl python3"
depends="dkms>=2.2.0.3_9 perl python3 xbps-triggers>=0.121_1"
conf_files="/etc/zfs/zed.d/zed.rc"
short_desc="Z File System -- userland, pyzfs, and kernel modules (using DKMS)"
maintainer="Toyam Cox <Vaelatern@voidlinux.org>"
@ -16,11 +16,12 @@ license="CDDL-1.0"
homepage="https://openzfs.github.io/openzfs-docs/"
distfiles="https://github.com/openzfs/zfs/releases/download/zfs-${version}/zfs-${version}.tar.gz"
checksum=7d1344c5433b91823f02c2e40b33d181fa6faf286bea5591f4b1965f23d45f6c
# dkms must be before initramfs-regenerate to build modules before images
triggers="dkms initramfs-regenerate"
dkms_modules="zfs ${version}"
replaces="spl<=0.7.13_1" # Because SPL was merged into zfs in 0.8.0
dkms_modules="zfs ${version}"
post_patch() {
# When collecting a "clean" tree for DKMS, don't leave patches in place
local _f