[Top][All Lists]

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

Re: Linking against indirect dependencies

From: Szombathelyi György
Subject: Re: Linking against indirect dependencies
Date: Mon, 31 May 2004 21:20:35 +0200
User-agent: KMail/1.6.52

Miert fizetsz az internetert? Korlatlan, ingyenes internet hozzaferes a 
Probald ki most!

szombat 29 május 2004 12:41 dátummal ezt írta:
> On May 28, 2004, Szombathelyi György <address@hidden> wrote:
> > AFAIK it's possible to link in libdep to libfoo if libdep is static
> Depends on the platform.  Some combinations of OSs, ABIs and hardware
> architectures don't allow non-PIC in shared libraries.  Yes, several
> of the platforms that don't support this are GNU/Linux ports.
> Try this on x86_64-linux-gnu, for example.  It won't work, unless you
> somehow arrange for libdep.o to not contain any relocations that
> aren't PIC.

Ok, as I see, libtool cannot solve this, but as I researched further, libtool 
doesn't need to solve it. Newer GNU 'ld' has the flag --as-needed, which does 
exactly the thing I wanted. The only problem from the libtool side is that if 
I specify LDFLAGS=-Wl,--as-needed, libtool will append these flags after 
dependency_libs, so the option will be useless. I attached a patch which puts 
$compiler_flags before any dependencies. Is this patch acceptable?


Attachment: lt.diff.gz
Description: GNU Zip compressed data

reply via email to

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