mirror of
https://github.com/void-linux/void-packages.git
synced 2025-06-05 06:33:50 +02:00
New package: zfs-lts-2.1.13.
This commit is contained in:
parent
7ab3a13c76
commit
9aec04d36b
10 changed files with 215 additions and 2 deletions
1
srcpkgs/libzfs-lts
Symbolic link
1
srcpkgs/libzfs-lts
Symbolic link
|
@ -0,0 +1 @@
|
||||||
|
zfs-lts
|
1
srcpkgs/zfs-lts-devel
Symbolic link
1
srcpkgs/zfs-lts-devel
Symbolic link
|
@ -0,0 +1 @@
|
||||||
|
zfs-lts
|
1
srcpkgs/zfs-lts-pam
Symbolic link
1
srcpkgs/zfs-lts-pam
Symbolic link
|
@ -0,0 +1 @@
|
||||||
|
zfs-lts
|
4
srcpkgs/zfs-lts/files/zed/run
Executable file
4
srcpkgs/zfs-lts/files/zed/run
Executable file
|
@ -0,0 +1,4 @@
|
||||||
|
#!/bin/sh
|
||||||
|
exec 2>&1
|
||||||
|
[ -r conf ] && . conf
|
||||||
|
exec zed -F $OPTS
|
|
@ -0,0 +1,44 @@
|
||||||
|
# Patch adapted from
|
||||||
|
#
|
||||||
|
# https://aur.archlinux.org/cgit/aur.git/tree/0001-only-build-the-module-in-dkms.conf.patch?h=zfs-dkms
|
||||||
|
#
|
||||||
|
# rebased for zfs-2.1.5.
|
||||||
|
#
|
||||||
|
# Avoids recompiling ZFS userland utilities with DKMS rebuilds
|
||||||
|
From b4a2c0b184c9c9599421b15a430fb88deb5dbd17 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Eli Schwartz <eschwartz@archlinux.org>
|
||||||
|
Date: Sun, 28 Oct 2018 15:01:58 -0400
|
||||||
|
Subject: [PATCH] only build the module in dkms.conf
|
||||||
|
|
||||||
|
---
|
||||||
|
scripts/dkms.mkconf | 19 ++-----------------
|
||||||
|
1 file changed, 2 insertions(+), 17 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/scripts/dkms.mkconf b/scripts/dkms.mkconf
|
||||||
|
--- a/scripts/dkms.mkconf
|
||||||
|
+++ b/scripts/dkms.mkconf
|
||||||
|
@@ -28,14 +28,7 @@
|
||||||
|
PRE_BUILD="configure
|
||||||
|
--prefix=/usr
|
||||||
|
--with-config=kernel
|
||||||
|
- --with-linux=\$(
|
||||||
|
- if [ -e "\${kernel_source_dir/%build/source}" ]
|
||||||
|
- then
|
||||||
|
- echo "\${kernel_source_dir/%build/source}"
|
||||||
|
- else
|
||||||
|
- echo "\${kernel_source_dir}"
|
||||||
|
- fi
|
||||||
|
- )
|
||||||
|
+ --with-linux="\${kernel_source_dir}"
|
||||||
|
--with-linux-obj="\${kernel_source_dir}"
|
||||||
|
\$(
|
||||||
|
[[ -n \"\${ICP_ROOT}\" ]] && \\
|
||||||
|
@@ -68,7 +61,7 @@
|
||||||
|
-t \${dkms_tree}
|
||||||
|
"
|
||||||
|
AUTOINSTALL="yes"
|
||||||
|
-MAKE[0]="make"
|
||||||
|
+MAKE[0]="make -C module/"
|
||||||
|
STRIP[0]="\$(
|
||||||
|
[[ -r \${PACKAGE_CONFIG} ]] \\
|
||||||
|
&& source \${PACKAGE_CONFIG} \\
|
56
srcpkgs/zfs-lts/patches/0002-fix-dracut-root.patch
Normal file
56
srcpkgs/zfs-lts/patches/0002-fix-dracut-root.patch
Normal file
|
@ -0,0 +1,56 @@
|
||||||
|
From eefe83eaa68f7cb4a49c580dd940d3688e42c849 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Toyam Cox <aviator45003@gmail.com>
|
||||||
|
Date: Thu, 30 Jun 2022 13:47:58 -0400
|
||||||
|
Subject: [PATCH] dracut: fix boot on non-zfs-root systems
|
||||||
|
|
||||||
|
Simply prevent overwriting root until it needs to be overwritten.
|
||||||
|
|
||||||
|
Dracut could change this value before this module is called, but won't
|
||||||
|
change the kernel command line.
|
||||||
|
|
||||||
|
Reviewed-by: Andrew J. Hesford <ajh@sideband.org>
|
||||||
|
Signed-off-by: Toyam Cox <vaelatern@voidlinux.org>
|
||||||
|
Closes #13592
|
||||||
|
---
|
||||||
|
contrib/dracut/90zfs/zfs-lib.sh.in | 10 +++++-----
|
||||||
|
1 file changed, 5 insertions(+), 5 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/contrib/dracut/90zfs/zfs-lib.sh.in b/contrib/dracut/90zfs/zfs-lib.sh.in
|
||||||
|
index e44673c2d75..3a43e514d6f 100755
|
||||||
|
--- a/contrib/dracut/90zfs/zfs-lib.sh.in
|
||||||
|
+++ b/contrib/dracut/90zfs/zfs-lib.sh.in
|
||||||
|
@@ -88,11 +88,11 @@ decode_root_args() {
|
||||||
|
return
|
||||||
|
fi
|
||||||
|
|
||||||
|
- root=$(getarg root=)
|
||||||
|
+ xroot=$(getarg root=)
|
||||||
|
rootfstype=$(getarg rootfstype=)
|
||||||
|
|
||||||
|
# shellcheck disable=SC2249
|
||||||
|
- case "$root" in
|
||||||
|
+ case "$xroot" in
|
||||||
|
""|zfs|zfs:|zfs:AUTO)
|
||||||
|
root=zfs:AUTO
|
||||||
|
rootfstype=zfs
|
||||||
|
@@ -100,7 +100,7 @@ decode_root_args() {
|
||||||
|
;;
|
||||||
|
|
||||||
|
ZFS=*|zfs:*)
|
||||||
|
- root="${root#zfs:}"
|
||||||
|
+ root="${xroot#zfs:}"
|
||||||
|
root="${root#ZFS=}"
|
||||||
|
root=$(echo "$root" | tr '+' ' ')
|
||||||
|
rootfstype=zfs
|
||||||
|
@@ -109,9 +109,9 @@ decode_root_args() {
|
||||||
|
esac
|
||||||
|
|
||||||
|
if [ "$rootfstype" = "zfs" ]; then
|
||||||
|
- case "$root" in
|
||||||
|
+ case "$xroot" in
|
||||||
|
"") root=zfs:AUTO ;;
|
||||||
|
- *) root=$(echo "$root" | tr '+' ' ') ;;
|
||||||
|
+ *) root=$(echo "$xroot" | tr '+' ' ') ;;
|
||||||
|
esac
|
||||||
|
return 0
|
||||||
|
fi
|
95
srcpkgs/zfs-lts/template
Normal file
95
srcpkgs/zfs-lts/template
Normal file
|
@ -0,0 +1,95 @@
|
||||||
|
# Template file for 'zfs-lts'
|
||||||
|
pkgname=zfs-lts
|
||||||
|
version=2.1.13
|
||||||
|
revision=1
|
||||||
|
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 xbps-triggers>=0.121_1
|
||||||
|
libzfs-lts>=${version}_${revision}"
|
||||||
|
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>"
|
||||||
|
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=06b24cbb3cbc1554e2edf2fcd71d1f8bec4febf4412aeac17070877c44302abd
|
||||||
|
# dkms must be before initramfs-regenerate to build modules before images
|
||||||
|
triggers="dkms initramfs-regenerate"
|
||||||
|
dkms_modules="zfs ${version}"
|
||||||
|
|
||||||
|
provides="zfs-${version}_${revision}"
|
||||||
|
replaces="spl<=0.7.13_1 zfs>=0" # Because SPL was merged into zfs in 0.8.0
|
||||||
|
|
||||||
|
pre_configure() {
|
||||||
|
export CFLAGS+=" -I${XBPS_CROSS_BASE}/usr/include/tirpc/"
|
||||||
|
autoreconf -fi
|
||||||
|
}
|
||||||
|
|
||||||
|
post_install() {
|
||||||
|
vlicense COPYRIGHT
|
||||||
|
vlicense LICENSE
|
||||||
|
vlicense NOTICE
|
||||||
|
|
||||||
|
vsv zed
|
||||||
|
|
||||||
|
make dist-gzip
|
||||||
|
vmkdir usr/src/
|
||||||
|
tar xf ${pkgname/%-lts}-${version}.tar.gz -C ${DESTDIR}/usr/src/
|
||||||
|
scripts/dkms.mkconf -v ${version} -f ${DESTDIR}/usr/src/${pkgname/%-lts}-${version}/dkms.conf -n zfs
|
||||||
|
|
||||||
|
# Remove init and service control pieces not used in Void
|
||||||
|
rm -rf ${DESTDIR}/usr/lib/systemd
|
||||||
|
rm -rf ${DESTDIR}/etc/init.d
|
||||||
|
rm -rf ${DESTDIR}/etc/default
|
||||||
|
rm -f ${DESTDIR}/etc/zfs/zfs-functions
|
||||||
|
|
||||||
|
# Remove pam config framework file not used in Void
|
||||||
|
rm -f ${DESTDIR}/usr/share/pam-configs/zfs_key
|
||||||
|
|
||||||
|
# zfs-mount-generator is a systemd helper, no need for its man page
|
||||||
|
rm -f ${DESTDIR}/usr/share/man/man8/zfs-mount-generator.8
|
||||||
|
|
||||||
|
# Contains ELF binaries. Remove it until upstream has a way to move this
|
||||||
|
# into /usr/libexec or similiar.
|
||||||
|
rm -rf ${DESTDIR}/usr/share/zfs/zfs-tests
|
||||||
|
}
|
||||||
|
|
||||||
|
libzfs-lts_package() {
|
||||||
|
short_desc="Z File System - libraries"
|
||||||
|
provides="libzfs-${version}_${revision}"
|
||||||
|
replaces="libzfs>=0"
|
||||||
|
pkg_install() {
|
||||||
|
vmove "usr/lib/*.so.*"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
zfs-lts-devel_package() {
|
||||||
|
depends="libzfs>=${version}_${revision}"
|
||||||
|
short_desc="Z File System -- development files"
|
||||||
|
provides="zfs-devel-${version}_${revision}"
|
||||||
|
replaces="zfs-devel>=0"
|
||||||
|
pkg_install() {
|
||||||
|
vmove usr/include
|
||||||
|
vmove "usr/lib/*.a"
|
||||||
|
vmove "usr/lib/*.so"
|
||||||
|
vmove usr/lib/pkgconfig
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
zfs-lts-pam_package() {
|
||||||
|
depends="${sourcepkg}>=${version}_${revision}"
|
||||||
|
short_desc="Z File System -- PAM integration"
|
||||||
|
provides="zfs-pam-${version}_${revision}"
|
||||||
|
replaces="zfs-pam>=0"
|
||||||
|
pkg_install() {
|
||||||
|
vmove usr/lib/security/pam_zfs_key.so
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
# REMARKS:
|
||||||
|
# Did not split out pyzfs, because it's distributed with zfs, and no reason to
|
||||||
|
# send separately.
|
3
srcpkgs/zfs-lts/update
Normal file
3
srcpkgs/zfs-lts/update
Normal file
|
@ -0,0 +1,3 @@
|
||||||
|
pkgname=zfs
|
||||||
|
ignore="*.*.99"
|
||||||
|
pattern="${pkgname}-\K2\.1\.[0-9.]+(?=\.tar\.gz)"
|
|
@ -21,7 +21,9 @@ checksum=42035fd059faa25a09cd511b24a57b8ad1285cb69127f2a0043b98562c5ec690
|
||||||
triggers="dkms initramfs-regenerate"
|
triggers="dkms initramfs-regenerate"
|
||||||
dkms_modules="zfs ${version}"
|
dkms_modules="zfs ${version}"
|
||||||
|
|
||||||
replaces="spl<=0.7.13_1" # Because SPL was merged into zfs in 0.8.0
|
provides="zfs-${version}_${revision}"
|
||||||
|
|
||||||
|
replaces="spl<=0.7.13_1 zfs-lts>=0" # Because SPL was merged into zfs in 0.8.0
|
||||||
|
|
||||||
pre_configure() {
|
pre_configure() {
|
||||||
export CFLAGS+=" -I${XBPS_CROSS_BASE}/usr/include/tirpc/"
|
export CFLAGS+=" -I${XBPS_CROSS_BASE}/usr/include/tirpc/"
|
||||||
|
@ -64,6 +66,8 @@ post_install() {
|
||||||
|
|
||||||
libzfs_package() {
|
libzfs_package() {
|
||||||
short_desc="Z File System - libraries"
|
short_desc="Z File System - libraries"
|
||||||
|
provides="libzfs-${version}_${revision}"
|
||||||
|
replaces="libzfs-lts>=0"
|
||||||
pkg_install() {
|
pkg_install() {
|
||||||
vmove "usr/lib/*.so.*"
|
vmove "usr/lib/*.so.*"
|
||||||
}
|
}
|
||||||
|
@ -72,6 +76,8 @@ libzfs_package() {
|
||||||
zfs-devel_package() {
|
zfs-devel_package() {
|
||||||
depends="libzfs>=${version}_${revision}"
|
depends="libzfs>=${version}_${revision}"
|
||||||
short_desc="Z File System -- development files"
|
short_desc="Z File System -- development files"
|
||||||
|
provides="zfs-devel-${version}_${revision}"
|
||||||
|
replaces="zfs-devel-lts>=0"
|
||||||
pkg_install() {
|
pkg_install() {
|
||||||
vmove usr/include
|
vmove usr/include
|
||||||
vmove "usr/lib/*.a"
|
vmove "usr/lib/*.a"
|
||||||
|
@ -83,6 +89,8 @@ zfs-devel_package() {
|
||||||
zfs-pam_package() {
|
zfs-pam_package() {
|
||||||
depends="${sourcepkg}>=${version}_${revision}"
|
depends="${sourcepkg}>=${version}_${revision}"
|
||||||
short_desc="Z File System -- PAM integration"
|
short_desc="Z File System -- PAM integration"
|
||||||
|
provides="zfs-pam-${version}_${revision}"
|
||||||
|
replaces="zfs-pam-lts>=0"
|
||||||
pkg_install() {
|
pkg_install() {
|
||||||
vmove usr/lib/security/pam_zfs_key.so
|
vmove usr/lib/security/pam_zfs_key.so
|
||||||
}
|
}
|
||||||
|
|
|
@ -1 +1 @@
|
||||||
ignore="2.1.99"
|
ignore="*.*.99"
|
||||||
|
|
Loading…
Add table
Reference in a new issue