source: BOOK/final-system/common/binutils.xml@ 7ddb05f

sysvinit
Last change on this file since 7ddb05f was b27081c4, checked in by Chris Staub <chris@…>, 9 years ago

Put one configure option per line

  • Property mode set to 100644
File size: 12.2 KB
RevLine 
[3f8be484]1<?xml version="1.0" encoding="ISO-8859-1"?>
[aa18ac0]2<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
3 "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
[3f8be484]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="b">Verify that the PTYs are working properly inside the build
29 environment. Check that everything is set up correctly by performing a
30 simple test:</para>
31
[0f3854e]32<screen os="c" role="nodump"><userinput>expect -c "spawn ls"</userinput></screen>
[3f8be484]33
[9ecbe5a]34 <para os="d">This command should give the following output:</para>
[3f8be484]35
[9ecbe5a]36<screen os="e"><computeroutput>spawn ls</computeroutput></screen>
[3f8be484]37
[9ecbe5a]38 <para os="f">If, instead, it gives a message saying to create more ptys,
39 then the environment is not set up for proper PTY operation. This issue
40 needs to be resolved before running the test suites for Binutils and GCC.</para>
[3f8be484]41
[e61fedb]42<!-- Branch update patch area
[3e0fdeb]43 <para os="p1">The following patch contains a number of updates to the
44 &binutils-version; branch by the Binutils developers:</para>
45
46 <screen os="p2"><userinput>patch -Np1 -i ../&binutils-branch_update-patch;</userinput></screen>
[e61fedb]47-->
[3e0fdeb]48
[3f8be484]49 <para os="g">The Binutils documentation recommends building Binutils outside of the
50 source directory in a dedicated build directory:</para>
51
[94e6142]52<screen os="h"><userinput>mkdir -v ../binutils-build
[3f8be484]53cd ../binutils-build</userinput></screen>
54
55 <para os="i">Prepare Binutils for compilation:</para>
56
[4173cd9]57<screen os="ca"><userinput>CC="gcc -isystem /usr/include" \
[b6831b6]58LDFLAGS="-Wl,-rpath-link,/usr/lib:/lib" \
[b27081c4]59../binutils-&binutils-dir;/configure \
60 --prefix=/usr \
61 --enable-shared \
62 --enable-gold=yes \
63 --enable-plugins \
64 --enable-threads</userinput></screen>
[3f8be484]65
66 <para os="j">Compile the package:</para>
67
[e1bee3d4]68<screen os="k"><userinput>make tooldir=/usr</userinput></screen>
[3f8be484]69
[51adad9]70<!-- <important os="l">
[e1bee3d4]71 <para>During <command>make tooldir=/usr</command> you may receive the
[3f8be484]72 following error message. It is safe to ignore.</para>
73
74<screen><computeroutput>WARNING: `flex' is missing on your system. You should only
75need it if you modified a `.l' file. You may need the `Flex'
76package in order for those modifications to take effect. You
77can get `Flex' from any GNU archive site.</computeroutput></screen>
[51adad9]78 </important> -->
[3f8be484]79
[44d357b]80 <variablelist os="n">
81 <title>The meaning of the make parameter:</title>
82
83 <varlistentry>
84 <term><parameter>tooldir=/usr</parameter></term>
85 <listitem>
86 <para>Normally, the tooldir (the directory where the executables
87 will ultimately be located) is set to <filename
88 class="directory">$(exec_prefix)/$(target_alias)</filename>. Because this
89 is a custom system, this target-specific directory in <filename
90 class="directory">/usr</filename> is not required.</para>
91 </listitem>
92 </varlistentry>
93 </variablelist>
[3f8be484]94
95 <important os="o">
[eb21c92]96 <para>Due to Binutils' critical role in a properly functioning system,
97 the CLFS developers strongly recommend running the testsuite.</para>
[3f8be484]98 </important>
99
[936dcb48]100 <para os="p">Test the results:</para>
[f54319a]101
[686839b]102<screen os="q"><userinput remap="test">make check</userinput></screen>
[f54319a]103
[3f8be484]104 <para os="r">Install the package:</para>
105
106<screen os="s"><userinput>make tooldir=/usr install</userinput></screen>
107
108 </sect2>
109
110 <sect2 id="contents-binutils" role="content">
111 <title>Contents of Binutils</title>
112
113 <segmentedlist>
114 <segtitle>Installed programs</segtitle>
115 <segtitle>Installed libraries</segtitle>
[61ad0b7f]116 <segtitle>Installed directory</segtitle>
[3f8be484]117
118 <seglistitem>
[bcda234]119 <seg>addr2line, ar, as, c++filt, elfedit, gprof, ld, ld.bfd, ld.gold,
120 nm, objcopy, objdump, ranlib, readelf, size, strings, strip</seg>
[c2102b28]121 <seg>libbfd.[a,so], libopcodes.[a,so]</seg>
[61ad0b7f]122 <seg>/usr/lib/ldscripts</seg>
[3f8be484]123 </seglistitem>
124 </segmentedlist>
125
126 <variablelist>
127 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
128 <?dbfo list-presentation="list"?>
129 <?dbhtml list-presentation="table"?>
130
131 <varlistentry id="addr2line">
132 <term><command>addr2line</command></term>
133 <listitem>
134 <para>Translates program addresses to file names and line numbers;
135 given an address and the name of an executable, it uses the debugging
136 information in the executable to determine which source file and line
137 number are associated with the address</para>
138 <indexterm zone="ch-system-binutils addr2line">
139 <primary sortas="b-addr2line">addr2line</primary>
140 </indexterm>
141 </listitem>
142 </varlistentry>
143
144 <varlistentry id="ar">
145 <term><command>ar</command></term>
146 <listitem>
147 <para>Creates, modifies, and extracts from archives</para>
148 <indexterm zone="ch-system-binutils ar">
149 <primary sortas="b-ar">ar</primary>
150 </indexterm>
151 </listitem>
152 </varlistentry>
153
154 <varlistentry id="as">
155 <term><command>as</command></term>
156 <listitem>
157 <para>An assembler that assembles the output of <command>gcc</command>
158 into object files</para>
159 <indexterm zone="ch-system-binutils as">
160 <primary sortas="b-as">as</primary>
161 </indexterm>
162 </listitem>
163 </varlistentry>
164
165 <varlistentry id="c-filt">
166 <term><command>c++filt</command></term>
167 <listitem>
168 <para>Used by the linker to de-mangle C++ and Java symbols and to keep
169 overloaded functions from clashing</para>
170 <indexterm zone="ch-system-binutils c-filt">
171 <primary sortas="b-c++filt">c++filt</primary>
172 </indexterm>
173 </listitem>
174 </varlistentry>
175
[2b220db9]176 <varlistentry id="elfedit">
177 <term><command>elfedit</command></term>
178 <listitem>
179 <para>Updates the ELF header of ELF files</para>
180 <indexterm zone="ch-system-binutils elfedit">
181 <primary sortas="b-elfedit">elfedit</primary>
182 </indexterm>
183 </listitem>
184 </varlistentry>
185
[3f8be484]186 <varlistentry id="gprof">
187 <term><command>gprof</command></term>
188 <listitem>
189 <para>Displays call graph profile data</para>
190 <indexterm zone="ch-system-binutils gprof">
191 <primary sortas="b-gprof">gprof</primary>
192 </indexterm>
193 </listitem>
194 </varlistentry>
195
196 <varlistentry id="ld">
197 <term><command>ld</command></term>
198 <listitem>
199 <para>A linker that combines a number of object and archive files
200 into a single file, relocating their data and tying up symbol
201 references</para>
202 <indexterm zone="ch-system-binutils ld">
203 <primary sortas="b-ld">ld</primary>
204 </indexterm>
205 </listitem>
206 </varlistentry>
207
[2b220db9]208 <varlistentry id="ld.bfd">
209 <term><command>ld.bfd</command></term>
210 <listitem>
211 <para>Hard link to <command>ld</command></para>
212 <indexterm zone="ch-system-binutils ld.bfd">
213 <primary sortas="b-ld.bfd">ld.bfd</primary>
214 </indexterm>
215 </listitem>
216 </varlistentry>
217
[bcda234]218 <varlistentry id="ld.gold">
219 <term><command>ld.gold</command></term>
220 <listitem>
221 <para>A linker designed to be faster than <command>ld</command>,
222 especially for large C++ applications.</para>
223 <indexterm zone="ch-system-binutils ld.gold">
224 <primary sortas="b-ld.gold">ld.gold</primary>
225 </indexterm>
226 </listitem>
227 </varlistentry>
228
[3f8be484]229 <varlistentry id="nm">
230 <term><command>nm</command></term>
231 <listitem>
232 <para>Lists the symbols occurring in a given object file</para>
233 <indexterm zone="ch-system-binutils nm">
234 <primary sortas="b-nm">nm</primary>
235 </indexterm>
236 </listitem>
237 </varlistentry>
238
239 <varlistentry id="objcopy">
240 <term><command>objcopy</command></term>
241 <listitem>
242 <para>Translates one type of object file into another</para>
243 <indexterm zone="ch-system-binutils objcopy">
244 <primary sortas="b-objcopy">objcopy</primary>
245 </indexterm>
246 </listitem>
247 </varlistentry>
248
249 <varlistentry id="objdump">
250 <term><command>objdump</command></term>
251 <listitem>
252 <para>Displays information about the given object file, with options
253 controlling the particular information to display; the information
254 shown is useful to programmers who are working on the compilation
255 tools</para>
256 <indexterm zone="ch-system-binutils objdump">
257 <primary sortas="b-objdump">objdump</primary>
258 </indexterm>
259 </listitem>
260 </varlistentry>
261
262 <varlistentry id="ranlib">
263 <term><command>ranlib</command></term>
264 <listitem>
265 <para>Generates an index of the contents of an archive and stores it
266 in the archive; the index lists all of the symbols defined by archive
267 members that are relocatable object files</para>
268 <indexterm zone="ch-system-binutils ranlib">
269 <primary sortas="b-ranlib">ranlib</primary>
270 </indexterm>
271 </listitem>
272 </varlistentry>
273
274 <varlistentry id="readelf">
275 <term><command>readelf</command></term>
276 <listitem>
277 <para>Displays information about ELF type binaries</para>
278 <indexterm zone="ch-system-binutils readelf">
279 <primary sortas="b-readelf">readelf</primary>
280 </indexterm>
281 </listitem>
282 </varlistentry>
283
284 <varlistentry id="size">
285 <term><command>size</command></term>
286 <listitem>
287 <para>Lists the section sizes and the total size for the given
288 object files</para>
289 <indexterm zone="ch-system-binutils size">
290 <primary sortas="b-size">size</primary>
291 </indexterm>
292 </listitem>
293 </varlistentry>
294
295 <varlistentry id="strings">
296 <term><command>strings</command></term>
297 <listitem>
298 <para>Outputs, for each given file, the sequences of printable
299 characters that are of at least the specified length (defaulting to
300 four); for object files, it prints, by default, only the strings from
301 the initializing and loading sections while for other types of files,
302 it scans the entire file</para>
303 <indexterm zone="ch-system-binutils strings">
304 <primary sortas="b-strings">strings</primary>
305 </indexterm>
306 </listitem>
307 </varlistentry>
308
309 <varlistentry id="strip">
310 <term><command>strip</command></term>
311 <listitem>
312 <para>Discards symbols from object files</para>
313 <indexterm zone="ch-system-binutils strip">
314 <primary sortas="b-strip">strip</primary>
315 </indexterm>
316 </listitem>
317 </varlistentry>
318
319 <varlistentry id="libbfd">
320 <term><filename class="libraryfile">libbfd</filename></term>
321 <listitem>
322 <para>The Binary File Descriptor library</para>
323 <indexterm zone="ch-system-binutils libbfd">
324 <primary sortas="c-libbfd">libbfd</primary>
325 </indexterm>
326 </listitem>
327 </varlistentry>
328
329 <varlistentry id="libopcodes">
330 <term><filename class="libraryfile">libopcodes</filename></term>
331 <listitem>
332 <para>A library for dealing with opcodes&mdash;the <quote>readable
333 text</quote> versions of instructions for the processor;
334 it is used for building utilities like
335 <command>objdump</command>.</para>
336 <indexterm zone="ch-system-binutils libopcodes">
337 <primary sortas="c-libopcodes">libopcodes</primary>
338 </indexterm>
339 </listitem>
340 </varlistentry>
341
342 </variablelist>
343
344 </sect2>
345
346</sect1>
Note: See TracBrowser for help on using the repository browser.