automake
[Top][All Lists]
Advanced

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

Re: getting a locally built library


From: Bruce Korb
Subject: Re: getting a locally built library
Date: Thu, 14 Nov 2002 07:47:13 -0800

Alexandre Duret-Lutz wrote:
>  >> /bin/sh ../libtool --mode=link gcc  -g -O2  -L/sw/lib -o autogen \
>  >> -export-dynamic -lguile *.o  -L/sw/lib -lguile -lm \
>  >> -L../autoopts/.libs -lopts -ldl
>  >> ld: Undefined symbols:
>  >> _aopts_alloc
>  >> _aopts_realloc
>  >> _aopts_strdup
>  >> make[1]: *** [autogen] Error 1
> 
> Where does this command comes from?  This doesn't look like an
> Automake-generated call to libtool.  First, Automake should not
> generate something like `*.o';

Sorry.  I edited slightly for clarity.  I thought I mentioned that.

> second, it should not output
> `-L../autoopts/.libs -lopts' but `../autoopts/libopts.la'
> since Bruce said `autogen_LDADD = $(top_builddir)/autoopts/libopts.la'.
> 
> I'm tempted to think that the link rule was hand-edited (either in the
> Makefile(|.in|.am), or in the output).

That part I did not change from David's email.
Here's my link (unedited and not David's and for 5.4.8pre2,
but I haven't changed the auto* tool stuff):

/bin/sh ../libtool --mode=link gcc  -g   -o autogen -export-dynamic -L/usr/lib 
-lguile -lqthreads -lpthread -lm autogen-opts.o
autogen-cgi-fsm.o autogen-agCgi.o autogen-agShell.o autogen-agUtils.o 
autogen-autogen.o autogen-defDirect.o autogen-defFind.o
autogen-defLex.o autogen-defLoad.o autogen-defParse.o autogen-defReduce.o 
autogen-expExtract.o autogen-expFormat.o
autogen-expGperf.o autogen-expGuile.o autogen-expMake.o autogen-expOutput.o 
autogen-expPrint.o autogen-expState.o
autogen-expString.o autogen-funcCase.o autogen-funcDef.o autogen-funcEval.o 
autogen-funcFor.o autogen-funcIf.o autogen-functions.o
autogen-loadPseudo.o autogen-tpLoad.o autogen-tpParse.o autogen-tpProcess.o 
../autoopts/libopts.la -ldl
mkdir .libs
gcc -g -o .libs/autogen autogen-opts.o autogen-cgi-fsm.o autogen-agCgi.o 
autogen-agShell.o autogen-agUtils.o autogen-autogen.o
autogen-defDirect.o autogen-defFind.o autogen-defLex.o autogen-defLoad.o 
autogen-defParse.o autogen-defReduce.o autogen-expExtract.o
autogen-expFormat.o autogen-expGperf.o autogen-expGuile.o autogen-expMake.o 
autogen-expOutput.o autogen-expPrint.o
autogen-expState.o autogen-expString.o autogen-funcCase.o autogen-funcDef.o 
autogen-funcEval.o autogen-funcFor.o autogen-funcIf.o
autogen-functions.o autogen-loadPseudo.o autogen-tpLoad.o autogen-tpParse.o 
autogen-tpProcess.o -Wl,--export-dynamic  -L/usr/lib
/usr/lib/libguile.so /usr/lib/libqthreads.so -lpthread -lm 
../autoopts/.libs/libopts.so -ldl -Wl,--rpath -Wl,/usr/local/lib
creating autogen

Abbreviated (for clarity):

/bin/sh ../libtool --mode=link gcc  -g   -o autogen \
   -export-dynamic -L/usr/lib -lguile -lqthreads -lpthread -lm \
   *.o ../autoopts/libopts.la -ldl
mkdir .libs
gcc -g -o .libs/autogen *.o -Wl,--export-dynamic  \
   -L/usr/lib /usr/lib/libguile.so /usr/lib/libqthreads.so -lpthread -lm \
   ../autoopts/.libs/libopts.so -ldl -Wl,--rpath -Wl,/usr/local/lib
creating autogen

So, here, too, it looks like a ``-L/usr/lib'' appears early in
the link arguments, only I'm sure the ``../autoopts/.libs/libopts.so''
will get handled before any -lwhatever's.  Perhaps when I edit
such in the future, I'll use ``<obj-list>'' instead of ``*.o''.

Oh, my configure invocation:

  sh ./configure CFLAGS="-g"




reply via email to

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