[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Linking Problem with Solaris ld
From: |
Ralf Wildenhues |
Subject: |
Re: Linking Problem with Solaris ld |
Date: |
Sat, 16 Apr 2005 19:57:06 +0200 |
User-agent: |
Mutt/1.5.6+20040907i |
Hi Moritz,
* Moritz Schulte wrote on Sat, Apr 16, 2005 at 06:50:27PM CEST:
>
> we have seen linking problems during building of Libgcrypt on Solaris
> when using the Solaris ld. I don't know if this is only a ld problem
> or also a libtool problem.
libtool --version?
> What happens is that the ld forgets to include symbols in the final
> DSO (libgcrypt.so). The linking command looks like this:
Please execute below line with `-v' added to see what ld gets to eat
(and which ld).
> gcc -shared -Wl,-h -Wl,libgcrypt.so.11 -o .libs/libgcrypt.so.11.2.0
> .libs/libgcrypt_la-misc.o .libs/libgcrypt_la-global.o
> .libs/libgcrypt_la-sexp.o .libs/libgcrypt_la-stdmem.o
> .libs/libgcrypt_la-secmem.o .libs/libgcrypt_la-missing-string.o
> .libs/libgcrypt_la-module.o .libs/libgcrypt_la-ath.o -z allextract
> ../cipher/.libs/libcipher.a ../mpi/.libs/libmpi.a -z defaultextract
> -R/usr/local/lib -R/usr/local/lib -L/usr/local/lib
> /usr/local/lib/libgpg-error.so -lnsl -lsocket -lc
>
> Now, there are a couple of functions (gcry_ac_*) in ac.o in
> ../cipher/.libs/libcipher.a. These functions are not referenced from
> any other object file. That's probably why they are skipped. (If I
> e.g. exclude .libs/libgcrypt_la-global.o from the linking command,
> other functions from libcipher.a, which are referenced from
> libgcrypt_la-global.o are also skipped)
It looks like libcipher.a and libmpi.a are convenience archives
containing PIC code and should be included completely in libgcrypt.
I don't know if that is what was intended(?).
> This happens on at least Solaris 2.6. Should be reproducible with
> Libgcrypt 1.2.1.
FYI: 1.5.14 is the current stable, but has a nasty bug on Solaris,
which is the reason 1.5.16 will be out soon (hopefully next weekend).
The output of `gcc -v' may show whether you have been hit the bug
which was fixed with the bogus patch (which broke other settings).
Regards,
Ralf