summaryrefslogtreecommitdiff
path: root/sys-fs/zfs-kmod/zfs-kmod-0.8.6.ebuild
diff options
context:
space:
mode:
Diffstat (limited to 'sys-fs/zfs-kmod/zfs-kmod-0.8.6.ebuild')
-rw-r--r--sys-fs/zfs-kmod/zfs-kmod-0.8.6.ebuild17
1 files changed, 16 insertions, 1 deletions
diff --git a/sys-fs/zfs-kmod/zfs-kmod-0.8.6.ebuild b/sys-fs/zfs-kmod/zfs-kmod-0.8.6.ebuild
index f63c737f2af0..68776243c4fb 100644
--- a/sys-fs/zfs-kmod/zfs-kmod-0.8.6.ebuild
+++ b/sys-fs/zfs-kmod/zfs-kmod-0.8.6.ebuild
@@ -19,7 +19,7 @@ else
fi
LICENSE="CDDL debug? ( GPL-2+ )"
-SLOT="0"
+SLOT="0/${PVR}"
IUSE="custom-cflags debug +rootfs"
DEPEND=""
@@ -33,10 +33,25 @@ BDEPEND="
virtual/awk
"
+# PDEPEND in this form is needed to trick portage suggest
+# enabling dist-kernel if only 1 package have it set
+PDEPEND="dist-kernel? ( ~sys-fs/zfs-${PV}[dist-kernel] )"
+
RESTRICT="debug? ( strip ) test"
DOCS=( AUTHORS COPYRIGHT META README.md )
+pkg_pretend() {
+ use rootfs || return 0
+
+ if has_version virtual/dist-kernel && ! use dist-kernel; then
+ ewarn "You have virtual/dist-kernel installed, but"
+ ewarn "USE=\"dist-kernel\" is not enabled for ${CATEGORY}/${PN}"
+ ewarn "It's recommended to globally enable dist-kernel USE flag"
+ ewarn "to auto-trigger initrd rebuilds with kernel updates"
+ fi
+}
+
# https://github.com/openzfs/zfs/pull/11371
PATCHES=( "${FILESDIR}/${PV}-copy-builtin.patch" )