summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChris Laplante <chris.laplante@agilent.com>2020-02-24 10:44:01 -0500
committerRichard Purdie <richard.purdie@linuxfoundation.org>2020-03-06 17:28:00 +0000
commit694904bde980606dc67c201da61f4fb685679b17 (patch)
treefe661e3c9be4115810d9365e4bd703e961266c31
parent83256115c7b1fdf3fa5129cfba6b9e7cba2ae0da (diff)
downloadbitbake-694904bde980606dc67c201da61f4fb685679b17.tar.gz
runqueue: teach runonly/runall to accept "do_task" as well as "task"
Previously --runonly=do_task would give a misleading error like: ERROR: Could not find any tasks with the tasknames ['do_task'] to run within the recipes of the taskgraphs of the targets... The problem is that BitBake tried to find "do_do_task". So teach it to only add the do_ prefix if it's not already there. Signed-off-by: Chris Laplante <chris.laplante@agilent.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--lib/bb/runqueue.py8
1 files changed, 6 insertions, 2 deletions
diff --git a/lib/bb/runqueue.py b/lib/bb/runqueue.py
index 71108eeed..32966b4f7 100644
--- a/lib/bb/runqueue.py
+++ b/lib/bb/runqueue.py
@@ -920,9 +920,11 @@ class RunQueueData:
runq_build = {}
for task in self.cooker.configuration.runall:
+ if not task.startswith("do_"):
+ task = "do_{0}".format(task)
runall_tids = set()
for tid in list(self.runtaskentries):
- wanttid = fn_from_tid(tid) + ":do_%s" % task
+ wanttid = "{0}:{1}".format(fn_from_tid(tid), task)
if wanttid in delcount:
self.runtaskentries[wanttid] = delcount[wanttid]
if wanttid in self.runtaskentries:
@@ -949,7 +951,9 @@ class RunQueueData:
runq_build = {}
for task in self.cooker.configuration.runonly:
- runonly_tids = { k: v for k, v in self.runtaskentries.items() if taskname_from_tid(k) == "do_%s" % task }
+ if not task.startswith("do_"):
+ task = "do_{0}".format(task)
+ runonly_tids = { k: v for k, v in self.runtaskentries.items() if taskname_from_tid(k) == task }
for tid in list(runonly_tids):
mark_active(tid,1)