]> code.ossystems Code Review - openembedded-core.git/commitdiff
jpeg: enable postinst to run at rootfs time successfully
authorChen Qi <Qi.Chen@windriver.com>
Thu, 31 Oct 2013 06:00:13 +0000 (14:00 +0800)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Fri, 1 Nov 2013 11:08:30 +0000 (11:08 +0000)
Signed-off-by: Saul Wold <sgw@linux.intel.com>
meta/recipes-core/jpeg/jpeg_8d.bb

index eba5bf46d28a1a80b1850c7cba4c7c99065aaefc..ad4fa514cd56e942f0f33fbc74e3885c1d7c58b5 100644 (file)
@@ -45,12 +45,8 @@ FILES_jpeg-tools =   "${bindir}/*"
 BBCLASSEXTEND = "native"
 
 pkg_postinst_${PN}_linuxstdbase () {
-    if [ "$D" = "" ]; then
-        if [ ! -e ${libdir}/libjpeg.so.62 ]; then
-            JPEG=`find ${libdir} -type f -name libjpeg.so.\*.\*.\*`
-            ln -sf `basename $JPEG` ${libdir}/libjpeg.so.62
-        fi
-    else
-        exit 1
+    if [ ! -e $D${libdir}/libjpeg.so.62 ]; then
+        JPEG=`find $D${libdir} -type f -name libjpeg.so.\*.\*.\*`
+        ln -sf `basename $JPEG` $D${libdir}/libjpeg.so.62
     fi
 }