summaryrefslogtreecommitdiffstats
path: root/meta/lib/oeqa
diff options
context:
space:
mode:
authorRichard Purdie <richard.purdie@linuxfoundation.org>2018-11-27 23:38:44 +0000
committerRichard Purdie <richard.purdie@linuxfoundation.org>2018-12-01 11:38:36 +0000
commit060c320e8a21f8a6e99ef4c8e0fad42041192304 (patch)
tree1893065c926dcc650738a6efe4922edde56327b7 /meta/lib/oeqa
parentdb20fe6f0ad360cf5f5db32bc599554ad404ae97 (diff)
downloadpoky-060c320e8a21f8a6e99ef4c8e0fad42041192304.tar.gz
oeqa/utils/commands: Add extra qemu failure logging
Rather than just referring the user to the logs containing the failure, print them on the console. This aids debugging with oe-selftest with parallelisation as the logs may otherwise be lost. (From OE-Core rev: 36a018e245a232f520ff946f152cc875927a6fb4) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/lib/oeqa')
-rw-r--r--meta/lib/oeqa/utils/commands.py6
1 files changed, 5 insertions, 1 deletions
diff --git a/meta/lib/oeqa/utils/commands.py b/meta/lib/oeqa/utils/commands.py
index 01add68689..e6a35d3d25 100644
--- a/meta/lib/oeqa/utils/commands.py
+++ b/meta/lib/oeqa/utils/commands.py
@@ -336,7 +336,11 @@ def runqemu(pn, ssh=True, runqemuparams='', image_fstype=None, launch_cmd=None,
336 try: 336 try:
337 qemu.start(params=qemuparams, ssh=ssh, runqemuparams=runqemuparams, launch_cmd=launch_cmd, discard_writes=discard_writes) 337 qemu.start(params=qemuparams, ssh=ssh, runqemuparams=runqemuparams, launch_cmd=launch_cmd, discard_writes=discard_writes)
338 except bb.build.FuncFailed: 338 except bb.build.FuncFailed:
339 raise Exception('Failed to start QEMU - see the logs in %s' % logdir) 339 msg = 'Failed to start QEMU - see the logs in %s' % logdir
340 if os.path.exists(qemu.qemurunnerlog):
341 with open(qemu.qemurunnerlog, 'r') as f:
342 msg = msg + "Qemurunner log output from %s:\n%s" % (qemu.qemurunnerlog, f.read())
343 raise Exception(msg)
340 344
341 yield qemu 345 yield qemu
342 346