Patchwork [1/1] rootfs_rpm.bbclass: fix a bug in run-postinst script

login
register
mail settings
Submitter Qi.Chen@windriver.com
Date Jan. 29, 2013, 9:02 a.m.
Message ID <5e787fa57650088573366333c26deb9c463bfe6f.1359449833.git.Qi.Chen@windriver.com>
Download mbox | patch
Permalink /patch/43611/
State Accepted
Commit 96180955d06e9ae74cd8e8c2a980167c485c2df1
Headers show

Comments

Qi.Chen@windriver.com - Jan. 29, 2013, 9:02 a.m.
From: Chen Qi <Qi.Chen@windriver.com>

This is a follow-up patch which fixes a bug introduced by the
commit bd10a6d257ab5ce2fc961788c278af7c43637404.

The `` command substitution characters should be excaped by \ to make
things work correctly.

[YOCTO #3767]

Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
---
 meta/classes/rootfs_rpm.bbclass |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Patch

diff --git a/meta/classes/rootfs_rpm.bbclass b/meta/classes/rootfs_rpm.bbclass
index accd7d9..119bf92 100644
--- a/meta/classes/rootfs_rpm.bbclass
+++ b/meta/classes/rootfs_rpm.bbclass
@@ -108,7 +108,7 @@  fakeroot rootfs_rpm_do_rootfs () {
 	i=\$i
 	cat > ${IMAGE_ROOTFS}${sysconfdir}/rcS.d/S${POSTINSTALL_INITPOSITION}run-postinsts << EOF
 #!/bin/sh
-for i in `ls /etc/rpm-postinsts/`; do
+for i in \`ls /etc/rpm-postinsts/\`; do
 	i=/etc/rpm-postinsts/$i
 	echo "Running postinst $i..."
 	if [ -f $i ] && $i; then