查看so文件是32位还是64位
[root@n1 native]# file libhadoop.so.1.0.0
libhadoop.so.1.0.0: ELF 64-bit LSB shared object, x86-64, version 1 (SYSV), dynamically linked, not stripped
nm用来列出目标文件的符号清单.
ar命令可以用来创建、修改库,也可以从库中提出单个模块。
objdump:显示目标文件中的详细信息
objdump -d <command>,可以查看这些工具究竟如何完成这项任务
ldd 查看可执行文件链接了哪些 系统动态链接库
-d是ldd的缩写
readelf 显示关于 ELF 目标文件的信息
readelf -d libffmpeg.so | grep NEEDED
objdump -V libhadoop.so.1.0.0
显示:
GNU objdump version 2.20.51.0.2-5.36.el6 20100205
Copyright 2009 Free Software Foundation, Inc.
This program is free software; you may redistribute it under the terms of
the GNU General Public License version 3 or (at your option) any later version.
This program has absolutely no warranty.
ldd libhadoop.so.1.0.0
显示: linux-vdso.so.1 => (0x00007fffbf3d6000)
libdl.so.2 =>/lib64/libdl.so.2 (0x00007fab46569000)
libjvm.so => not found
libc.so.6 => /lib64/libc.so.6 (0x00007fab461d4000)
/lib64/ld-linux-x86-64.so.2 (0x00007fab46990000)