commit:     1e1b278d4fd7e09720ef65bb83d16c91d032f7c5
Author:     Joonas Niilola <juippis <AT> gentoo <DOT> org>
AuthorDate: Fri Apr  5 13:21:29 2024 +0000
Commit:     Joonas Niilola <juippis <AT> gentoo <DOT> org>
CommitDate: Fri Apr  5 13:24:17 2024 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=1e1b278d

app-containers/lxc: flip -Dinstall-init-files from false to true

 - it installs more files, under /etc/default, /usr/libexec, etc, that
   may be important to some users.

Signed-off-by: Joonas Niilola <juippis <AT> gentoo.org>

 app-containers/lxc/{lxc-6.0.0.ebuild => lxc-6.0.0-r1.ebuild} | 10 ++++++++--
 1 file changed, 8 insertions(+), 2 deletions(-)

diff --git a/app-containers/lxc/lxc-6.0.0.ebuild 
b/app-containers/lxc/lxc-6.0.0-r1.ebuild
similarity index 94%
rename from app-containers/lxc/lxc-6.0.0.ebuild
rename to app-containers/lxc/lxc-6.0.0-r1.ebuild
index 7452b2ec74ca..64d7aef60e47 100644
--- a/app-containers/lxc/lxc-6.0.0.ebuild
+++ b/app-containers/lxc/lxc-6.0.0-r1.ebuild
@@ -74,7 +74,6 @@ pkg_setup() {
 
 src_configure() {
 
-       # -Dinstall-init-files=false: prefer our own files from ${FILESDIR}
        # -Dtools-multicall=false: will create a single binary called 'lxc' 
that conflicts with LXD.
        local emesonargs=(
                --localstatedir "${EPREFIX}/var"
@@ -82,13 +81,13 @@ src_configure() {
                -Ddbus=true
 
                -Dcoverity-build=false
-               -Dinstall-init-files=false
                -Dinstall-state-dirs=false
                -Doss-fuzz=false
                -Dspecfile=false
                -Dtools-multicall=false
 
                -Dcommands=true
+               -Dinstall-init-files=true
                -Dmemfd-rexec=true
                -Dthread-safety=true
 
@@ -139,6 +138,13 @@ src_install() {
 
        find "${ED}" -name '*.la' -delete -o -name '*.a' -delete || die
 
+       # Replace upstream sysvinit/systemd files.
+       if use systemd; then
+       rm -r "${D}$(systemd_get_systemunitdir)" || die "Failed to remove 
systemd lib dir"
+       else
+               rm "${ED}"/etc/init.d/lxc-{containers,net} || die "Failed to 
remove sysvinit scripts"
+       fi
+
        newinitd "${FILESDIR}/${PN}.initd.9" ${PN}
        systemd_newunit "${FILESDIR}"/lxc-monitord.service.5.0.0 
lxc-monitord.service
        systemd_newunit "${FILESDIR}"/lxc-net.service.5.0.0 lxc-net.service

Reply via email to