diff options
author | Joshua Watt <jpewhacker@gmail.com> | 2018-12-18 21:10:29 -0600 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2019-01-03 22:47:11 +0000 |
commit | 3b5bdb227b91c6a37338311d7b6ffda798bf5cc8 (patch) | |
tree | 2444b4de6a587fbd9363f5bc4cff6aeaa729bbcb /bitbake/lib/bb | |
parent | 57e3c55f6dd17f8019335818c6f34e67f8110295 (diff) | |
download | poky-3b5bdb227b91c6a37338311d7b6ffda798bf5cc8.tar.gz |
bitbake: runqueue: Pass unique hash to task
The unique hash is now passed to the task in the BB_UNIHASH variable
[YOCTO #13030]
(Bitbake rev: aab80b099f6f259e4b57cba2c26dd385d07c5947)
Signed-off-by: Joshua Watt <JPEWhacker@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake/lib/bb')
-rw-r--r-- | bitbake/lib/bb/runqueue.py | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/bitbake/lib/bb/runqueue.py b/bitbake/lib/bb/runqueue.py index 27b188256d..de57dcb37b 100644 --- a/bitbake/lib/bb/runqueue.py +++ b/bitbake/lib/bb/runqueue.py | |||
@@ -2034,6 +2034,7 @@ class RunQueueExecuteTasks(RunQueueExecute): | |||
2034 | 2034 | ||
2035 | taskdep = self.rqdata.dataCaches[mc].task_deps[taskfn] | 2035 | taskdep = self.rqdata.dataCaches[mc].task_deps[taskfn] |
2036 | taskhash = self.rqdata.get_task_hash(task) | 2036 | taskhash = self.rqdata.get_task_hash(task) |
2037 | unihash = self.rqdata.get_task_unihash(task) | ||
2037 | if 'fakeroot' in taskdep and taskname in taskdep['fakeroot'] and not (self.cooker.configuration.dry_run or self.rqdata.setscene_enforce): | 2038 | if 'fakeroot' in taskdep and taskname in taskdep['fakeroot'] and not (self.cooker.configuration.dry_run or self.rqdata.setscene_enforce): |
2038 | if not mc in self.rq.fakeworker: | 2039 | if not mc in self.rq.fakeworker: |
2039 | try: | 2040 | try: |
@@ -2043,10 +2044,10 @@ class RunQueueExecuteTasks(RunQueueExecute): | |||
2043 | self.rq.state = runQueueFailed | 2044 | self.rq.state = runQueueFailed |
2044 | self.stats.taskFailed() | 2045 | self.stats.taskFailed() |
2045 | return True | 2046 | return True |
2046 | self.rq.fakeworker[mc].process.stdin.write(b"<runtask>" + pickle.dumps((taskfn, task, taskname, taskhash, False, self.cooker.collection.get_file_appends(taskfn), taskdepdata, self.rqdata.setscene_enforce)) + b"</runtask>") | 2047 | self.rq.fakeworker[mc].process.stdin.write(b"<runtask>" + pickle.dumps((taskfn, task, taskname, taskhash, unihash, False, self.cooker.collection.get_file_appends(taskfn), taskdepdata, self.rqdata.setscene_enforce)) + b"</runtask>") |
2047 | self.rq.fakeworker[mc].process.stdin.flush() | 2048 | self.rq.fakeworker[mc].process.stdin.flush() |
2048 | else: | 2049 | else: |
2049 | self.rq.worker[mc].process.stdin.write(b"<runtask>" + pickle.dumps((taskfn, task, taskname, taskhash, False, self.cooker.collection.get_file_appends(taskfn), taskdepdata, self.rqdata.setscene_enforce)) + b"</runtask>") | 2050 | self.rq.worker[mc].process.stdin.write(b"<runtask>" + pickle.dumps((taskfn, task, taskname, taskhash, unihash, False, self.cooker.collection.get_file_appends(taskfn), taskdepdata, self.rqdata.setscene_enforce)) + b"</runtask>") |
2050 | self.rq.worker[mc].process.stdin.flush() | 2051 | self.rq.worker[mc].process.stdin.flush() |
2051 | 2052 | ||
2052 | self.build_stamps[task] = bb.build.stampfile(taskname, self.rqdata.dataCaches[mc], taskfn, noextra=True) | 2053 | self.build_stamps[task] = bb.build.stampfile(taskname, self.rqdata.dataCaches[mc], taskfn, noextra=True) |
@@ -2462,13 +2463,14 @@ class RunQueueExecuteScenequeue(RunQueueExecute): | |||
2462 | 2463 | ||
2463 | taskdep = self.rqdata.dataCaches[mc].task_deps[taskfn] | 2464 | taskdep = self.rqdata.dataCaches[mc].task_deps[taskfn] |
2464 | taskhash = self.rqdata.get_task_hash(task) | 2465 | taskhash = self.rqdata.get_task_hash(task) |
2466 | unihash = self.rqdata.get_task_unihash(task) | ||
2465 | if 'fakeroot' in taskdep and taskname in taskdep['fakeroot'] and not self.cooker.configuration.dry_run: | 2467 | if 'fakeroot' in taskdep and taskname in taskdep['fakeroot'] and not self.cooker.configuration.dry_run: |
2466 | if not mc in self.rq.fakeworker: | 2468 | if not mc in self.rq.fakeworker: |
2467 | self.rq.start_fakeworker(self, mc) | 2469 | self.rq.start_fakeworker(self, mc) |
2468 | self.rq.fakeworker[mc].process.stdin.write(b"<runtask>" + pickle.dumps((taskfn, task, taskname, taskhash, True, self.cooker.collection.get_file_appends(taskfn), taskdepdata, False)) + b"</runtask>") | 2470 | self.rq.fakeworker[mc].process.stdin.write(b"<runtask>" + pickle.dumps((taskfn, task, taskname, taskhash, unihash, True, self.cooker.collection.get_file_appends(taskfn), taskdepdata, False)) + b"</runtask>") |
2469 | self.rq.fakeworker[mc].process.stdin.flush() | 2471 | self.rq.fakeworker[mc].process.stdin.flush() |
2470 | else: | 2472 | else: |
2471 | self.rq.worker[mc].process.stdin.write(b"<runtask>" + pickle.dumps((taskfn, task, taskname, taskhash, True, self.cooker.collection.get_file_appends(taskfn), taskdepdata, False)) + b"</runtask>") | 2473 | self.rq.worker[mc].process.stdin.write(b"<runtask>" + pickle.dumps((taskfn, task, taskname, taskhash, unihash, True, self.cooker.collection.get_file_appends(taskfn), taskdepdata, False)) + b"</runtask>") |
2472 | self.rq.worker[mc].process.stdin.flush() | 2474 | self.rq.worker[mc].process.stdin.flush() |
2473 | 2475 | ||
2474 | self.build_stamps[task] = bb.build.stampfile(taskname, self.rqdata.dataCaches[mc], taskfn, noextra=True) | 2476 | self.build_stamps[task] = bb.build.stampfile(taskname, self.rqdata.dataCaches[mc], taskfn, noextra=True) |