diff options
| -rw-r--r-- | meta/recipes-core/busybox/busybox.inc | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/meta/recipes-core/busybox/busybox.inc b/meta/recipes-core/busybox/busybox.inc index 2f269534bb..8b38c1aaa8 100644 --- a/meta/recipes-core/busybox/busybox.inc +++ b/meta/recipes-core/busybox/busybox.inc | |||
| @@ -274,25 +274,28 @@ do_install () { | |||
| 274 | 274 | ||
| 275 | ln -sf /dev/null ${D}${systemd_unitdir}/system/syslog.service | 275 | ln -sf /dev/null ${D}${systemd_unitdir}/system/syslog.service |
| 276 | fi | 276 | fi |
| 277 | |||
| 278 | # Remove the sysvinit specific configuration file for systemd systems to avoid confusion | ||
| 279 | if ${@base_contains('DISTRO_FEATURES', 'sysvinit', 'false', 'true', d)}; then | ||
| 280 | rm ${D}${sysconfdir}/syslog-startup.conf.${BPN} | ||
| 281 | fi | ||
| 277 | } | 282 | } |
| 278 | 283 | ||
| 279 | inherit update-alternatives | 284 | inherit update-alternatives |
| 280 | 285 | ||
| 281 | ALTERNATIVE_PRIORITY = "50" | 286 | ALTERNATIVE_PRIORITY = "50" |
| 282 | 287 | ||
| 283 | ALTERNATIVE_${PN}-syslog = "syslog-startup-conf" | ||
| 284 | |||
| 285 | python () { | 288 | python () { |
| 286 | if 'sysvinit' in d.getVar("DISTRO_FEATURES", True).split(): | 289 | if 'sysvinit' in d.getVar("DISTRO_FEATURES", True).split(): |
| 287 | pn = d.getVar('PN', True) | 290 | pn = d.getVar('PN', True) |
| 288 | d.appendVar('ALTERNATIVE_%s-syslog' % (pn), ' syslog-init') | 291 | d.appendVar('ALTERNATIVE_%s-syslog' % (pn), ' syslog-init') |
| 289 | d.setVarFlag('ALTERNATIVE_LINK_NAME', 'syslog-init', '%s/init.d/syslog' % (d.getVar('sysconfdir', True))) | 292 | 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))) | 293 | d.setVarFlag('ALTERNATIVE_TARGET', 'syslog-init', '%s/init.d/syslog.%s' % (d.getVar('sysconfdir', True), d.getVar('BPN', True))) |
| 294 | d.appendVar('ALTERNATIVE_%s-syslog' % (pn), ' syslog-startup-conf') | ||
| 295 | d.setVarFlag('ALTERNATIVE_LINK_NAME', 'syslog-startup-conf', '%s/syslog-startup.conf' % (d.getVar('sysconfdir', True))) | ||
| 296 | d.setVarFlag('ALTERNATIVE_TARGET', 'syslog-startup-conf', '%s/syslog-startup.conf.%s' % (d.getVar('sysconfdir', True), d.getVar('BPN', True))) | ||
| 291 | } | 297 | } |
| 292 | 298 | ||
| 293 | ALTERNATIVE_LINK_NAME[syslog-startup-conf] = "${sysconfdir}/syslog-startup.conf" | ||
| 294 | ALTERNATIVE_TARGET[syslog-startup-conf] = "${sysconfdir}/syslog-startup.conf.${BPN}" | ||
| 295 | |||
| 296 | python do_package_prepend () { | 299 | python do_package_prepend () { |
| 297 | # We need to load the full set of busybox provides from the /etc/busybox.links | 300 | # We need to load the full set of busybox provides from the /etc/busybox.links |
| 298 | # Use this to see the update-alternatives with the right information | 301 | # Use this to see the update-alternatives with the right information |
