搜尋此網誌

Check linux user mode application depend shared libraries

I. Using ldd (source code delong to Linux binutil )
ldd bluetoothd
libgmodule-2.0.so.0 => /usr/local/lib/libgmodule-2.0.so.0 (0xb7f7d000)
libdl.so.2 => /lib/tls/i686/cmov/libdl.so.2 (0xb7f6a000)
librt.so.1 => /lib/tls/i686/cmov/librt.so.1 (0xb7f63000)
libglib-2.0.so.0 => /usr/local/lib/libglib-2.0.so.0 (0xb7e85000)
libdbus-1.so.3 => /usr/local/lib/libdbus-1.so.3 (0xb7e55000)
libbluetooth.so.3 => /home/jacky/bt/root/lib/libbluetooth.so.3 (0xb7e43000)
libpthread.so.0 => /lib/tls/i686/cmov/libpthread.so.0 (0xb7e33000)
libc.so.6 => /lib/tls/i686/cmov/libc.so.6 (0xb7cfd000)
/lib/ld-linux.so.2 => /lib/ld-linux.so.2 (0xb7f82000)
2. Using readelf -d bluetoothd
readelf -d bluetoothd
Dynamic segment at offset 0x2844c contains 29 entries:
Tag Type Name/Value
0x00000001 (NEEDED) Shared library: [libgmodule-2.0.so.0]
0x00000001 (NEEDED) Shared library: [libdl.so.2]
0x00000001 (NEEDED) Shared library: [librt.so.1]
0x00000001 (NEEDED) Shared library: [libglib-2.0.so.0]
0x00000001 (NEEDED) Shared library: [libdbus-1.so.3]
0x00000001 (NEEDED) Shared library: [libbluetooth.so.3]
0x00000001 (NEEDED) Shared library: [libpthread.so.0]
0x00000001 (NEEDED) Shared library: [libc.so.6]
0x0000000f (RPATH) Library rpath: [/usr/local/lib:/home/jacky/bt/root/lib]
0x0000000c (INIT) 0x7704
0x0000000d (FINI) 0x246c0
0x00000004 (HASH) 0x148
0x00000005 (STRTAB) 0x39f8
0x00000006 (SYMTAB) 0x1328
0x0000000a (STRSZ) 10777 (bytes)
0x0000000b (SYMENT) 16 (bytes)
0x00000015 (DEBUG) 0x0
0x00000003 (PLTGOT) 0x28568
0x00000002 (PLTRELSZ) 2256 (bytes)
0x00000014 (PLTREL) REL
0x00000017 (JMPREL) 0x6e34
0x00000011 (REL) 0x695c
0x00000012 (RELSZ) 1240 (bytes)
0x00000013 (RELENT) 8 (bytes)
0x6ffffffe (VERNEED) 0x68ec
0x6fffffff (VERNEEDNUM) 2
0x6ffffff0 (VERSYM) 0x6412
0x6ffffffa (RELCOUNT) 144
0x00000000 (NULL) 0x0