HP-UX Reference (11i v2 04/09) - 1 User Commands N-Z (vol 2)
n
nm(1) nm(1)
-r Prefix each output line with the name of the object file or archive, file. Equivalent
to
-A.
-q (SOM only) Silence some warning messages.
-s Print the section index instead of the section name (ELF only).
-t format Display each numeric value in the specified format. format can be one of:
d Display the value and size of a symbol in decimal. This is the default for the
default format or the -p format. Equivalent to
-d.
o Display the value and size of a symbol in octal. Equivalent to
-o.
x Display the value and size of a symbol in hexadecimal. This is the default for
the -P format. Equivalent to -x
.
-T (SOM only) Truncate every name that would otherwise overflow its column and
place an asterisk as the last character in the displayed name to mark it as trun-
cated. If -A or -r
is also specified, the file prefix is truncated first.
-u Display undefined symbols only.
-U Print the usage menu.
-v Sort symbols by value before they are printed.
-V Display the executing version of the nm command on standard error.
-x Display the value and size of a symbol in hexadecimal. This is the default for the
-P format. Equivalent to -t x.
Operands
nm recognizes the following operand:
file A relocatable object file or an executable object file, or an archive of relocatable or
executable object files.
Default Output Format - 32 bit
If the default (neither the -p nor the -P option) output format is specified, each symbol has the following
columns, separated by vertical bars (|). The default for numbers is decimal (-d
or -t d).
If decimal:
"%20s|%10d|%6s|%7s|%s",
name, value, scope, type, subspace
If octal:
"%20s|%012o|%6s|%7s|%s",
name, value, scope, type, subspace
If hexadecimal:
"%20s|0x%08x|%6s|%7s|%s", name, value, scope, type,
subspace
Default Output Format - 64 bit
If the default (neither the
-p nor the -P option) output format is specified, each symbol has the following
columns, separated by vertical bars (|). The default for numbers is decimal (-d or -t d).
If decimal:
"[%u]%s|%22llu|%8u|%s|%s|%1d|%s|%s",
index, value, size, type, bind, O, shndx, name
If octal:
"[%u]%s|%022llo|%010o|%s|%s|%1o|%s|%s",
index, value, size, type, bind, O, shndx, name
If hexadecimal:
"[%u]%s|0x%016llx|0x%08x|%s|%s|%1x|%s|%s",
index, value, size, type, bind, O, shndx, name
The descriptions are explained below:
HP-UX 11i Version 2: September 2004 − 2 − Hewlett-Packard Company Section 1−−677