diff options
author | Muhammad Shakeel <muhammad_shakeel@mentor.com> | 2013-07-29 13:09:52 +0500 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2013-07-31 06:59:56 +0100 |
commit | fe378e1d462d2c44b0e73c0d5b8647c3d90d300d (patch) | |
tree | 77b421f4c2b057d4f92515dcb6cbf30c7410c241 /meta/recipes-core | |
parent | 3b9b8d571da6bb3652427e8ccc7948cbcec0e517 (diff) | |
download | poky-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.inc | 11 |
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 | ||
281 | ALTERNATIVE_PRIORITY = "50" | 281 | ALTERNATIVE_PRIORITY = "50" |
282 | 282 | ||
283 | ALTERNATIVE_${PN}-syslog = "syslog-init syslog-startup-conf" | 283 | ALTERNATIVE_${PN}-syslog = "syslog-startup-conf" |
284 | 284 | ||
285 | ALTERNATIVE_LINK_NAME[syslog-init] = "${sysconfdir}/init.d/syslog" | 285 | python () { |
286 | ALTERNATIVE_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 | ||
288 | ALTERNATIVE_LINK_NAME[syslog-startup-conf] = "${sysconfdir}/syslog-startup.conf" | 293 | ALTERNATIVE_LINK_NAME[syslog-startup-conf] = "${sysconfdir}/syslog-startup.conf" |
289 | ALTERNATIVE_TARGET[syslog-startup-conf] = "${sysconfdir}/syslog-startup.conf.${BPN}" | 294 | ALTERNATIVE_TARGET[syslog-startup-conf] = "${sysconfdir}/syslog-startup.conf.${BPN}" |