Hi Bruno, * Bruno Haible wrote on Sun, Mar 14, 2010 at 05:07:33PM CET: > But this does not fix the problem with coreutils, as long as it has some > source > files in C++. I would therefore find it useful to change lib-ignore.m4 so that > it sets an AC_SUBSTed variable IGNORE_UNUSED_LIBS, and coreutils/Makefile.am > can then do > AM_LDFLAGS = $(IGNORE_UNUSED_LIBS) > > What do you think?
Sounds sensible to me. Thanks. I would like to avoid having to add per-language linker flag variables such as CXXLDFLAGS unless unavoidable. If the package doesn't want to be reliant on which compiler is used for linking, or use it for both, you might want to make the macro callable more than once, with different language set, similar to how AC_OPENMP works; then, the user can add CXX_IGNORE_UNUSED_LIBS to CXXFLAGS (or CXXLINK) CC_IGNORE_UNUSED_LIBS to CFLAGS, or, why not s/^CC_// to arrive at IGNORE_UNUSED_LIBS for $CC, then you're backward-compatible, if she so prefers. (I'd suggest a patch but I'm so hopelessly behind on everything else already, so it'd be a bit.) Cheers, Ralf