[Top][All Lists]

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

Re: Enabling/disabling shared or static libs from

From: Robert Boehne
Subject: Re: Enabling/disabling shared or static libs from
Date: Fri, 08 Jun 2001 10:51:50 -0500


If you put additional files in the subdirectories,
you can specify whatever you like in them, and they'll only
affect those subdirectories.
In general you can use one top-level if everything
is the same, if not you just need to have separate configure
scripts.  The scripts should run automatically so it doesn't
require multiple "configure" commands to be executed by
the user.  Another option may be to use libtool convience
libraries, but I'm not certain that would work for your case.



Pierre Sarrazin wrote:
> I am autoconfiscating a large source tree with Autoconf (2.13),
> Automake (1.4) and Libtool (1.3.5) on a GNU/Linux system.
> In this tree, there are subtrees that constitute the sources for
> shared libraries.  Other subtrees should give static libraries
> because they will never be needed in shared form.  Yet other subtrees
> define executable commands.
> In the files that define the libraries, I specify that
> I want to build libtool libraries, e.g.,
> One problem is that libtool then compiles every source file twice:
> once with position-independent code for a shared library, and once
> with position-dependent code for a static library.
> None of the libraries need to be created in both shared and static
> form.  Thus, compiling twice wastes time and disk space.
> I know that I can specify AC_DISABLE_STATIC before AM_PROG_LIBTOOL
> in the file.  But then, all libraries are created in
> shared form, which is inappropriate in my case.  This solution is
> too centralized.
> Logically, it is in a file that I would like to ask
> that a specific library should be static.
> There is one file in which I build two libraries:
>     lib_LTLIBRARIES =
> libutils should be static, while libmem should be shared.
> I tried adding the -static flag to the *_LDFLAGS variable:
>     libutils_la_LDFLAGS = -version-info 0:0:0 -no-undefined -static
> But the source files are still compiled twice.
> Does automake support what I am trying to say?
> I would not mind if all source files were compiled as
> position-independent code, even for static libraries.
> --
> Pierre Sarrazin <sarrazip -at- sympatico -dot- ca>
> _______________________________________________
> Libtool mailing list
> address@hidden

Robert Boehne             Software Engineer
Ricardo Software   Chicago Technical Center
TEL: (630)789-0003 x. 238
FAX: (630)789-0127
email:  address@hidden

reply via email to

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