autoconf
[Top][All Lists]
Advanced

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

Re: AC_TRY_LINK with libtool libraries


From: s_a_white
Subject: Re: AC_TRY_LINK with libtool libraries
Date: Tue, 3 Apr 2001 08:44:58 +0100

>
> > This is a known deficiency in the coupling between libtool and autoconf,
> > which needs fixing at some point.  In the mean time how about (wild
guess
> > here!):
>
> >   save_CC=$CC
> >   CC="${SHELL-/bin/sh} ${top_srcdir)/libtool $CC"
> >   AC_TRY_LINK(blah)
> >   CC=$save_CC
>
> This doesn't work.  libtool needs two-pass compile&link, whereas
> AC_TRY_LINK assumes $CC can take a source file and generate an
> executable directly out of it.
>

Gary second suggestion worked after removing the back slashes:

save_CXX=$CXX
CXX="${SHELL-/bin/sh} ${srcdir}/libtool $CXX"
AC_TRY_LINK(blah)
CXX=$save_CXX


It seems ok as looking at the config.log it's a one liner which does both
the compile and link in one go.  As such it's correctly converting the
library dependecies on it.  Btw, what would be your solution?

Simon





reply via email to

[Prev in Thread] Current Thread [Next in Thread]