elf: Executable and Linkable Formatz, 可执行,可链接的文件格式
readelf, 读取可执行文件或者库文件中elf部分的信息,并显示出来。
1)对于release的动态库,没有 符号表,但是有动态符号使用-d读取
2)如果有符号表中版本信息,那么对应函数后面@version1;如果没有版本信息使用默认的版本信息,那么会添加两个@, @@version1
3)readelf, 和 nm 基本可以平替
readelf [-a|--all]
[-h|--file-header]
[-l|--program-headers|--segments]
[-S|--section-headers|--sections]
[-g|--section-groups]
[-t|--section-details]
[-e|--headers]
[-s|--syms|--symbols]
[--dyn-syms|--lto-syms]
[--sym-base=[0|8|10|16]]
[--demangle=style|--no-demangle]
[--quiet]
[--recurse-limit|--no-recurse-limit]
[-U method|--unicode=method]
[-n|--notes]
[-r|--relocs]
[-u|--unwind]
[-d|--dynamic]
[-V|--version-info]
[-A|--arch-specific]
[-D|--use-dynamic]
[-L|--lint|--enable-checks]
[-x <number or name>|--hex-dump=<number or name>]
[-p <number or name>|--string-dump=<number or name>]
[-R <number or name>|--relocated-dump=<number or name>]
[-z|--decompress]
[-c|--archive-index]
[-w[lLiaprmfFsoORtUuTgAck]|
--debug-dump[=rawline,=decodedline,=info,=abbrev,=pubnames,=aranges,=macro,=frames,=frames-interp,=str,=str-offsets,=loc,=Ranges,=pubtypes,=trace_info,=trace_abbrev,=trace_aranges,=gdb_index,=addr,=cu_index,=links]]
[-wK|--debug-dump=follow-links]
[-wN|--debug-dump=no-follow-links]
[-wD|--debug-dump=use-debuginfod]
[-wE|--debug-dump=do-not-use-debuginfod]
[-P|--process-links]
[--dwarf-depth=n]
[--dwarf-start=n]
[--ctf=section]
[--ctf-parent=section]
[--ctf-symbols=section]
[--ctf-strings=section]
[-I|--histogram]
[-v|--version]
[-W|--wide]
[-T|--silent-truncation]
[-H|--help]
elffile...