summaryrefslogtreecommitdiffstats
path: root/meta/classes
diff options
context:
space:
mode:
authorSaul Wold <sgw@linux.intel.com>2015-02-02 14:07:47 -0800
committerRichard Purdie <richard.purdie@linuxfoundation.org>2015-02-08 08:00:25 +0000
commitd42963a3feda6c4cf074cbdacc7cf904734d70cf (patch)
treecaf5322a7e660c5e126ebd8cfcd753d06f8896b3 /meta/classes
parentdbfed41b76fa4ef7774882c9e121917a58f84a41 (diff)
downloadpoky-d42963a3feda6c4cf074cbdacc7cf904734d70cf.tar.gz
core-image: split debug-tweaks into individual features
Split the debug-tweaks into a more fine tunable set of IMAGE_FEATURES which activate the component functions. Clean-up image-core and image bbclass by having the ROOTFS_POSTPROCESS_COMMANDs in in one place for the debug-tweaks related functions [YOCTO #5344] (From OE-Core rev: e52d8281eb98dbade2d82451fa9788285121437e) Signed-off-by: Saul Wold <sgw@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/classes')
-rw-r--r--meta/classes/core-image.bbclass3
-rw-r--r--meta/classes/image.bbclass10
2 files changed, 8 insertions, 5 deletions
diff --git a/meta/classes/core-image.bbclass b/meta/classes/core-image.bbclass
index 62363fb334..a78f93405b 100644
--- a/meta/classes/core-image.bbclass
+++ b/meta/classes/core-image.bbclass
@@ -73,8 +73,5 @@ inherit image
73# Create /etc/timestamp during image construction to give a reasonably sane default time setting 73# Create /etc/timestamp during image construction to give a reasonably sane default time setting
74ROOTFS_POSTPROCESS_COMMAND += "rootfs_update_timestamp ; " 74ROOTFS_POSTPROCESS_COMMAND += "rootfs_update_timestamp ; "
75 75
76# Zap the root password if debug-tweaks feature is not enabled
77ROOTFS_POSTPROCESS_COMMAND += '${@bb.utils.contains("IMAGE_FEATURES", "debug-tweaks", "", "zap_empty_root_password ; ",d)}'
78
79# Tweak the mount options for rootfs in /etc/fstab if read-only-rootfs is enabled 76# Tweak the mount options for rootfs in /etc/fstab if read-only-rootfs is enabled
80ROOTFS_POSTPROCESS_COMMAND += '${@bb.utils.contains("IMAGE_FEATURES", "read-only-rootfs", "read_only_rootfs_hook; ", "",d)}' 77ROOTFS_POSTPROCESS_COMMAND += '${@bb.utils.contains("IMAGE_FEATURES", "read-only-rootfs", "read_only_rootfs_hook; ", "",d)}'
diff --git a/meta/classes/image.bbclass b/meta/classes/image.bbclass
index b2a3e97820..152164851e 100644
--- a/meta/classes/image.bbclass
+++ b/meta/classes/image.bbclass
@@ -162,10 +162,16 @@ IMAGE_CLASSES += "image_types"
162inherit ${IMAGE_CLASSES} 162inherit ${IMAGE_CLASSES}
163 163
164IMAGE_POSTPROCESS_COMMAND ?= "" 164IMAGE_POSTPROCESS_COMMAND ?= ""
165
166# Zap the root password if debug-tweaks feature is not enabled
167ROOTFS_POSTPROCESS_COMMAND += '${@bb.utils.contains_any("IMAGE_FEATURES", [ 'debug-tweaks', 'empty-root-password' ], "", "zap_empty_root_password ; ",d)}'
168
165# Allow dropbear/openssh to accept logins from accounts with an empty password string if debug-tweaks is enabled 169# Allow dropbear/openssh to accept logins from accounts with an empty password string if debug-tweaks is enabled
166ROOTFS_POSTPROCESS_COMMAND += '${@bb.utils.contains("IMAGE_FEATURES", "debug-tweaks", "ssh_allow_empty_password; ", "",d)}' 170ROOTFS_POSTPROCESS_COMMAND += '${@bb.utils.contains_any("IMAGE_FEATURES", [ 'debug-tweaks', 'allow-empty-password' ], "ssh_allow_empty_password; ", "",d)}'
171
167# Enable postinst logging if debug-tweaks is enabled 172# Enable postinst logging if debug-tweaks is enabled
168ROOTFS_POSTPROCESS_COMMAND += '${@bb.utils.contains("IMAGE_FEATURES", "debug-tweaks", "postinst_enable_logging; ", "",d)}' 173ROOTFS_POSTPROCESS_COMMAND += '${@bb.utils.contains_any("IMAGE_FEATURES", [ 'debug-tweaks', 'post-install-logging' ], "postinst_enable_logging; ", "",d)}'
174
169# Write manifest 175# Write manifest
170IMAGE_MANIFEST = "${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.rootfs.manifest" 176IMAGE_MANIFEST = "${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.rootfs.manifest"
171ROOTFS_POSTUNINSTALL_COMMAND =+ "write_image_manifest ; " 177ROOTFS_POSTUNINSTALL_COMMAND =+ "write_image_manifest ; "