Allow to override build date with SOURCE_DATE_EPOCH
Allow to override build date with SOURCE_DATE_EPOCH
to make builds reproducible.
See https://reproducible-builds.org/ for why this is good
and https://reproducible-builds.org/specs/source-date-epoch/
for the definition of this variable.
Also use UTC/gmtime
to be independent of timezone.
Without this patch, build results had such a diff:
--- zcat RPMS.1/usr/share/man/man1/gnutls-cli.1.gz
+++ zcat RPMS.2/usr/share/man/man1/gnutls-cli.1.gz
[...]
-.TH gnutls-cli 1 "18 Feb 2023" "3.7.9" "User Commands"
+.TH gnutls-cli 1 "26 Mar 2024" "3.7.9" "User Commands"
This patch was done while working on reproducible builds for openSUSE, sponsored by the NLnet NGI0 fund.