From f49854c1f7b7ab72c803864ab7f4c782fc503ca0 Mon Sep 17 00:00:00 2001 From: Richard Purdie Date: Fri, 10 Sep 2021 10:28:18 +0100 Subject: [PATCH] bitbake: build: Avoid duplicating logs in verbose mode With "bitbake -v", for task failures you'd see the log output twice. Avoid this by using the existing "did we print info" switch. (Bitbake rev: e2c1afda4cb8023ed4ffeb5dc5bee4f0055659a8) Signed-off-by: Richard Purdie --- bitbake/lib/bb/build.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/bitbake/lib/bb/build.py b/bitbake/lib/bb/build.py index 9862e8878e..1e062adb51 100644 --- a/bitbake/lib/bb/build.py +++ b/bitbake/lib/bb/build.py @@ -699,6 +699,10 @@ def _exec_task(fn, task, d, quieterr): event.fire(TaskFailedSilent(task, fn, logfn, localdata), localdata) else: errprinted = errchk.triggered + # If the output is already on stdout, we've printed the information in the + # logs once already so don't duplicate + if verboseStdoutLogging: + errprinted = True logger.error(str(exc)) event.fire(TaskFailed(task, fn, logfn, localdata, errprinted), localdata) return 1