* [PATCH] siggen.py: Pass the datacache to signature generator classes
@ 2012-02-22 22:50 Richard Purdie
0 siblings, 0 replies; only message in thread
From: Richard Purdie @ 2012-02-22 22:50 UTC (permalink / raw)
To: bitbake-devel
The dataCache exposes much useful information to the singature generation code
for example its possible to figure out whether kernel dependencies are
important or not based on the RRECOMMENDS values.
We therefore pass this information to the handler and trust it to handle
any API changes in the dataCache structure.
For backwards compatibility, OE-Core is already updated to handle
the extra argument when it appears.
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
---
diff --git a/bitbake/lib/bb/siggen.py b/bitbake/lib/bb/siggen.py
index 3a9e132..975ae41 100644
--- a/bitbake/lib/bb/siggen.py
+++ b/bitbake/lib/bb/siggen.py
@@ -135,7 +135,7 @@ class SignatureGeneratorBasic(SignatureGenerator):
for task in taskdeps:
d.setVar("BB_BASEHASH_task-%s" % task, self.basehash[fn + "." + task])
- def rundep_check(self, fn, recipename, task, dep, depname):
+ def rundep_check(self, fn, recipename, task, dep, depname, dataCache):
# Return True if we should keep the dependency, False to drop it
# We only manipulate the dependencies for packages not in the whitelist
if self.twl and not self.twl.search(recipename):
@@ -151,7 +151,7 @@ class SignatureGeneratorBasic(SignatureGenerator):
recipename = dataCache.pkg_fn[fn]
for dep in sorted(deps, key=clean_basepath):
depname = dataCache.pkg_fn[self.pkgnameextract.search(dep).group('fn')]
- if not self.rundep_check(fn, recipename, task, dep, depname):
+ if not self.rundep_check(fn, recipename, task, dep, depname, dataCache):
continue
if dep not in self.taskhash:
bb.fatal("%s is not in taskhash, caller isn't calling in dependency order?", dep)
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2012-02-22 22:58 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-02-22 22:50 [PATCH] siggen.py: Pass the datacache to signature generator classes Richard Purdie
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.