diff options
Diffstat (limited to 'meta/classes/update-rc.d.bbclass')
| -rw-r--r-- | meta/classes/update-rc.d.bbclass | 28 |
1 files changed, 14 insertions, 14 deletions
diff --git a/meta/classes/update-rc.d.bbclass b/meta/classes/update-rc.d.bbclass index 1366fee653..0a3a608662 100644 --- a/meta/classes/update-rc.d.bbclass +++ b/meta/classes/update-rc.d.bbclass | |||
| @@ -1,11 +1,11 @@ | |||
| 1 | UPDATERCPN ?= "${PN}" | 1 | UPDATERCPN ?= "${PN}" |
| 2 | 2 | ||
| 3 | DEPENDS_append_class-target = "${@bb.utils.contains('DISTRO_FEATURES', 'sysvinit', ' update-rc.d initscripts', '', d)}" | 3 | DEPENDS:append:class-target = "${@bb.utils.contains('DISTRO_FEATURES', 'sysvinit', ' update-rc.d initscripts', '', d)}" |
| 4 | 4 | ||
| 5 | UPDATERCD = "update-rc.d" | 5 | UPDATERCD = "update-rc.d" |
| 6 | UPDATERCD_class-cross = "" | 6 | UPDATERCD:class-cross = "" |
| 7 | UPDATERCD_class-native = "" | 7 | UPDATERCD:class-native = "" |
| 8 | UPDATERCD_class-nativesdk = "" | 8 | UPDATERCD:class-nativesdk = "" |
| 9 | 9 | ||
| 10 | INITSCRIPT_PARAMS ?= "defaults" | 10 | INITSCRIPT_PARAMS ?= "defaults" |
| 11 | 11 | ||
| @@ -62,8 +62,8 @@ python __anonymous() { | |||
| 62 | update_rc_after_parse(d) | 62 | update_rc_after_parse(d) |
| 63 | } | 63 | } |
| 64 | 64 | ||
| 65 | PACKAGESPLITFUNCS_prepend = "${@bb.utils.contains('DISTRO_FEATURES', 'sysvinit', 'populate_packages_updatercd ', '', d)}" | 65 | PACKAGESPLITFUNCS:prepend = "${@bb.utils.contains('DISTRO_FEATURES', 'sysvinit', 'populate_packages_updatercd ', '', d)}" |
| 66 | PACKAGESPLITFUNCS_remove_class-nativesdk = "populate_packages_updatercd " | 66 | PACKAGESPLITFUNCS:remove:class-nativesdk = "populate_packages_updatercd " |
| 67 | 67 | ||
| 68 | populate_packages_updatercd[vardeps] += "updatercd_prerm updatercd_postrm updatercd_postinst" | 68 | populate_packages_updatercd[vardeps] += "updatercd_prerm updatercd_postrm updatercd_postinst" |
| 69 | populate_packages_updatercd[vardepsexclude] += "OVERRIDES" | 69 | populate_packages_updatercd[vardepsexclude] += "OVERRIDES" |
| @@ -78,7 +78,7 @@ python populate_packages_updatercd () { | |||
| 78 | statement = "grep -q -w '/etc/init.d/functions' %s" % path | 78 | statement = "grep -q -w '/etc/init.d/functions' %s" % path |
| 79 | if subprocess.call(statement, shell=True) == 0: | 79 | if subprocess.call(statement, shell=True) == 0: |
| 80 | mlprefix = d.getVar('MLPREFIX') or "" | 80 | mlprefix = d.getVar('MLPREFIX') or "" |
| 81 | d.appendVar('RDEPENDS_' + pkg, ' %sinitd-functions' % (mlprefix)) | 81 | d.appendVar('RDEPENDS:' + pkg, ' %sinitd-functions' % (mlprefix)) |
| 82 | 82 | ||
| 83 | def update_rcd_package(pkg): | 83 | def update_rcd_package(pkg): |
| 84 | bb.debug(1, 'adding update-rc.d calls to postinst/prerm/postrm for %s' % pkg) | 84 | bb.debug(1, 'adding update-rc.d calls to postinst/prerm/postrm for %s' % pkg) |
| @@ -89,25 +89,25 @@ python populate_packages_updatercd () { | |||
| 89 | 89 | ||
| 90 | update_rcd_auto_depend(pkg) | 90 | update_rcd_auto_depend(pkg) |
| 91 | 91 | ||
| 92 | postinst = d.getVar('pkg_postinst_%s' % pkg) | 92 | postinst = d.getVar('pkg_postinst:%s' % pkg) |
| 93 | if not postinst: | 93 | if not postinst: |
| 94 | postinst = '#!/bin/sh\n' | 94 | postinst = '#!/bin/sh\n' |
| 95 | postinst += localdata.getVar('updatercd_postinst') | 95 | postinst += localdata.getVar('updatercd_postinst') |
| 96 | d.setVar('pkg_postinst_%s' % pkg, postinst) | 96 | d.setVar('pkg_postinst:%s' % pkg, postinst) |
| 97 | 97 | ||
| 98 | prerm = d.getVar('pkg_prerm_%s' % pkg) | 98 | prerm = d.getVar('pkg_prerm:%s' % pkg) |
| 99 | if not prerm: | 99 | if not prerm: |
| 100 | prerm = '#!/bin/sh\n' | 100 | prerm = '#!/bin/sh\n' |
| 101 | prerm += localdata.getVar('updatercd_prerm') | 101 | prerm += localdata.getVar('updatercd_prerm') |
| 102 | d.setVar('pkg_prerm_%s' % pkg, prerm) | 102 | d.setVar('pkg_prerm:%s' % pkg, prerm) |
| 103 | 103 | ||
| 104 | postrm = d.getVar('pkg_postrm_%s' % pkg) | 104 | postrm = d.getVar('pkg_postrm:%s' % pkg) |
| 105 | if not postrm: | 105 | if not postrm: |
| 106 | postrm = '#!/bin/sh\n' | 106 | postrm = '#!/bin/sh\n' |
| 107 | postrm += localdata.getVar('updatercd_postrm') | 107 | postrm += localdata.getVar('updatercd_postrm') |
| 108 | d.setVar('pkg_postrm_%s' % pkg, postrm) | 108 | d.setVar('pkg_postrm:%s' % pkg, postrm) |
| 109 | 109 | ||
| 110 | d.appendVar('RRECOMMENDS_' + pkg, " ${MLPREFIX}${UPDATERCD}") | 110 | d.appendVar('RRECOMMENDS:' + pkg, " ${MLPREFIX}${UPDATERCD}") |
| 111 | 111 | ||
| 112 | # Check that this class isn't being inhibited (generally, by | 112 | # Check that this class isn't being inhibited (generally, by |
| 113 | # systemd.bbclass) before doing any work. | 113 | # systemd.bbclass) before doing any work. |
