sys-apps/systemd: fix file collisions with sysv-utils disabled

Closes: https://bugs.gentoo.org/650160
Package-Manager: Portage-2.3.24, Repoman-2.3.6_p81
This commit is contained in:
Mike Gilbert
2018-03-10 22:26:10 -05:00
parent 592f387c8b
commit 208664c8fc
2 changed files with 8 additions and 20 deletions

View File

@@ -302,17 +302,11 @@ multilib_src_install_all() {
einstalldocs
dodoc "${FILESDIR}"/nsswitch.conf
if use sysv-utils; then
local app
for app in halt poweroff reboot runlevel shutdown telinit; do
dosym ../bin/systemctl /sbin/${app}
done
dosym ../lib/systemd/systemd /sbin/init
else
# we just keep sysvinit tools, so no need for the mans
rm "${ED%/}"/usr/share/man/man8/{halt,poweroff,reboot,runlevel,shutdown,telinit}.8 \
|| die
if ! use sysv-utils; then
rm "${ED%/}"/sbin/{halt,init,poweroff,reboot,runlevel,shutdown,telinit} || die
rmdir "${ED%/}"/sbin || die
rm "${ED%/}"/usr/share/man/man1/init.1 || die
rm "${ED%/}"/usr/share/man/man8/{halt,poweroff,reboot,runlevel,shutdown,telinit}.8 || die
fi
# Preserve empty dirs in /etc & /var, bug #437008

View File

@@ -300,17 +300,11 @@ multilib_src_install_all() {
einstalldocs
dodoc "${FILESDIR}"/nsswitch.conf
if use sysv-utils; then
local app
for app in halt poweroff reboot runlevel shutdown telinit; do
dosym ../bin/systemctl /sbin/${app}
done
dosym ../lib/systemd/systemd /sbin/init
else
# we just keep sysvinit tools, so no need for the mans
rm "${ED%/}"/usr/share/man/man8/{halt,poweroff,reboot,runlevel,shutdown,telinit}.8 \
|| die
if ! use sysv-utils; then
rm "${ED%/}"/sbin/{halt,init,poweroff,reboot,runlevel,shutdown,telinit} || die
rmdir "${ED%/}"/sbin || die
rm "${ED%/}"/usr/share/man/man1/init.1 || die
rm "${ED%/}"/usr/share/man/man8/{halt,poweroff,reboot,runlevel,shutdown,telinit}.8 || die
fi
# Preserve empty dirs in /etc & /var, bug #437008