mirror of
git://git.yoctoproject.org/poky.git
synced 2025-07-19 21:09:03 +02:00
install-buildtools: remove md5 checksum validation
No need to validate with the md5 checksum, as the file is not even uploaded to the Yocto release webpage (the download never failed due to a wrong indentation of an else statement). For validation purposes, use the sha256 checksum only. (From OE-Core rev: b740d2f9d40aef1e18c022d1e82b4fb2c5c1fc22) Signed-off-by: Aleksandar Nikolic <aleksandar.nikolic@zeiss.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
parent
ecad518092
commit
cedb7197cc
|
@ -238,16 +238,12 @@ def main():
|
|||
# Verify checksum
|
||||
if args.check:
|
||||
logger.info("Fetching buildtools installer checksum")
|
||||
checksum_type = ""
|
||||
for checksum_type in ["md5sum", "sha256sum"]:
|
||||
checksum_type = "sha256sum"
|
||||
check_url = "{}.{}".format(buildtools_url, checksum_type)
|
||||
checksum_filename = "{}.{}".format(filename, checksum_type)
|
||||
tmpbuildtools_checksum = os.path.join(tmpsdk_dir, checksum_filename)
|
||||
ret = subprocess.call("wget -q -O %s %s" %
|
||||
(tmpbuildtools_checksum, check_url), shell=True)
|
||||
if ret == 0:
|
||||
break
|
||||
else:
|
||||
if ret != 0:
|
||||
logger.error("Could not download file from %s" % check_url)
|
||||
return ret
|
||||
|
@ -263,9 +259,6 @@ def main():
|
|||
logger.error("Filename does not match name in checksum")
|
||||
return 1
|
||||
checksum = m.group('checksum')
|
||||
if checksum_type == "md5sum":
|
||||
checksum_value = md5_file(tmpbuildtools)
|
||||
else:
|
||||
checksum_value = sha256_file(tmpbuildtools)
|
||||
if checksum == checksum_value:
|
||||
logger.info("Checksum success")
|
||||
|
|
Loading…
Reference in New Issue
Block a user