diff options
author | Richard Purdie <richard.purdie@linuxfoundation.org> | 2016-11-14 09:51:38 +0000 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2017-01-11 17:21:46 +0000 |
commit | e171e9a0886f35e8b783c73bc6b78d5987dda3c7 (patch) | |
tree | 0f9c8e30b9b74dbe1b3f5581cb160c21380f3a84 /bitbake/lib | |
parent | a411abf823a2c23f228cb7355ae9311590de952e (diff) | |
download | poky-e171e9a0886f35e8b783c73bc6b78d5987dda3c7.tar.gz |
bitbake: bitbake: cooker: Fix world taskgraph generation issue
The processing of the "do_" prefix to tasks is currently inconsistent
and has resulted in "bitbake world -g" being broken as task prefixes
don't get handled correctly.
Make the "do_" task prefix handling consistent through various codepaths.
[YOCTO #10651]
(Bitbake rev: 3d7186353e804c9410096c408bc337a98c8b33fe)
(Bitbake rev: 100439e715841ecfd6460d59cd51c831184b328d)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Signed-off-by: Armin Kuster <akuster808@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake/lib')
-rw-r--r-- | bitbake/lib/bb/cooker.py | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/bitbake/lib/bb/cooker.py b/bitbake/lib/bb/cooker.py index 42831e2771..d112f8219c 100644 --- a/bitbake/lib/bb/cooker.py +++ b/bitbake/lib/bb/cooker.py | |||
@@ -657,6 +657,8 @@ class BBCooker: | |||
657 | # A task of None means use the default task | 657 | # A task of None means use the default task |
658 | if task is None: | 658 | if task is None: |
659 | task = self.configuration.cmd | 659 | task = self.configuration.cmd |
660 | if not task.startswith("do_"): | ||
661 | task = "do_%s" % task | ||
660 | 662 | ||
661 | fulltargetlist = self.checkPackages(pkgs_to_build, task) | 663 | fulltargetlist = self.checkPackages(pkgs_to_build, task) |
662 | taskdata = {} | 664 | taskdata = {} |
@@ -715,6 +717,9 @@ class BBCooker: | |||
715 | Create a dependency graph of pkgs_to_build including reverse dependency | 717 | Create a dependency graph of pkgs_to_build including reverse dependency |
716 | information. | 718 | information. |
717 | """ | 719 | """ |
720 | if not task.startswith("do_"): | ||
721 | task = "do_%s" % task | ||
722 | |||
718 | runlist, taskdata = self.prepareTreeData(pkgs_to_build, task) | 723 | runlist, taskdata = self.prepareTreeData(pkgs_to_build, task) |
719 | rq = bb.runqueue.RunQueue(self, self.data, self.recipecaches, taskdata, runlist) | 724 | rq = bb.runqueue.RunQueue(self, self.data, self.recipecaches, taskdata, runlist) |
720 | rq.rqdata.prepare() | 725 | rq.rqdata.prepare() |
@@ -818,6 +823,9 @@ class BBCooker: | |||
818 | """ | 823 | """ |
819 | Create a dependency tree of pkgs_to_build, returning the data. | 824 | Create a dependency tree of pkgs_to_build, returning the data. |
820 | """ | 825 | """ |
826 | if not task.startswith("do_"): | ||
827 | task = "do_%s" % task | ||
828 | |||
821 | _, taskdata = self.prepareTreeData(pkgs_to_build, task) | 829 | _, taskdata = self.prepareTreeData(pkgs_to_build, task) |
822 | 830 | ||
823 | seen_fns = [] | 831 | seen_fns = [] |
@@ -1318,6 +1326,8 @@ class BBCooker: | |||
1318 | # If we are told to do the None task then query the default task | 1326 | # If we are told to do the None task then query the default task |
1319 | if (task == None): | 1327 | if (task == None): |
1320 | task = self.configuration.cmd | 1328 | task = self.configuration.cmd |
1329 | if not task.startswith("do_"): | ||
1330 | task = "do_%s" % task | ||
1321 | 1331 | ||
1322 | fn, cls, mc = bb.cache.virtualfn2realfn(buildfile) | 1332 | fn, cls, mc = bb.cache.virtualfn2realfn(buildfile) |
1323 | fn = self.matchFile(fn) | 1333 | fn = self.matchFile(fn) |
@@ -1354,8 +1364,6 @@ class BBCooker: | |||
1354 | # Invalidate task for target if force mode active | 1364 | # Invalidate task for target if force mode active |
1355 | if self.configuration.force: | 1365 | if self.configuration.force: |
1356 | logger.verbose("Invalidate task %s, %s", task, fn) | 1366 | logger.verbose("Invalidate task %s, %s", task, fn) |
1357 | if not task.startswith("do_"): | ||
1358 | task = "do_%s" % task | ||
1359 | bb.parse.siggen.invalidate_task(task, self.recipecaches[mc], fn) | 1367 | bb.parse.siggen.invalidate_task(task, self.recipecaches[mc], fn) |
1360 | 1368 | ||
1361 | # Setup taskdata structure | 1369 | # Setup taskdata structure |
@@ -1367,8 +1375,6 @@ class BBCooker: | |||
1367 | bb.event.fire(bb.event.BuildStarted(buildname, [item]), self.expanded_data) | 1375 | bb.event.fire(bb.event.BuildStarted(buildname, [item]), self.expanded_data) |
1368 | 1376 | ||
1369 | # Execute the runqueue | 1377 | # Execute the runqueue |
1370 | if not task.startswith("do_"): | ||
1371 | task = "do_%s" % task | ||
1372 | runlist = [[mc, item, task, fn]] | 1378 | runlist = [[mc, item, task, fn]] |
1373 | 1379 | ||
1374 | rq = bb.runqueue.RunQueue(self, self.data, self.recipecaches, taskdata, runlist) | 1380 | rq = bb.runqueue.RunQueue(self, self.data, self.recipecaches, taskdata, runlist) |