diff options
Diffstat (limited to 'meta/lib/oeqa/utils/commands.py')
-rw-r--r-- | meta/lib/oeqa/utils/commands.py | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/meta/lib/oeqa/utils/commands.py b/meta/lib/oeqa/utils/commands.py index 08e2cbb906..dfb6c215bb 100644 --- a/meta/lib/oeqa/utils/commands.py +++ b/meta/lib/oeqa/utils/commands.py | |||
@@ -18,6 +18,7 @@ from oeqa.utils import CommandError | |||
18 | from oeqa.utils import ftools | 18 | from oeqa.utils import ftools |
19 | import re | 19 | import re |
20 | import contextlib | 20 | import contextlib |
21 | import bb | ||
21 | 22 | ||
22 | class Command(object): | 23 | class Command(object): |
23 | def __init__(self, command, bg=False, timeout=None, data=None, **options): | 24 | def __init__(self, command, bg=False, timeout=None, data=None, **options): |
@@ -208,6 +209,16 @@ def runqemu(pn, test): | |||
208 | # Luckily QemuTarget doesn't need it after the constructor. | 209 | # Luckily QemuTarget doesn't need it after the constructor. |
209 | tinfoil.shutdown() | 210 | tinfoil.shutdown() |
210 | 211 | ||
212 | # Setup bitbake logger as console handler is removed by tinfoil.shutdown | ||
213 | bblogger = logging.getLogger('BitBake') | ||
214 | bblogger.setLevel(logging.INFO) | ||
215 | console = logging.StreamHandler(sys.stdout) | ||
216 | bbformat = bb.msg.BBLogFormatter("%(levelname)s: %(message)s") | ||
217 | if sys.stdout.isatty(): | ||
218 | bbformat.enable_color() | ||
219 | console.setFormatter(bbformat) | ||
220 | bblogger.addHandler(console) | ||
221 | |||
211 | try: | 222 | try: |
212 | qemu.deploy() | 223 | qemu.deploy() |
213 | try: | 224 | try: |