diff options
author | Richard Purdie <richard.purdie@linuxfoundation.org> | 2017-07-06 12:53:33 +0100 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2017-07-08 13:29:54 +0100 |
commit | bca4396106a51c7eba1da5fcbaba5e4e4964ca91 (patch) | |
tree | 95433a53454f13095c3926446ea4b68587467ad5 /bitbake/lib/bb | |
parent | 754c03006943a219ffd417c36ab909b464f57f67 (diff) | |
download | poky-bca4396106a51c7eba1da5fcbaba5e4e4964ca91.tar.gz |
bitbake: bitbake: Add MultiConfigParsed event
There are some cases where the metadata needs to be aware a multiconfig build
is happening and have access to the multiconfig data stores to merge data into
the common build. This adds such an event allowing access to these datastores.
(Bitbake rev: 160e47f5df90850e64dcb857c81a5039abc9235f)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake/lib/bb')
-rw-r--r-- | bitbake/lib/bb/cookerdata.py | 2 | ||||
-rw-r--r-- | bitbake/lib/bb/event.py | 6 | ||||
-rw-r--r-- | bitbake/lib/bb/ui/knotty.py | 1 |
3 files changed, 9 insertions, 0 deletions
diff --git a/bitbake/lib/bb/cookerdata.py b/bitbake/lib/bb/cookerdata.py index 4d32aa0318..644bb383e8 100644 --- a/bitbake/lib/bb/cookerdata.py +++ b/bitbake/lib/bb/cookerdata.py | |||
@@ -294,6 +294,8 @@ class CookerDataBuilder(object): | |||
294 | mcdata = self.parseConfigurationFiles(self.prefiles, self.postfiles, config) | 294 | mcdata = self.parseConfigurationFiles(self.prefiles, self.postfiles, config) |
295 | bb.event.fire(bb.event.ConfigParsed(), mcdata) | 295 | bb.event.fire(bb.event.ConfigParsed(), mcdata) |
296 | self.mcdata[config] = mcdata | 296 | self.mcdata[config] = mcdata |
297 | if multiconfig: | ||
298 | bb.event.fire(bb.event.MultiConfigParsed(self.mcdata), self.data) | ||
297 | 299 | ||
298 | except (SyntaxError, bb.BBHandledException): | 300 | except (SyntaxError, bb.BBHandledException): |
299 | raise bb.BBHandledException | 301 | raise bb.BBHandledException |
diff --git a/bitbake/lib/bb/event.py b/bitbake/lib/bb/event.py index 6ccd4bdc38..1462382f10 100644 --- a/bitbake/lib/bb/event.py +++ b/bitbake/lib/bb/event.py | |||
@@ -358,6 +358,12 @@ class OperationProgress(Event): | |||
358 | class ConfigParsed(Event): | 358 | class ConfigParsed(Event): |
359 | """Configuration Parsing Complete""" | 359 | """Configuration Parsing Complete""" |
360 | 360 | ||
361 | class MultiConfigParsed(Event): | ||
362 | """Multi-Config Parsing Complete""" | ||
363 | def __init__(self, mcdata): | ||
364 | self.mcdata = mcdata | ||
365 | Event.__init__(self) | ||
366 | |||
361 | class RecipeEvent(Event): | 367 | class RecipeEvent(Event): |
362 | def __init__(self, fn): | 368 | def __init__(self, fn): |
363 | self.fn = fn | 369 | self.fn = fn |
diff --git a/bitbake/lib/bb/ui/knotty.py b/bitbake/lib/bb/ui/knotty.py index a19c3b3ba5..936d5a4fb1 100644 --- a/bitbake/lib/bb/ui/knotty.py +++ b/bitbake/lib/bb/ui/knotty.py | |||
@@ -664,6 +664,7 @@ def main(server, eventHandler, params, tf = TerminalFilter): | |||
664 | bb.event.MetadataEvent, | 664 | bb.event.MetadataEvent, |
665 | bb.event.StampUpdate, | 665 | bb.event.StampUpdate, |
666 | bb.event.ConfigParsed, | 666 | bb.event.ConfigParsed, |
667 | bb.event.MultiConfigParsed, | ||
667 | bb.event.RecipeParsed, | 668 | bb.event.RecipeParsed, |
668 | bb.event.RecipePreFinalise, | 669 | bb.event.RecipePreFinalise, |
669 | bb.runqueue.runQueueEvent, | 670 | bb.runqueue.runQueueEvent, |