On 08/12/2014 04:01 AM, bmorbach wrote: > Hi everyone! > > I've been doing some work towards reproducible builds in Fedora (mostly > with various upstreams so far) and one of the elephants in the Room are > obviously Pythons .pyc and .pyo files. > > As those contain the mtime of the original .py file, they might be > different for each rebuild of an srpm. > For many rpms this isn't a problem, because the files are not modified > and thus retain their timestamp from the archive. Quite a few rpms do > modify to .py files though and because of that, every build has a > different result. > > I would like to propose to set the mtime of all .py files to a fixed > (for this specific srpm) time. This could be done > in /usr/lib/rpm/brp-python-bytecompile before doing the actual > byte-compilation. This would result in the same .py{c,o} files being > created for each rebuild.
This sounds like a reasonable approach to me, especially if the mtime for the SRPM is derived from dist-git. Regards, Nick. -- Nick Coghlan Red Hat Hosted & Shared Services Software Engineering & Development, Brisbane HSS Provisioning Architect _______________________________________________ python-devel mailing list python-devel@lists.fedoraproject.org https://admin.fedoraproject.org/mailman/listinfo/python-devel