1、readelf命令解释
readelf命令用来显示一个或者多个elf格式的目标文件的信息
2、ELF文件类型
- 可重定位文件:用户和其他目标文件一起创建可执行文件或者共享目标文件,例如lib*.a文件。
- 可执行文件:用于生成进程映像,载入内存执行,例如编译好的可执行文件a.out。
- 共享目标文件:用于和其他共享目标文件或者可重定位文件一起生成elf目标文件或者和执行文件一起创建进程映像,例如lib*.so文件。
2、一般使用
Usage: readelf <option(s)> elf-file(s)Display information about the contents of ELF format filesOptions are:-a --all Equivalent to: -h -l -S -s -r -d -V -A -I-h --file-header Display the ELF file header-l --program-headers Display the program headers--segments An alias for --program-headers-S --section-headers Display the sections' header--sections An alias for --section-headers-g --section-groups Display the section groups-t --section-details Display