sys-kernel/dracut: add 'dracut-cpio' USE flag

Signed-off-by: Mike Gilbert <floppym@gentoo.org>
This commit is contained in:
Mike Gilbert
2024-11-12 12:24:25 -05:00
parent 39c4d60e78
commit 3cc00482e6
2 changed files with 12 additions and 2 deletions
+9 -2
View File
@@ -2,8 +2,9 @@
# Distributed under the terms of the GNU General Public License v2
EAPI=8
RUST_OPTIONAL=1
inherit flag-o-matic bash-completion-r1 edo optfeature systemd toolchain-funcs
inherit flag-o-matic bash-completion-r1 edo optfeature rust systemd toolchain-funcs
if [[ ${PV} == 9999 ]] ; then
inherit git-r3
@@ -21,7 +22,7 @@ HOMEPAGE="https://github.com/dracut-ng/dracut-ng/wiki"
LICENSE="GPL-2"
SLOT="0"
IUSE="selinux test"
IUSE="+dracut-cpio selinux test"
RESTRICT="test"
PROPERTIES="test? ( test_privileged test_network )"
@@ -50,6 +51,7 @@ RDEPEND="
"
DEPEND="
>=sys-apps/kmod-23
dracut-cpio? ( ${RUST_DEPEND} )
elibc_musl? ( sys-libs/fts-standalone )
"
@@ -101,12 +103,17 @@ PATCHES=(
"${FILESDIR}"/${PN}-103-acct-user-group-gentoo.patch
)
pkg_setup() {
use dracut-cpio && rust_pkg_setup
}
src_configure() {
local myconf=(
--prefix="${EPREFIX}/usr"
--sysconfdir="${EPREFIX}/etc"
--bashcompletiondir="$(get_bashcompdir)"
--systemdsystemunitdir="$(systemd_get_systemunitdir)"
$(use_enable dracut-cpio)
)
# this emulates what the build system would be doing without us
+3
View File
@@ -13,6 +13,9 @@
<email>andrewammerlaan@gentoo.org</email>
<name>Andrew Ammerlaan</name>
</maintainer>
<use>
<flag name="dracut-cpio">Build the enhanced 'dracut-cpio' program</flag>
</use>
<upstream>
<remote-id type="github">dracut-ng/dracut-ng</remote-id>
</upstream>