source: clfs-sysroot/BOOK/final-system/common/binutils.xml@ d847aa5

Last change on this file since d847aa5 was 586feb7, checked in by Joe Ciccone <jciccone@…>, 18 years ago

Updated the bootscripts package and make LFS to CLFS updates.

  • Property mode set to 100644
File size: 10.8 KB
Line 
1<?xml version="1.0" encoding="ISO-8859-1"?>
2<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN"
3 "http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd" [
4 <!ENTITY % general-entities SYSTEM "../../general.ent">
5 %general-entities;
6]>
7
8<sect1 id="ch-system-binutils" role="wrap">
9 <?dbhtml filename="binutils.html"?>
10
11 <title>Binutils-&binutils-version;</title>
12
13 <indexterm zone="ch-system-binutils">
14 <primary sortas="a-Binutils">Binutils</primary>
15 </indexterm>
16
17 <sect2 role="package">
18 <title/>
19
20 <para>The Binutils package contains a linker, an assembler, and other
21 tools for handling object files.</para>
22
23 </sect2>
24
25 <sect2 role="installation">
26 <title>Installation of Binutils</title>
27
28 <para os="p1">To make sure that the proper syntax is used for a couple of
29 tools, apply the following patch:</para>
30
31<screen os="p2"><userinput>patch -Np1 -i ../&binutils-posix-patch;</userinput></screen>
32
33 <para os="a">The Binutils documentation recommends building Binutils outside of the
34 source directory in a dedicated build directory:</para>
35
36<screen os="b"><userinput>mkdir -v ../binutils-build
37cd ../binutils-build</userinput></screen>
38
39 <para os="c">Prepare Binutils for compilation:</para>
40
41<screen os="d"><userinput>../binutils-&binutils-version;/configure --prefix=/usr \
42 --build=${CLFS_HOST} --host=${CLFS_TARGET} \
43 --target=${CLFS_TARGET} --enable-shared</userinput></screen>
44
45 <para os="e">Compile the package:</para>
46
47<screen os="f"><userinput>make configure-host</userinput></screen>
48
49 <important os="g">
50 <para>During <command>make configure-host</command> you may receive the
51 following error message. It is safe to ignore.</para>
52
53<screen><computeroutput>WARNING: `flex' is missing on your system. You should only
54need it if you modified a `.l' file. You may need the `Flex'
55package in order for those modifications to take effect. You
56can get `Flex' from any GNU archive site.</computeroutput></screen>
57 </important>
58
59<screen os="h"><userinput>make tooldir=/usr</userinput></screen>
60
61 <variablelist os="i">
62 <title>The meaning of the make parameter:</title>
63
64 <varlistentry>
65 <term><parameter>tooldir=/usr</parameter></term>
66 <listitem>
67 <para>Normally, the tooldir (the directory where the executables
68 will ultimately be located) is set to <filename
69 class="directory">$(exec_prefix)/$(target_alias)</filename>. Because this
70 is a custom system, this target-specific directory in <filename
71 class="directory">/usr</filename> is not required.</para>
72 </listitem>
73 </varlistentry>
74 </variablelist>
75
76 <para os="j">Install the package:</para>
77
78<screen os="k"><userinput>make DESTDIR=${CLFS} tooldir=/usr install</userinput></screen>
79
80 <para os="l">Install the <filename class="headerfile">libiberty</filename> header
81 file that is needed by some packages:</para>
82
83<screen os="m"><userinput>cp -v ../binutils-&binutils-version;/include/libiberty.h ${CLFS}/usr/include</userinput></screen>
84
85 </sect2>
86
87 <sect2 id="contents-binutils" role="content">
88 <title>Contents of Binutils</title>
89
90 <segmentedlist>
91 <segtitle>Installed programs</segtitle>
92 <segtitle>Installed libraries</segtitle>
93
94 <seglistitem>
95 <seg>addr2line, ar, as, c++filt, gprof, ld, nm, objcopy, objdump,
96 ranlib, readelf, size, strings, and strip</seg>
97 <seg>libiberty.a, libbfd.[a,so], and libopcodes.[a,so]</seg>
98 </seglistitem>
99 </segmentedlist>
100
101 <variablelist>
102 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
103 <?dbfo list-presentation="list"?>
104 <?dbhtml list-presentation="table"?>
105
106 <varlistentry id="addr2line">
107 <term><command>addr2line</command></term>
108 <listitem>
109 <para>Translates program addresses to file names and line numbers;
110 given an address and the name of an executable, it uses the debugging
111 information in the executable to determine which source file and line
112 number are associated with the address</para>
113 <indexterm zone="ch-system-binutils addr2line">
114 <primary sortas="b-addr2line">addr2line</primary>
115 </indexterm>
116 </listitem>
117 </varlistentry>
118
119 <varlistentry id="ar">
120 <term><command>ar</command></term>
121 <listitem>
122 <para>Creates, modifies, and extracts from archives</para>
123 <indexterm zone="ch-system-binutils ar">
124 <primary sortas="b-ar">ar</primary>
125 </indexterm>
126 </listitem>
127 </varlistentry>
128
129 <varlistentry id="as">
130 <term><command>as</command></term>
131 <listitem>
132 <para>An assembler that assembles the output of <command>gcc</command>
133 into object files</para>
134 <indexterm zone="ch-system-binutils as">
135 <primary sortas="b-as">as</primary>
136 </indexterm>
137 </listitem>
138 </varlistentry>
139
140 <varlistentry id="c-filt">
141 <term><command>c++filt</command></term>
142 <listitem>
143 <para>Used by the linker to de-mangle C++ and Java symbols and to keep
144 overloaded functions from clashing</para>
145 <indexterm zone="ch-system-binutils c-filt">
146 <primary sortas="b-c++filt">c++filt</primary>
147 </indexterm>
148 </listitem>
149 </varlistentry>
150
151 <varlistentry id="gprof">
152 <term><command>gprof</command></term>
153 <listitem>
154 <para>Displays call graph profile data</para>
155 <indexterm zone="ch-system-binutils gprof">
156 <primary sortas="b-gprof">gprof</primary>
157 </indexterm>
158 </listitem>
159 </varlistentry>
160
161 <varlistentry id="ld">
162 <term><command>ld</command></term>
163 <listitem>
164 <para>A linker that combines a number of object and archive files
165 into a single file, relocating their data and tying up symbol
166 references</para>
167 <indexterm zone="ch-system-binutils ld">
168 <primary sortas="b-ld">ld</primary>
169 </indexterm>
170 </listitem>
171 </varlistentry>
172
173 <varlistentry id="nm">
174 <term><command>nm</command></term>
175 <listitem>
176 <para>Lists the symbols occurring in a given object file</para>
177 <indexterm zone="ch-system-binutils nm">
178 <primary sortas="b-nm">nm</primary>
179 </indexterm>
180 </listitem>
181 </varlistentry>
182
183 <varlistentry id="objcopy">
184 <term><command>objcopy</command></term>
185 <listitem>
186 <para>Translates one type of object file into another</para>
187 <indexterm zone="ch-system-binutils objcopy">
188 <primary sortas="b-objcopy">objcopy</primary>
189 </indexterm>
190 </listitem>
191 </varlistentry>
192
193 <varlistentry id="objdump">
194 <term><command>objdump</command></term>
195 <listitem>
196 <para>Displays information about the given object file, with options
197 controlling the particular information to display; the information
198 shown is useful to programmers who are working on the compilation
199 tools</para>
200 <indexterm zone="ch-system-binutils objdump">
201 <primary sortas="b-objdump">objdump</primary>
202 </indexterm>
203 </listitem>
204 </varlistentry>
205
206 <varlistentry id="ranlib">
207 <term><command>ranlib</command></term>
208 <listitem>
209 <para>Generates an index of the contents of an archive and stores it
210 in the archive; the index lists all of the symbols defined by archive
211 members that are relocatable object files</para>
212 <indexterm zone="ch-system-binutils ranlib">
213 <primary sortas="b-ranlib">ranlib</primary>
214 </indexterm>
215 </listitem>
216 </varlistentry>
217
218 <varlistentry id="readelf">
219 <term><command>readelf</command></term>
220 <listitem>
221 <para>Displays information about ELF type binaries</para>
222 <indexterm zone="ch-system-binutils readelf">
223 <primary sortas="b-readelf">readelf</primary>
224 </indexterm>
225 </listitem>
226 </varlistentry>
227
228 <varlistentry id="size">
229 <term><command>size</command></term>
230 <listitem>
231 <para>Lists the section sizes and the total size for the given
232 object files</para>
233 <indexterm zone="ch-system-binutils size">
234 <primary sortas="b-size">size</primary>
235 </indexterm>
236 </listitem>
237 </varlistentry>
238
239 <varlistentry id="strings">
240 <term><command>strings</command></term>
241 <listitem>
242 <para>Outputs, for each given file, the sequences of printable
243 characters that are of at least the specified length (defaulting to
244 four); for object files, it prints, by default, only the strings from
245 the initializing and loading sections while for other types of files,
246 it scans the entire file</para>
247 <indexterm zone="ch-system-binutils strings">
248 <primary sortas="b-strings">strings</primary>
249 </indexterm>
250 </listitem>
251 </varlistentry>
252
253 <varlistentry id="strip">
254 <term><command>strip</command></term>
255 <listitem>
256 <para>Discards symbols from object files</para>
257 <indexterm zone="ch-system-binutils strip">
258 <primary sortas="b-strip">strip</primary>
259 </indexterm>
260 </listitem>
261 </varlistentry>
262
263 <varlistentry id="libiberty">
264 <term><filename class="libraryfile">libiberty</filename></term>
265 <listitem>
266 <para>Contains routines used by various GNU programs, including
267 <command>getopt</command>, <command>obstack</command>,
268 <command>strerror</command>, <command>strtol</command>, and
269 <command>strtoul</command></para>
270 <indexterm zone="ch-system-binutils libiberty">
271 <primary sortas="c-libiberty">libiberty</primary>
272 </indexterm>
273 </listitem>
274 </varlistentry>
275
276 <varlistentry id="libbfd">
277 <term><filename class="libraryfile">libbfd</filename></term>
278 <listitem>
279 <para>The Binary File Descriptor library</para>
280 <indexterm zone="ch-system-binutils libbfd">
281 <primary sortas="c-libbfd">libbfd</primary>
282 </indexterm>
283 </listitem>
284 </varlistentry>
285
286 <varlistentry id="libopcodes">
287 <term><filename class="libraryfile">libopcodes</filename></term>
288 <listitem>
289 <para>A library for dealing with opcodes&mdash;the <quote>readable
290 text</quote> versions of instructions for the processor;
291 it is used for building utilities like
292 <command>objdump</command>.</para>
293 <indexterm zone="ch-system-binutils libopcodes">
294 <primary sortas="c-libopcodes">libopcodes</primary>
295 </indexterm>
296 </listitem>
297 </varlistentry>
298
299 </variablelist>
300
301 </sect2>
302
303</sect1>
Note: See TracBrowser for help on using the repository browser.