Commit | Line | Data |
---|---|---|
a689557b KM |
1 | .\" Copyright (c) 1980 Regents of the University of California. |
2 | .\" All rights reserved. The Berkeley software License Agreement | |
3 | .\" specifies the terms and conditions for redistribution. | |
4 | .\" | |
aa652bde | 5 | .\" @(#)nm.1 6.1 (Berkeley) %G% |
a689557b | 6 | .\" |
aa652bde | 7 | .TH NM 1 "" |
a689557b KM |
8 | .UC 4 |
9 | .SH NAME | |
10 | nm \- print name list | |
11 | .SH SYNOPSIS | |
12 | .B nm | |
13 | [ | |
aa652bde | 14 | .B \-agnopru |
a689557b KM |
15 | ] |
16 | [ file ... ] | |
17 | .SH DESCRIPTION | |
18 | .I Nm | |
19 | prints the name list (symbol table) of each object | |
20 | .I file | |
7104227d KM |
21 | in the argument list. If an argument is an archive, a listing for each object |
22 | file in the archive will be produced. If no | |
a689557b | 23 | .I file |
7104227d | 24 | is given, the symbols in "a.out" are listed. |
a689557b KM |
25 | .PP |
26 | Each symbol name is preceded by its value (blanks if undefined) | |
27 | and one of the letters | |
28 | .SM | |
29 | .B U | |
30 | (undefined), | |
31 | .SM | |
32 | .B A | |
33 | (absolute), | |
34 | .SM | |
35 | .B T | |
36 | (text segment symbol), | |
37 | .SM | |
38 | .B D | |
39 | (data segment symbol), | |
40 | .SM | |
41 | .B B | |
42 | (bss segment symbol), | |
43 | .SM | |
44 | .B C | |
45 | (common symbol), | |
46 | .SM | |
47 | .B f | |
48 | file name, | |
49 | or | |
50 | .B \- | |
aa652bde | 51 | for debugger symbol table entries (see |
a689557b KM |
52 | .B \-a |
53 | below). | |
7104227d | 54 | If the symbol is local (non-external) the type letter is in lower case. |
a689557b KM |
55 | The output is sorted alphabetically. |
56 | .PP | |
57 | Options are: | |
58 | .TP | |
aa652bde KM |
59 | .B \-a |
60 | Print symbol table entries inserted for use by debuggers. | |
61 | .TP | |
a689557b KM |
62 | .B \-g |
63 | Print only global (external) symbols. | |
64 | .TP | |
65 | .B \-n | |
66 | Sort numerically rather than alphabetically. | |
67 | .TP | |
68 | .B \-o | |
7104227d | 69 | Prepend file or archive element name to each output line rather than only once. |
a689557b KM |
70 | .TP |
71 | .B \-p | |
72 | Don't sort; print in symbol-table order. | |
73 | .TP | |
74 | .B \-r | |
75 | Sort in reverse order. | |
76 | .TP | |
77 | .B \-u | |
78 | Print only undefined symbols. | |
79 | .SH SEE ALSO | |
80 | ar(1), ar(5), a.out(5), stab(5) |