Re: AC_TRY_LINK with static libraries (*.a)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello Roman,

* Roman Rybalko wrote on Mon, Aug 27, 2007 at 11:39:01AM CEST:
> AC_TRY_LINK(
>     [ #include <mysql.h> ],
>     [ mysql_shutdown(0, 0); ],
>     AC_DEFINE(HAVE_MYSQL_SHUTDOWN_LEVEL_ARG, 1, [ Define if
> mysql_shutdown() has a second 'level' argument ])
> )
> this generates "compile string" like:
> gcc -o conftest -march=pentium4 -O3
> -I/usr/local/mysql-4.1.12/include/mysql -mcpu=athlon-xp 
> -I/usr/local/include  -L/usr/local/lib
> -L/usr/local/mysql-4.1.12/lib/mysql -lmysqlclient -lz -lcrypt -lnsl -lm
> -L/usr/lib -lssl -lcrypto conftest.c

That's because you use $LDFLAGS for -l, but you should be using $LIBS.

Cheers,
Ralf


_______________________________________________
Autoconf mailing list
Autoconf@xxxxxxx
http://lists.gnu.org/mailman/listinfo/autoconf

[Index of Archives]     [GCC Help]     [Kernel Discussion]     [RPM Discussion]     [Red Hat Development]     [Yosemite News]     [Linux USB]     [Samba]

  Powered by Linux