diff options
Diffstat (limited to 'bitbake/lib/bb/utils.py')
| -rw-r--r-- | bitbake/lib/bb/utils.py | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/bitbake/lib/bb/utils.py b/bitbake/lib/bb/utils.py index e6e21e20fe..64a004d0d8 100644 --- a/bitbake/lib/bb/utils.py +++ b/bitbake/lib/bb/utils.py | |||
| @@ -547,7 +547,12 @@ def md5_file(filename): | |||
| 547 | Return the hex string representation of the MD5 checksum of filename. | 547 | Return the hex string representation of the MD5 checksum of filename. |
| 548 | """ | 548 | """ |
| 549 | import hashlib | 549 | import hashlib |
| 550 | return _hasher(hashlib.new('MD5', usedforsecurity=False), filename) | 550 | try: |
| 551 | sig = hashlib.new('MD5', usedforsecurity=False) | ||
| 552 | except TypeError: | ||
| 553 | # Some configurations don't appear to support two arguments | ||
| 554 | sig = hashlib.new('MD5') | ||
| 555 | return _hasher(sig, filename) | ||
| 551 | 556 | ||
| 552 | def sha256_file(filename): | 557 | def sha256_file(filename): |
| 553 | """ | 558 | """ |
