Commit | Line | Data |
---|---|---|
458bbd1f | 1 | .\" Copyright (c) 1991, 1996 Free Software Foundation |
19450a0c | 2 | .\" See section COPYING for conditions for redistribution |
19450a0c RP |
3 | .TH objdump 1 "5 November 1991" "cygnus support" "GNU Development Tools" |
4 | .de BP | |
5 | .sp | |
6 | .ti \-.2i | |
7 | \(** | |
8 | .. | |
9 | ||
10 | .SH NAME | |
938fa52b | 11 | objdump \- display information from object files. |
19450a0c RP |
12 | |
13 | .SH SYNOPSIS | |
14 | .hy 0 | |
15 | .na | |
16 | .TP | |
b26ac613 | 17 | .B objdump |
eae04238 | 18 | .RB "[\|" \-a | \-\-archive\-headers "\|]" |
19450a0c RP |
19 | .RB "[\|" "\-b\ "\c |
20 | .I bfdname\c | |
eae04238 DM |
21 | .RB " | " "\-\-target="\c |
22 | .I bfdname\c | |
19450a0c | 23 | \&\|] |
e1c14599 | 24 | .RB "[\|" \-\-debugging "\|]" |
eae04238 | 25 | .RB "[\|" \-d | \-\-disassemble "\|]" |
d5464baa | 26 | .RB "[\|" \-D | \-\-disassemble-all "\|]" |
67c8c901 ILT |
27 | .RB "[\|" \-EB | \-EL | \-\-endian=\c |
28 | .I {big|little}\c | |
29 | \&\|] | |
eae04238 DM |
30 | .RB "[\|" \-f | \-\-file\-headers "\|]" |
31 | .RB "[\|" \-h | \-\-section\-headers | |
32 | .RB "| " \-\-headers "\|]" | |
33 | .RB "[\|" \-i | \-\-info "\|]" | |
19450a0c RP |
34 | .RB "[\|" "\-j\ "\c |
35 | .I section\c | |
eae04238 DM |
36 | .RB " | " "\-\-section="\c |
37 | .I section\c | |
19450a0c | 38 | \&\|] |
eae04238 | 39 | .RB "[\|" \-l | \-\-line\-numbers "\|]" |
19450a0c RP |
40 | .RB "[\|" "\-m\ "\c |
41 | .I machine\c | |
eae04238 DM |
42 | .RB " | " "\-\-architecture="\c |
43 | .I machine\c | |
19450a0c | 44 | \&\|] |
4cb99ff2 | 45 | .RB "[\|" \-\-prefix\-addresses "\|]" |
1f72cab1 | 46 | .RB "[\|" \-r | \-\-reloc "\|]" |
de3b08ac | 47 | .RB "[\|" \-R | \-\-dynamic\-reloc "\|]" |
eae04238 | 48 | .RB "[\|" \-s | \-\-full\-contents "\|]" |
a8e27cc6 | 49 | .RB "[\|" \-S | \-\-source "\|]" |
458bbd1f | 50 | .RB "[\|" \-\-show\-raw\-insn "\|]" |
1f72cab1 DM |
51 | .RB "[\|" \-\-stabs "\|]" |
52 | .RB "[\|" \-t | \-\-syms "\|]" | |
de3b08ac | 53 | .RB "[\|" \-T | \-\-dynamic\-syms "\|]" |
eae04238 | 54 | .RB "[\|" \-x | \-\-all\-headers "\|]" |
aa21a2a9 ILT |
55 | .RB "[\|" "\-\-start\-address="\c |
56 | .I address\c | |
57 | \&\|] | |
58 | .RB "[\|" "\-\-stop\-address="\c | |
59 | .I address\c | |
60 | \&\|] | |
b26ac613 DM |
61 | .RB "[\|" \-\-version "\|]" |
62 | .RB "[\|" \-\-help "\|]" | |
1f72cab1 | 63 | .I objfile\c |
19450a0c RP |
64 | \&.\|.\|. |
65 | .ad b | |
66 | .hy 1 | |
67 | .SH DESCRIPTION | |
68 | \c | |
69 | .B objdump\c | |
70 | \& displays information about one or more object files. | |
71 | The options control what particular information to display. This | |
72 | information is mostly useful to programmers who are working on the | |
73 | compilation tools, as opposed to programmers who just want their | |
74 | program to compile and work. | |
b26ac613 | 75 | .PP |
1f72cab1 | 76 | .IR "objfile" .\|.\|. |
b26ac613 | 77 | are the object files to be examined. When you specify archives, |
19450a0c RP |
78 | \c |
79 | .B objdump\c | |
80 | \& shows information on each of the member object files. | |
81 | ||
b26ac613 DM |
82 | .SH OPTIONS |
83 | Where long and short forms of an option are shown together, they are | |
ed78872a DM |
84 | equivalent. At least one option besides |
85 | .B \-l | |
eae04238 | 86 | (\fB\-\-line\-numbers\fP) must be given. |
b26ac613 | 87 | |
19450a0c RP |
88 | .TP |
89 | .B \-a | |
eae04238 DM |
90 | .TP |
91 | .B \-\-archive\-headers | |
19450a0c | 92 | If any files from \c |
1f72cab1 | 93 | .I objfile\c |
19450a0c RP |
94 | \& are archives, display the archive |
95 | header information (in a format similar to `\|\c | |
96 | .B ls \-l\c | |
97 | \|'). Besides the | |
98 | information you could list with `\|\c | |
99 | .B ar tv\c | |
100 | \|', `\|\c | |
101 | .B objdump \-a\c | |
102 | \|' shows | |
103 | the object file format of each archive member. | |
104 | ||
105 | .TP | |
eae04238 DM |
106 | .BI "\-b " "bfdname"\c |
107 | .TP | |
5740d9df | 108 | .BI "\-\-target=" "bfdname" |
b26ac613 | 109 | Specify the object-code format for the object files to be |
19450a0c RP |
110 | \c |
111 | .I bfdname\c | |
112 | \&. This may not be necessary; \c | |
113 | .I objdump\c | |
114 | \& can | |
115 | automatically recognize many formats. For example, | |
116 | .sp | |
117 | .br | |
118 | objdump\ \-b\ oasys\ \-m\ vax\ \-h\ fu.o | |
119 | .br | |
120 | .sp | |
b26ac613 | 121 | display summary information from the section headers (`\|\c |
19450a0c RP |
122 | .B \-h\c |
123 | \|') of | |
124 | `\|\c | |
125 | .B fu.o\c | |
126 | \|', which is explicitly identified (`\|\c | |
127 | .B \-m\c | |
128 | \|') as a Vax object | |
129 | file in the format produced by Oasys compilers. You can list the | |
130 | formats available with the `\|\c | |
131 | .B \-i\c | |
132 | \|' option. | |
133 | ||
e1c14599 ILT |
134 | .TP |
135 | .B \-\-debugging | |
136 | Display debugging information. This attempts to parse debugging | |
137 | information stored in the file and print it out using a C like syntax. | |
138 | Only certain types of debugging information have been implemented. | |
139 | ||
19450a0c RP |
140 | .TP |
141 | .B \-d | |
eae04238 DM |
142 | .TP |
143 | .B \-\-disassemble | |
144 | Display the assembler mnemonics for the machine | |
19450a0c | 145 | instructions from \c |
1f72cab1 | 146 | .I objfile\c |
19450a0c | 147 | \&. |
d5464baa ILT |
148 | This option only disassembles those sections which are |
149 | expected to contain instructions. | |
150 | ||
151 | .TP | |
152 | .B \-D | |
153 | .TP | |
154 | .B \-\-disassemble-all | |
155 | Like \fB\-d\fP, but disassemble the contents of all sections, not just | |
156 | those expected to contain instructions. | |
19450a0c | 157 | |
67c8c901 ILT |
158 | .TP |
159 | .B \-EB | |
160 | .TP | |
161 | .B \-EL | |
162 | .TP | |
163 | .BI "\-\-endian=" "{big|little}" | |
164 | Specify the endianness of the object files. This only affects | |
165 | disassembly. This can be useful when disassembling a file format which | |
166 | does not describe endianness information, such as S-records. | |
167 | ||
19450a0c RP |
168 | .TP |
169 | .B \-f | |
eae04238 DM |
170 | .TP |
171 | .B \-\-file\-headers | |
172 | Display summary information from the overall header of | |
19450a0c | 173 | each file in \c |
1f72cab1 | 174 | .I objfile\c |
19450a0c RP |
175 | \&. |
176 | ||
177 | .TP | |
178 | .B \-h | |
179 | .TP | |
eae04238 DM |
180 | .B \-\-section\-headers |
181 | .TP | |
182 | .B \-\-headers | |
183 | Display summary information from the section headers of the | |
19450a0c RP |
184 | object file. |
185 | ||
b26ac613 DM |
186 | .TP |
187 | .B \-\-help | |
188 | Print a summary of the options to | |
189 | .B objdump | |
190 | and exit. | |
191 | ||
19450a0c RP |
192 | .TP |
193 | .B \-i | |
eae04238 DM |
194 | .TP |
195 | .B \-\-info | |
19450a0c RP |
196 | Display a list showing all architectures and object formats available |
197 | for specification with \c | |
198 | .B \-b\c | |
199 | \& or \c | |
200 | .B \-m\c | |
201 | \&. | |
202 | ||
203 | .TP | |
eae04238 DM |
204 | .BI "\-j " "name"\c |
205 | .TP | |
5740d9df | 206 | .BI "\-\-section=" "name" |
19450a0c RP |
207 | Display information only for section \c |
208 | .I name\c | |
5740d9df | 209 | \&. |
19450a0c RP |
210 | |
211 | .TP | |
212 | .B \-l | |
eae04238 DM |
213 | .TP |
214 | .B \-\-line\-numbers | |
215 | Label the display (using debugging information) with the filename | |
216 | and source line numbers corresponding to the object code shown. | |
11548211 | 217 | Only useful with \fB\-d\fP, \fB\-D\fP, or \fB\-r\fP. |
19450a0c RP |
218 | |
219 | .TP | |
eae04238 DM |
220 | .BI "\-m " "machine"\c |
221 | .TP | |
5740d9df | 222 | .BI "\-\-architecture=" "machine" |
67c8c901 ILT |
223 | Specify the architecture to use when disassembling object files. This |
224 | can be useful when disasembling object files which do not describe | |
225 | architecture information, such as S-records. You can list the available | |
226 | architectures with the \fB\-i\fP option. | |
19450a0c | 227 | |
4cb99ff2 ILT |
228 | .TP |
229 | .B \-\-prefix\-addresses | |
230 | When disassembling, print the complete address on each line. This is | |
231 | the older disassembly format. | |
232 | ||
19450a0c RP |
233 | .TP |
234 | .B \-r | |
235 | .TP | |
1f72cab1 | 236 | .B \-\-reloc |
d5464baa ILT |
237 | Print the relocation entries of the file. If used with \fB\-d\fP or |
238 | \fB\-d\fP, the relocations are printed interspersed with the | |
239 | disassembly. | |
19450a0c | 240 | |
de3b08ac ILT |
241 | .TP |
242 | .B \-R | |
243 | .TP | |
244 | .B \-\-dynamic\-reloc | |
245 | Print the dynamic relocation entries of the file. This is only | |
246 | meaningful for dynamic objects, such as certain types of shared | |
247 | libraries. | |
248 | ||
19450a0c RP |
249 | .TP |
250 | .B \-s | |
eae04238 DM |
251 | .TP |
252 | .B \-\-full\-contents | |
19450a0c RP |
253 | Display the full contents of any sections requested. |
254 | ||
a8e27cc6 ILT |
255 | .TP |
256 | .B \-S | |
257 | .TP | |
258 | .B \-\-source | |
259 | Display source code intermixed with disassembly, if possible. Implies | |
260 | \fB-d\fP. | |
261 | ||
458bbd1f | 262 | .TP |
4cb99ff2 | 263 | .B \-\-show\-raw\-insn |
458bbd1f | 264 | When disassembling instructions, print the instruction in hex as well as |
4cb99ff2 ILT |
265 | in symbolic form. This is the default except when |
266 | .B \-\-prefix\-addresses | |
267 | is used. | |
458bbd1f | 268 | |
c5f0c938 | 269 | .TP |
1f72cab1 | 270 | .B \-\-stabs |
c3c93fda JG |
271 | Display the contents of the .stab, .stab.index, and .stab.excl |
272 | sections from an ELF file. This is only useful on systems (such as | |
273 | Solaris 2.0) in which .stab debugging symbol-table entries are carried | |
274 | in an ELF section. In most other file formats, debugging symbol-table | |
275 | entries are interleaved with linkage symbols, and are visible in the | |
1f72cab1 | 276 | \-\-syms output. |
c5f0c938 | 277 | |
aa21a2a9 ILT |
278 | .TP |
279 | .BI "\-\-start\-address=" "address" | |
280 | Start displaying data at the specified address. This affects the output | |
281 | of the | |
282 | .B \-d\c | |
283 | , | |
284 | .B \-r | |
285 | and | |
286 | .B \-s | |
287 | options. | |
288 | ||
289 | .TP | |
290 | .BI "\-\-stop\-address=" "address" | |
291 | Stop displaying data at the specified address. This affects the output | |
292 | of the | |
293 | .B \-d\c | |
294 | , | |
295 | .B \-r | |
296 | and | |
297 | .B \-s | |
298 | options. | |
299 | ||
19450a0c RP |
300 | .TP |
301 | .B \-t | |
302 | .TP | |
1f72cab1 | 303 | .B \-\-syms |
19450a0c RP |
304 | Symbol Table. Print the symbol table entries of the file. |
305 | This is similar to the information provided by the `\|\c | |
306 | .B nm\c | |
307 | \|' program. | |
308 | ||
de3b08ac ILT |
309 | .TP |
310 | .B \-T | |
311 | .TP | |
312 | .B \-\-dynamic\-syms | |
313 | Dynamic Symbol Table. Print the dynamic symbol table entries of the | |
314 | file. This is only meaningful for dynamic objects, such as certain | |
315 | types of shared libraries. This is similar to the information | |
316 | provided by the `\|\c | |
317 | .B nm\c | |
318 | \|' program when given the | |
319 | .B \-D (\-\-dynamic) | |
320 | option. | |
321 | ||
b26ac613 DM |
322 | .TP |
323 | .B \-\-version | |
324 | Print the version number of | |
325 | .B objdump | |
326 | and exit. | |
327 | ||
19450a0c RP |
328 | .TP |
329 | .B \-x | |
eae04238 DM |
330 | .TP |
331 | .B \-\-all\-headers | |
19450a0c RP |
332 | Display all available header information, including the symbol table and |
333 | relocation entries. Using `\|\c | |
334 | .B \-x\c | |
335 | \|' is equivalent to specifying all of | |
336 | `\|\c | |
337 | .B \-a \-f \-h \-r \-t\c | |
338 | \|'. | |
339 | ||
19450a0c RP |
340 | .SH "SEE ALSO" |
341 | .RB "`\|" binutils "\|'" | |
342 | entry in | |
343 | .B | |
344 | info\c | |
345 | \&; | |
346 | .I | |
347 | The GNU Binary Utilities\c | |
348 | \&, Roland H. Pesch (October 1991); | |
349 | .BR nm "(" 1 ")." | |
350 | ||
351 | .SH COPYING | |
1a418120 | 352 | Copyright (c) 1991, 92, 93, 94, 95, 1996 Free Software Foundation, Inc. |
19450a0c RP |
353 | .PP |
354 | Permission is granted to make and distribute verbatim copies of | |
355 | this manual provided the copyright notice and this permission notice | |
356 | are preserved on all copies. | |
357 | .PP | |
358 | Permission is granted to copy and distribute modified versions of this | |
359 | manual under the conditions for verbatim copying, provided that the | |
360 | entire resulting derived work is distributed under the terms of a | |
361 | permission notice identical to this one. | |
362 | .PP | |
363 | Permission is granted to copy and distribute translations of this | |
364 | manual into another language, under the above conditions for modified | |
365 | versions, except that this permission notice may be included in | |
366 | translations approved by the Free Software Foundation instead of in | |
367 | the original English. |