2010/10/31 Ralf Wildenhues <Ralf.Wildenhues@xxxxxx>: > Hello Sergio, > > * Sergio Belkin wrote on Sat, Oct 30, 2010 at 11:55:17PM CEST: >> I've autoconfiscated a project that link against libresolv and >> libtpthread, and optionally against ssl, mysqlclient and pq. I am >> working on Fedora 13 (i686). >> >> I've found a macro AX_EXT_HAVE_LIB >> (http://www.gnu.org/software/autoconf-archive/ax_ext_have_lib.html) >> that "is identical to AC_SEARCH_LIBS with the exception that will add >> -L<directory> when looking, and use a different variable for each >> directory. " It seems great for me! >> >> The problem is that at the end only take the last library found, in my >> case "pq". >> >> It seems that macro override the earlier value of "LIBS" variable. > > This looks like a bug in the AX_EXT_HAVE_LIB macro to me, as it is > documented to only add to LIBS but not remove existing entries. Indeed. > >> I've examined the configure script but it's a bit tricky, you may >> read a snippet about the macro on http://pastebin.com/vHKYp0UR >> >> I've tried modifying macro, replacing the final LIBS="$new_libs" por >> LIBS="$new_libs $LIBS" which you may read on >> http://pastebin.com/DNCCfgnU >> >> But now LIBS ends as: '-lpq -lmysqlclient -lssl -lpthread -lresolv >> -lssl -lpthread -lresolv ' >> >> It seems harmless but it's too ugly, isn't it? > > Not necessarily. Not necessarily what? :) (sorry english is not my native language) Do you say that that cane be harmful or that is not ugly? :) > > I suggest you report this to the autoconf-archive-maintainers list, > or their bug tracker, so that the macro can be fixed. Good point I've done it. > > Cheers, > Ralf > -- -- Sergio Belkin http://www.sergiobelkin.com Watch More TV http://sebelk.blogspot.com Sergio Belkin - _______________________________________________ Autoconf mailing list Autoconf@xxxxxxx http://lists.gnu.org/mailman/listinfo/autoconf