From: Richard Purdie <richard.purdie@linuxfoundation.org>
To: bitbake-devel <bitbake-devel@lists.openembedded.org>
Subject: [PATCH] cooker: Add option of specifying indvidual tasks for targets
Date: Mon, 27 Jan 2014 14:37:04 +0000 [thread overview]
Message-ID: <1390833424.17424.251.camel@ted> (raw)
Currently its near enough impossible to tell bitbake to run target X,
task Y and target A, task B. We could hack various parts of the API
around but it would mean incompatibilities.
An alternative is to accept the syntax "<target>:do_<task>" as a target
name. The default task would be used where the task is unspecified.
This has the advantage that its neat/clean code and works from all
current APIs including the commandline.
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
---
diff --git a/bitbake/lib/bb/cooker.py b/bitbake/lib/bb/cooker.py
index db4cb51..cc7d84e 100644
--- a/bitbake/lib/bb/cooker.py
+++ b/bitbake/lib/bb/cooker.py
@@ -449,9 +449,14 @@ class BBCooker:
current = 0
runlist = []
for k in fulltargetlist:
+ ktask = task
+ if ":do_" in k:
+ k2 = k.split(":do_")
+ k = k2[0]
+ ktask = k2[1]
taskdata.add_provider(localdata, self.recipecache, k)
current += 1
- runlist.append([k, "do_%s" % task])
+ runlist.append([k, "do_%s" % ktask])
bb.event.fire(bb.event.TreeDataPreparationProgress(current, len(fulltargetlist)), self.data)
taskdata.add_unresolved(localdata, self.recipecache)
bb.event.fire(bb.event.TreeDataPreparationCompleted(len(fulltargetlist)), self.data)
next reply other threads:[~2014-01-27 14:37 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-01-27 14:37 Richard Purdie [this message]
2014-01-27 22:39 ` [PATCH] cooker: Add option of specifying indvidual tasks for targets Khem Raj
2014-01-27 22:43 ` Richard Purdie
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1390833424.17424.251.camel@ted \
--to=richard.purdie@linuxfoundation.org \
--cc=bitbake-devel@lists.openembedded.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.