[csw-maintainers] opening both 32bit and 64bit shared libs

Dagobert Michelsen dam at opencsw.org
Mon Apr 26 17:10:48 CEST 2010


Hi Darin,

Am 26.04.2010 um 15:09 schrieb Darin Perusich:
> You say this is normal behavior, i.e listing all the applicable
> libraries, but there is no other instance where an open() to a 64bit
> library is occurring. Whenever a 64bit lib is evaluated I get  
> "rejected:
> wrong ELF class: ELFCLASS64" for those libs.

Just take an arbitrary binary from /opt/csw/bin which has $ISALIST
in the RPATH, like 411toppm. It is always the same behaviour:

dam at testing9s :/opt/csw/bin > dump -Lv 411toppm

411toppm:

   **** DYNAMIC SECTION INFORMATION ****
.dynamic:
[INDEX] Tag         Value
[1]     NEEDED          libnetpbm.so.10
[2]     NEEDED          libpng12.so.0
[3]     NEEDED          libz.so
[4]     NEEDED          libjpeg.so.62
[5]     NEEDED          libtiff.so.3
[6]     NEEDED          libm.so.1
[7]     NEEDED          libsocket.so.1
[8]     NEEDED          libnsl.so.1
[9]     NEEDED          libc.so.1
[10]    INIT            0x1fe258
[11]    FINI            0x1fe268
[12]    RUNPATH         /opt/csw/lib/$ISALIST:/opt/csw/lib
[13]    RPATH           /opt/csw/lib/$ISALIST:/opt/csw/lib
[14]    HASH            0x100e8
...

dam at testing9s :/opt/csw/bin > truss -f ./411toppm
2932:   execve("netpbm", 0xFFBFFAD4, 0xFFBFFADC)  argc = 1
...
2932:   mprotect(0xFF1C0000, 159436, PROT_READ|PROT_EXEC) = 0
2932:   stat("/opt/csw/lib/sparcv9+vis2/libjpeg.so.7", 0xFFBFF148)  
Err#2 ENOENT
2932:   stat("/opt/csw/lib/sparcv9+vis/libjpeg.so.7", 0xFFBFF148)  
Err#2 ENOENT
2932:   stat("/opt/csw/lib/sparcv9/libjpeg.so.7", 0xFFBFF148) = 0
2932:   resolvepath("/opt/csw/lib/sparcv9/libjpeg.so.7", "/opt/csw/lib/ 
sparcv9/libjpeg.so.7.0.0", 1023) = 37
2932:   open("/opt/csw/lib/sparcv9/libjpeg.so.7", O_RDONLY) = 3
2932:   mmap(0x00010000, 32768, PROT_READ|PROT_EXEC, MAP_PRIVATE| 
MAP_ALIGN, 3, 0) = 0xFF0F0000
2932:   close(3)                                        = 0
2932:   stat("/opt/csw/lib/sparcv8plus+vis2/libjpeg.so.7", 0xFFBFF148)  
Err#2 ENOENT
2932:   stat("/opt/csw/lib/sparcv8plus+vis/libjpeg.so.7", 0xFFBFF148)  
Err#2 ENOENT
2932:   stat("/opt/csw/lib/sparcv8plus/libjpeg.so.7", 0xFFBFF148)  
Err#2 ENOENT
2932:   stat("/opt/csw/lib/sparcv8/libjpeg.so.7", 0xFFBFF148) = 0
2932:   resolvepath("/opt/csw/lib/sparcv8/libjpeg.so.7", "/opt/csw/lib/ 
libjpeg.so.7.0.0", 1023) = 29
2932:   open("/opt/csw/lib/sparcv8/libjpeg.so.7", O_RDONLY) = 3
2932:   mmap(0xFF0F0000, 32768, PROT_READ|PROT_EXEC, MAP_PRIVATE| 
MAP_FIXED, 3, 0) = 0xFF0F0000
2932:   mmap(0x00010000, 368640, PROT_NONE, MAP_PRIVATE|MAP_NORESERVE| 
MAP_ANON|MAP_ALIGN, -1, 0) = 0xFEDA0000
...


Best regards

   -- Dago


More information about the maintainers mailing list