-
Notifications
You must be signed in to change notification settings - Fork 445
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Build is not reproducible: linking order #111
Comments
Seems doubtful - most build stuff depends either on sorted wildcards (shell, $(wildcard)) or how stuff is declared in makefile. Really hard to see where FS order comes in. The diff you posted shows '.' vs '_' difference, plus various noise with LC vars. So please check first if the difference comes from sort order difference in different locale settings. And what is ReproducibleBuilds attitude to locale management? What part of build is responsible for locale reset? |
Re: Marko Kreen 2016-02-21 pgbouncer/pgbouncer/issues/111/186847962@github.com
Hi Marko, I should have provided more context here. The build log diff wasn't The problem is really visible in the binary diff: Interestingly the difference between the first and the second build is
The idea is that the build result is independent of the locale One particular item varied is the order of items returned by readdir() NB: $(wildcard) doesn't sort (while shell globs are sorted by Christoph |
Hadn't realized about $(wildcard). I'm still on 3.81... Please test if this commit in libusual fixes it. |
Seems github auto-closed it. Please reopen if problem persist. |
The build is reproducible now. Thanks! |
Rebuilding pgbouncer will not always produce the same executable, as the linking order depends on the filesystem order of the object files:
... which also affects CCLD, but is not visible with V=0. See https://tests.reproducible-builds.org/logdiffs/unstable/armhf/pgbouncer_1.7.1-1.diff.gz for the full build log diff.
Reproducible builds are Debian release goal: https://wiki.debian.org/ReproducibleBuilds
I've been staring at lib/mk/antimake.mk to locate the missing $(sort) which would fix this issue, but the complexity of that file is beyond me. We'd be happy if someone could find a fix for this issue. Thanks!
(There is a second source of unreproducibility which I will report separately.)
The text was updated successfully, but these errors were encountered: