|
@@ -57,10 +57,10 @@ def swupdate_write_sha256(s):
|
|
|
with open(os.path.join(s, "sw-description"), 'r') as f:
|
|
with open(os.path.join(s, "sw-description"), 'r') as f:
|
|
|
for line in f:
|
|
for line in f:
|
|
|
shastr = r"sha256.+=.+@(.+\")"
|
|
shastr = r"sha256.+=.+@(.+\")"
|
|
|
- #m = re.match(r"^(?P<before_placeholder>.+)sha256.+=.+(?P<filename>\w+)", line)
|
|
|
|
|
m = re.match(r"^(?P<before_placeholder>.+)(sha256|version).+[=:].*(?P<quote>[\'\"])@(?P<filename>.*)(?P=quote)", line)
|
|
m = re.match(r"^(?P<before_placeholder>.+)(sha256|version).+[=:].*(?P<quote>[\'\"])@(?P<filename>.*)(?P=quote)", line)
|
|
|
if m:
|
|
if m:
|
|
|
filename = m.group('filename')
|
|
filename = m.group('filename')
|
|
|
|
|
+ bb.warn("Syntax for sha256 changed, please use $swupdate_get_sha256(%s)" % filename)
|
|
|
hash = swupdate_get_sha256(None, s, filename)
|
|
hash = swupdate_get_sha256(None, s, filename)
|
|
|
write_lines.append(line.replace("@%s" % (filename), hash))
|
|
write_lines.append(line.replace("@%s" % (filename), hash))
|
|
|
else:
|
|
else:
|