summaryrefslogtreecommitdiffstats
path: root/meta/recipes-core
diff options
context:
space:
mode:
authorAnuj Mittal <anuj.mittal@intel.com>2018-10-11 16:41:11 +0800
committerRichard Purdie <richard.purdie@linuxfoundation.org>2018-10-12 16:57:21 +0100
commit8421aede4fdd5132eb953a59099670f9ab1f7f01 (patch)
treea6f597520994f50cbb4969aea2f91f5afe1d6670 /meta/recipes-core
parentef4a417ab04779bd9fc8a6540a20cca7d14e98cf (diff)
downloadpoky-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>
Diffstat (limited to 'meta/recipes-core')
-rw-r--r--meta/recipes-core/systemd/systemd_239.bb7
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
559ALTERNATIVE_${PN} = "resolv-conf" 559ALTERNATIVE_${PN} = "resolv-conf reboot"
560 560
561ALTERNATIVE_TARGET[resolv-conf] = "${sysconfdir}/resolv-conf.systemd" 561ALTERNATIVE_TARGET[resolv-conf] = "${sysconfdir}/resolv-conf.systemd"
562ALTERNATIVE_LINK_NAME[resolv-conf] = "${sysconfdir}/resolv.conf" 562ALTERNATIVE_LINK_NAME[resolv-conf] = "${sysconfdir}/resolv.conf"
563ALTERNATIVE_PRIORITY[resolv-conf] ?= "50" 563ALTERNATIVE_PRIORITY[resolv-conf] ?= "50"
564 564
565ALTERNATIVE_LINK_NAME[reboot] = "${base_sbindir}/reboot"
566ALTERNATIVE_PRIORITY[reboot] = "100"
567
565pkg_postinst_${PN} () { 568pkg_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/' \