[oe-commits] [bitbake] 05/10: siggen: Use unique hashes for tasks

git at git.openembedded.org git at git.openembedded.org
Sat Jul 13 21:17:33 UTC 2019

This is an automated email from the git hooks/post-receive script.

rpurdie pushed a commit to branch master-next
in repository bitbake.

commit aac5f15dd4a71a9f89f660cc57389fc6b246fc92
Author: Richard Purdie <richard.purdie at linuxfoundation.org>
AuthorDate: Thu Jul 11 16:58:14 2019 +0100

    siggen: Use unique hashes for tasks
    Now that runqueue optimises based on task hash, we need to ensure
    tasks have unique hashes even in the simplest siggen mode. Use
    the task name to calculate a unique hash.
    This fixes runqueue tests when hash optimisations are added.
    Signed-off-by: Richard Purdie <richard.purdie at linuxfoundation.org>
 lib/bb/siggen.py | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/lib/bb/siggen.py b/lib/bb/siggen.py
index 3b01721..f9c4798 100644
--- a/lib/bb/siggen.py
+++ b/lib/bb/siggen.py
@@ -49,8 +49,9 @@ class SignatureGenerator(object):
         return self.taskhash[task]
     def get_taskhash(self, fn, task, deps, dataCache):
-        self.taskhash[fn + "." + task] = "0"
-        return self.taskhash[fn + "." + task]
+        k = fn + "." + task
+        self.taskhash[k] = hashlib.sha256(k.encode("utf-8")).hexdigest()
+        return self.taskhash[k]
     def writeout_file_checksum_cache(self):
         """Write/update the file checksum cache onto disk"""

To stop receiving notification emails like this one, please contact
the administrator of this repository.

More information about the Openembedded-commits mailing list