This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH] libtool: Sort output of 'find' to enable deterministic builds.
- From: Jeff Law <law at redhat dot com>
- To: Richard Biener <richard dot guenther at gmail dot com>, bwiedemann at suse dot de, Ian Lance Taylor <iant at google dot com>
- Cc: GCC Patches <gcc-patches at gcc dot gnu dot org>, "Joseph S. Myers" <joseph at codesourcery dot com>
- Date: Fri, 29 Jun 2018 09:09:38 -0600
- Subject: Re: [PATCH] libtool: Sort output of 'find' to enable deterministic builds.
- References: <fd112d9a-17d4-5b03-1710-1b2734fa0ef1@redhat.com> <20180625113856.12031-1-bwiedemann@suse.de> <CAFiYyc3qFQAqtjF6iKX1Eingr=4F1pPmDE_b=5xKaGYjQ-PEEw@mail.gmail.com>
On 06/29/2018 02:13 AM, Richard Biener wrote:
> On Mon, Jun 25, 2018 at 1:39 PM Bernhard M. Wiedemann
> <bwiedemann@suse.de> wrote:
>>
>> so that gcc builds in a reproducible way
>> in spite of indeterministic filesystem readdir order
>>
>> See https://reproducible-builds.org/ for why this is good.
>>
>> While working on the reproducible builds effort, I found that
>> when building the gcc8 package for openSUSE, there were differences
>> between each build in resulting binaries like gccgo, cc1obj and cpp
>> because the order of objects in libstdc++.a varied based on
>> the order of entries returned by the filesystem.
>>
>> Two remaining issues are with timestamps in the ada build
>> and with profiledbootstrap that only is reproducible if all inputs
>> in the profiling run remain constant (and make -j breaks it too)
>>
>> Testcases:
>> none included because patch is trivial and it would need to compare builds on 2 filesystems.
>>
>> Bootstrapping and testing:
>> tested successfully with gcc8 on x86_64
>
> Looks ok to me.
>
> Btw, running find to search for libtool.m4/ltmain.sh I find extra copies in
>
> ./libgo/config/ltmain.sh
> ./libgo/config/libtool.m4
>
> which are nearly identical besides appearantly patched in GO support?
>
> Can we consolidate those and/or do we need to patch those as well?
Ideally consolidate. The README indicates that directory is supposed
"temporarily until Go support is added to autoconf and libtool".
So, assuming autoconf/libtool have updated appropriately upstream, then
we "just" need to get ourselves up-to-date and I think that directory of
stuff can go away.
In the immediate term, applying the patch to both instances seems wise.
Bernhard, do you have commit privs?
jeff