libtool
[Top][All Lists]
Advanced

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

Re: Conditional sources in archive libraries


From: Ralf Wildenhues
Subject: Re: Conditional sources in archive libraries
Date: Tue, 30 May 2006 20:11:15 +0200
User-agent: Mutt/1.5.11+cvs20060403

* Liviu Nicoara wrote on Tue, May 30, 2006 at 07:49:38PM CEST:
>
> /bin/sh ../libtool --tag=CXX --mode=link g++  -g -O2   -o libfoo.la
> -rpath /usr/local/lib -release 0.0.2 foo.lo bar.o
> mkdir .libs
> 
> *** Warning: Linking the shared library libfoo.la against the non-libtool
> *** objects  bar.o is not portable!

> However, in a shared library build:

> /bin/sh ../libtool --tag=CXX --mode=link g++  -g -O2   -o libfoo.la
> -rpath /usr/local/lib -release 0.0.2 foo.lo bar.o
> 
> *** Warning: Linking the shared library libfoo.la against the non-libtool
> *** objects  bar.o is not portable!

Easy: just change configure.ac to read:
  ## Using only bar.s
  MY_EXTRA_SOURCES='bar.lo'

as libtool hides PIC/non-PIC objects behind the .lo pseudo objects.

Cheers,
Ralf




reply via email to

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