]> code.ossystems Code Review - openembedded-core.git/commitdiff
nss: Fix postinstall script
authorDavid Vincent <freesilicon@gmail.com>
Wed, 4 Jan 2017 16:43:02 +0000 (17:43 +0100)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Mon, 9 Jan 2017 13:34:30 +0000 (13:34 +0000)
When installing NSS on a read-only rootfs, the current postinstall
scriptlet exits after having run the signing part. This causes an error
when appending the task because the rest of the script is simply ignored
and therefore never run.

Signed-off-by: David Vincent <freesilicon@gmail.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
meta/recipes-support/nss/nss_3.27.1.bb

index 091793899fce209e96f2548db48b4dabf1896fbb..a69672b3d8211266d7ae6278e2a439edcb34e5c9 100644 (file)
@@ -208,18 +208,18 @@ do_install_append_class-target() {
 
 pkg_postinst_${PN} () {
     if [ -n "$D" ]; then
-        for I in $D/${libdir}/lib*.chk; do
+        for I in $D${libdir}/lib*.chk; do
             DN=`dirname $I`
             BN=`basename $I .chk`
             FN=$DN/$BN.so
             shlibsign -i $FN
-           if [ $? -ne 0 ]; then
-              exit 1
-           fi
+            if [ $? -ne 0 ]; then
+                exit 1
+            fi
         done
-        exit 0
+    else
+        signlibs.sh
     fi
-    signlibs.sh
 }
 
 PACKAGES =+ "${PN}-smime"