[oe-commits] Richard Purdie : imagetest-qemu: Adapt to bitbake environment changes
git at git.openembedded.org
git at git.openembedded.org
Wed Feb 6 23:41:12 UTC 2013
Module: openembedded-core.git
Branch: master
Commit: 8ad8b34b5ac36d805bb10c120f3388e7dce83b98
URL: http://git.openembedded.org/?p=openembedded-core.git&a=commit;h=8ad8b34b5ac36d805bb10c120f3388e7dce83b98
Author: Richard Purdie <richard.purdie at linuxfoundation.org>
Date: Wed Feb 6 23:16:34 2013 +0000
imagetest-qemu: Adapt to bitbake environment changes
Load environment variables like DISPLAY from BB_ORIGENV after recent
bitbake changes.
Signed-off-by: Richard Purdie <richard.purdie at linuxfoundation.org>
---
meta/classes/imagetest-qemu.bbclass | 11 ++++++++++-
1 files changed, 10 insertions(+), 1 deletions(-)
diff --git a/meta/classes/imagetest-qemu.bbclass b/meta/classes/imagetest-qemu.bbclass
index 06ba3e3..0d18f06 100644
--- a/meta/classes/imagetest-qemu.bbclass
+++ b/meta/classes/imagetest-qemu.bbclass
@@ -67,7 +67,6 @@ def qemuimagetest_main(d):
os.environ["DEPLOY_DIR"] = d.getVar("DEPLOY_DIR", True)
os.environ["QEMUARCH"] = machine
os.environ["QEMUTARGET"] = pname
- os.environ["DISPLAY"] = d.getVar("DISPLAY", True)
os.environ["COREBASE"] = d.getVar("COREBASE", True)
os.environ["TOPDIR"] = d.getVar("TOPDIR", True)
os.environ["OE_TMPDIR"] = d.getVar("TMPDIR", True)
@@ -76,6 +75,16 @@ def qemuimagetest_main(d):
os.environ["TEST_SERIALIZE"] = d.getVar("TEST_SERIALIZE", True)
os.environ["SDK_NAME"] = d.getVar("SDK_NAME", True)
+ # Add in all variables from the user's original environment which
+ # haven't subsequntly been set/changed
+ origbbenv = d.getVar("BB_ORIGENV", False) or {}
+ for key in origbbenv:
+ if key in os.environ:
+ continue
+ value = origbbenv.getVar(key, True)
+ if value is not None:
+ os.environ[key] = str(value)
+
"""run Test Case"""
bb.note("Run %s test in scenario %s" % (case, scen))
subprocess.call("%s" % fulltestpath, shell=True)
More information about the Openembedded-commits
mailing list