]> code.ossystems Code Review - openembedded-core.git/commitdiff
qemuimage-testlib: Ensure TOPDIR/BUILDDIR are set
authorRichard Purdie <rpurdie@linux.intel.com>
Thu, 23 Dec 2010 17:27:14 +0000 (17:27 +0000)
committerRichard Purdie <rpurdie@linux.intel.com>
Thu, 23 Dec 2010 17:27:14 +0000 (17:27 +0000)
The recent environment changes mean TOPDIR/BUILDDIR need to be exported
specifcially to the enviromnent so the qemu scripts can find the correct
build directory.

Without this, qemu can fail to run.

Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
meta/classes/imagetest-qemu.bbclass
scripts/qemuimage-testlib

index 4b3ddfc362a3467a34b7518b0dd90c666666c333..bcae10d61dea9fc343fe46ee2c340650d00082ec 100644 (file)
@@ -55,6 +55,7 @@ def qemuimagetest_main(d):
         os.environ["QEMUTARGET"] = pname
         os.environ["DISPLAY"] = bb.data.getVar("DISPLAY", d, True)
         os.environ["POKYBASE"] = bb.data.getVar("POKYBASE", d, True)
+        os.environ["TOPDIR"] = bb.data.getVar("TOPDIR", d, True)
 
         """run Test Case"""
         bb.note("Run %s test in scenario %s" % (case, scen))
index 608c6f0a754d88c2652517311afa390fb8fc84b8..79882d9ea702f661df93257b61ec0467a04df0b4 100644 (file)
@@ -396,7 +396,8 @@ Test_Create_Qemu()
        export MACHINE=$QEMUARCH
 
        # Create Qemu in localhost VNC Port 1
-       xterm -display ${DISPLAY} -e "${RUNQEMU} ${KERNEL} ${TEST_ROOTFS_IMAGE}" &
+       echo "Running xterm -display ${DISPLAY} -e 'BUILDDIR=${TOPDIR} ${RUNQEMU} ${KERNEL} ${TEST_ROOTFS_IMAGE}' &"
+       xterm -display ${DISPLAY} -e "BUILDDIR=${TOPDIR} ${RUNQEMU} ${KERNEL} ${TEST_ROOTFS_IMAGE}" &
 
        # Get the pid of the xterm processor, which will be used in Test_Kill_Qemu
        PID=$!