summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChangqing Li <changqing.li@windriver.com>2020-06-30 17:50:53 +0800
committerRichard Purdie <richard.purdie@linuxfoundation.org>2020-06-30 23:02:11 +0100
commit790276bde066ecc9876120c3097dcd57a9936f00 (patch)
treef8d38c6ef50b7ecb85c372135bd82931eedd9761
parenteec648f23df0a4e05130f8ef5a04902296567e38 (diff)
downloadopenembedded-core-790276bde066ecc9876120c3097dcd57a9936f00.tar.gz
openembedded-core-790276bde066ecc9876120c3097dcd57a9936f00.tar.bz2
openembedded-core-790276bde066ecc9876120c3097dcd57a9936f00.zip
initscripts: update postinst
in container image, it don't have init system, install package initscripts will report error: systemctl: command not found fix by use same way as systemd.bbclass to decide if systemctl mask will run Signed-off-by: Changqing Li <changqing.li@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--meta/recipes-core/initscripts/initscripts_1.0.bb2
1 files changed, 1 insertions, 1 deletions
diff --git a/meta/recipes-core/initscripts/initscripts_1.0.bb b/meta/recipes-core/initscripts/initscripts_1.0.bb
index 4080c4a495..32c527799e 100644
--- a/meta/recipes-core/initscripts/initscripts_1.0.bb
+++ b/meta/recipes-core/initscripts/initscripts_1.0.bb
@@ -170,7 +170,7 @@ MASKED_SCRIPTS = " \
urandom"
pkg_postinst_${PN} () {
- if ${@bb.utils.contains('DISTRO_FEATURES','systemd','true','false',d)}; then
+ if type systemctl >/dev/null 2>/dev/null; then
if [ -n "$D" ]; then
OPTS="--root=$D"
fi