summaryrefslogtreecommitdiffstats
path: root/meta/classes
diff options
context:
space:
mode:
authorMark Hatle <mark.hatle@kernel.crashing.org>2022-10-06 16:54:07 -0500
committerRichard Purdie <richard.purdie@linuxfoundation.org>2022-11-09 17:42:08 +0000
commit8c13777e741db11b2525c29ba79ce3123f3045bc (patch)
tree5e91aaf9613197e41617fdafc7b008a33bac93fc /meta/classes
parent38ae1b6e5f416a7780dbf93735ac3a88f871a522 (diff)
downloadpoky-8c13777e741db11b2525c29ba79ce3123f3045bc.tar.gz
insane.bbclass: Allow hashlib version that only accepts on parameter
Some versions of hashlib don't appear to implement the second FIPS related argument. Detect this and support both versions. (From OE-Core rev: 01af6453baccc926c245c51dda81aba5e15725c5) Signed-off-by: Mark Hatle <mark.hatle@amd.com> Signed-off-by: Mark Hatle <mark.hatle@kernel.crashing.org> Signed-off-by: Ross Burton <ross.burton@arm.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit 2bbabed51e3aca138486d3feef640f5d3249be40) Signed-off-by: Steve Sakoman <steve@sakoman.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/classes')
-rw-r--r--meta/classes/insane.bbclass5
1 files changed, 4 insertions, 1 deletions
diff --git a/meta/classes/insane.bbclass b/meta/classes/insane.bbclass
index 0d93d50e58..dfda70bad6 100644
--- a/meta/classes/insane.bbclass
+++ b/meta/classes/insane.bbclass
@@ -552,7 +552,10 @@ python populate_lic_qa_checksum() {
552 import hashlib 552 import hashlib
553 lineno = 0 553 lineno = 0
554 license = [] 554 license = []
555 m = hashlib.new('MD5', usedforsecurity=False) 555 try:
556 m = hashlib.new('MD5', usedforsecurity=False)
557 except TypeError:
558 m = hashlib.new('MD5')
556 for line in f: 559 for line in f:
557 lineno += 1 560 lineno += 1
558 if (lineno >= beginline): 561 if (lineno >= beginline):