Bug 16152 - Single file downloads in SRC_URI cause inconsistent source date epoch values and non-reproducible builds
Summary: Single file downloads in SRC_URI cause inconsistent source date epoch values ...
Status: NEW
Alias: None
Product: OE-Core
Classification: Build System, Metadata & Runtime
Component: core (show other bugs)
Version: 6.1
Hardware: x86 Multiple
: Medium normal
Target Milestone: 6.1
Assignee: Unassigned
QA Contact:
URL:
Whiteboard:
Depends on:
Blocks:
 
Reported: 2026-01-26 18:02 UTC by Joshua Watt
Modified: 2026-05-28 13:16 UTC (History)
5 users (show)

See Also:
OS type for building Yocto: ---
Type of Regression: ---
Verified:
Documentation change: No (bug/feature does not impact docs)


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Joshua Watt 2026-01-26 18:02:08 UTC
If a recipe downloads a bare file in SRC_URI (i.e. not a tarball), and doesn't download a git repo, the source date epoch can be inconsistent. This can particularly happen if the file ends up in a pre-mirror. The reason is that the reproducible code falls to get_source_date_epoch_from_youngest_file(), and this date will likely be the date of the downloaded file. Note that this generally doesn't affect file:// SRC_URI values, because their mtime is fixed.

The fix is probably that get_source_date_epoch_from_youngest_file should detect single file downloads (e.g. non-tarball files) and skip itself, allowing SOURCE_DATE_EPOCH_FALLBACK to be used instead. Alternatively, get_source_date_epoch_from_youngest_file might be able to be completely removed, although it does provide value for the common case of downloading a tarball.
Comment 1 Randy MacLeod 2026-05-28 13:16:30 UTC
Bulk move of 6.0 Medium bugs to 6.1.