This is the mail archive of the
automake@gnu.org
mailing list for the automake project.
Re: difference between link objects and librarys
- From: Ralf Wildenhues <Ralf dot Wildenhues at gmx dot de>
- To: "automake at gnu dot org" <automake at gnu dot org>
- Date: Mon, 21 Jun 2004 08:42:57 +0200
- Subject: Re: difference between link objects and librarys
- Organization: Department of Numerical Simulation, University of Bonn
- References: <40D6127C.8030806@sbcglobal.net>
* David T Farning wrote on Mon, Jun 21, 2004 at 12:41:00AM CEST:
> I am unclear as to the difference between LIBADD and LDADD. Diffent
> resources seems to say different things.
To make it clear:
Whether to use *_LDADD or *_LIBADD, does not depend on what's to the
right of it (may that be a Libtool library, a "normal" library, or
merely object files), but what's to the left of _LDADD or _LIBADD
respectively.
It makes a difference whether you are trying to *build* a program or
a library. So, it's always
fooprogram_LDADD
and
libfoo_a_LIBADD
libbaz_la_LIBADD
and so on.
Does that help?
> >From
> http://www.murrayc.com/learning/linux/building_libraries/building_libraries.shtml.
>
> Libtool libraries have the .la suffix, instead of .a
> We need to use _LIBADD instead of_ LDADD.
Tell the author of this site to improve his wording, as it is not quite
clear on this point.
> For instance
> lib_LTLIBRARIES = something.la
> something_la_SOURCES = main.cc
> something_la_LIBADD = sub/libsubstuff.la
This example is ok, however. He just left out a few explaining steps.
Regards,
Ralf