This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
Re: [PATCH] GNU_AR_DETERMINISTIC env var, --enable-deterministic-archives
Hi Roland,
I agree with this as a general principle. (But it's worth pointing out
that GCC is indeed affected by various environment variables--which, at
least, are documented in their own section of the GCC manual.)
True.
Well, it's just not very true at all about GCC. But I take your point.
However, you didn't say anything about the build-time configure option.
Sorry, I should have covered that.
I am OK with the configure option. In fact I think that it is the best
way forward. Allow users (or toolchain providers) to choose what the
default behaviour will be, and provide a command line option to
explicitly determine determinism.
Also - there needs to be some way for the user to find out how the
particular ar/ranlib that they are using was configured.
What do you have in mind? It's easy enough to add the information to
--help output,
That was what I had in mind.
but that is not programmatically friendly.
True. Another option would be to have "ar --verbose" display the
configure arguments that were used when it was built. Ie similar to the
way that gcc behaves.
But I don't
really see why someone really needs to know the default.
I was thinking more about debugging again. If user reports a strange
behaviour with ar not storing file timestamps say, then we can ask them
to run "ar --help" or "ar --verbose" and explain what the output means.
So - if you will accept dropping the environment variable and just using
a configure time parameter to set the default behaviour then please do
resubmit your patch.
Cheers
Nick