[PATCH v1 0/6] TIMESTAMP output section command
Joseph Myers
josmyers@redhat.com
Tue Oct 7 16:11:39 GMT 2025
On Tue, 7 Oct 2025, binutils@emagii.com wrote:
> The TIMESTAMP command inserts a QUAD-word entry with the current time
> into the image at the current location.
> The value is the number of seconds since the Epoch,
> 1970-01-01 00:00:00 +0000 (UTC)
In the modern world of reproducible builds, embedding timestamps in output
files is an antipattern and new instances of it should be avoided.
Anything embedding a timestamp for legacy reasons needs to respect
SOURCE_DATE_EPOCH (via using bfd_get_current_time, for example); anything
new should not determine a timestamp itself but might use an identifier
passed into the linker by a command-line option so it's the responsibility
of an external build system to pass in the timestamp it wants to use if it
wants to use one.
--
Joseph S. Myers
josmyers@redhat.com
More information about the Binutils
mailing list