summaryrefslogtreecommitdiff
path: root/sys-fs/zfs
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2020-09-02 14:09:07 +0100
committerV3n3RiX <venerix@redcorelinux.org>2020-09-02 14:09:07 +0100
commitb17a3ef12038de50228bade1f05502c74e135321 (patch)
tree9026dffec53f92cba48ca9a500a4f778e6304380 /sys-fs/zfs
parent3cf7c3ef441822c889356fd1812ebf2944a59851 (diff)
gentoo resync : 02.09.2020
Diffstat (limited to 'sys-fs/zfs')
-rw-r--r--sys-fs/zfs/Manifest8
-rw-r--r--sys-fs/zfs/metadata.xml1
-rw-r--r--sys-fs/zfs/zfs-0.8.4-r2.ebuild39
-rw-r--r--sys-fs/zfs/zfs-2.0.0_rc1-r1.ebuild228
-rw-r--r--sys-fs/zfs/zfs-9999.ebuild48
5 files changed, 290 insertions, 34 deletions
diff --git a/sys-fs/zfs/Manifest b/sys-fs/zfs/Manifest
index 6372e6be32fa..de09315414d3 100644
--- a/sys-fs/zfs/Manifest
+++ b/sys-fs/zfs/Manifest
@@ -2,6 +2,8 @@ AUX 0.8.4-initconfdir.patch 1004 BLAKE2B fd4186b5f378f562098040a8e13a12e6fd7f0f3
AUX bash-completion-r1 11310 BLAKE2B f6c105fef1737d4be0e76967fdec62aa52fa7665bfc1e9aa4c944dd6442d64d7d31b8af54f92f5db25542f968ecf83da46db8c2a8f978577526bf9f90d8bccf3 SHA512 03be521e2c646196766d5fd049f241cb97f290abf0409881ea6ba709934984deda402c8513009e62a5787e0648023b55c040e5f99baef27709e81c3bc9c8f56e
AUX bash-completion-sudo.patch 905 BLAKE2B 92e58ff097893436d589f7df0134e09d2e0699ae82618c4c14caf4b26cb466367a5372d7e0a030aa857d024e3db0faef4bb5fa32c54f41f0d4766693a95ba5ab SHA512 e53c79401f4c634a94af27b2f88a40440b68a4c192fd1944668786650aaa0f1f08dff851dca5b9666ce8bba1f0e2b7cb195314cd9d1314c9bab1194d03122319
DIST zfs-0.8.4.tar.gz 9285838 BLAKE2B 776bcd6dfab8825c07d315085e288b29bf543d6957325d5d566b7b78c04505dde9bd25eb6684cb4a1b6a657de8a4e1290d04d2b9079d26d6b834a70f1ec3b569 SHA512 9086dc6a6262dd93ca6ec43f1b4c2e5c804deba708c8a7460b8531aa4802b0bf8cac0917a1a00e6af2e96d4a21cd68b85e226bf571bd94041d0325c457106eb1
-EBUILD zfs-0.8.4-r2.ebuild 5197 BLAKE2B 20e55e42cc96b02acddf326c2ef75869cc73698d56aa7ae3e8797f50dc121c18c0b9d1424a7837a88d77e7e098eeaee353f26e841cabfbce3e18ad13023940e5 SHA512 6bcdf42cd77ffbb64e651e849edbb594a7f2482e481a0bf2f846f36e9524d637c1bd172dce0359a7907d6020622404e68ffbccd0839408f959f50a2d2b0fd5d9
-EBUILD zfs-9999.ebuild 5386 BLAKE2B d29282595b19ed397d5997da0cca17ad0b40648ac0252ae2acdc71e68e4513a3c57039b656862c41733d78e3e3cafa9192001aaddb7a9463126ba58d71de4ed6 SHA512 0d8e0912bb058a176dee139bd6106c03da560e84f07345d0b7a73f0308912b8bba4ca27e62ca498a803980bcf68086f1662438eace0c45c1d98646070e3df06a
-MISC metadata.xml 869 BLAKE2B 1efbc16c39a86816ce9b80bd0b13bd251b391c780ef4dbf05817639927cb725c25648593933a31c1a598bf331667a232cfc9331b48c4db35b455bbc95db7fd61 SHA512 e615f9628121aaea23014e91235bb8aa15b938bc7c831d7edbc88c98dddd0ee1170b1c7e025912f547f613f132e0ef46fba7bf1d8aaaf308d8ea9cefaf1a5252
+DIST zfs-2.0.0-rc1.tar.gz 12820598 BLAKE2B 6ea935447e4f95eb4040533843677f0091c9620fc387c76818df69a6653467e10aecd07ece22b2a32f849dc52ab0160149147416af90d78c5284f403571f7962 SHA512 b70cd10672d4424a6ffaaa58b4fa14b7d1b6481413463abd9b6d75698e80d94301fd54c7e091d63ebad9c8838eaaef6449223a55f041a62ae8292882feb195b5
+EBUILD zfs-0.8.4-r2.ebuild 5608 BLAKE2B add2a38bfd55510e47404281ce6892eeeaa3b37c9c8bc5ce7d5c03e3e42193fe7855416af7b0d884e7819c4700ed91da658d9841b65c830c96f6881c855a2d29 SHA512 a5753013f83ca7f5b66505305b478ef29f7dbb2e7e3c361aacacde4945257f01996bbea60c5ab48b4857c381bf4610895d1398cc90cf43f5e5fec71b4144d9a0
+EBUILD zfs-2.0.0_rc1-r1.ebuild 5836 BLAKE2B 7e067ccb6a60ce39e17a44e83ce3a4a84b68a2ed6f19a523a2aacbff642c673e301fc0f75427b3d76b47e475e2eaf7d8c35ba7d96a9f14e8e86a3bf713983612 SHA512 d9201ddf41e9c82b0b135be99888bc0afb1621c6aa83aead3b90a116b2434b3945aa8d001eb47506b3bb7d9d14fb597bf12d83333a383fe516d8851334234923
+EBUILD zfs-9999.ebuild 5859 BLAKE2B daee60e94c597e1306b87cdd2018a1347ef8db5cdba3b9b398127ec758d5a93d23eba3fab8d0867dde4ef0bdb3611dd009418f92c961b8bfdb56995bf101df19 SHA512 2d811674de3373cdce8c408429c0a419c0a51ed9502adcd5e3be1844220af7c42e49cfd12701229766c2e68d56a57188d971a129318ef52d2efbb3b2100a396d
+MISC metadata.xml 1003 BLAKE2B 640ef6d6f178ae9c3f3281a8e8539980c4a263f6cf0c5f4e1de3f0572f2acfe409865e85a12473129eb026130c9b76b946ee7698bd990b05f14e6b26c40fcb22 SHA512 965eabb5488a3cb54b360b33c847a2eb0d326a2c6761d86d581e06c2f52db9478fe7df131f68cb57bf32a2a872ecc1597e2a1a6b457d254f578d684cf73810c5
diff --git a/sys-fs/zfs/metadata.xml b/sys-fs/zfs/metadata.xml
index 85d50d081aff..9ce9230943f9 100644
--- a/sys-fs/zfs/metadata.xml
+++ b/sys-fs/zfs/metadata.xml
@@ -11,6 +11,7 @@
</maintainer>
<use>
<flag name="kernel-builtin">Disable dependency on sys-fs/zfs-kmod under the assumption that ZFS is part of the kernel source tree</flag>
+ <flag name="minimal">Don't install python scripts (arcstat, dbufstat etc) and avoid dependency on <pkg>dev-lang/python</pkg></flag>
<flag name="pam">Install zfs_key pam module, for automatically loading zfs encryption keys for home datasets</flag>
<flag name="rootfs">Enable dependencies required for booting off a pool containing a rootfs</flag>
<flag name="test-suite">Install regression test suite</flag>
diff --git a/sys-fs/zfs/zfs-0.8.4-r2.ebuild b/sys-fs/zfs/zfs-0.8.4-r2.ebuild
index b24ddaf0dcba..5501d0e9c675 100644
--- a/sys-fs/zfs/zfs-0.8.4-r2.ebuild
+++ b/sys-fs/zfs/zfs-0.8.4-r2.ebuild
@@ -21,10 +21,9 @@ fi
LICENSE="BSD-2 CDDL MIT"
SLOT="0"
-IUSE="custom-cflags debug kernel-builtin libressl python +rootfs test-suite static-libs"
+IUSE="custom-cflags debug kernel-builtin libressl minimal nls python +rootfs test-suite static-libs"
DEPEND="
- ${PYTHON_DEPS}
net-libs/libtirpc[static-libs?]
sys-apps/util-linux[static-libs?]
sys-libs/zlib[static-libs(+)?]
@@ -32,6 +31,7 @@ DEPEND="
virtual/libudev[static-libs(-)?]
libressl? ( dev-libs/libressl:0=[static-libs?] )
!libressl? ( dev-libs/openssl:0=[static-libs?] )
+ !minimal? ( ${PYTHON_DEPS} )
python? (
virtual/python-cffi[${PYTHON_USEDEP}]
)
@@ -39,6 +39,7 @@ DEPEND="
BDEPEND="virtual/awk
virtual/pkgconfig
+ nls? ( sys-devel/gettext )
python? (
dev-python/setuptools[${PYTHON_USEDEP}]
)
@@ -64,7 +65,11 @@ RDEPEND="${DEPEND}
)
"
-REQUIRED_USE="${PYTHON_REQUIRED_USE}"
+REQUIRED_USE="
+ !minimal? ( ${PYTHON_REQUIRED_USE} )
+ python? ( !minimal )
+ test-suite? ( !minimal )
+"
RESTRICT="test"
@@ -118,7 +123,7 @@ src_prepare() {
src_configure() {
use custom-cflags || strip-flags
- python_setup
+ use minimal || python_setup
local myconf=(
--bindir="${EPREFIX}/bin"
@@ -132,12 +137,13 @@ src_configure() {
--with-linux="${KV_DIR}"
--with-linux-obj="${KV_OUT_DIR}"
--with-udevdir="$(get_udevdir)"
- --with-python="${EPYTHON}"
--with-systemdunitdir="$(systemd_get_systemunitdir)"
--with-systemdpresetdir="${EPREFIX}/lib/systemd/system-preset"
$(use_enable debug)
+ $(use_enable nls)
$(use_enable python pyzfs)
$(use_enable static-libs static)
+ $(usex minimal --without-python --with-python="${EPYTHON}")
)
econf "${myconf[@]}"
@@ -176,7 +182,7 @@ src_install() {
fi
# enforce best available python implementation
- python_fix_shebang "${ED}/bin"
+ use minimal || python_fix_shebang "${ED}/bin"
}
pkg_postinst() {
@@ -195,14 +201,19 @@ pkg_postinst() {
update_moduledb
fi
- [[ -e "${EROOT}/etc/runlevels/boot/zfs-import" ]] || \
- einfo "You should add zfs-import to the boot runlevel."
- [[ -e "${EROOT}/etc/runlevels/boot/zfs-mount" ]]|| \
- einfo "You should add zfs-mount to the boot runlevel."
- [[ -e "${EROOT}/etc/runlevels/default/zfs-share" ]] || \
- einfo "You should add zfs-share to the default runlevel."
- [[ -e "${EROOT}/etc/runlevels/default/zfs-zed" ]] || \
- einfo "You should add zfs-zed to the default runlevel."
+ if systemd_is_booted || has_version sys-apps/systemd; then
+ einfo "Please refer to ${EROOT}/lib/systemd/system-preset/50-zfs.preset"
+ einfo "for default zfs systemd service configuration"
+ else
+ [[ -e "${EROOT}/etc/runlevels/boot/zfs-import" ]] || \
+ einfo "You should add zfs-import to the boot runlevel."
+ [[ -e "${EROOT}/etc/runlevels/boot/zfs-mount" ]]|| \
+ einfo "You should add zfs-mount to the boot runlevel."
+ [[ -e "${EROOT}/etc/runlevels/default/zfs-share" ]] || \
+ einfo "You should add zfs-share to the default runlevel."
+ [[ -e "${EROOT}/etc/runlevels/default/zfs-zed" ]] || \
+ einfo "You should add zfs-zed to the default runlevel."
+ fi
}
pkg_postrm() {
diff --git a/sys-fs/zfs/zfs-2.0.0_rc1-r1.ebuild b/sys-fs/zfs/zfs-2.0.0_rc1-r1.ebuild
new file mode 100644
index 000000000000..486de47acc47
--- /dev/null
+++ b/sys-fs/zfs/zfs-2.0.0_rc1-r1.ebuild
@@ -0,0 +1,228 @@
+# Copyright 1999-2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+DISTUTILS_OPTIONAL=1
+PYTHON_COMPAT=( python3_{6,7} )
+
+inherit autotools bash-completion-r1 distutils-r1 flag-o-matic linux-info pam systemd toolchain-funcs udev usr-ldscript
+
+DESCRIPTION="Userland utilities for ZFS Linux kernel module"
+HOMEPAGE="https://github.com/openzfs/zfs"
+
+if [[ ${PV} == "9999" ]] ; then
+ inherit git-r3 linux-mod
+ EGIT_REPO_URI="https://github.com/openzfs/zfs.git"
+else
+ MY_P="${P/_rc/-rc}"
+ SRC_URI="https://github.com/openzfs/${PN}/releases/download/${MY_P}/${MY_P}.tar.gz"
+ KEYWORDS="~amd64 ~arm64 ~ppc64"
+ S="${WORKDIR}/${P%_rc?}"
+fi
+
+LICENSE="BSD-2 CDDL MIT"
+SLOT="0"
+IUSE="custom-cflags debug kernel-builtin libressl minimal nls pam python +rootfs test-suite static-libs"
+
+DEPEND="
+ net-libs/libtirpc[static-libs?]
+ sys-apps/util-linux[static-libs?]
+ sys-libs/zlib[static-libs(+)?]
+ virtual/awk
+ virtual/libudev[static-libs(-)?]
+ libressl? ( dev-libs/libressl:0=[static-libs?] )
+ !libressl? ( dev-libs/openssl:0=[static-libs?] )
+ !minimal? ( ${PYTHON_DEPS} )
+ pam? ( sys-libs/pam )
+ python? (
+ virtual/python-cffi[${PYTHON_USEDEP}]
+ )
+"
+
+BDEPEND="virtual/awk
+ virtual/pkgconfig
+ nls? ( sys-devel/gettext )
+ python? (
+ dev-python/setuptools[${PYTHON_USEDEP}]
+ )
+"
+
+RDEPEND="${DEPEND}
+ !kernel-builtin? ( ~sys-fs/zfs-kmod-${PV} )
+ !prefix? ( virtual/udev )
+ sys-fs/udev-init-scripts
+ rootfs? (
+ app-arch/cpio
+ app-misc/pax-utils
+ !<sys-kernel/genkernel-3.5.1.1
+ )
+ 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
+ )
+"
+
+REQUIRED_USE="
+ !minimal? ( ${PYTHON_REQUIRED_USE} )
+ python? ( !minimal )
+ test-suite? ( !minimal )
+"
+
+RESTRICT="test"
+
+PATCHES=( "${FILESDIR}/bash-completion-sudo.patch" )
+
+pkg_setup() {
+ if use kernel_linux && use test-suite; then
+ linux-info_pkg_setup
+
+ if ! linux_config_exists; then
+ ewarn "Cannot check the linux kernel configuration."
+ else
+ if use test-suite; then
+ if linux_chkconfig_present BLK_DEV_LOOP; then
+ eerror "The ZFS test suite requires loop device support enabled."
+ eerror "Please enable it:"
+ eerror " CONFIG_BLK_DEV_LOOP=y"
+ eerror "in /usr/src/linux/.config or"
+ eerror " Device Drivers --->"
+ eerror " Block devices --->"
+ eerror " [X] Loopback device support"
+ fi
+ fi
+ fi
+ fi
+}
+
+src_prepare() {
+ default
+
+ if [[ ${PV} == "9999" ]]; then
+ eautoreconf
+ else
+ # Set revision number
+ sed -i "s/\(Release:\)\(.*\)1/\1\2${PR}-gentoo/" META || die "Could not set Gentoo release"
+ fi
+
+ if use python; then
+ pushd contrib/pyzfs >/dev/null || die
+ distutils-r1_src_prepare
+ popd >/dev/null || die
+ fi
+
+ # 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() {
+ use custom-cflags || strip-flags
+ use minimal || python_setup
+
+ local myconf=(
+ --bindir="${EPREFIX}/bin"
+ --enable-shared
+ --enable-systemd
+ --enable-sysvinit
+ --localstatedir="${EPREFIX}/var"
+ --sbindir="${EPREFIX}/sbin"
+ --with-config=user
+ --with-dracutdir="${EPREFIX}/usr/lib/dracut"
+ --with-linux="${KV_DIR}"
+ --with-linux-obj="${KV_OUT_DIR}"
+ --with-udevdir="$(get_udevdir)"
+ --with-pamconfigsdir="${EPREFIX}/unwanted_files"
+ --with-pammoduledir="$(getpam_mod_dir)"
+ --with-systemdunitdir="$(systemd_get_systemunitdir)"
+ --with-systemdpresetdir="${EPREFIX}/lib/systemd/system-preset"
+ $(use_enable debug)
+ $(use_enable nls)
+ $(use_enable pam)
+ $(use_enable python pyzfs)
+ $(use_enable static-libs static)
+ $(usex minimal --without-python --with-python="${EPYTHON}")
+ )
+
+ econf "${myconf[@]}"
+}
+
+src_compile() {
+ default
+ if use python; then
+ pushd contrib/pyzfs >/dev/null || die
+ distutils-r1_src_compile
+ popd >/dev/null || die
+ fi
+}
+
+src_install() {
+ default
+
+ gen_usr_ldscript -a uutil nvpair zpool zfs zfs_core
+
+ use pam && { rm -rv "${ED}/unwanted_files" || die ; }
+
+ use test-suite || { rm -r "${ED}/usr/share/zfs" || die ; }
+
+ if ! use static-libs; then
+ find "${ED}/" -name '*.la' -delete || die
+ fi
+
+ dobashcomp contrib/bash_completion.d/zfs
+ bashcomp_alias zfs zpool
+
+ # strip executable bit from conf.d file
+ fperms 0644 /etc/conf.d/zfs
+
+ if use python; then
+ pushd contrib/pyzfs >/dev/null || die
+ distutils-r1_src_install
+ popd >/dev/null || die
+ fi
+
+ # enforce best available python implementation
+ use minimal || python_fix_shebang "${ED}/bin"
+}
+
+pkg_postinst() {
+ if use rootfs; then
+ if ! has_version sys-kernel/genkernel && ! has_version sys-kernel/dracut; then
+ elog "root on zfs requires initramfs to boot"
+ elog "the following packages known to provide one and tested on regular basis:"
+ elog " sys-kernel/dracut"
+ elog " sys-kernel/genkernel"
+ fi
+ fi
+
+ if ! use kernel-builtin && [[ ${PV} = "9999" ]]; then
+ einfo "Adding ${P} to the module database to ensure that the"
+ einfo "kernel modules and userland utilities stay in sync."
+ update_moduledb
+ fi
+
+ if systemd_is_booted || has_version sys-apps/systemd; then
+ einfo "Please refer to ${EROOT}/lib/systemd/system-preset/50-zfs.preset"
+ einfo "for default zfs systemd service configuration"
+ else
+ [[ -e "${EROOT}/etc/runlevels/boot/zfs-import" ]] || \
+ einfo "You should add zfs-import to the boot runlevel."
+ [[ -e "${EROOT}/etc/runlevels/boot/zfs-mount" ]]|| \
+ einfo "You should add zfs-mount to the boot runlevel."
+ [[ -e "${EROOT}/etc/runlevels/default/zfs-share" ]] || \
+ einfo "You should add zfs-share to the default runlevel."
+ [[ -e "${EROOT}/etc/runlevels/default/zfs-zed" ]] || \
+ einfo "You should add zfs-zed to the default runlevel."
+ fi
+}
+
+pkg_postrm() {
+ if ! use kernel-builtin && [[ ${PV} == "9999" ]]; then
+ remove_moduledb
+ fi
+}
diff --git a/sys-fs/zfs/zfs-9999.ebuild b/sys-fs/zfs/zfs-9999.ebuild
index 11bc0febcb0a..7def71113015 100644
--- a/sys-fs/zfs/zfs-9999.ebuild
+++ b/sys-fs/zfs/zfs-9999.ebuild
@@ -15,16 +15,17 @@ if [[ ${PV} == "9999" ]] ; then
inherit git-r3 linux-mod
EGIT_REPO_URI="https://github.com/openzfs/zfs.git"
else
- SRC_URI="https://github.com/openzfs/${PN}/releases/download/${P}/${P}.tar.gz"
+ MY_P="${P/_rc/-rc}"
+ SRC_URI="https://github.com/openzfs/${PN}/releases/download/${MY_P}/${MY_P}.tar.gz"
KEYWORDS="~amd64 ~arm64 ~ppc64"
+ S="${WORKDIR}/${P%_rc?}"
fi
LICENSE="BSD-2 CDDL MIT"
SLOT="0"
-IUSE="custom-cflags debug kernel-builtin libressl pam python +rootfs test-suite static-libs"
+IUSE="custom-cflags debug kernel-builtin libressl minimal nls pam python +rootfs test-suite static-libs"
DEPEND="
- ${PYTHON_DEPS}
net-libs/libtirpc[static-libs?]
sys-apps/util-linux[static-libs?]
sys-libs/zlib[static-libs(+)?]
@@ -32,6 +33,7 @@ DEPEND="
virtual/libudev[static-libs(-)?]
libressl? ( dev-libs/libressl:0=[static-libs?] )
!libressl? ( dev-libs/openssl:0=[static-libs?] )
+ !minimal? ( ${PYTHON_DEPS} )
pam? ( sys-libs/pam )
python? (
virtual/python-cffi[${PYTHON_USEDEP}]
@@ -40,6 +42,7 @@ DEPEND="
BDEPEND="virtual/awk
virtual/pkgconfig
+ nls? ( sys-devel/gettext )
python? (
dev-python/setuptools[${PYTHON_USEDEP}]
)
@@ -65,7 +68,11 @@ RDEPEND="${DEPEND}
)
"
-REQUIRED_USE="${PYTHON_REQUIRED_USE}"
+REQUIRED_USE="
+ !minimal? ( ${PYTHON_REQUIRED_USE} )
+ python? ( !minimal )
+ test-suite? ( !minimal )
+"
RESTRICT="test"
@@ -116,7 +123,7 @@ src_prepare() {
src_configure() {
use custom-cflags || strip-flags
- python_setup
+ use minimal || python_setup
local myconf=(
--bindir="${EPREFIX}/bin"
@@ -130,15 +137,17 @@ src_configure() {
--with-linux="${KV_DIR}"
--with-linux-obj="${KV_OUT_DIR}"
--with-udevdir="$(get_udevdir)"
- --with-pamconfigsdir="${EPREFIX}/unwanted_debian_files"
+ --with-pamconfigsdir="${EPREFIX}/unwanted_files"
--with-pammoduledir="$(getpam_mod_dir)"
- --with-python="${EPYTHON}"
--with-systemdunitdir="$(systemd_get_systemunitdir)"
--with-systemdpresetdir="${EPREFIX}/lib/systemd/system-preset"
+ --with-vendor=gentoo
$(use_enable debug)
+ $(use_enable nls)
$(use_enable pam)
$(use_enable python pyzfs)
$(use_enable static-libs static)
+ $(usex minimal --without-python --with-python="${EPYTHON}")
)
econf "${myconf[@]}"
@@ -158,7 +167,7 @@ src_install() {
gen_usr_ldscript -a uutil nvpair zpool zfs zfs_core
- use pam && { rm -rv "${ED}/unwanted_debian_files" || die ; }
+ use pam && { rm -rv "${ED}/unwanted_files" || die ; }
use test-suite || { rm -r "${ED}/usr/share/zfs" || die ; }
@@ -179,7 +188,7 @@ src_install() {
fi
# enforce best available python implementation
- python_fix_shebang "${ED}/bin"
+ use minimal || python_fix_shebang "${ED}/bin"
}
pkg_postinst() {
@@ -198,14 +207,19 @@ pkg_postinst() {
update_moduledb
fi
- [[ -e "${EROOT}/etc/runlevels/boot/zfs-import" ]] || \
- einfo "You should add zfs-import to the boot runlevel."
- [[ -e "${EROOT}/etc/runlevels/boot/zfs-mount" ]]|| \
- einfo "You should add zfs-mount to the boot runlevel."
- [[ -e "${EROOT}/etc/runlevels/default/zfs-share" ]] || \
- einfo "You should add zfs-share to the default runlevel."
- [[ -e "${EROOT}/etc/runlevels/default/zfs-zed" ]] || \
- einfo "You should add zfs-zed to the default runlevel."
+ if systemd_is_booted || has_version sys-apps/systemd; then
+ einfo "Please refer to ${EROOT}/lib/systemd/system-preset/50-zfs.preset"
+ einfo "for default zfs systemd service configuration"
+ else
+ [[ -e "${EROOT}/etc/runlevels/boot/zfs-import" ]] || \
+ einfo "You should add zfs-import to the boot runlevel."
+ [[ -e "${EROOT}/etc/runlevels/boot/zfs-mount" ]]|| \
+ einfo "You should add zfs-mount to the boot runlevel."
+ [[ -e "${EROOT}/etc/runlevels/default/zfs-share" ]] || \
+ einfo "You should add zfs-share to the default runlevel."
+ [[ -e "${EROOT}/etc/runlevels/default/zfs-zed" ]] || \
+ einfo "You should add zfs-zed to the default runlevel."
+ fi
}
pkg_postrm() {