summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrew Ammerlaan <andrewammerlaan@gentoo.org>2023-11-08 14:09:48 +0100
committerAndrew Ammerlaan <andrewammerlaan@gentoo.org>2023-11-09 08:27:27 +0100
commit8ca2ec8588ee57b61f26fc823191cce940707309 (patch)
tree7d22683b5be8c8f57dcff6d2ead9b4372155e05d /sys-apps
parentsys-apps/systemd-utils: add USE=kernel-install,ukify (diff)
downloadgentoo-8ca2ec8588ee57b61f26fc823191cce940707309.tar.gz
gentoo-8ca2ec8588ee57b61f26fc823191cce940707309.tar.bz2
gentoo-8ca2ec8588ee57b61f26fc823191cce940707309.zip
sys-apps/systemd: add USE=kernel-install,ukify
AFAIK there is no reason why we could not use systemd's kernel-install with other bootloaders then systemd-boot. The systemd version of kernel-install has the advantage that its behaviour can be customized with plugins. This is the first step to make it possible to use Gentoo's dist-kernels with initrd generators other then Dracut. Signed-off-by: Andrew Ammerlaan <andrewammerlaan@gentoo.org>
Diffstat (limited to 'sys-apps')
-rw-r--r--sys-apps/systemd/metadata.xml2
-rw-r--r--sys-apps/systemd/systemd-254.5-r1.ebuild (renamed from sys-apps/systemd/systemd-254.5.ebuild)22
-rw-r--r--sys-apps/systemd/systemd-9999.ebuild22
3 files changed, 24 insertions, 22 deletions
diff --git a/sys-apps/systemd/metadata.xml b/sys-apps/systemd/metadata.xml
index 9576ddd514ee..abd1315edcc4 100644
--- a/sys-apps/systemd/metadata.xml
+++ b/sys-apps/systemd/metadata.xml
@@ -23,6 +23,7 @@
<flag name="http">Enable embedded HTTP server in journald</flag>
<flag name="importd">Enable import daemon</flag>
<flag name="iptables">Use libiptc from <pkg>net-firewall/iptables</pkg> for NAT support in systemd-networkd; this is used only if the running kernel does not support nftables</flag>
+ <flag name="kernel-install">Enable kernel-install</flag>
<flag name="kmod">Enable kernel module loading via <pkg>sys-apps/kmod</pkg></flag>
<flag name="lz4">Enable lz4 compression for the journal</flag>
<flag name="openssl">Enable use of <pkg>dev-libs/openssl</pkg> for various features</flag>
@@ -32,6 +33,7 @@
<flag name="resolvconf">Install resolvconf symlink for systemd-resolve</flag>
<flag name="sysv-utils">Install sysvinit compatibility symlinks and manpages for init, telinit, halt, poweroff, reboot, runlevel, and shutdown</flag>
<flag name="tpm">Enable TPM support</flag>
+ <flag name="ukify">Enable systemd-ukify</flag>
<flag name="vanilla">Disable Gentoo-specific behavior and compatibility quirks</flag>
<flag name="xkb">Depend on <pkg>x11-libs/libxkbcommon</pkg> to allow logind to control the X11 keymap</flag>
</use>
diff --git a/sys-apps/systemd/systemd-254.5.ebuild b/sys-apps/systemd/systemd-254.5-r1.ebuild
index 3fbd0bbf96e1..663677dee912 100644
--- a/sys-apps/systemd/systemd-254.5.ebuild
+++ b/sys-apps/systemd/systemd-254.5-r1.ebuild
@@ -36,9 +36,9 @@ LICENSE="GPL-2 LGPL-2.1 MIT public-domain"
SLOT="0/2"
IUSE="
acl apparmor audit boot cgroup-hybrid cryptsetup curl +dns-over-tls elfutils
- fido2 +gcrypt gnutls homed http idn importd iptables +kmod
+ fido2 +gcrypt gnutls homed http idn importd iptables kernel-install +kmod
+lz4 lzma +openssl pam pcre pkcs11 policykit pwquality qrcode
- +resolvconf +seccomp selinux split-usr +sysv-utils test tpm vanilla xkb +zstd
+ +resolvconf +seccomp selinux split-usr +sysv-utils test tpm ukify vanilla xkb +zstd
"
REQUIRED_USE="
${PYTHON_REQUIRED_USE}
@@ -47,6 +47,8 @@ REQUIRED_USE="
homed? ( cryptsetup pam openssl )
importd? ( curl lzma || ( gcrypt openssl ) )
pwquality? ( homed )
+ boot? ( kernel-install )
+ ukify? ( boot )
"
RESTRICT="!test? ( test )"
@@ -124,7 +126,7 @@ RDEPEND="${COMMON_DEPEND}
>=acct-user/systemd-resolve-0-r1
>=acct-user/systemd-timesync-0-r1
>=sys-apps/baselayout-2.2
- boot? (
+ ukify? (
${PYTHON_DEPS}
$(python_gen_cond_dep "${PEFILE_DEPEND}")
)
@@ -170,10 +172,8 @@ BDEPEND="
$(python_gen_cond_dep "
dev-python/jinja[\${PYTHON_USEDEP}]
dev-python/lxml[\${PYTHON_USEDEP}]
- boot? (
- >=dev-python/pyelftools-0.30[\${PYTHON_USEDEP}]
- test? ( ${PEFILE_DEPEND} )
- )
+ boot? ( >=dev-python/pyelftools-0.30[\${PYTHON_USEDEP}] )
+ ukify? ( test? ( ${PEFILE_DEPEND} ) )
")
"
@@ -302,6 +302,7 @@ multilib_src_configure() {
$(meson_native_use_bool importd)
$(meson_native_use_bool importd bzip2)
$(meson_native_use_bool importd zlib)
+ $(meson_native_use_bool kernel-install)
$(meson_native_use_bool kmod)
$(meson_use lz4)
$(meson_use lzma xz)
@@ -319,6 +320,7 @@ multilib_src_configure() {
$(meson_native_use_bool selinux)
$(meson_native_use_bool tpm tpm2)
$(meson_native_use_bool test dbus)
+ $(meson_native_use_bool ukify)
$(meson_native_use_bool xkb xkbcommon)
-Dntp-servers="0.gentoo.pool.ntp.org 1.gentoo.pool.ntp.org 2.gentoo.pool.ntp.org 3.gentoo.pool.ntp.org"
# Breaks screen, tmux, etc.
@@ -408,10 +410,8 @@ multilib_src_install_all() {
gen_usr_ldscript -a systemd udev
- if use boot; then
- python_fix_shebang "${ED}"
- secureboot_auto_sign
- fi
+ use ukify && python_fix_shebang "${ED}"
+ use boot && secureboot_auto_sign
}
migrate_locale() {
diff --git a/sys-apps/systemd/systemd-9999.ebuild b/sys-apps/systemd/systemd-9999.ebuild
index 7c6c59f40926..f4cfdbfefc00 100644
--- a/sys-apps/systemd/systemd-9999.ebuild
+++ b/sys-apps/systemd/systemd-9999.ebuild
@@ -36,9 +36,9 @@ LICENSE="GPL-2 LGPL-2.1 MIT public-domain"
SLOT="0/2"
IUSE="
acl apparmor audit boot cgroup-hybrid cryptsetup curl +dns-over-tls elfutils
- fido2 +gcrypt gnutls homed http idn importd iptables +kmod
+ fido2 +gcrypt gnutls homed http idn importd iptables kernel-install +kmod
+lz4 lzma +openssl pam pcre pkcs11 policykit pwquality qrcode
- +resolvconf +seccomp selinux split-usr +sysv-utils test tpm vanilla xkb +zstd
+ +resolvconf +seccomp selinux split-usr +sysv-utils test tpm ukify vanilla xkb +zstd
"
REQUIRED_USE="
${PYTHON_REQUIRED_USE}
@@ -47,6 +47,8 @@ REQUIRED_USE="
homed? ( cryptsetup pam openssl )
importd? ( curl lzma || ( gcrypt openssl ) )
pwquality? ( homed )
+ boot? ( kernel-install )
+ ukify? ( boot )
"
RESTRICT="!test? ( test )"
@@ -124,7 +126,7 @@ RDEPEND="${COMMON_DEPEND}
>=acct-user/systemd-resolve-0-r1
>=acct-user/systemd-timesync-0-r1
>=sys-apps/baselayout-2.2
- boot? (
+ ukify? (
${PYTHON_DEPS}
$(python_gen_cond_dep "${PEFILE_DEPEND}")
)
@@ -170,10 +172,8 @@ BDEPEND="
$(python_gen_cond_dep "
dev-python/jinja[\${PYTHON_USEDEP}]
dev-python/lxml[\${PYTHON_USEDEP}]
- boot? (
- >=dev-python/pyelftools-0.30[\${PYTHON_USEDEP}]
- test? ( ${PEFILE_DEPEND} )
- )
+ boot? ( >=dev-python/pyelftools-0.30[\${PYTHON_USEDEP}] )
+ ukify? ( test? ( ${PEFILE_DEPEND} ) )
")
"
@@ -300,6 +300,7 @@ multilib_src_configure() {
$(meson_native_use_bool importd)
$(meson_native_use_bool importd bzip2)
$(meson_native_use_bool importd zlib)
+ $(meson_native_use_bool kernel-install)
$(meson_native_use_bool kmod)
$(meson_use lz4)
$(meson_use lzma xz)
@@ -317,6 +318,7 @@ multilib_src_configure() {
$(meson_native_use_bool selinux)
$(meson_native_use_bool tpm tpm2)
$(meson_native_use_bool test dbus)
+ $(meson_native_use_bool ukify)
$(meson_native_use_bool xkb xkbcommon)
-Dntp-servers="0.gentoo.pool.ntp.org 1.gentoo.pool.ntp.org 2.gentoo.pool.ntp.org 3.gentoo.pool.ntp.org"
# Breaks screen, tmux, etc.
@@ -395,10 +397,8 @@ multilib_src_install_all() {
newpamd "${FILESDIR}"/systemd-user.pam systemd-user
fi
- if use boot; then
- python_fix_shebang "${ED}"
- secureboot_auto_sign
- fi
+ use ukify && python_fix_shebang "${ED}"
+ use boot && secureboot_auto_sign
}
migrate_locale() {