summaryrefslogtreecommitdiffstats
path: root/meta/recipes-core
diff options
context:
space:
mode:
authorMuhammad Shakeel <muhammad_shakeel@mentor.com>2013-07-29 13:09:52 +0500
committerRichard Purdie <richard.purdie@linuxfoundation.org>2013-07-31 06:59:56 +0100
commitfe378e1d462d2c44b0e73c0d5b8647c3d90d300d (patch)
tree77b421f4c2b057d4f92515dcb6cbf30c7410c241 /meta/recipes-core
parent3b9b8d571da6bb3652427e8ccc7948cbcec0e517 (diff)
downloadpoky-fe378e1d462d2c44b0e73c0d5b8647c3d90d300d.tar.gz
busybox: Add syslog-init alternative only if SysV in enabled
If systemd is enabled then syslog is handled through a service file and related files in /etc/init.d are removed. This removes following warning: WARNING: busybox: NOT adding alternative provide /etc/init.d/syslog: /etc/init.d/syslog.busybox does not exist (From OE-Core rev: 29c3ecee32d9bfb03099a4f10456fd0270e107fb) Signed-off-by: Muhammad Shakeel <muhammad_shakeel@mentor.com> Signed-off-by: Saul Wold <sgw@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-core')
-rw-r--r--meta/recipes-core/busybox/busybox.inc11
1 files changed, 8 insertions, 3 deletions
diff --git a/meta/recipes-core/busybox/busybox.inc b/meta/recipes-core/busybox/busybox.inc
index acd2bfbcff..2f269534bb 100644
--- a/meta/recipes-core/busybox/busybox.inc
+++ b/meta/recipes-core/busybox/busybox.inc
@@ -280,10 +280,15 @@ inherit update-alternatives
280 280
281ALTERNATIVE_PRIORITY = "50" 281ALTERNATIVE_PRIORITY = "50"
282 282
283ALTERNATIVE_${PN}-syslog = "syslog-init syslog-startup-conf" 283ALTERNATIVE_${PN}-syslog = "syslog-startup-conf"
284 284
285ALTERNATIVE_LINK_NAME[syslog-init] = "${sysconfdir}/init.d/syslog" 285python () {
286ALTERNATIVE_TARGET[syslog-init] = "${sysconfdir}/init.d/syslog.${BPN}" 286 if 'sysvinit' in d.getVar("DISTRO_FEATURES", True).split():
287 pn = d.getVar('PN', True)
288 d.appendVar('ALTERNATIVE_%s-syslog' % (pn), ' syslog-init')
289 d.setVarFlag('ALTERNATIVE_LINK_NAME', 'syslog-init', '%s/init.d/syslog' % (d.getVar('sysconfdir', True)))
290 d.setVarFlag('ALTERNATIVE_TARGET', 'syslog-init', '%s/init.d/syslog.%s' % (d.getVar('sysconfdir', True), d.getVar('BPN', True)))
291}
287 292
288ALTERNATIVE_LINK_NAME[syslog-startup-conf] = "${sysconfdir}/syslog-startup.conf" 293ALTERNATIVE_LINK_NAME[syslog-startup-conf] = "${sysconfdir}/syslog-startup.conf"
289ALTERNATIVE_TARGET[syslog-startup-conf] = "${sysconfdir}/syslog-startup.conf.${BPN}" 294ALTERNATIVE_TARGET[syslog-startup-conf] = "${sysconfdir}/syslog-startup.conf.${BPN}"