[oe-commits] Khem Raj : rootfs: Conditionally uninstall update-rc.d
git at git.openembedded.org
git at git.openembedded.org
Fri Sep 11 22:42:03 UTC 2015
Module: openembedded-core.git
Branch: master-next
Commit: 5dd5b8adc225d5c703d85fc0187ae65ff6067b58
URL: http://git.openembedded.org/?p=openembedded-core.git&a=commit;h=5dd5b8adc225d5c703d85fc0187ae65ff6067b58
Author: Khem Raj <raj.khem at gmail.com>
Date: Sun Sep 6 15:08:15 2015 +0000
rootfs: Conditionally uninstall update-rc.d
update-rc.d is now needed by systemd to interact with sysv
scripts, so if we have a mixed system, then we can not uninstall
update-rc.d as it is going to break systemd functionality, we check for
sysvinit and sytemd in distro and also ensure that its not building an
image with readonly rootfs
Signed-off-by: Khem Raj <raj.khem at gmail.com>
---
meta/lib/oe/rootfs.py | 10 +++++++++-
1 file changed, 9 insertions(+), 1 deletion(-)
diff --git a/meta/lib/oe/rootfs.py b/meta/lib/oe/rootfs.py
index 2372226..3b53fce 100644
--- a/meta/lib/oe/rootfs.py
+++ b/meta/lib/oe/rootfs.py
@@ -230,6 +230,14 @@ class Rootfs(object):
runtime_pkgmanage = bb.utils.contains("IMAGE_FEATURES", "package-management",
True, False, self.d)
+ sysvcompat_in_distro = bb.utils.contains("DISTRO_FEATURES", [ "systemd", "sysvinit" ],
+ True, False, self.d)
+ image_rorfs = bb.utils.contains("IMAGE_FEATURES", "read-only-rootfs",
+ True, False, self.d)
+ if sysvcompat_in_distro and not image_rorfs:
+ pkg_to_remove = ""
+ else:
+ pkg_to_remove = "update-rc.d"
if not runtime_pkgmanage:
# Remove components that we don't need if we're not going to install
# additional packages at runtime
@@ -243,7 +251,7 @@ class Rootfs(object):
if pkg in ["update-rc.d",
"base-passwd",
"shadow",
- "update-alternatives",
+ "update-alternatives", pkg_to_remove,
self.d.getVar("ROOTFS_BOOTSTRAP_INSTALL", True)
]:
pkgs_to_remove.append(pkg)
More information about the Openembedded-commits
mailing list