I'm using link-time optimisation (LTO) in a project that compiles under both GCC and Clang and builds a static library. It's working with GCC 4.8, but GCC 5.4 makes thin LTO objects and when automake tries to build the static library with ar
it fails, because it needs the wrapper script gcc-ar
.
Is there a good example I can look at for how to make automake use gcc-ar
instead of ar
(and similarly for gcc-ranlib
)? I can probably hack something in, but ideally it should:
You can override the default tools used by calling
./configure AR=gcc-ar RANLIB=gcc-ranlib
I'm afraid for ./configure
to pick them up by default, autoconf/automake will have to be fixed to know about those in the default set of checks.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With