[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Not installing local library.
From: |
Ralf Wildenhues |
Subject: |
Re: Not installing local library. |
Date: |
Wed, 18 Jun 2008 20:48:48 +0200 |
User-agent: |
Mutt/1.5.18 (2008-05-17) |
Hello Edward, and sorry for the slow reply,
* Edward Tomasz Napierala wrote on Tue, Jun 10, 2008 at 10:17:24PM CEST:
> On 0610T1755, Ralf Wildenhues wrote:
> > > I have a program thad depends on a library. I want to achieve
> > > the following: if the library is already installed, than use it,
> > > linking dynamically. If it's not installed, then build it (it's
> > > included in the program tarball) and link against it statically.
> > > It pretty much works, except that in the latter case 'make install'
> > > in program source directory installs the library too, and I don't
> > > want that to happen - I want it to install only the main program,
> > > and not the library and its headers. How to do that?
> >
> > Does this help?
> > <http://thread.gmane.org/gmane.comp.sysutils.autoconf.general/10512/focus=10515>
> > <http://thread.gmane.org/gmane.comp.gnu.libtool.general/9363/focus=9365>
>
> Well, I've already read that and that's why I have most of this thing
> working. But it doesn't answer the last missing part - how to tell
> autotools that contents of libsmf/ are not to be installed in 'make
> install'.
Well, you could make a switch --disable-libsmf-install or
--enable-lsmf-convenience. Either you let the user pass this, or you
the toplevel configure add the needed setting to ac_configure_args.
> As for the 'why' question in the latter post - for me, it's because I
> don't want to force users to install additional dependency, and at the
> same time don't want to create conflict with that dependancy should it
> be installed later.
OK.
> > > SMF_LIBS="../libsmf/src/.libs/libsmf.a"
> >
> > Strictly speaking, it could be .libs or _libs (but systems where .libs
> > doesn't work are dying out). Anyway, you shouldn't have to know. The
> > rest is answered in the threads above.
>
> In other words, I should be using '.la' file instead of '.a' directly?
Yes.
Cheers,
Ralf