scc

A fork of https://git.simple-cc.org/scc/ for Qute

git clone https://git.8pit.net/scc.git

  1.TH SCC-OBJDUMP 1 scc\-VERSION
  2.SH NAME
  3scc-objdump \- display information from object files
  4.SH SYNOPSIS
  5.B scc-objdump
  6.RB [ \-afhps ]
  7.RB [ \-t ]
  8.RB [ \-j
  9.IR section ]
 10.RI [ file ...]
 11.SH DESCRIPTION
 12.B scc-objdump
 13displays information about one or more object files.
 14The options control what information is displayed.
 15.PP
 16If no
 17.I file
 18arguments are given,
 19.B scc-objdump
 20reads from
 21.B a.out
 22by default.
 23.PP
 24At least one of the
 25.BR \-a ,
 26.BR \-f ,
 27.BR \-h ,
 28.BR \-t ,
 29or
 30.B \-s
 31options must be specified.
 32.PP
 33Archive libraries are also accepted, in which case
 34.B scc-objdump
 35processes each object file member within the archive.
 36.SH OPTIONS
 37.TP
 38.B \-a
 39If any of the
 40.I files
 41are archives, display the archive header information for each member
 42(file permissions, owner, group, size, and date) in a format similar to
 43.BR ls (1)
 44.BR \-l .
 45.TP
 46.B \-f
 47Display summary information from the file header of each
 48.IR file .
 49This includes the architecture name, the file flags in hexadecimal,
 50and the start address.
 51.PP
 52.RS
 53The file flags field is followed by a comma-separated list of the
 54flag names that are set, which may include:
 55.PP
 56.RS
 57.PD 0
 58.TP
 59.B HAS_RELOC
 60The file contains relocation entries.
 61.TP
 62.B EXEC_P
 63The file is an executable.
 64.TP
 65.B HAS_LINENO
 66The file contains line number information.
 67.TP
 68.B HAS_DEBUG
 69The file contains debugging information.
 70.TP
 71.B HAS_SYMS
 72The file contains a symbol table.
 73.TP
 74.B HAS_LOCALS
 75The file contains local symbols.
 76.TP
 77.B DYNAMIC
 78The file is a dynamically linked object.
 79.PD
 80.RE
 81.RE
 82.TP
 83.B \-h
 84Display summary information from the section headers of each
 85.IR file .
 86For each section, the output includes the section index, name, size,
 87virtual memory address (VMA), load memory address (LMA), file offset,
 88alignment (as a power of two), and a set of flags.
 89.PP
 90.RS
 91The section flags that may appear include:
 92.PP
 93.RS
 94.PD 0
 95.TP
 96.B CONTENTS
 97The section has contents stored in the file.
 98.TP
 99.B ALLOC
100The section is allocated in memory at runtime.
101.TP
102.B LOAD
103The section is loaded from the file into memory.
104.TP
105.B RELOC
106The section has relocation entries.
107.TP
108.B READONLY
109The section is not writable.
110.TP
111.B CODE
112The section contains executable code.
113.TP
114.B DATA
115The section contains initialised data.
116.TP
117.B DEBUGGING
118The section contains debugging information.
119.PD
120.RE
121.RE
122.TP
123.B \-p
124When combined with
125.BR \-h ,
126also display the full contents of each section using the
127format-specific representation.
128This option has no effect without
129.BR \-h .
130.TP
131.B \-s
132Display the full contents of all sections in hex and ASCII.
133For each section that is allocated and non-empty, the output includes
134the section name followed by rows of 16 bytes.
135Each row shows the VMA-relative offset, the bytes in hexadecimal,
136and a printable ASCII representation enclosed in
137.B |
138characters, with non-printable bytes shown as
139.BR . .
140.TP
141.B \-t
142Display the symbol table of each
143.IR file .
144The exact format depends on the object file format.
145.TP
146.BI \-j " section"
147Display information only for the named
148.IR section .
149This option may be specified multiple times to select more than one section.
150When no
151.B \-j
152option is given, all sections are processed.
153.SH OPERANDS
154.TP
155.I file
156A pathname of an object file or archive library to examine.
157If no operands are given,
158.B scc-objdump
159reads from
160.BR a.out .
161.SH EXAMPLES
162Display file header information for an object file:
163.IP
164.EX
165scc-objdump \-f foo.o
166.EE
167.PP
168Display section headers for an object file:
169.IP
170.EX
171scc-objdump \-h foo.o
172.EE
173.PP
174Display symbol table for an object file:
175.IP
176.EX
177scc-objdump \-t foo.o
178.EE
179.PP
180Display hex contents of all sections:
181.IP
182.EX
183scc-objdump \-s foo.o
184.EE
185.PP
186Display file header and section headers together:
187.IP
188.EX
189scc-objdump \-fh foo.o
190.EE
191.PP
192Display section headers and hex contents of a specific section:
193.IP
194.EX
195scc-objdump \-hs \-j .text foo.o
196.EE
197.PP
198Display archive member headers and symbol tables for all members:
199.IP
200.EX
201scc-objdump \-at libfoo.a
202.EE
203.PP
204Display all available information:
205.IP
206.EX
207scc-objdump \-afhst foo.o
208.EE
209.SH SEE ALSO
210.BR scc-nm (1),
211.BR scc-size (1),
212.BR scc-strip (1),
213.BR scc-ar (1),
214.BR scc-ranlib (1)