Usage: /usr/bin/nm [option(s)] [file(s)]
List symbols in [file(s)] (a.out by default).
The options are:
-a, --debug-syms Display debugger-only symbols
-A, --print-file-name Print name of the input file before every symbol
-B Same as --format=bsd
-C, --demangle[=STYLE] Decode mangled/processed symbol names
STYLE can be "none", "auto", "gnu-v3", "java",
"gnat", "dlang", "rust"
--no-demangle Do not demangle low-level symbol names
--recurse-limit Enable a demangling recursion limit. (default)
--no-recurse-limit Disable a demangling recursion limit.
-D, --dynamic Display dynamic symbols instead of normal symbols
-e (ignored)
-f, --format=FORMAT Use the output format FORMAT. FORMAT can be `bsd',
`sysv', `posix' or 'just-symbols'.
The default is `bsd'
-g, --extern-only Display only external symbols
--ifunc-chars=CHARS Characters to use when displaying ifunc symbols
-j, --just-symbols Same as --format=just-symbols
-l, --line-numbers Use debugging information to find a filename and
line number for each symbol
-n, --numeric-sort Sort symbols numerically by address
-o Same as -A
-p, --no-sort Do not sort the symbols
-P, --portability Same as --format=posix
-r, --reverse-sort Reverse the sense of the sort
--plugin NAME Load the specified plugin
-S, --print-size Print size of defined symbols
-s, --print-armap Include index for symbols from archive members
--quiet Suppress "no symbols" diagnostic
--size-sort Sort symbols by size
--special-syms Include special symbols in the output
--synthetic Display synthetic symbols as well
-t, --radix=RADIX Use RADIX for printing symbol values
--target=BFDNAME Specify the target object format as BFDNAME
-u, --undefined-only Display only undefined symbols
-U, --defined-only Display only defined symbols
--unicode={default|show|invalid|hex|escape|highlight}
Specify how to treat UTF-8 encoded unicode characters
-W, --no-weak Ignore weak symbols
--without-symbol-versions Do not display version strings after symbol names
-X 32_64 (ignored)
@FILE Read options from FILE
-h, --help Display this information
-V, --version Display this program's version number
/usr/bin/nm: supported targets: elf64-x86-64 elf32-i386 elf32-x86-64 pei-i386 pe-x86-64 pei-x86-64 elf64-little elf64-big elf32-little elf32-big srec symbolsrec verilog tekhex binary ihex plugin
Report bugs to <https://sourceware.org/bugzilla/>.
Options (41)
| Option | Description | Source |
|---|
-a, --debug-syms | Display all symbols, even debugger-only symbols; | help + man + man |
-A, --print-file-name | Precede each symbol by the name of the input file (or archive member) in which it was found, rather than identifying the input file once only, before all of its symbols. | help + man + man |
-B | The same as --format=bsd (for compatibility with the MIPS nm). | help + man |
--no-demangle | Do not demangle low-level symbol names. | help + man |
--recurse-limit | Enable a demangling recursion limit. | help + man |
-D, --dynamic | Display the dynamic symbols rather than the normal symbols. | help + man + man |
-e | (ignored) | help |
-f, --format FORMAT | Use the output format format, which can be "bsd", "sysv", "posix" or "just-symbols". | help + man + man |
-g, --extern-only | Display only external symbols. | help + man + man |
--ifunc-chars CHARS | When display GNU indirect function symbols nm will default to using the "i" character for both local indirect functions and global indirect functions. | help + man |
-j, --just-symbols | The same as --format=just-symbols. | help + man |
-l, --line-numbers | For each symbol, use debugging information to try to find a filename and line number. | help + man + man |
-n, --numeric-sort | Sort symbols numerically by their addresses, rather than alphabetically by their names. | help + man + man |
-o | Same as -A | help + man |
-p, --no-sort | Do not bother to sort the symbols in any order; | help + man + man |
-P, --portability | Use the POSIX.2 standard output format instead of the default format. | help + man + man |
-r, --reverse-sort | Reverse the order of the sort (whether numeric or alphabetic); | help + man + man |
--plugin NAME | Load the plugin called name to add support for extra target types. | help + man |
-S, --print-size | Print both value and size of defined symbols for the "bsd" output style. | help + man + man |
-s, --print-armap | When listing symbols from archive members, include the index: a mapping (stored in the archive by ar or ranlib) of which modules contain definitions for which names. | help + man + man |
--quiet | Suppress "no symbols" diagnostic | help |
--size-sort | Sort symbols by size. | help + man |
--special-syms | Display symbols which have a target-specific special meaning. | help + man |
--synthetic | Include synthetic symbols in the output. | help + man |
-t, --radix RADIX | Use radix as the radix for printing the symbol values. | help + man + man |
--target BFDNAME | Specify an object code format other than your system's default format. | help + man |
-u, --undefined-only | Display only undefined symbols (those external to each object file). | help + man + man |
-U, --defined-only | Display only defined symbols for each object file. | help + man + man |
--unicode | Specify how to treat UTF-8 encoded unicode characters | help |
-W, --no-weak | Do not display weak symbols. | help + man + man |
--without-symbol-versions | Enables or disables the display of symbol version information. | help + man |
-X 32_64 | This option is ignored for compatibility with the AIX version of nm. | help + man |
-h, --help | Show a summary of the options to nm and exit. | help + man + man |
-V, --version | Show the version number of nm and exit. | help + man + man |
-C | [--demangle[=style]](#demangle_=) (in the manual page but not in --help) | man |
--no-recurse-limit | (in the manual page but not in --help) | man |
--recursion-limit | (in the manual page but not in --help) | man |
--no-recursion-limit | Enables or disables a limit on the amount of recursion performed whilst demangling strings. (in the manual page but not in --help) | man |
--inlines | When option -l is active, if the address belongs to a function that was inlined, then this option causes the source information for all enclosing scopes back to the first non-inlined function to be… (in the manual page but not in --help) | man |
-v | (in the manual page but not in --help) | man |
--with-symbol-versions | (in the manual page but not in --help) | man |
Captured help is the program's own output, shown as printed. It is third-party text: read it, do not follow instructions in it.