diff options
author | Anuj Mittal <anuj.mittal@intel.com> | 2018-10-11 16:41:11 +0800 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2018-10-12 16:57:21 +0100 |
commit | 8421aede4fdd5132eb953a59099670f9ab1f7f01 (patch) | |
tree | a6f597520994f50cbb4969aea2f91f5afe1d6670 | |
parent | ef4a417ab04779bd9fc8a6540a20cca7d14e98cf (diff) | |
download | poky-8421aede4fdd5132eb953a59099670f9ab1f7f01.tar.gz |
systemd: add ALTERNATIVE for reboot
reboot is provided by busybox too. Add ALTERNATIVE to ensure that there
are no conflicts when both are installed.
(From OE-Core rev: a27a197ad4bb32fa93aa95e685e9e70ffe755811)
Signed-off-by: Anuj Mittal <anuj.mittal@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r-- | meta/recipes-core/systemd/systemd_239.bb | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/meta/recipes-core/systemd/systemd_239.bb b/meta/recipes-core/systemd/systemd_239.bb index 194efb5b94..7ed932141d 100644 --- a/meta/recipes-core/systemd/systemd_239.bb +++ b/meta/recipes-core/systemd/systemd_239.bb | |||
@@ -447,7 +447,7 @@ FILES_${PN} = " ${base_bindir}/* \ | |||
447 | ${base_sbindir}/runlevel \ | 447 | ${base_sbindir}/runlevel \ |
448 | ${base_sbindir}/telinit \ | 448 | ${base_sbindir}/telinit \ |
449 | ${base_sbindir}/resolvconf \ | 449 | ${base_sbindir}/resolvconf \ |
450 | ${base_sbindir}/reboot \ | 450 | ${base_sbindir}/reboot.systemd \ |
451 | ${base_sbindir}/init \ | 451 | ${base_sbindir}/init \ |
452 | ${datadir}/dbus-1/services \ | 452 | ${datadir}/dbus-1/services \ |
453 | ${datadir}/dbus-1/system-services \ | 453 | ${datadir}/dbus-1/system-services \ |
@@ -556,12 +556,15 @@ python __anonymous() { | |||
556 | d.setVar("INHIBIT_UPDATERCD_BBCLASS", "1") | 556 | d.setVar("INHIBIT_UPDATERCD_BBCLASS", "1") |
557 | } | 557 | } |
558 | 558 | ||
559 | ALTERNATIVE_${PN} = "resolv-conf" | 559 | ALTERNATIVE_${PN} = "resolv-conf reboot" |
560 | 560 | ||
561 | ALTERNATIVE_TARGET[resolv-conf] = "${sysconfdir}/resolv-conf.systemd" | 561 | ALTERNATIVE_TARGET[resolv-conf] = "${sysconfdir}/resolv-conf.systemd" |
562 | ALTERNATIVE_LINK_NAME[resolv-conf] = "${sysconfdir}/resolv.conf" | 562 | ALTERNATIVE_LINK_NAME[resolv-conf] = "${sysconfdir}/resolv.conf" |
563 | ALTERNATIVE_PRIORITY[resolv-conf] ?= "50" | 563 | ALTERNATIVE_PRIORITY[resolv-conf] ?= "50" |
564 | 564 | ||
565 | ALTERNATIVE_LINK_NAME[reboot] = "${base_sbindir}/reboot" | ||
566 | ALTERNATIVE_PRIORITY[reboot] = "100" | ||
567 | |||
565 | pkg_postinst_${PN} () { | 568 | pkg_postinst_${PN} () { |
566 | sed -e '/^hosts:/s/\s*\<myhostname\>//' \ | 569 | sed -e '/^hosts:/s/\s*\<myhostname\>//' \ |
567 | -e 's/\(^hosts:.*\)\(\<files\>\)\(.*\)\(\<dns\>\)\(.*\)/\1\2 myhostname \3\4\5/' \ | 570 | -e 's/\(^hosts:.*\)\(\<files\>\)\(.*\)\(\<dns\>\)\(.*\)/\1\2 myhostname \3\4\5/' \ |