[Python-Dev] Deterministic builds of the interpreter

2017年2月09日 08:15:04 -0800

Hi,
I'm attempting to make the builds of the Python interpreters for Nixpkgs
[1] deterministic.
In the case of Python 2.7 we have a patch [2] that fixes the timestamp used
in .pyc files in case the env var `DETERMINISTIC_BUILD` is set. We also
remove `wininst*.exe`. This works fine, although there are 4 small issues
left [3]. Do you have any idea what is going on in these files that could
make them indeterministic?
For Python 3.x I disabled ensurepip, removed `wininst*.exe`, and modified
`py_compile` to use `0` instead of `source_stats['mtime']`. The builds are
not yet deterministic [4]. Any suggestions what could be fixed here?
Kind regards,
Freddy
[1] https://github.com/NixOS/nixpkgs
[2]
https://github.com/NixOS/nixpkgs/blob/1da6775/pkgs/development/interpreters/python/cpython/2.7/deterministic-build.patch
[3] https://github.com/NixOS/nixpkgs/issues/22570#issuecomment-278474082
[4] https://gist.github.com/anonymous/7cc147af6511dee2dc5a5b8d110f0e6b
_______________________________________________
Python-Dev mailing list
[email protected]
https://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com

Reply via email to