]> code.ossystems Code Review - openembedded-core.git/commitdiff
runqemu-internal: don't append an empty element to PATH
authorScott Garman <scott.a.garman@intel.com>
Wed, 26 Sep 2012 18:02:27 +0000 (11:02 -0700)
committerSaul Wold <sgw@linux.intel.com>
Fri, 28 Sep 2012 08:14:01 +0000 (01:14 -0700)
Bitbake fails to run when an empty element exists in $PATH. Avoid
creating this situation when $CROSSPATH is not set.

This fixes bug [YOCTO #3101]

Signed-off-by: Scott Garman <scott.a.garman@intel.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
scripts/runqemu-internal

index 6b8bb6520ea0728879ce0e45b87c1883a162c8fc..0f07bad9700c6ca6101f02883f432355895eb1ed 100755 (executable)
@@ -472,7 +472,11 @@ if [ "x$QEMUOPTIONS" = "x" ]; then
     return
 fi
 
-PATH=$CROSSPATH:$OECORE_NATIVE_SYSROOT/usr/bin:$PATH
+if [ "x$CROSSPATH" = "x" ]; then
+    PATH=$OECORE_NATIVE_SYSROOT/usr/bin:$PATH
+else
+    PATH=$CROSSPATH:$OECORE_NATIVE_SYSROOT/usr/bin:$PATH
+fi
 
 QEMUBIN=`which $QEMU 2> /dev/null`
 if [ ! -x "$QEMUBIN" ]; then