Can't find libgcc after building 1.4.1
Jeff Blaine
jblaine at mitre.org
Fri Feb 10 12:17:13 EST 2006
Reviving an old thread here from August 2005.
http://mailman.mit.edu/pipermail/kerberos/2005-August/008229.html
I continue to have this same problem. At first I thought
it was a configuration issue on my end. I mistakenly
read a test on another machine as successful.
Sectioned info below, with what I suspect is the
problem. Please comment!
==================================================================
Solaris 9 SPARC
MIT Kerberos 1.4.3
GCC 3.2.3 ...or...
GCC 3.3.2 ...or...
GCC 3.4.2
GNU ld/binutils 2.14 ...or...
GNU ld/binutils 2.16.1 ...or...
Solaris /usr/ccs/bin/ld
The problem seems to stem from building Kerberos into a
different 'prefix' than where GCC was built for. More
specifically, the objects created during the build process
only include runtime linker path information for the
Kerberos build 'prefix', and do not include anything
from LDFLAGS.
==================================================================
1. /export/home is the prefix for GCC
2. /export/home/lib/libgcc_s.so.1 exists
3. /export/home/krb5 is the prefix for my desired
Kerberos build. See the failure below. If I
use /export/home as the prefix, it all works (but
is not an acceptable location).
src # CC=/export/home/bin/gcc
src # export CC
src # LD=/export/home/bin/ld
src # export LD
src # LDFLAGS="-L/export/home/lib -R/export/home/lib"
src # export LDFLAGS
src # ./configure --prefix=/export/home/krb5
src # make; make install
src # ldd /export/home/krb5/bin/kinit
libkrb4.so.2 => /export/home/krb5/lib/libkrb4.so.2
libdes425.so.3 => /export/home/krb5/lib/libdes425.so.3
libkrb5.so.3 => /export/home/krb5/lib/libkrb5.so.3
libk5crypto.so.3 => /export/home/krb5/lib/libk5crypto.so.3
libcom_err.so.3 => /export/home/krb5/lib/libcom_err.so.3
libkrb5support.so.0 => /export/home/krb5/lib/libkrb5support.so.0
libresolv.so.2 => /usr/lib/libresolv.so.2
libsocket.so.1 => /usr/lib/libsocket.so.1
libnsl.so.1 => /usr/lib/libnsl.so.1
libc.so.1 => /usr/lib/libc.so.1
libgcc_s.so.1 => (file not found)
libgcc_s.so.1 => (file not found)
libgcc_s.so.1 => (file not found)
libgcc_s.so.1 => (file not found)
libgcc_s.so.1 => (file not found)
libgcc_s.so.1 => (file not found)
libdl.so.1 => /usr/lib/libdl.so.1
libmp.so.2 => /usr/lib/libmp.so.2
/usr/platform/SUNW,Ultra-60/lib/libc_psr.so.1
==================================================================
NOTE: "RPATH" and "RUNPATH" below which do not include
/export/home/lib. This is just one .so as an
example. They are all like this.
src # dump -Lv /export/home/krb5/lib/libkrb4.so.2
/export/home/krb5/lib/libkrb4.so.2:
**** DYNAMIC SECTION INFORMATION ****
.dynamic:
[INDEX] Tag Value
[1] NEEDED libkrb5.so.3
[2] NEEDED libcom_err.so.3
[3] NEEDED libdes425.so.3
[4] NEEDED libk5crypto.so.3
[5] NEEDED libgcc_s.so.1
[6] INIT 0x5704
[7] FINI 0x5720
[8] SONAME libkrb4.so.2
[9] RUNPATH /export/home/krb5/lib
[10] RPATH /export/home/krb5/lib
[11] HASH 0x94
[12] STRTAB 0x1bec
[13] STRSZ 0x108c
[14] SYMTAB 0x9bc
[15] SYMENT 0x10
[16] CHECKSUM 0xb52c
[17] VERNEED 0x2c78
[18] VERNEEDNUM 0x1
[19] PLTSZ 0x930
[20] PLTREL 0x7
[21] JMPREL 0x4dd4
[22] RELA 0x2c98
[23] RELASZ 0x2a6c
[24] RELAENT 0xc
[25] FEATURE_1 PARINIT
[26] FLAGS 0
[27] FLAGS_1 0
[28] PLTGOT 0x26f84
src #
==================================================================
Shared libs need LDFLAGS too! Note the missing
-L/export/home/lib -R/export/home/lib in the link
line below!
building shared krb5support library (0.0)
...text deleted...
+ /export/home/bin/gcc -shared -h libkrb5support.so.0 -o
libkrb5support.so.0.0 threads.so fake-addrinfo.so
-R/export/home/krb5/lib -lresolv -lsocket -lnsl
rm -f libkrb5support.so
More information about the Kerberos
mailing list