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] [-n|--notes] [-r|--relocs] [-u|--unwind] [-d|--dynamic] [-V|--version-info] [-A|--arch-specific] [-D|--use-dynamic] [-x <number or name>|--hex-dump=<number or name>] [-p <number or name>|--string-dump=<number or name>] [-c|--archive-index] [-w[lLiaprmfFsoR]| --debug-dump[=rawline,=decodedline,=info,=abbrev,=pubnames,=aranges,=macro,=frames,=frames-interp,=str,=loc,=Ranges]] [-I|-histogram] [-v|--version] [-W|--wide] [-H|--help] elffile...
readelf displays information about one or more ELF format object files. The options control what particular information to display.
elffile ... are the object files to be examined. 32-bit and 64-bit ELF files are supported, as are archives containing ELF files.
This program performs a similar function to objdump but it goes into more detail and it exists independently of the bfd library, so if there is a bug in bfd then readelf will not be affected.
The long and short forms of options, shown here as alternatives, are equivalent. At least one option besides -v or -H must be given.
Displays the information contained in the ELF header at the start of the
file.
Displays the information contained in the file's segment headers, if it
has any.
Displays the information contained in the file's section headers, if it
has any.
Displays the information contained in the file's section groups, if it
has any.
Displays the detailed section information. Implies -S.
Displays the entries in symbol table section of the file, if it has one.
Displays the contents of the NOTE segments and/or sections, if any.
Displays the contents of the file's relocation section, if it has one.
Displays the contents of the file's unwind section, if it has one. Only
the unwind sections for IA64 ELF files are currently supported.
Displays the contents of the file's dynamic section, if it has one.
Displays the contents of the version sections in the file, it they
exist.
Displays the file symbol index infomation contained in the header part
of binary archives. Performs the same function as the t
command to ar, but without using the BFD library. See ar.
Note: the =decodedline option will display the interpreted
contents of a .debug_line section whereas the =rawline option
dumps the contents in a raw format.
Corrections, suggestions, and new documentation should be posted to the Forum.
The text of the Arduino reference is licensed under a Creative Commons Attribution-ShareAlike 3.0 License. Code samples in the reference are released into the public domain.