Replies: 2 comments
-
How is the timestamp used? |
Beta Was this translation helpful? Give feedback.
0 replies
-
If reproducible means we can generate the same results again, then timestamps in built archives would be the difference. I only made this a discussion because I don't know if that's a problem - the topic was mentioned on the site but not to the level of detail to know whether it "really matters". |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Support for environment variable
SOURCE_DATE_EPOCH
in constructing SCons packages was added a few releases ago (this is written as 4.5 is current). It changes the default behavior of three values written intoSCons/__init__.py
as the "build" is done -__date__
,__developer__
and__buildsys__
. If any of those values were supplied to the build (asDATE
,DEVELOPER
,BUILDSYSTEM
build variables) those are used; if not supplied a setSOURCE_DATE_EPOCH
causes the latter two to become_reproducible
, and for the date, the value ofSOURCE_DATE_EPOCH
is taken as a UNIX-style timestamp and that is converted. This prevents building again at a different time, on a different machine, or as a different user from producing packages with different contents.This post is to noodle about whether additional work is needed (at this time there have not been requests, which is why this is a "discussion", not an "issue"). When SCons does a build, it copies files to the build directory, and packages those up with a variety of tools. If this wasn't done in an existing build tree, the documentation will be regenerated. This means essentially all the timestamps of the files used to prepare packages will be set to the time the build is done. https://reproducible-builds.org/specs/source-date-epoch/ mentions this case:
In our case, we can not assume that source timestamps are before
SOURCE_DATE_EPOCH
. Rebuilt packages (wheel, sdist, tar and zip bundles) will definitely get different file timestamps. Whether this matters in practice, I'm not sure. Because we don't directly call the tools that produce the archives (e.g. setuptools may do for us), we don't have a ton of control at that level.Beta Was this translation helpful? Give feedback.
All reactions