2010/9/27 Sergio Belkin <sebelk@xxxxxxxxx>: > 2010/8/23 Eric Blake <eblake@xxxxxxxxxx>: > >>>> Ah - the difference is the presence of -L/usr/lib/mysql in the working >>>> command line. For your configure test to work, you'd also have to >>>> provide >>>> that same -L option to LDFLAGS prior to using AC_CHECK_LIB (or the better >>>> AC_SEARCH_LIBS). >>> >>> But I don't understand why... with AC_CHECK_LIB I have no need to use >>> LDFLAGS on Mandriva or Ubuntu... >> >> Most likely, because Mandriva or Ubuntu chooses to install the package >> directly into /usr/lib instead of Fedora's choice of installing into >> /usr/lib/mysql (I don't use Ubuntu myself to state that with certainty). I >> can't say whether the difference in layout between the distros is worthy of >> a bug report (or even to which distro you should file such a bug report), >> but that's one of the joys you get to encounter when porting software to >> multiple platforms. More importantly, you should remember that someone >> might not have mysql installed anywhere under /usr/lib at all; perhaps they >> installed it in $HOME/lib instead. >> >> Hence, the autoconf approach is to expose LDFLAGS as the desired way of >> letting the user tune where to look for particular libraries, and both the >> autoconf-archives and gnulib projects have written wrapper macros that make >> it easier to search in several default candidate locations (including the >> location relative to ${prefix}) to set the correct LDFLAGS for a given >> library. >> >> -- >> Eric Blake eblake@xxxxxxxxxx +1-801-349-2682 >> Libvirt virtualization library http://libvirt.org >> > > > Hi, I've added > > LDFLAGS="-L/usr/lib/mysql $LDFLAGS" > > > and it worked. I wonder if the proper way to do it. > > Thanks in advance!! Clarification: I meant added to configure.ac TIA -- -- 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