summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--bitbake/lib/bb/cooker.py4
-rw-r--r--bitbake/lib/bb/event.py6
2 files changed, 9 insertions, 1 deletions
diff --git a/bitbake/lib/bb/cooker.py b/bitbake/lib/bb/cooker.py
index a73a55de96..d4dd23f09c 100644
--- a/bitbake/lib/bb/cooker.py
+++ b/bitbake/lib/bb/cooker.py
@@ -1235,6 +1235,7 @@ class BBCooker:
1235 """ 1235 """
1236 Build the file matching regexp buildfile 1236 Build the file matching regexp buildfile
1237 """ 1237 """
1238 bb.event.fire(bb.event.BuildInit(), self.expanded_data)
1238 1239
1239 # Too many people use -b because they think it's how you normally 1240 # Too many people use -b because they think it's how you normally
1240 # specify a target to be built, so show a warning 1241 # specify a target to be built, so show a warning
@@ -1377,6 +1378,9 @@ class BBCooker:
1377 if not task.startswith("do_"): 1378 if not task.startswith("do_"):
1378 task = "do_%s" % task 1379 task = "do_%s" % task
1379 1380
1381 packages = ["%s:%s" % (target, task) for target in targets]
1382 bb.event.fire(bb.event.BuildInit(packages), self.expanded_data)
1383
1380 taskdata, runlist, fulltargetlist = self.buildTaskData(targets, task, self.configuration.abort) 1384 taskdata, runlist, fulltargetlist = self.buildTaskData(targets, task, self.configuration.abort)
1381 1385
1382 buildname = self.data.getVar("BUILDNAME", False) 1386 buildname = self.data.getVar("BUILDNAME", False)
diff --git a/bitbake/lib/bb/event.py b/bitbake/lib/bb/event.py
index a5f026e151..1f3200e196 100644
--- a/bitbake/lib/bb/event.py
+++ b/bitbake/lib/bb/event.py
@@ -382,7 +382,11 @@ class BuildBase(Event):
382 382
383 383
384 384
385 385class BuildInit(BuildBase):
386 """buildFile or buildTargets was invoked"""
387 def __init__(self, p=[]):
388 name = None
389 BuildBase.__init__(self, name, p)
386 390
387class BuildStarted(BuildBase, OperationStarted): 391class BuildStarted(BuildBase, OperationStarted):
388 """bbmake build run started""" 392 """bbmake build run started"""