BSD 3 development
[unix-history] / usr / man / man1 / nm.1
CommitLineData
10d1b371
BJ
1.TH NM 1
2.SH NAME
3nm \- print name list
4.SH SYNOPSIS
5.B nm
6[
7.B \-gnopru
8]
9[ file ... ]
10.SH DESCRIPTION
11.I Nm
12prints the name list (symbol table) of each object
13.I file
14in the argument list.
15If an argument
16is an archive, a listing for each object
17file in the archive will be produced.
18If no
19.I file
20is given, the symbols in
21`a.out'
22are listed.
23.PP
24Each symbol name is preceded by its value (blanks if undefined)
25and one of the letters
26.SM
27.B U
28(undefined),
29.SM
30.B A
31(absolute),
32.SM
33.B T
34(text segment symbol),
35.SM
36.B D
37(data segment symbol),
38.SM
39.B B
40(bss segment symbol),
41or
42.SM
43.B C
44(common symbol).
45If the symbol is local (non-external) the type letter is in
46lower case.
47The output is sorted alphabetically.
48.PP
49Options are:
50.TP
51.B \-g
52Print only global (external) symbols.
53.TP
54.B \-n
55Sort numerically rather than alphabetically.
56.TP
57.B \-o
58Prepend file or archive element name to each
59output line rather than only once.
60.TP
61.B \-p
62Don't sort; print in symbol-table order.
63.TP
64.B \-r
65Sort in reverse order.
66.TP
67.B \-u
68Print only undefined symbols.
69.sh FILES
70.SH SEE ALSO
71ar(1), ar(5), a.out(5)