path: root/meta/recipes-core/initscripts
diff options
authorChen Qi <>2014-01-06 15:27:34 +0800
committerRichard Purdie <>2014-01-06 16:30:00 +0000
commit736dd8380f41d6ff1d3d0e4fe33cc01e2e873ef6 (patch)
tree69674baaad81a99c2e54d9bdfa6e5ffc660f95c7 /meta/recipes-core/initscripts
parentd93fdb740e6b73fe168f64575f4ceb4b3db17504 (diff)
initscripts: split the functions script into a separate package
Many SysV init scripts need the /etc/init.d/functions script. But this script is part of the initscripts package. As a result, the initscripts package should always be installed into the system to avoid errors when starting daemons. However, it makes no sense to install the initscripts package into a systemd based image, because what the init scripts provide has already been provided by the systemd. On the other hand, the functions script might be still needed in a systemd based image because other init scripts such as distcc might need it. The above situation leads to a natural separation of the functions script from the initscripts package. And this patch does so. It separates the functions script into initscripts-functions packages. Signed-off-by: Chen Qi <> Signed-off-by: Richard Purdie <>
Diffstat (limited to 'meta/recipes-core/initscripts')
1 files changed, 6 insertions, 2 deletions
diff --git a/meta/recipes-core/initscripts/ b/meta/recipes-core/initscripts/
index 5951e0c198..d1644a3204 100644
--- a/meta/recipes-core/initscripts/
+++ b/meta/recipes-core/initscripts/
@@ -42,8 +42,12 @@ KERNEL_VERSION = ""
inherit update-alternatives
DEPENDS_append = " update-rc.d-native"
-ALTERNATIVE_${PN} = "functions"
+PACKAGES =+ "${PN}-functions"
+RDEPENDS_${PN} = "${PN}-functions"
+FILES_${PN}-functions = "${sysconfdir}/init.d/functions*"
+ALTERNATIVE_PRIORITY_${PN}-functions = "90"
+ALTERNATIVE_${PN}-functions = "functions"
ALTERNATIVE_LINK_NAME[functions] = "${sysconfdir}/init.d/functions"
HALTARGS ?= "-d -f"