summaryrefslogtreecommitdiffstats
path: root/meta/lib/oe
diff options
context:
space:
mode:
authorJoshua Watt <JPEWhacker@gmail.com>2024-02-18 13:08:30 -0700
committerRichard Purdie <richard.purdie@linuxfoundation.org>2024-02-19 11:58:12 +0000
commitba68f3132d1993180c540bb6df2ee735834f3a79 (patch)
tree7b7f83b000609dbc3303200b637298e97b8ce2cf /meta/lib/oe
parenteca5708b873453cefdf1e1e97844065a34009168 (diff)
downloadpoky-ba68f3132d1993180c540bb6df2ee735834f3a79.tar.gz
sstatesig: Implement new siggen API
Implements the new API required for querying unihashes in parallel (From OE-Core rev: 0c66d07238d20dc1b34355e4c472aa7457d2e5fe) Signed-off-by: Joshua Watt <JPEWhacker@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/lib/oe')
-rw-r--r--meta/lib/oe/sstatesig.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/meta/lib/oe/sstatesig.py b/meta/lib/oe/sstatesig.py
index 1b4380f21b..aa891ecf0a 100644
--- a/meta/lib/oe/sstatesig.py
+++ b/meta/lib/oe/sstatesig.py
@@ -205,10 +205,10 @@ class SignatureGeneratorOEBasicHashMixIn(object):
205 return self.lockedhashes[tid] 205 return self.lockedhashes[tid]
206 return super().get_stampfile_hash(tid) 206 return super().get_stampfile_hash(tid)
207 207
208 def get_unihash(self, tid): 208 def get_cached_unihash(self, tid):
209 if tid in self.lockedhashes and self.lockedhashes[tid] and not self._internal: 209 if tid in self.lockedhashes and self.lockedhashes[tid] and not self._internal:
210 return self.lockedhashes[tid] 210 return self.lockedhashes[tid]
211 return super().get_unihash(tid) 211 return super().get_cached_unihash(tid)
212 212
213 def dump_sigtask(self, fn, task, stampbase, runtime): 213 def dump_sigtask(self, fn, task, stampbase, runtime):
214 tid = fn + ":" + task 214 tid = fn + ":" + task
@@ -326,6 +326,7 @@ class SignatureGeneratorOEEquivHash(SignatureGeneratorOEBasicHashMixIn, bb.sigge
326 self.method = data.getVar('SSTATE_HASHEQUIV_METHOD') 326 self.method = data.getVar('SSTATE_HASHEQUIV_METHOD')
327 if not self.method: 327 if not self.method:
328 bb.fatal("OEEquivHash requires SSTATE_HASHEQUIV_METHOD to be set") 328 bb.fatal("OEEquivHash requires SSTATE_HASHEQUIV_METHOD to be set")
329 self.max_parallel = int(data.getVar('BB_HASHSERVE_MAX_PARALLEL') or 1)
329 330
330# Insert these classes into siggen's namespace so it can see and select them 331# Insert these classes into siggen's namespace so it can see and select them
331bb.siggen.SignatureGeneratorOEBasicHash = SignatureGeneratorOEBasicHash 332bb.siggen.SignatureGeneratorOEBasicHash = SignatureGeneratorOEBasicHash