Openembedded Core Discussions
 help / color / mirror / Atom feed
* [PATCH] image_types.bbclass: fix cpio IMAGE_CMD to preserve working directory
@ 2014-02-18 12:08 Jonathan Liu
  2014-02-18 14:56 ` Khem Raj
  0 siblings, 1 reply; 3+ messages in thread
From: Jonathan Liu @ 2014-02-18 12:08 UTC (permalink / raw)
  To: openembedded-core

The working directory is changed in a subshell when executing cpio to
preserve the working directory for any subsequent commands. This is to
keep the working directory consistent when generating multiple image
types.

Signed-off-by: Jonathan Liu <net147@gmail.com>
---
 meta/classes/image_types.bbclass | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/meta/classes/image_types.bbclass b/meta/classes/image_types.bbclass
index 944e6db..747a59b 100644
--- a/meta/classes/image_types.bbclass
+++ b/meta/classes/image_types.bbclass
@@ -74,7 +74,7 @@ CPIO_TOUCH_INIT () {
 }
 IMAGE_CMD_cpio () {
 	${CPIO_TOUCH_INIT}
-	cd ${IMAGE_ROOTFS} && (find . | cpio -o -H newc >${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.rootfs.cpio)
+	(cd ${IMAGE_ROOTFS} && (find . | cpio -o -H newc >${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.rootfs.cpio))
 }
 
 ELF_KERNEL ?= "${STAGING_DIR_HOST}/usr/src/kernel/${KERNEL_IMAGETYPE}"
-- 
1.8.5.4



^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2014-02-18 20:23 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-02-18 12:08 [PATCH] image_types.bbclass: fix cpio IMAGE_CMD to preserve working directory Jonathan Liu
2014-02-18 14:56 ` Khem Raj
2014-02-18 20:23   ` Bernhard Reutner-Fischer

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox