Openembedded Core Discussions
 help / color / mirror / Atom feed
From: Mark Hatle <mark.hatle@windriver.com>
To: <openembedded-core@lists.openembedded.org>
Subject: [master][dora][PATCH] rootfs_*.bbclass: List which post-install scripts can not be run
Date: Thu, 21 Nov 2013 01:34:41 -0600	[thread overview]
Message-ID: <1385019281-24577-1-git-send-email-mark.hatle@windriver.com> (raw)

From: Jeffrey C Honig <jeffrey.honig@windriver.com>

When preping a read-only rootfs and finding some post-install
scripts that can not be run, list the names of said scripts to
avoid having to look around the rootfs to find a list.

Signed-off-by: Jeffrey C Honig <jeffrey.honig@windriver.com>
Signed-off-by: Jeff Polk <jeff.polk@windriver.com>
---
 meta/classes/rootfs_deb.bbclass | 5 +++--
 meta/classes/rootfs_ipk.bbclass | 5 +++--
 meta/classes/rootfs_rpm.bbclass | 5 +++--
 3 files changed, 9 insertions(+), 6 deletions(-)

diff --git a/meta/classes/rootfs_deb.bbclass b/meta/classes/rootfs_deb.bbclass
index b1c52f9..8613032 100644
--- a/meta/classes/rootfs_deb.bbclass
+++ b/meta/classes/rootfs_deb.bbclass
@@ -91,8 +91,9 @@ fakeroot rootfs_deb_do_rootfs () {
 	${ROOTFS_POSTPROCESS_COMMAND}
 
 	if ${@base_contains("IMAGE_FEATURES", "read-only-rootfs", "true", "false" ,d)}; then
-		if [ -n "$(delayed_postinsts)" ]; then
-			bberror "Some packages could not be configured offline and rootfs is read-only."
+	        delayed_postinsts="$(delayed_postinsts)"
+		if [ -n "$delayed_postinsts" ]; then
+			bberror "The following packages could not be configured offline and rootfs is read-only: $delayed_postinsts"
 			exit 1
 		fi
 	fi
diff --git a/meta/classes/rootfs_ipk.bbclass b/meta/classes/rootfs_ipk.bbclass
index b0805dc..6ce3e5d 100644
--- a/meta/classes/rootfs_ipk.bbclass
+++ b/meta/classes/rootfs_ipk.bbclass
@@ -89,8 +89,9 @@ fakeroot rootfs_ipk_do_rootfs () {
 	${ROOTFS_POSTPROCESS_COMMAND}
 
 	if ${@base_contains("IMAGE_FEATURES", "read-only-rootfs", "true", "false" ,d)}; then
-		if [ -n "$(delayed_postinsts)" ]; then
-			bberror "Some packages could not be configured offline and rootfs is read-only."
+	        delayed_postinsts="$(delayed_postinsts)"
+		if [ -n "$delayed_postinsts" ]; then
+			bberror "The following packages could not be configured offline and rootfs is read-only: $delayed_postinsts"
 			exit 1
 		fi
 	fi
diff --git a/meta/classes/rootfs_rpm.bbclass b/meta/classes/rootfs_rpm.bbclass
index 6c68ac8..1a0c225 100644
--- a/meta/classes/rootfs_rpm.bbclass
+++ b/meta/classes/rootfs_rpm.bbclass
@@ -115,8 +115,9 @@ fakeroot rootfs_rpm_do_rootfs () {
 
 	if ${@base_contains("IMAGE_FEATURES", "read-only-rootfs", "true", "false" ,d)}; then
 		if [ -d ${IMAGE_ROOTFS}${sysconfdir}/rpm-postinsts ] ; then
-			if [ "`ls -A ${IMAGE_ROOTFS}${sysconfdir}/rpm-postinsts`" != "" ] ; then
-				bberror "Some packages could not be configured offline and rootfs is read-only."
+		        failed_pkgs=$(ls -A ${IMAGE_ROOTFS}${sysconfdir}/rpm-postinsts)
+			if [ -n "$failed_pkgs" ] ; then
+				bberror "The following post-install scripts could not be run offline and rootfs is read-only: $failed_pkgs"
 				exit 1
 			fi
 		fi
-- 
1.8.1.2.545.g2f19ada



                 reply	other threads:[~2013-11-21  7:34 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1385019281-24577-1-git-send-email-mark.hatle@windriver.com \
    --to=mark.hatle@windriver.com \
    --cc=openembedded-core@lists.openembedded.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox