diff options
Diffstat (limited to 'meta/lib/oe/sstatesig.py')
| -rw-r--r-- | meta/lib/oe/sstatesig.py | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/meta/lib/oe/sstatesig.py b/meta/lib/oe/sstatesig.py index 30f27b0f4f..331b67c6e4 100644 --- a/meta/lib/oe/sstatesig.py +++ b/meta/lib/oe/sstatesig.py | |||
| @@ -510,6 +510,7 @@ def OEOuthashBasic(path, sigfile, task, d): | |||
| 510 | if task == "package": | 510 | if task == "package": |
| 511 | include_timestamps = True | 511 | include_timestamps = True |
| 512 | include_root = False | 512 | include_root = False |
| 513 | source_date_epoch = float(d.getVar("SOURCE_DATE_EPOCH")) | ||
| 513 | hash_version = d.getVar('HASHEQUIV_HASH_VERSION') | 514 | hash_version = d.getVar('HASHEQUIV_HASH_VERSION') |
| 514 | extra_sigdata = d.getVar("HASHEQUIV_EXTRA_SIGDATA") | 515 | extra_sigdata = d.getVar("HASHEQUIV_EXTRA_SIGDATA") |
| 515 | 516 | ||
| @@ -601,7 +602,11 @@ def OEOuthashBasic(path, sigfile, task, d): | |||
| 601 | raise Exception(msg).with_traceback(e.__traceback__) | 602 | raise Exception(msg).with_traceback(e.__traceback__) |
| 602 | 603 | ||
| 603 | if include_timestamps: | 604 | if include_timestamps: |
| 604 | update_hash(" %10d" % s.st_mtime) | 605 | # Need to clamp to SOURCE_DATE_EPOCH |
| 606 | if s.st_mtime > source_date_epoch: | ||
| 607 | update_hash(" %10d" % source_date_epoch) | ||
| 608 | else: | ||
| 609 | update_hash(" %10d" % s.st_mtime) | ||
| 605 | 610 | ||
| 606 | update_hash(" ") | 611 | update_hash(" ") |
| 607 | if stat.S_ISBLK(s.st_mode) or stat.S_ISCHR(s.st_mode): | 612 | if stat.S_ISBLK(s.st_mode) or stat.S_ISCHR(s.st_mode): |
