summaryrefslogtreecommitdiffstats
path: root/bitbake
diff options
context:
space:
mode:
authorRichard Purdie <richard.purdie@linuxfoundation.org>2023-02-15 10:43:17 +0000
committerRichard Purdie <richard.purdie@linuxfoundation.org>2023-02-22 10:12:32 +0000
commit0922cef2f411b7932337164c66acfbc38073d537 (patch)
treeca3a6bbfcd0d198ccba1c62d72fe28299119b3b6 /bitbake
parente5414e596233896bb711cb72246a89a077ab9eed (diff)
downloadpoky-0922cef2f411b7932337164c66acfbc38073d537.tar.gz
bitbake: runqueue: Handle deferred task rehashing in multiconfig builds
If the hash of a task changes and that hash is a deferred task (e.g. a multiconfig build), we need to ensure that the hash change propagates through to all the tasks else the build will run multiple copies of the task, sometimes with oddly differing results as the outhashes of native tasks built in differing locations can confuse things. (Bitbake rev: 01936b4dd8e680f1f8035ff2d6231673f61efeab) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit 2db571324f755edc4981deecbcfdf0aaa5a97627) Signed-off-by: Fabio Berton <fabio.berton@criticaltechworks.com> Signed-off-by: Steve Sakoman <steve@sakoman.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake')
-rw-r--r--bitbake/lib/bb/runqueue.py14
1 files changed, 10 insertions, 4 deletions
diff --git a/bitbake/lib/bb/runqueue.py b/bitbake/lib/bb/runqueue.py
index f82bc41357..a437aeef90 100644
--- a/bitbake/lib/bb/runqueue.py
+++ b/bitbake/lib/bb/runqueue.py
@@ -2348,10 +2348,16 @@ class RunQueueExecute:
2348 self.updated_taskhash_queue.remove((tid, unihash)) 2348 self.updated_taskhash_queue.remove((tid, unihash))
2349 2349
2350 if unihash != self.rqdata.runtaskentries[tid].unihash: 2350 if unihash != self.rqdata.runtaskentries[tid].unihash:
2351 hashequiv_logger.verbose("Task %s unihash changed to %s" % (tid, unihash)) 2351 # Make sure we rehash any other tasks with the same task hash that we're deferred against.
2352 self.rqdata.runtaskentries[tid].unihash = unihash 2352 torehash = [tid]
2353 bb.parse.siggen.set_unihash(tid, unihash) 2353 for deftid in self.sq_deferred:
2354 toprocess.add(tid) 2354 if self.sq_deferred[deftid] == tid:
2355 torehash.append(deftid)
2356 for hashtid in torehash:
2357 hashequiv_logger.verbose("Task %s unihash changed to %s" % (hashtid, unihash))
2358 self.rqdata.runtaskentries[hashtid].unihash = unihash
2359 bb.parse.siggen.set_unihash(hashtid, unihash)
2360 toprocess.add(hashtid)
2355 2361
2356 # Work out all tasks which depend upon these 2362 # Work out all tasks which depend upon these
2357 total = set() 2363 total = set()