commit:     d80667d80ec11906c6b3b570f5bb9a55a0e7b318
Author:     Mike Gilbert <floppym <AT> gentoo <DOT> org>
AuthorDate: Mon Aug 12 14:11:15 2019 +0000
Commit:     Mike Gilbert <floppym <AT> gentoo <DOT> org>
CommitDate: Mon Aug 12 14:12:02 2019 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=d80667d8

sys-apps/systemd: enable some basic services for new installs

Also update the preset-all postinst message.

Bug: https://bugs.gentoo.org/691854
Package-Manager: Portage-2.3.71, Repoman-2.3.16_p24
Signed-off-by: Mike Gilbert <floppym <AT> gentoo.org>

 sys-apps/systemd/systemd-242-r6.ebuild     | 13 ++++++++-----
 sys-apps/systemd/systemd-243_rc1-r2.ebuild | 13 ++++++++-----
 sys-apps/systemd/systemd-9999.ebuild       | 13 ++++++++-----
 3 files changed, 24 insertions(+), 15 deletions(-)

diff --git a/sys-apps/systemd/systemd-242-r6.ebuild 
b/sys-apps/systemd/systemd-242-r6.ebuild
index 96430b07ddd..ca3aee2f6d1 100644
--- a/sys-apps/systemd/systemd-242-r6.ebuild
+++ b/sys-apps/systemd/systemd-242-r6.ebuild
@@ -465,6 +465,14 @@ pkg_postinst() {
                systemctl --root="${ROOT:-/}" enable "${ENABLED_UNITS[@]}"
        fi
 
+       if [[ -z ${REPLACING_VERSIONS} ]]; then
+               if type systemctl &>/dev/null; then
+                       systemctl --root="${ROOT:-/}" enable [email protected] 
remote-fs.target || FAIL=1
+               fi
+               elog "To enable a useful set of services, run the following:"
+               elog "  systemctl preset-all --preset-mode=enable-only"
+       fi
+
        if [[ -L ${EROOT}/var/lib/systemd/timesync ]]; then
                rm "${EROOT}/var/lib/systemd/timesync"
        fi
@@ -481,11 +489,6 @@ pkg_postinst() {
                eerror "systemd again."
                eerror
        fi
-
-       if [[ -z ${REPLACING_VERSIONS} ]]; then
-               elog "To enable a useful set of services, run the following:"
-               elog "  systemctl preset-all"
-       fi
 }
 
 pkg_prerm() {

diff --git a/sys-apps/systemd/systemd-243_rc1-r2.ebuild 
b/sys-apps/systemd/systemd-243_rc1-r2.ebuild
index d67b45ec87d..988973dd9a7 100644
--- a/sys-apps/systemd/systemd-243_rc1-r2.ebuild
+++ b/sys-apps/systemd/systemd-243_rc1-r2.ebuild
@@ -449,6 +449,14 @@ pkg_postinst() {
                systemctl --root="${ROOT:-/}" enable "${ENABLED_UNITS[@]}"
        fi
 
+       if [[ -z ${REPLACING_VERSIONS} ]]; then
+               if type systemctl &>/dev/null; then
+                       systemctl --root="${ROOT:-/}" enable [email protected] 
remote-fs.target || FAIL=1
+               fi
+               elog "To enable a useful set of services, run the following:"
+               elog "  systemctl preset-all --preset-mode=enable-only"
+       fi
+
        if [[ -L ${EROOT}/var/lib/systemd/timesync ]]; then
                rm "${EROOT}/var/lib/systemd/timesync"
        fi
@@ -465,11 +473,6 @@ pkg_postinst() {
                eerror "systemd again."
                eerror
        fi
-
-       if [[ -z ${REPLACING_VERSIONS} ]]; then
-               elog "To enable a useful set of services, run the following:"
-               elog "  systemctl preset-all"
-       fi
 }
 
 pkg_prerm() {

diff --git a/sys-apps/systemd/systemd-9999.ebuild 
b/sys-apps/systemd/systemd-9999.ebuild
index c4350573c99..7556cea0b55 100644
--- a/sys-apps/systemd/systemd-9999.ebuild
+++ b/sys-apps/systemd/systemd-9999.ebuild
@@ -445,6 +445,14 @@ pkg_postinst() {
                systemctl --root="${ROOT:-/}" enable "${ENABLED_UNITS[@]}"
        fi
 
+       if [[ -z ${REPLACING_VERSIONS} ]]; then
+               if type systemctl &>/dev/null; then
+                       systemctl --root="${ROOT:-/}" enable [email protected] 
remote-fs.target || FAIL=1
+               fi
+               elog "To enable a useful set of services, run the following:"
+               elog "  systemctl preset-all --preset-mode=enable-only"
+       fi
+
        if [[ -L ${EROOT}/var/lib/systemd/timesync ]]; then
                rm "${EROOT}/var/lib/systemd/timesync"
        fi
@@ -461,11 +469,6 @@ pkg_postinst() {
                eerror "systemd again."
                eerror
        fi
-
-       if [[ -z ${REPLACING_VERSIONS} ]]; then
-               elog "To enable a useful set of services, run the following:"
-               elog "  systemctl preset-all"
-       fi
 }
 
 pkg_prerm() {

Reply via email to