diff options
author | Jiajun Xu <jiajun.xu@intel.com> | 2010-12-16 16:04:00 +0800 |
---|---|---|
committer | Richard Purdie <rpurdie@linux.intel.com> | 2010-12-16 15:27:14 +0000 |
commit | b99fd0374e554f4d2183f349f271220951299c9a (patch) | |
tree | 5045d8250246244c166b6fa75cf5177ffdc0c50f | |
parent | ace52b0da36d2909c1aaf344ff5f321a8de777ba (diff) | |
download | openembedded-core-b99fd0374e554f4d2183f349f271220951299c9a.tar.gz openembedded-core-b99fd0374e554f4d2183f349f271220951299c9a.tar.bz2 openembedded-core-b99fd0374e554f4d2183f349f271220951299c9a.zip |
sanity.bbclass: Check if DISPLAY is set when IMAGETEST is set
Fixes [BUGID: 594]
In imagetest-qemu.bbclass, we depend on DISPLAY to start qemu in
a X desktop. When user wants to run qemu sanity test, we need to
check if the variable is set.
Signed-off-by Jiajun Xu <jiajun.xu@intel.com>
-rw-r--r-- | meta/classes/sanity.bbclass | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/meta/classes/sanity.bbclass b/meta/classes/sanity.bbclass index e1f37ac1f4..bc02a828c4 100644 --- a/meta/classes/sanity.bbclass +++ b/meta/classes/sanity.bbclass @@ -139,6 +139,10 @@ def check_sanity(e): missing = missing.rstrip(',') messages = messages + "Please install following missing utilities: %s\n" % missing + # Check if DISPLAY is set if IMAGETEST is set + if not data.getVar( 'DISPLAY', e.data, True ) and data.getVar( 'IMAGETEST', e.data, True ) == 'qemu': + messages = messages + 'qemuimagetest needs a X desktop to start qemu, please set DISPLAY correctly (e.g. DISPLAY=:1.0)\n' + # Ensure we have the binary for TERMCMD, as when patch application fails the error is fairly intimidating termcmd = data.getVar("TERMCMD", e.data, True) term = termcmd.split()[0] |