3 <title>Host/Target specific installation notes for GCC
</title>
4 <meta http-equiv=
"Content-Type" content=
"text/html">
5 <meta name=
"description" content=
"Host/Target specific installation notes for GCC">
6 <meta name=
"generator" content=
"makeinfo 4.7">
7 <link title=
"Top" rel=
"top" href=
"#Top">
8 <link href=
"http://www.gnu.org/software/texinfo/" rel=
"generator-home" title=
"Texinfo Homepage">
10 Copyright (C) 1988, 1989, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
11 1999, 2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc.
13 Permission is granted to copy, distribute and/or modify this document
14 under the terms of the GNU Free Documentation License, Version 1.2 or
15 any later version published by the Free Software Foundation; with no
16 Invariant Sections, the Front-Cover texts being (a) (see below), and
17 with the Back-Cover Texts being (b) (see below). A copy of the
18 license is included in the section entitled "GNU Free Documentation License".
20 (a) The FSF's Front-Cover Text is:
24 (b) The FSF's Back-Cover Text is:
26 You have freedom to copy and modify this GNU Manual, like GNU
27 software. Copies published by the Free Software Foundation raise
28 funds for GNU development.-->
29 <meta http-equiv=
"Content-Style-Type" content=
"text/css">
30 <style type=
"text/css"><!--
31 pre
.display
{ font-family:inherit
}
32 pre
.format
{ font-family:inherit
}
33 pre
.smalldisplay
{ font-family:inherit
; font-size:smaller
}
34 pre
.smallformat
{ font-family:inherit
; font-size:smaller
}
35 pre
.smallexample
{ font-size:smaller
}
36 pre
.smalllisp
{ font-size:smaller
}
37 span
.sc
{ font-variant:small-caps
}
38 span
.roman
{ font-family: serif
; font-weight: normal
; }
42 <h1 class=
"settitle">Host/Target specific installation notes for GCC
</h1>
43 <a name=
"index-Specific-1"></a><a name=
"index-Specific-installation-notes-2"></a><a name=
"index-Target-specific-installation-3"></a><a name=
"index-Host-specific-installation-4"></a><a name=
"index-Target-specific-installation-notes-5"></a>
44 Please read this document carefully
<em>before
</em> installing the
45 GNU Compiler Collection on your machine.
48 <li><a href=
"#alpha*-*-*">alpha*-*-*
</a>
49 <li><a href=
"#alpha*-dec-osf*">alpha*-dec-osf*
</a>
50 <li><a href=
"#alphaev5-cray-unicosmk*">alphaev5-cray-unicosmk*
</a>
51 <li><a href=
"#arc-*-elf">arc-*-elf
</a>
52 <li><a href=
"#arm-*-elf">arm-*-elf
</a>
53 <a href=
"#arm-*-coff">arm-*-coff
</a>
54 <a href=
"#arm-*-aout">arm-*-aout
</a>
55 <li><a href=
"#xscale-*-*">xscale-*-*
</a>
56 <li><a href=
"#avr">avr
</a>
57 <li><a href=
"#c4x">c4x
</a>
58 <li><a href=
"#dos">DOS
</a>
59 <li><a href=
"#dsp16xx">dsp16xx
</a>
60 <li><a href=
"#*-*-freebsd*">*-*-freebsd*
</a>
61 <li><a href=
"#h8300-hms">h8300-hms
</a>
62 <li><a href=
"#hppa*-hp-hpux*">hppa*-hp-hpux*
</a>
63 <li><a href=
"#hppa*-hp-hpux10">hppa*-hp-hpux10
</a>
64 <li><a href=
"#hppa*-hp-hpux11">hppa*-hp-hpux11
</a>
65 <li><a href=
"#i370-*-*">i370-*-*
</a>
66 <li><a href=
"#*-*-linux-gnu">*-*-linux-gnu
</a>
67 <li><a href=
"#ix86-*-linux*aout">i?
86-*-linux*aout
</a>
68 <li><a href=
"#ix86-*-linux*">i?
86-*-linux*
</a>
69 <li><a href=
"#ix86-*-sco3.2v5*">i?
86-*-sco3.2v5*
</a>
70 <li><a href=
"#ix86-*-udk">i?
86-*-udk
</a>
71 <li><a href=
"#ix86-*-esix">i?
86-*-esix
</a>
72 <li><a href=
"#ia64-*-linux">ia64-*-linux
</a>
73 <li><a href=
"#ia64-*-hpux*">ia64-*-hpux*
</a>
74 <li><a href=
"#*-ibm-aix*">*-ibm-aix*
</a>
75 <li><a href=
"#ip2k-*-elf">ip2k-*-elf
</a>
76 <li><a href=
"#iq2000-*-elf">iq2000-*-elf
</a>
77 <li><a href=
"#m32r-*-elf">m32r-*-elf
</a>
78 <li><a href=
"#m6811-elf">m6811-elf
</a>
79 <li><a href=
"#m6812-elf">m6812-elf
</a>
80 <li><a href=
"#m68k-hp-hpux">m68k-hp-hpux
</a>
81 <li><a href=
"#mips-*-*">mips-*-*
</a>
82 <li><a href=
"#mips-sgi-irix5">mips-sgi-irix5
</a>
83 <li><a href=
"#mips-sgi-irix6">mips-sgi-irix6
</a>
84 <li><a href=
"#powerpc*-*-*">powerpc*-*-*
</a> powerpc-*-sysv4
85 <li><a href=
"#powerpc-*-darwin*">powerpc-*-darwin*
</a>
86 <li><a href=
"#powerpc-*-elf">powerpc-*-elf
</a> powerpc-*-sysv4
87 <li><a href=
"#powerpc-*-linux-gnu*">powerpc-*-linux-gnu*
</a>
88 <li><a href=
"#powerpc-*-netbsd*">powerpc-*-netbsd*
</a>
89 <li><a href=
"#powerpc-*-eabiaix">powerpc-*-eabiaix
</a>
90 <li><a href=
"#powerpc-*-eabisim">powerpc-*-eabisim
</a>
91 <li><a href=
"#powerpc-*-eabi">powerpc-*-eabi
</a>
92 <li><a href=
"#powerpcle-*-elf">powerpcle-*-elf
</a> powerpcle-*-sysv4
93 <li><a href=
"#powerpcle-*-eabisim">powerpcle-*-eabisim
</a>
94 <li><a href=
"#powerpcle-*-eabi">powerpcle-*-eabi
</a>
95 <li><a href=
"#s390-*-linux*">s390-*-linux*
</a>
96 <li><a href=
"#s390x-*-linux*">s390x-*-linux*
</a>
97 <li><a href=
"#s390x-ibm-tpf*">s390x-ibm-tpf*
</a>
98 <li><a href=
"#*-*-solaris2*">*-*-solaris2*
</a>
99 <li><a href=
"#sparc-sun-solaris2*">sparc-sun-solaris2*
</a>
100 <li><a href=
"#sparc-sun-solaris2.7">sparc-sun-solaris2.7
</a>
101 <li><a href=
"#sparc-*-linux*">sparc-*-linux*
</a>
102 <li><a href=
"#sparc64-*-solaris2*">sparc64-*-solaris2*
</a>
103 <li><a href=
"#sparcv9-*-solaris2*">sparcv9-*-solaris2*
</a>
104 <li><a href=
"#*-*-sysv*">*-*-sysv*
</a>
105 <li><a href=
"#vax-dec-ultrix">vax-dec-ultrix
</a>
106 <li><a href=
"#*-*-vxworks*">*-*-vxworks*
</a>
107 <li><a href=
"#x86_64-*-*">x86_64-*-*
</a> amd64-*-*
108 <li><a href=
"#xtensa-*-elf">xtensa-*-elf
</a>
109 <li><a href=
"#xtensa-*-linux*">xtensa-*-linux*
</a>
110 <li><a href=
"#windows">Microsoft Windows
</a>
111 <li><a href=
"#os2">OS/
2</a>
112 <li><a href=
"#older">Older systems
</a>
116 <li><a href=
"#elf_targets">all ELF targets
</a> (SVR4, Solaris
2, etc.)
119 <p><!-- -------- host/target specific issues start here ---------------- -->
122 <h3 class=
"heading"><a name=
"TOC0"></a><a name=
"alpha_002a_002d_002a_002d_002a"></a>alpha*-*-*
</h3>
124 <p>This section contains general configuration information for all
125 alpha-based platforms using ELF (in particular, ignore this section for
126 DEC OSF/
1, Digital UNIX and Tru64 UNIX). In addition to reading this
127 section, please read all other sections that match your target.
129 <p>We require binutils
2.11.2 or newer.
130 Previous binutils releases had a number of problems with DWARF
2
131 debugging information, not the least of which is incorrect linking of
136 <h3 class=
"heading"><a name=
"TOC1"></a><a name=
"alpha_002a_002ddec_002dosf_002a"></a>alpha*-dec-osf*
</h3>
138 <p>Systems using processors that implement the DEC Alpha architecture and
139 are running the DEC/Compaq Unix (DEC OSF/
1, Digital UNIX, or Compaq
140 Tru64 UNIX) operating system, for example the DEC Alpha AXP systems.
142 <p>As of GCC
3.2, versions before
<code>alpha*-dec-osf4
</code> are no longer
143 supported. (These are the versions which identify themselves as DEC
146 <p>In Digital Unix V4.0, virtual memory exhausted bootstrap failures
147 may be fixed by configuring with
<span class=
"option">--with-gc=simple
</span>,
148 reconfiguring Kernel Virtual Memory and Swap parameters
149 per the
<span class=
"command">/usr/sbin/sys_check
</span> Tuning Suggestions,
150 or applying the patch in
151 <a href=
"http://gcc.gnu.org/ml/gcc/2002-08/msg00822.html">http://gcc.gnu.org/ml/gcc/
2002-
08/msg00822.html
</a>.
153 <p>In Tru64 UNIX V5.1, Compaq introduced a new assembler that does not
154 currently (
2001-
06-
13) work with
<span class=
"command">mips-tfile
</span>. As a workaround,
155 we need to use the old assembler, invoked via the barely documented
156 <span class=
"option">-oldas
</span> option. To bootstrap GCC, you either need to use the
159 <pre class=
"smallexample"> % CC=cc
<var>srcdir
</var>/configure [
<var>options
</var>] [
<var>target
</var>]
161 <p>or you can use a copy of GCC
2.95.3 or higher built on Tru64 UNIX V4.0:
163 <pre class=
"smallexample"> % CC=gcc -Wa,-oldas
<var>srcdir
</var>/configure [
<var>options
</var>] [
<var>target
</var>]
165 <p>As of GNU binutils
2.11.2, neither GNU
<span class=
"command">as
</span> nor GNU
<span class=
"command">ld
</span>
166 are supported on Tru64 UNIX, so you must not configure GCC with
167 <span class=
"option">--with-gnu-as
</span> or
<span class=
"option">--with-gnu-ld
</span>.
169 <p>GCC writes a
<span class=
"samp">.verstamp
</span> directive to the assembler output file
170 unless it is built as a cross-compiler. It gets the version to use from
171 the system header file
<span class=
"file">/usr/include/stamp.h
</span>. If you install a
172 new version of DEC Unix, you should rebuild GCC to pick up the new version
175 <p>Note that since the Alpha is a
64-bit architecture, cross-compilers from
176 32-bit machines will not generate code as efficient as that generated
177 when the compiler is running on a
64-bit machine because many
178 optimizations that depend on being able to represent a word on the
179 target in an integral value on the host cannot be performed. Building
180 cross-compilers on the Alpha for
32-bit machines has only been tested in
181 a few cases and may not work properly.
183 <p><span class=
"samp">make compare
</span> may fail on old versions of DEC Unix unless you add
184 <span class=
"option">-save-temps
</span> to
<code>CFLAGS
</code>. On these systems, the name of the
185 assembler input file is stored in the object file, and that makes
186 comparison fail if it differs between the
<code>stage1
</code> and
187 <code>stage2
</code> compilations. The option
<span class=
"option">-save-temps
</span> forces a
188 fixed name to be used for the assembler input file, instead of a
189 randomly chosen name in
<span class=
"file">/tmp
</span>. Do not add
<span class=
"option">-save-temps
</span>
190 unless the comparisons fail without that option. If you add
191 <span class=
"option">-save-temps
</span>, you will have to manually delete the
<span class=
"samp">.i
</span> and
192 <span class=
"samp">.s
</span> files after each series of compilations.
194 <p>GCC now supports both the native (ECOFF) debugging format used by DBX
195 and GDB and an encapsulated STABS format for use only with GDB. See the
196 discussion of the
<span class=
"option">--with-stabs
</span> option of
<span class=
"file">configure
</span> above
197 for more information on these formats and how to select them.
199 <p>There is a bug in DEC's assembler that produces incorrect line numbers
200 for ECOFF format when the
<span class=
"samp">.align
</span> directive is used. To work
201 around this problem, GCC will not emit such alignment directives
202 while writing ECOFF format debugging information even if optimization is
203 being performed. Unfortunately, this has the very undesirable
204 side-effect that code addresses when
<span class=
"option">-O
</span> is specified are
205 different depending on whether or not
<span class=
"option">-g
</span> is also specified.
207 <p>To avoid this behavior, specify
<span class=
"option">-gstabs+
</span> and use GDB instead of
208 DBX. DEC is now aware of this problem with the assembler and hopes to
209 provide a fix shortly.
213 <h3 class=
"heading"><a name=
"TOC2"></a><a name=
"alphaev5_002dcray_002dunicosmk_002a"></a>alphaev5-cray-unicosmk*
</h3>
215 <p>Cray T3E systems running Unicos/Mk.
217 <p>This port is incomplete and has many known bugs. We hope to improve the
218 support for this target soon. Currently, only the C front end is supported,
219 and it is not possible to build parallel applications. Cray modules are not
220 supported; in particular, Craylibs are assumed to be in
221 <span class=
"file">/opt/ctl/craylibs/craylibs
</span>.
223 <p>You absolutely
<strong>must
</strong> use GNU make on this platform. Also, you
224 need to tell GCC where to find the assembler and the linker. The
225 simplest way to do so is by providing
<span class=
"option">--with-as
</span> and
226 <span class=
"option">--with-ld
</span> to
<span class=
"file">configure
</span>, e.g.
228 <pre class=
"smallexample"> configure --with-as=/opt/ctl/bin/cam --with-ld=/opt/ctl/bin/cld \
231 <p>The comparison test during
<span class=
"samp">make bootstrap
</span> fails on Unicos/Mk
232 because the assembler inserts timestamps into object files. You should
233 be able to work around this by doing
<span class=
"samp">make all
</span> after getting this
238 <h3 class=
"heading"><a name=
"TOC3"></a><a name=
"arc_002d_002a_002delf"></a>arc-*-elf
</h3>
240 <p>Argonaut ARC processor.
241 This configuration is intended for embedded systems.
245 <h3 class=
"heading"><a name=
"TOC4"></a><a name=
"arm_002d_002a_002delf"></a>arm-*-elf
</h3>
247 <h3 class=
"heading"><a name=
"TOC5"></a><a name=
"xscale_002d_002a_002d_002a"></a>xscale-*-*
</h3>
249 <p>ARM-family processors. Subtargets that use the ELF object format
250 require GNU binutils
2.13 or newer. Such subtargets include:
251 <code>arm-*-freebsd
</code>,
<code>arm-*-netbsdelf
</code>,
<code>arm-*-*linux
</code>,
252 <code>arm-*-rtems
</code> and
<code>arm-*-kaos
</code>.
256 <h3 class=
"heading"><a name=
"TOC6"></a><a name=
"arm_002d_002a_002dcoff"></a>arm-*-coff
</h3>
258 <p>ARM-family processors. Note that there are two different varieties
259 of PE format subtarget supported:
<code>arm-wince-pe
</code> and
260 <code>arm-pe
</code> as well as a standard COFF target
<code>arm-*-coff
</code>.
264 <h3 class=
"heading"><a name=
"TOC7"></a><a name=
"arm_002d_002a_002daout"></a>arm-*-aout
</h3>
266 <p>ARM-family processors. These targets support the AOUT file format:
267 <code>arm-*-aout
</code>,
<code>arm-*-netbsd
</code>.
271 <h3 class=
"heading"><a name=
"TOC8"></a><a name=
"avr"></a>avr
</h3>
273 <p>ATMEL AVR-family micro controllers. These are used in embedded
274 applications. There are no standard Unix configurations.
275 See
“AVR Options
” in the main manual
276 for the list of supported MCU types.
278 <p>Use
<span class=
"samp">configure --target=avr
--enable-languages=
"c"</span> to configure GCC.
280 <p>Further installation notes and other useful information about AVR tools
281 can also be obtained from:
284 <li><a href=
"http://www.openavr.org">http://www.openavr.org
</a>
285 <li><a href=
"http://home.overta.ru/users/denisc/">http://home.overta.ru/users/denisc/
</a>
286 <li><a href=
"http://www.amelek.gda.pl/avr/">http://www.amelek.gda.pl/avr/
</a>
289 <p>We
<em>strongly
</em> recommend using binutils
2.13 or newer.
291 <p>The following error:
292 <pre class=
"smallexample"> Error: register required
294 <p>indicates that you should upgrade to a newer version of the binutils.
298 <h3 class=
"heading"><a name=
"TOC9"></a><a name=
"c4x"></a>c4x
</h3>
300 <p>Texas Instruments TMS320C3x and TMS320C4x Floating Point Digital Signal
301 Processors. These are used in embedded applications. There are no
302 standard Unix configurations.
303 See
“TMS320C3x/C4x Options
” in the main manual
304 for the list of supported MCU types.
306 <p>GCC can be configured as a cross compiler for both the C3x and C4x
307 architectures on the same system. Use
<span class=
"samp">configure --target=c4x
308 --enable-languages=
"c,c++"</span> to configure.
310 <p>Further installation notes and other useful information about C4x tools
311 can also be obtained from:
314 <li><a href=
"http://www.elec.canterbury.ac.nz/c4x/">http://www.elec.canterbury.ac.nz/c4x/
</a>
319 <h3 class=
"heading"><a name=
"TOC10"></a><a name=
"cris"></a>CRIS
</h3>
321 <p>CRIS is the CPU architecture in Axis Communications ETRAX system-on-a-chip
322 series. These are used in embedded applications.
324 <p>See
“CRIS Options
” in the main manual
325 for a list of CRIS-specific options.
327 <p>There are a few different CRIS targets:
329 <dt><code>cris-axis-aout
</code><dd>Old target. Includes a multilib for the
<span class=
"samp">elinux
</span> a.out-based
330 target. No multilibs for newer architecture variants.
331 <br><dt><code>cris-axis-elf
</code><dd>Mainly for monolithic embedded systems. Includes a multilib for the
332 <span class=
"samp">v10
</span> core used in
<span class=
"samp">ETRAX
100 LX
</span>.
333 <br><dt><code>cris-axis-linux-gnu
</code><dd>A GNU/Linux port for the CRIS architecture, currently targeting
334 <span class=
"samp">ETRAX
100 LX
</span> by default.
337 <p>For
<code>cris-axis-aout
</code> and
<code>cris-axis-elf
</code> you need binutils
2.11
338 or newer. For
<code>cris-axis-linux-gnu
</code> you need binutils
2.12 or newer.
340 <p>Pre-packaged tools can be obtained from
341 <a href=
"ftp://ftp.axis.com/pub/axis/tools/cris/compiler-kit/">ftp://ftp.axis.com/pub/axis/tools/cris/compiler-kit/
</a>. More
342 information about this platform is available at
343 <a href=
"http://developer.axis.com/">http://developer.axis.com/
</a>.
347 <h3 class=
"heading"><a name=
"TOC11"></a><a name=
"dos"></a>DOS
</h3>
349 <p>Please have a look at the
<a href=
"binaries.html">binaries page
</a>.
351 <p>You cannot install GCC by itself on MSDOS; it will not compile under
352 any MSDOS compiler except itself. You need to get the complete
353 compilation package DJGPP, which includes binaries as well as sources,
354 and includes all the necessary compilation tools and libraries.
358 <h3 class=
"heading"><a name=
"TOC12"></a><a name=
"dsp16xx"></a>dsp16xx
</h3>
360 <p>A port to the AT
&T DSP1610 family of processors.
364 <h3 class=
"heading"><a name=
"TOC13"></a><a name=
"_002a_002d_002a_002dfreebsd_002a"></a>*-*-freebsd*
</h3>
366 <p>The version of binutils installed in
<span class=
"file">/usr/bin
</span> probably works with
367 this release of GCC. However, on FreeBSD
4, bootstrapping against the
368 latest FSF binutils is known to improve overall testsuite results; and,
369 on FreeBSD/alpha, using binutils
2.14 or later is required to build libjava.
371 <p>Support for FreeBSD
1 was discontinued in GCC
3.2.
373 <p>Support for FreeBSD
2 will be discontinued after GCC
3.4. The
374 following was true for GCC
3.1 but the current status is unknown.
375 For FreeBSD
2 or any mutant a.out versions of FreeBSD
3: All
376 configuration support and files as shipped with GCC
2.95 are still in
377 place. FreeBSD
2.2.7 has been known to bootstrap completely; however,
378 it is unknown which version of binutils was used (it is assumed that it
379 was the system copy in
<span class=
"file">/usr/bin
</span>) and C++ EH failures were noted.
381 <p>For FreeBSD using the ELF file format: DWARF
2 debugging is now the
382 default for all CPU architectures. It had been the default on
383 FreeBSD/alpha since its inception. You may use
<span class=
"option">-gstabs
</span> instead
384 of
<span class=
"option">-g
</span>, if you really want the old debugging format. There are
385 no known issues with mixing object files and libraries with different
386 debugging formats. Otherwise, this release of GCC should now match more
387 of the configuration used in the stock FreeBSD configuration of GCC. In
388 particular,
<span class=
"option">--enable-threads
</span> is now configured by default.
389 However, as a general user, do not attempt to replace the system
390 compiler with this release. Known to bootstrap and check with good
391 results on FreeBSD
4.9-STABLE and
5-CURRENT. In the past, known to
392 bootstrap and check with good results on FreeBSD
3.0,
3.4,
4.0,
4.2,
393 4.3,
4.4,
4.5,
4.8-STABLE.
395 <p>In principle,
<span class=
"option">--enable-threads
</span> is now compatible with
396 <span class=
"option">--enable-libgcj
</span> on FreeBSD. However, it has only been built
397 and tested on
<span class=
"samp">i386-*-freebsd[
45]
</span> and
<span class=
"samp">alpha-*-freebsd[
45]
</span>.
399 library may be incorrectly built (symbols are missing at link time).
400 There is a rare timing-based startup hang (probably involves an
401 assumption about the thread library). Multi-threaded boehm-gc (required for
402 libjava) exposes severe threaded signal-handling bugs on FreeBSD before
403 4.5-RELEASE. Other CPU architectures
404 supported by FreeBSD will require additional configuration tuning in, at
405 the very least, both boehm-gc and libffi.
407 <p>Shared
<span class=
"file">libgcc_s.so
</span> is now built and installed by default.
411 <h3 class=
"heading"><a name=
"TOC14"></a><a name=
"h8300_002dhms"></a>h8300-hms
</h3>
413 <p>Renesas H8/
300 series of processors.
415 <p>Please have a look at the
<a href=
"binaries.html">binaries page
</a>.
417 <p>The calling convention and structure layout has changed in release
2.6.
418 All code must be recompiled. The calling convention now passes the
419 first three arguments in function calls in registers. Structures are no
420 longer a multiple of
2 bytes.
424 <h3 class=
"heading"><a name=
"TOC15"></a><a name=
"hppa_002a_002dhp_002dhpux_002a"></a>hppa*-hp-hpux*
</h3>
426 <p>Support for HP-UX version
9 and older was discontinued in GCC
3.4.
428 <p>We
<em>highly
</em> recommend using gas/binutils
2.8 or newer on all hppa
429 platforms; you may encounter a variety of problems when using the HP
432 <p>Specifically,
<span class=
"option">-g
</span> does not work on HP-UX (since that system
433 uses a peculiar debugging format which GCC does not know about), unless you
434 use GAS and GDB and configure GCC with the
435 <a href=
"./configure.html#with-gnu-as"><span class=
"option">--with-gnu-as
</span></a> and
436 <span class=
"option">--with-as=...
</span> options.
438 <p>If you wish to use the pa-risc
2.0 architecture support with a
32-bit
439 runtime, you must use either the HP assembler, or gas/binutils
2.11
442 <p>There are two default scheduling models for instructions. These are
443 PROCESSOR_7100LC and PROCESSOR_8000. They are selected from the pa-risc
444 architecture specified for the target machine when configuring.
445 PROCESSOR_8000 is the default. PROCESSOR_7100LC is selected when
446 the target is a
<span class=
"samp">hppa1*
</span> machine.
448 <p>The PROCESSOR_8000 model is not well suited to older processors. Thus,
449 it is important to completely specify the machine architecture when
450 configuring if you want a model other than PROCESSOR_8000. The macro
451 TARGET_SCHED_DEFAULT can be defined in BOOT_CFLAGS if a different
452 default scheduling model is desired.
454 <p>More specific information to
<span class=
"samp">hppa*-hp-hpux*
</span> targets follows.
458 <h3 class=
"heading"><a name=
"TOC16"></a><a name=
"hppa_002a_002dhp_002dhpux10"></a>hppa*-hp-hpux10
</h3>
460 <p>For hpux10.20, we
<em>highly
</em> recommend you pick up the latest sed patch
461 <code>PHCO_19798
</code> from HP. HP has two sites which provide patches free of
465 <li><a href=
"http://us.itrc.hp.com/service/home/home.do">US, Canada, Asia-Pacific, and
466 Latin-America
</a><li><a href=
"http://europe.itrc.hp.com/service/home/home.do">http://europe.itrc.hp.com/service/home/home.do
</a> Europe.
469 <p>The HP assembler on these systems has some problems. Most notably the
470 assembler inserts timestamps into each object file it creates, causing
471 the
3-stage comparison test to fail during a
<span class=
"samp">make bootstrap
</span>.
472 You should be able to continue by saying
<span class=
"samp">make all
</span> after getting
473 the failure from
<span class=
"samp">make bootstrap
</span>.
477 <h3 class=
"heading"><a name=
"TOC17"></a><a name=
"hppa_002a_002dhp_002dhpux11"></a>hppa*-hp-hpux11
</h3>
479 <p>GCC
3.0 and up support HP-UX
11. GCC
2.95.x is not supported and cannot
480 be used to compile GCC
3.0 and up.
482 <p>Refer to
<a href=
"binaries.html">binaries
</a> for information about obtaining
483 precompiled GCC binaries for HP-UX. Precompiled binaries must be obtained
484 to build the Ada language as it can't be bootstrapped using C. Ada is
485 only available for the
32-bit PA-RISC runtime. The libffi and libjava
486 haven't been ported to HP-UX and don't build.
488 <p>It is possible to build GCC
3.3 starting with the bundled HP compiler,
489 but the process requires several steps. GCC
3.3 can then be used to
490 build later versions. The fastjar program contains ISO C code and
491 can't be built with the HP bundled compiler. This problem can be
492 avoided by not building the Java language. For example, use the
493 <span class=
"option">--enable-languages=
"c,c++,f77,objc"</span> option in your configure
496 <p>Starting with GCC
3.4 an ISO C compiler is required to bootstrap. The
497 bundled compiler supports only traditional C; you will need either HP's
498 unbundled compiler, or a binary distribution of GCC.
500 <p>There are several possible approaches to building the distribution.
501 Binutils can be built first using the HP tools. Then, the GCC
502 distribution can be built. The second approach is to build GCC
503 first using the HP tools, then build binutils, then rebuild GCC.
504 There have been problems with various binary distributions, so it
505 is best not to start from a binary distribution.
507 <p>On
64-bit capable systems, there are two distinct targets. Different
508 installation prefixes must be used if both are to be installed on
509 the same system. The
<span class=
"samp">hppa[
1-
2]*-hp-hpux11*
</span> target generates code
510 for the
32-bit PA-RISC runtime architecture and uses the HP linker.
511 The
<span class=
"samp">hppa64-hp-hpux11*
</span> target generates
64-bit code for the
512 PA-RISC
2.0 architecture. The HP and GNU linkers are both supported
515 <p>The script config.guess now selects the target type based on the compiler
516 detected during configuration. You must define
<span class=
"env">PATH
</span> or
<span class=
"env">CC
</span> so
517 that configure finds an appropriate compiler for the initial bootstrap.
518 When
<span class=
"env">CC
</span> is used, the definition should contain the options that are
519 needed whenever
<span class=
"env">CC
</span> is used.
521 <p>Specifically, options that determine the runtime architecture must be
522 in
<span class=
"env">CC
</span> to correctly select the target for the build. It is also
523 convenient to place many other compiler options in
<span class=
"env">CC
</span>. For example,
524 <span class=
"env">CC=
"cc -Ac +DA2.0W -Wp,-H16376 -D_CLASSIC_TYPES -D_HPUX_SOURCE"</span>
525 can be used to bootstrap the GCC
3.3 branch with the HP compiler in
526 64-bit K
&R/bundled mode. The
<span class=
"option">+DA2.0W
</span> option will result in
527 the automatic selection of the
<span class=
"samp">hppa64-hp-hpux11*
</span> target. The
528 macro definition table of cpp needs to be increased for a successful
529 build with the HP compiler. _CLASSIC_TYPES and _HPUX_SOURCE need to
530 be defined when building with the bundled compiler, or when using the
531 <span class=
"option">-Ac
</span> option. These defines aren't necessary with
<span class=
"option">-Ae
</span>.
533 <p>It is best to explicitly configure the
<span class=
"samp">hppa64-hp-hpux11*
</span> target
534 with the
<span class=
"option">--with-ld=...
</span> option. This overrides the standard
535 search for ld. The two linkers supported on this target require different
536 commands. The default linker is determined during configuration. As a
537 result, it's not possible to switch linkers in the middle of a GCC build.
538 This has been been reported to sometimes occur in unified builds of
541 <p>With GCC
3.0 through
3.2, you must use binutils
2.11 or above. As of
542 GCC
3.3, binutils
2.14 or later is required.
544 <p>Although the HP assembler can be used for an initial build, it shouldn't
545 be used with any languages other than C and perhaps Fortran due to its
546 many limitations. For example, it does not support weak symbols or alias
547 definitions. As a result, explicit template instantiations are required
548 when using C++. This makes it difficult if not impossible to build many
549 C++ applications. You can't generate debugging information when using
550 the HP assembler. Finally,
<span class=
"samp">make bootstrap
</span> fails in the final
551 comparison of object modules due to the time stamps that it inserts into
552 the modules. The bootstrap can be continued from this point with
553 <span class=
"samp">make all
</span>.
555 <p>A recent linker patch must be installed for the correct operation of
556 GCC
3.3 and later.
<code>PHSS_26559
</code> and
<code>PHSS_24304
</code> are the
557 oldest linker patches that are known to work. They are for HP-UX
558 11.00 and
11.11, respectively.
<code>PHSS_24303
</code>, the companion to
559 <code>PHSS_24304
</code>, might be usable but it hasn't been tested. These
560 patches have been superseded. Consult the HP patch database to obtain
561 the currently recommended linker patch for your system.
563 <p>The patches are necessary for the support of weak symbols on the
564 32-bit port, and for the running of initializers and finalizers. Weak
565 symbols are implemented using SOM secondary definition symbols. Prior
566 to HP-UX
11, there are bugs in the linker support for secondary symbols.
567 The patches correct a problem of linker core dumps creating shared
568 libraries containing secondary symbols, as well as various other
569 linking issues involving secondary symbols.
571 <p>GCC
3.3 uses the ELF DT_INIT_ARRAY and DT_FINI_ARRAY capabilities to
572 run initializers and finalizers on the
64-bit port. The
32-bit port
573 uses the linker
<span class=
"option">+init
</span> and
<span class=
"option">+fini
</span> options for the same
574 purpose. The patches correct various problems with the +init/+fini
575 options, including program core dumps. Binutils
2.14 corrects a
576 problem on the
64-bit port resulting from HP's non-standard use of
577 the .init and .fini sections for array initializers and finalizers.
579 <p>There are a number of issues to consider in selecting which linker to
580 use with the
64-bit port. The GNU
64-bit linker can only create dynamic
581 binaries. The
<span class=
"option">-static
</span> option causes linking with archive
582 libraries but doesn't produce a truly static binary. Dynamic binaries
583 still require final binding by the dynamic loader to resolve a set of
584 dynamic-loader-defined symbols. The default behavior of the HP linker
585 is the same as the GNU linker. However, it can generate true
64-bit
586 static binaries using the
<span class=
"option">+compat
</span> option.
588 <p>The HP
64-bit linker doesn't support linkonce semantics. As a
589 result, C++ programs have many more sections than they should.
591 <p>The GNU
64-bit linker has some issues with shared library support
592 and exceptions. As a result, we only support libgcc in archive
593 format. For similar reasons, dwarf2 unwind and exception support
594 are disabled. The GNU linker also has problems creating binaries
595 with
<span class=
"option">-static
</span>. It doesn't provide stubs for internal
596 calls to global functions in shared libraries, so these calls
599 <p>Thread support is not implemented in GCC
3.0 through
3.2, so the
600 <span class=
"option">--enable-threads
</span> configure option does not work. In
3.3
601 and later, POSIX threads are supported. The optional DCE thread
602 library is not supported.
604 <p>This port still is undergoing significant development.
608 <h3 class=
"heading"><a name=
"TOC18"></a><a name=
"i370_002d_002a_002d_002a"></a>i370-*-*
</h3>
610 <p>This port is very preliminary and has many known bugs. We hope to
611 have a higher-quality port for this machine soon.
615 <h3 class=
"heading"><a name=
"TOC19"></a><a name=
"_002a_002d_002a_002dlinux_002dgnu"></a>*-*-linux-gnu
</h3>
617 <p>Versions of libstdc++-v3 starting with
3.2.1 require bugfixes present
618 in glibc
2.2.5 and later. More information is available in the
619 libstdc++-v3 documentation.
623 <h3 class=
"heading"><a name=
"TOC20"></a><a name=
"ix86_002d_002a_002dlinux_002aaout"></a>i?
86-*-linux*aout
</h3>
625 <p>Use this configuration to generate
<span class=
"file">a.out
</span> binaries on Linux-based
626 GNU systems. This configuration is being superseded.
630 <h3 class=
"heading"><a name=
"TOC21"></a><a name=
"ix86_002d_002a_002dlinux_002a"></a>i?
86-*-linux*
</h3>
632 <p>As of GCC
3.3, binutils
2.13.1 or later is required for this platform.
633 See
<a href=
"http://gcc.gnu.org/PR10877">bug
10877</a> for more information.
635 <p>If you receive Signal
11 errors when building on GNU/Linux, then it is
636 possible you have a hardware problem. Further information on this can be
637 found on
<a href=
"http://www.bitwizard.nl/sig11/">www.bitwizard.nl
</a>.
639 <p>Some recent versions of GNU/Linux, such as Fedora Core
1, support
640 exec-shield-randomize. Turning this on interferes with precompiled
641 headers. If you need to use precompiled headers,
642 exec-shield-randomize can be turned off for the entire system by
643 editing
<span class=
"file">/etc/sysctl.conf
</span> and adding a line:
644 <pre class=
"smallexample"> kernel.exec-shield-randomize =
0
646 <p>You may then need to run
<span class=
"samp">sysctl -p
</span>.
648 <p>This will be fixed in future releases of GCC.
652 <h3 class=
"heading"><a name=
"TOC22"></a><a name=
"ix86_002d_002a_002dsco3_002e2v5_002a"></a>i?
86-*-sco3.2v5*
</h3>
654 <p>Use this for the SCO OpenServer Release
5 family of operating systems.
656 <p>Unlike earlier versions of GCC, the ability to generate COFF with this
657 target is no longer provided.
659 <p>Earlier versions of GCC emitted DWARF
1 when generating ELF to allow
660 the system debugger to be used. That support was too burdensome to
661 maintain. GCC now emits only DWARF
2 for this target. This means you
662 may use either the UDK debugger or GDB to debug programs built by this
665 <p>GCC is now only supported on releases
5.0.4 and later, and requires that
666 you install Support Level Supplement OSS646B or later, and Support Level
667 Supplement OSS631C or later. If you are using release
5.0.7 of
668 OpenServer, you must have at least the first maintenance pack installed
669 (this includes the relevant portions of OSS646). OSS646, also known as
670 the
"Execution Environment Update", provides updated link editors and
671 assemblers, as well as updated standard C and math libraries. The C
672 startup modules are also updated to support the System V gABI draft, and
673 GCC relies on that behavior. OSS631 provides a collection of commonly
674 used open source libraries, some of which GCC depends on (such as GNU
675 gettext and zlib). SCO OpenServer Release
5.0.7 has all of this built
676 in by default, but OSS631C and later also apply to that release. Please
678 <a href=
"ftp://ftp.sco.com/pub/openserver5">ftp://ftp.sco.com/pub/openserver5
</a>
679 for the latest versions of these (and other potentially useful)
682 <p>Although there is support for using the native assembler, it is
683 recommended that you configure GCC to use the GNU assembler. You do
684 this by using the flags
685 <a href=
"./configure.html#with-gnu-as"><span class=
"option">--with-gnu-as
</span></a>. You should
686 use a modern version of GNU binutils. Version
2.13.2.1 was used for all
687 testing. In general, only the
<span class=
"option">--with-gnu-as
</span> option is tested.
688 A modern bintuils (as well as a plethora of other development related
689 GNU utilities) can be found in Support Level Supplement OSS658A, the
690 "GNU Development Tools" package. See the SCO web and ftp sites for details.
691 That package also contains the currently
"officially supported" version of
692 GCC, version
2.95.3. It is useful for bootstrapping this version.
696 <h3 class=
"heading"><a name=
"TOC23"></a><a name=
"ix86_002d_002a_002dudk"></a>i?
86-*-udk
</h3>
698 <p>This target emulates the SCO Universal Development Kit and requires that
699 package be installed. (If it is installed, you will have a
700 <span class=
"file">/udk/usr/ccs/bin/cc
</span> file present.) It's very much like the
701 <span class=
"samp">i?
86-*-unixware7*
</span> target
702 but is meant to be used when hosting on a system where UDK isn't the
703 default compiler such as OpenServer
5 or Unixware
2. This target will
704 generate binaries that will run on OpenServer, Unixware
2, or Unixware
7,
705 with the same warnings and caveats as the SCO UDK.
707 <p>This target is a little tricky to build because we have to distinguish
708 it from the native tools (so it gets headers, startups, and libraries
709 from the right place) while making the tools not think we're actually
710 building a cross compiler. The easiest way to do this is with a configure
713 <pre class=
"smallexample"> CC=/udk/usr/ccs/bin/cc
<var>/your/path/to
</var>/gcc/configure \
714 --host=i686-pc-udk --target=i686-pc-udk --program-prefix=udk-
716 <p><em>You should substitute
</em><span class=
"samp">i686
</span><em> in the above command with the appropriate
717 processor for your host.
</em>
719 <p>After the usual
<span class=
"samp">make bootstrap
</span> and
720 <span class=
"samp">make install
</span>, you can then access the UDK-targeted GCC
721 tools by adding
<span class=
"command">udk-
</span> before the commonly known name. For
722 example, to invoke the C compiler, you would use
<span class=
"command">udk-gcc
</span>.
723 They will coexist peacefully with any native-target GCC tools you may
728 <h3 class=
"heading"><a name=
"TOC24"></a><a name=
"ia64_002d_002a_002dlinux"></a>ia64-*-linux
</h3>
730 <p>IA-
64 processor (also known as IPF, or Itanium Processor Family)
733 <p>If you are using the optional libunwind library, then you must use
734 libunwind
0.96 or later.
736 <p>None of the following versions of GCC has an ABI that is compatible
737 with any of the other versions in this list, with the exception that
738 Red Hat
2.96 and Trillian
000171 are compatible with each other:
739 3.1,
3.0.2,
3.0.1,
3.0, Red Hat
2.96, and Trillian
000717.
740 This primarily affects C++ programs and programs that create shared libraries.
741 GCC
3.1 or later is recommended for compiling linux, the kernel.
742 As of version
3.1 GCC is believed to be fully ABI compliant, and hence no
743 more major ABI changes are expected.
747 <h3 class=
"heading"><a name=
"TOC25"></a><a name=
"ia64_002d_002a_002dhpux_002a"></a>ia64-*-hpux*
</h3>
749 <p>Building GCC on this target requires the GNU Assembler. The bundled HP
750 assembler will not work. To prevent GCC from using the wrong assembler,
751 the option
<span class=
"option">--with-gnu-as
</span> may be necessary.
753 <p>The GCC libunwind library has not been ported to HPUX. This means that for
754 GCC versions
3.2.3 and earlier,
<span class=
"option">--enable-libunwind-exceptions
</span>
755 is required to build GCC. For GCC
3.3 and later, this is the default.
758 <!-- rs6000-ibm-aix*, powerpc-ibm-aix* -->
760 <h3 class=
"heading"><a name=
"TOC26"></a><a name=
"_002a_002dibm_002daix_002a"></a>*-ibm-aix*
</h3>
762 <p>Support for AIX version
3 and older was discontinued in GCC
3.4.
764 <p>AIX Make frequently has problems with GCC makefiles. GNU Make
3.79.1 or
765 newer is recommended to build on this platform.
767 <p>To speed up the configuration phases of bootstrapping and installing GCC,
768 one may use GNU Bash instead of AIX
<span class=
"command">/bin/sh
</span>, e.g.,
770 <pre class=
"smallexample"> % CONFIG_SHELL=/opt/freeware/bin/bash
771 % export CONFIG_SHELL
773 <p>and then proceed as described in
<a href=
"build.html">the build instructions
</a>,
774 where we strongly recommend using GNU make and specifying an absolute path
775 to invoke
<var>srcdir
</var>/configure.
777 <p>Errors involving
<code>alloca
</code> when building GCC generally are due
778 to an incorrect definition of
<code>CC
</code> in the Makefile or mixing files
779 compiled with the native C compiler and GCC. During the stage1 phase of
780 the build, the native AIX compiler
<strong>must
</strong> be invoked as
<span class=
"command">cc
</span>
781 (not
<span class=
"command">xlc
</span>). Once
<span class=
"command">configure
</span> has been informed of
782 <span class=
"command">xlc
</span>, one needs to use
<span class=
"samp">make distclean
</span> to remove the
783 configure cache files and ensure that
<span class=
"env">CC
</span> environment variable
784 does not provide a definition that will confuse
<span class=
"command">configure
</span>.
785 If this error occurs during stage2 or later, then the problem most likely
786 is the version of Make (see above).
788 <p>The native
<span class=
"command">as
</span> and
<span class=
"command">ld
</span> are recommended for bootstrapping
789 on AIX
4 and required for bootstrapping on AIX
5L. The GNU Assembler
790 reports that it supports WEAK symbols on AIX
4, which causes GCC to try to
791 utilize weak symbol functionality although it is not supported. The GNU
792 Assembler and Linker do not support AIX
5L sufficiently to bootstrap GCC.
793 The native AIX tools do interoperate with GCC.
795 <p>Building
<span class=
"file">libstdc++.a
</span> requires a fix for an AIX Assembler bug
796 APAR IY26685 (AIX
4.3) or APAR IY25528 (AIX
5.1). It also requires a
797 fix for another AIX Assembler bug and a co-dependent AIX Archiver fix
798 referenced as APAR IY53606 (AIX
5.2) or a APAR IY54774 (AIX
5.1)
800 <p><span class=
"samp">libstdc++
</span> in GCC
3.4 increments the major version number of the
801 shared object and GCC installation places the
<span class=
"file">libstdc++.a
</span>
802 shared library in a common location which will overwrite the and GCC
803 3.3 version of the shared library. Applications either need to be
804 re-linked against the new shared library or the GCC
3.1 and GCC
3.3
805 versions of the
<span class=
"samp">libstdc++
</span> shared object needs to be available
806 to the AIX runtime loader. The GCC
3.1 <span class=
"samp">libstdc++.so
.4</span>, if
807 present, and GCC
3.3 <span class=
"samp">libstdc++.so
.5</span> shared objects can be
808 installed for runtime dynamic loading using the following steps to set
809 the
<span class=
"samp">F_LOADONLY
</span> flag in the shared object for
<em>each
</em>
810 multilib
<span class=
"file">libstdc++.a
</span> installed:
812 <p>Extract the shared objects from the currently installed
813 <span class=
"file">libstdc++.a
</span> archive:
814 <pre class=
"smallexample"> % ar -x libstdc++.a libstdc++.so
.4 libstdc++.so
.5
816 <p>Enable the
<span class=
"samp">F_LOADONLY
</span> flag so that the shared object will be
817 available for runtime dynamic loading, but not linking:
818 <pre class=
"smallexample"> % strip -e libstdc++.so
.4 libstdc++.so
.5
820 <p>Archive the runtime-only shared object in the GCC
3.4
821 <span class=
"file">libstdc++.a
</span> archive:
822 <pre class=
"smallexample"> % ar -q libstdc++.a libstdc++.so
.4 libstdc++.so
.5
824 <p>Linking executables and shared libraries may produce warnings of
825 duplicate symbols. The assembly files generated by GCC for AIX always
826 have included multiple symbol definitions for certain global variable
827 and function declarations in the original program. The warnings should
828 not prevent the linker from producing a correct library or runnable
831 <p>AIX
4.3 utilizes a
“large format
” archive to support both
32-bit and
832 64-bit object modules. The routines provided in AIX
4.3.0 and AIX
4.3.1
833 to parse archive libraries did not handle the new format correctly.
834 These routines are used by GCC and result in error messages during
835 linking such as
“not a COFF file
”. The version of the routines shipped
836 with AIX
4.3.1 should work for a
32-bit environment. The
<span class=
"option">-g
</span>
837 option of the archive command may be used to create archives of
32-bit
838 objects using the original
“small format
”. A correct version of the
839 routines is shipped with AIX
4.3.2 and above.
841 <p>Some versions of the AIX binder (linker) can fail with a relocation
842 overflow severe error when the
<span class=
"option">-bbigtoc
</span> option is used to link
843 GCC-produced object files into an executable that overflows the TOC. A fix
844 for APAR IX75823 (OVERFLOW DURING LINK WHEN USING GCC AND -BBIGTOC) is
845 available from IBM Customer Support and from its
846 <a href=
"http://techsupport.services.ibm.com/">techsupport.services.ibm.com
</a>
847 website as PTF U455193.
849 <p>The AIX
4.3.2.1 linker (bos.rte.bind_cmds Level
4.3.2.1) will dump core
850 with a segmentation fault when invoked by any version of GCC. A fix for
851 APAR IX87327 is available from IBM Customer Support and from its
852 <a href=
"http://techsupport.services.ibm.com/">techsupport.services.ibm.com
</a>
853 website as PTF U461879. This fix is incorporated in AIX
4.3.3 and above.
855 <p>The initial assembler shipped with AIX
4.3.0 generates incorrect object
856 files. A fix for APAR IX74254 (
64BIT DISASSEMBLED OUTPUT FROM COMPILER FAILS
857 TO ASSEMBLE/BIND) is available from IBM Customer Support and from its
858 <a href=
"http://techsupport.services.ibm.com/">techsupport.services.ibm.com
</a>
859 website as PTF U453956. This fix is incorporated in AIX
4.3.1 and above.
861 <p>AIX provides National Language Support (NLS). Compilers and assemblers
862 use NLS to support locale-specific representations of various data
863 formats including floating-point numbers (e.g.,
<span class=
"samp">.
</span> vs
<span class=
"samp">,
</span> for
864 separating decimal fractions). There have been problems reported where
865 GCC does not produce the same floating-point formats that the assembler
866 expects. If one encounters this problem, set the
<span class=
"env">LANG
</span>
867 environment variable to
<span class=
"samp">C
</span> or
<span class=
"samp">En_US
</span>.
869 <p>By default, GCC for AIX
4.1 and above produces code that can be used on
870 both Power or PowerPC processors.
872 <p>A default can be specified with the
<span class=
"option">-mcpu=
</span><var>cpu_type
</var>
873 switch and using the configure option
<span class=
"option">--with-cpu-
</span><var>cpu_type
</var>.
877 <h3 class=
"heading"><a name=
"TOC27"></a><a name=
"ip2k_002d_002a_002delf"></a>ip2k-*-elf
</h3>
879 <p>Ubicom IP2022 micro controller.
880 This configuration is intended for embedded systems.
881 There are no standard Unix configurations.
883 <p>Use
<span class=
"samp">configure --target=ip2k-elf --enable-languages=c
</span> to configure GCC.
887 <h3 class=
"heading"><a name=
"TOC28"></a><a name=
"iq2000_002d_002a_002delf"></a>iq2000-*-elf
</h3>
889 <p>Vitesse IQ2000 processors. These are used in embedded
890 applications. There are no standard Unix configurations.
894 <h3 class=
"heading"><a name=
"TOC29"></a><a name=
"m32r_002d_002a_002delf"></a>m32r-*-elf
</h3>
896 <p>Renesas M32R processor.
897 This configuration is intended for embedded systems.
901 <h3 class=
"heading"><a name=
"TOC30"></a><a name=
"m6811_002delf"></a>m6811-elf
</h3>
903 <p>Motorola
68HC11 family micro controllers. These are used in embedded
904 applications. There are no standard Unix configurations.
908 <h3 class=
"heading"><a name=
"TOC31"></a><a name=
"m6812_002delf"></a>m6812-elf
</h3>
910 <p>Motorola
68HC12 family micro controllers. These are used in embedded
911 applications. There are no standard Unix configurations.
915 <h3 class=
"heading"><a name=
"TOC32"></a><a name=
"m68k_002dhp_002dhpux"></a>m68k-hp-hpux
</h3>
917 <p>HP
9000 series
300 or
400 running HP-UX. HP-UX version
8.0 has a bug in
918 the assembler that prevents compilation of GCC. This
919 bug manifests itself during the first stage of compilation, while
920 building
<span class=
"file">libgcc2.a
</span>:
922 <pre class=
"smallexample"> _floatdisf
923 cc1: warning: `-g' option not supported on this version of GCC
924 cc1: warning: `-g1' option not supported on this version of GCC
925 ./xgcc: Internal compiler error: program as got fatal signal
11
927 <p>A patched version of the assembler is available as the file
928 <a href=
"ftp://altdorf.ai.mit.edu/archive/cph/hpux-8.0-assembler">ftp://altdorf.ai.mit.edu/archive/cph/hpux-
8.0-assembler
</a>. If you
929 have HP software support, the patch can also be obtained directly from
930 HP, as described in the following note:
933 This is the patched assembler, to patch SR#
1653-
010439, where the
934 assembler aborts on floating point constants.
936 <p>The bug is not really in the assembler, but in the shared library
937 version of the function
“cvtnum(
3c)
”. The bug on
“cvtnum(
3c)
” is
938 SR#
4701-
078451. Anyway, the attached assembler uses the archive
939 library version of
“cvtnum(
3c)
” and thus does not exhibit the bug.
942 <p>This patch is also known as PHCO_4484.
944 <p>In addition gdb does not understand that native HP-UX format, so
945 you must use gas if you wish to use gdb.
947 <p>On HP-UX version
8.05, but not on
8.07 or more recent versions, the
948 <span class=
"command">fixproto
</span> shell script triggers a bug in the system shell. If you
949 encounter this problem, upgrade your operating system or use BASH (the
950 GNU shell) to run
<span class=
"command">fixproto
</span>. This bug will cause the fixproto
951 program to report an error of the form:
953 <pre class=
"smallexample"> ./fixproto: sh internal
1K buffer overflow
955 <p>To fix this, you can also change the first line of the fixproto script
958 <pre class=
"smallexample"> #!/bin/ksh
962 <h3 class=
"heading"><a name=
"TOC33"></a><a name=
"mips_002d_002a_002d_002a"></a>mips-*-*
</h3>
964 <p>If on a MIPS system you get an error message saying
“does not have gp
965 sections for all it's [sic] sectons [sic]
”, don't worry about it. This
966 happens whenever you use GAS with the MIPS linker, but there is not
967 really anything wrong, and it is okay to use the output file. You can
968 stop such warnings by installing the GNU linker.
970 <p>It would be nice to extend GAS to produce the gp tables, but they are
971 optional, and there should not be a warning about their absence.
973 <p>The libstdc++ atomic locking routines for MIPS targets requires MIPS II
974 and later. A patch went in just after the GCC
3.3 release to
975 make
<span class=
"samp">mips*-*-*
</span> use the generic implementation instead. You can also
976 configure for
<span class=
"samp">mipsel-elf
</span> as a workaround. The
977 <span class=
"samp">mips*-*-linux*
</span> target continues to use the MIPS II routines. More
978 work on this is expected in future releases.
980 <p>Cross-compilers for the Mips as target using the Mips assembler
981 currently do not work, because the auxiliary programs
982 <span class=
"file">mips-tdump.c
</span> and
<span class=
"file">mips-tfile.c
</span> can't be compiled on
983 anything but a Mips. It does work to cross compile for a Mips
984 if you use the GNU assembler and linker.
988 <h3 class=
"heading"><a name=
"TOC34"></a><a name=
"mips_002dsgi_002dirix5"></a>mips-sgi-irix5
</h3>
990 <p>In order to compile GCC on an SGI running IRIX
5, the
<span class=
"samp">compiler_dev.hdr
</span>
991 subsystem must be installed from the IDO CD-ROM supplied by SGI.
992 It is also available for download from
993 <a href=
"ftp://ftp.sgi.com/sgi/IRIX5.3/iris-development-option-5.3.tardist">ftp://ftp.sgi.com/sgi/IRIX5.3/iris-development-option-
5.3.tardist
</a>.
995 <p>If you use the MIPS C compiler to bootstrap, it may be necessary
996 to increase its table size for switch statements with the
997 <span class=
"option">-Wf,-XNg1500
</span> option. If you use the
<span class=
"option">-O2
</span>
998 optimization option, you also need to use
<span class=
"option">-Olimit
3000</span>.
1000 <p>To enable debugging under IRIX
5, you must use GNU binutils
2.15 or
1001 later, and use the
<span class=
"option">--with-gnu-as
</span> and
<span class=
"option">--with-gnu-ld
</span>
1002 <span class=
"command">configure
</span> options when configuring GCC. You need to use GNU
1003 <span class=
"command">ar
</span> and
<span class=
"command">nm
</span>, also distributed with GNU binutils.
1007 <h3 class=
"heading"><a name=
"TOC35"></a><a name=
"mips_002dsgi_002dirix6"></a>mips-sgi-irix6
</h3>
1009 <p>If you are using SGI's MIPSpro
<span class=
"command">cc
</span> as your bootstrap compiler, you must
1010 ensure that the N32 ABI is in use. To test this, compile a simple C
1011 file with
<span class=
"command">cc
</span> and then run
<span class=
"command">file
</span> on the
1012 resulting object file. The output should look like:
1014 <pre class=
"smallexample"> test.o: ELF N32 MSB ...
1018 <pre class=
"smallexample"> test.o: ELF
32-bit MSB ...
1022 <pre class=
"smallexample"> test.o: ELF
64-bit MSB ...
1024 <p>then your version of
<span class=
"command">cc
</span> uses the O32 or N64 ABI by default. You
1025 should set the environment variable
<span class=
"env">CC
</span> to
<span class=
"samp">cc -n32
</span>
1026 before configuring GCC. SGI's MIPSpro
7.2 assembler may misassemble
1027 parts of the compiler, causing bootstrap failures. MIPSpro
7.3 is
1028 known to work. MIPSpro C
7.4 may cause bootstrap failures, too, due
1029 to a bug when inlining
<code>memcmp
</code>. Either add
<code>-U__INLINE_INTRINSICS
</code>
1030 to the
<span class=
"env">CC
</span> environment variable as a workaround or upgrade to
1033 <p>If you want the resulting
<span class=
"command">gcc
</span> to run on old
32-bit systems
1034 with the MIPS R4400 CPU, you need to ensure that only code for the
<span class=
"samp">mips3
</span>
1035 instruction set architecture (ISA) is generated. While GCC
3.x does
1036 this correctly, both GCC
2.95 and SGI's MIPSpro
<span class=
"command">cc
</span> may change
1037 the ISA depending on the machine where GCC is built. Using one of them
1038 as the bootstrap compiler may result in
<span class=
"samp">mips4
</span> code, which won't run at
1039 all on
<span class=
"samp">mips3
</span>-only systems. For the test program above, you should see:
1041 <pre class=
"smallexample"> test.o: ELF N32 MSB mips-
3 ...
1045 <pre class=
"smallexample"> test.o: ELF N32 MSB mips-
4 ...
1047 <p>instead, you should set the environment variable
<span class=
"env">CC
</span> to
<span class=
"samp">cc
1048 -n32 -mips3
</span> or
<span class=
"samp">gcc -mips3
</span> respectively before configuring GCC.
1050 <p>GCC on IRIX
6 is usually built to support the N32, O32 and N64 ABIs. If
1051 you build GCC on a system that doesn't have the N64 libraries installed
1052 or cannot run
64-bit binaries,
1053 you need to configure with
<span class=
"option">--disable-multilib
</span> so GCC doesn't
1054 try to use them. This will disable building the O32 libraries, too.
1055 Look for
<span class=
"file">/usr/lib64/libc.so
.1</span> to see if you
1056 have the
64-bit libraries installed.
1058 <p>To enable debugging for the O32 ABI, you must use GNU
<span class=
"command">as
</span> from
1059 GNU binutils
2.15 or later. You may also use GNU
<span class=
"command">ld
</span>, but
1060 this is not required and currently causes some problems with Ada.
1062 <p>The
<span class=
"option">--enable-threads
</span> option doesn't currently work, a patch is
1063 in preparation for a future release. The
<span class=
"option">--enable-libgcj
</span>
1064 option is disabled by default: IRIX
6 uses a very low default limit
1065 (
20480) for the command line length. Although
<span class=
"command">libtool
</span> contains a
1066 workaround for this problem, at least the N64
<span class=
"samp">libgcj
</span> is known not
1067 to build despite this, running into an internal error of the native
1068 <span class=
"command">ld
</span>. A sure fix is to increase this limit (
<span class=
"samp">ncargs
</span>) to
1069 its maximum of
262144 bytes. If you have root access, you can use the
1070 <span class=
"command">systune
</span> command to do this.
1072 <p>See
<a href=
"http://freeware.sgi.com/">http://freeware.sgi.com/
</a> for more
1073 information about using GCC on IRIX platforms.
1077 <h3 class=
"heading"><a name=
"TOC36"></a><a name=
"powerpc_002a_002d_002a_002d_002a"></a>powerpc-*-*
</h3>
1079 <p>You can specify a default version for the
<span class=
"option">-mcpu=
</span><var>cpu_type
</var>
1080 switch by using the configure option
<span class=
"option">--with-cpu-
</span><var>cpu_type
</var>.
1084 <h3 class=
"heading"><a name=
"TOC37"></a><a name=
"powerpc_002d_002a_002ddarwin_002a"></a>powerpc-*-darwin*
</h3>
1086 <p>PowerPC running Darwin (Mac OS X kernel).
1088 <p>Pre-installed versions of Mac OS X may not include any developer tools,
1089 meaning that you will not be able to build GCC from source. Tool
1090 binaries are available at
1091 <a href=
"http://developer.apple.com/tools/compilers.html">http://developer.apple.com/tools/compilers.html
</a> (free
1092 registration required).
1094 <p>The default stack limit of
512K is too small, which may cause compiles
1095 to fail with 'Bus error'. Set the stack larger, for instance
1096 by doing
<span class=
"samp">limit stack
800</span>. It's a good idea to use the GNU
1097 preprocessor instead of Apple's
<span class=
"file">cpp-precomp
</span> during the first stage of
1098 bootstrapping; this is automatic when doing
<span class=
"samp">make bootstrap
</span>, but
1099 to do it from the toplevel objdir you will need to say
<span class=
"samp">make
1100 CC='cc -no-cpp-precomp' bootstrap
</span>.
1102 <p>The version of GCC shipped by Apple typically includes a number of
1103 extensions not available in a standard GCC release. These extensions
1104 are generally specific to Mac programming.
1108 <h3 class=
"heading"><a name=
"TOC38"></a><a name=
"powerpc_002d_002a_002delf"></a>powerpc-*-elf, powerpc-*-sysv4
</h3>
1110 <p>PowerPC system in big endian mode, running System V
.4.
1114 <h3 class=
"heading"><a name=
"TOC39"></a><a name=
"powerpc_002d_002a_002dlinux_002dgnu_002a"></a>powerpc-*-linux-gnu*
</h3>
1117 <a href=
"ftp://ftp.kernel.org/pub/linux/devel/binutils">binutils
2.13.90.0.10</a>
1118 or newer for a working GCC.
1122 <h3 class=
"heading"><a name=
"TOC40"></a><a name=
"powerpc_002d_002a_002dnetbsd_002a"></a>powerpc-*-netbsd*
</h3>
1124 <p>PowerPC system in big endian mode running NetBSD. To build the
1125 documentation you will need Texinfo version
4.2 (NetBSD
1.5.1 included
1126 Texinfo version
3.12).
1130 <h3 class=
"heading"><a name=
"TOC41"></a><a name=
"powerpc_002d_002a_002deabisim"></a>powerpc-*-eabisim
</h3>
1132 <p>Embedded PowerPC system in big endian mode for use in running under the
1137 <h3 class=
"heading"><a name=
"TOC42"></a><a name=
"powerpc_002d_002a_002deabi"></a>powerpc-*-eabi
</h3>
1139 <p>Embedded PowerPC system in big endian mode.
1143 <h3 class=
"heading"><a name=
"TOC43"></a><a name=
"powerpcle_002d_002a_002delf"></a>powerpcle-*-elf, powerpcle-*-sysv4
</h3>
1145 <p>PowerPC system in little endian mode, running System V
.4.
1149 <h3 class=
"heading"><a name=
"TOC44"></a><a name=
"powerpcle_002d_002a_002deabisim"></a>powerpcle-*-eabisim
</h3>
1151 <p>Embedded PowerPC system in little endian mode for use in running under
1156 <h3 class=
"heading"><a name=
"TOC45"></a><a name=
"powerpcle_002d_002a_002deabi"></a>powerpcle-*-eabi
</h3>
1158 <p>Embedded PowerPC system in little endian mode.
1162 <h3 class=
"heading"><a name=
"TOC46"></a><a name=
"s390_002d_002a_002dlinux_002a"></a>s390-*-linux*
</h3>
1164 <p>S/
390 system running GNU/Linux for S/
390.
1168 <h3 class=
"heading"><a name=
"TOC47"></a><a name=
"s390x_002d_002a_002dlinux_002a"></a>s390x-*-linux*
</h3>
1170 <p>zSeries system (
64-bit) running GNU/Linux for zSeries.
1174 <h3 class=
"heading"><a name=
"TOC48"></a><a name=
"s390x_002dibm_002dtpf_002a"></a>s390x-ibm-tpf*
</h3>
1176 <p>zSeries system (
64-bit) running TPF. This platform is
1177 supported as cross-compilation target only.
1179 <p><hr /><!-- Please use Solaris 2 to refer to all release of Solaris, starting -->
1180 <!-- with 2.0 until 2.6, 7, 8, etc. Solaris 1 was a marketing name for -->
1181 <!-- SunOS 4 releases which we don't use to avoid confusion. Solaris -->
1182 <!-- alone is too unspecific and must be avoided. -->
1184 <h3 class=
"heading"><a name=
"TOC49"></a><a name=
"_002a_002d_002a_002dsolaris2_002a"></a>*-*-solaris2*
</h3>
1186 <p>Sun does not ship a C compiler with Solaris
2. To bootstrap and install
1187 GCC you first have to install a pre-built compiler, see the
1188 <a href=
"binaries.html">binaries page
</a> for details.
1190 <p>The Solaris
2 <span class=
"command">/bin/sh
</span> will often fail to configure
1191 <span class=
"file">libstdc++-v3
</span>,
<span class=
"file">boehm-gc
</span> or
<span class=
"file">libjava
</span>. We therefore
1192 recommend to use the following sequence of commands to bootstrap and
1195 <pre class=
"smallexample"> % CONFIG_SHELL=/bin/ksh
1196 % export CONFIG_SHELL
1198 <p>and then proceed as described in
<a href=
"build.html">the build instructions
</a>.
1199 In addition we strongly recommend specifying an absolute path to invoke
1200 <var>srcdir
</var>/configure.
1202 <p>Solaris
2 comes with a number of optional OS packages. Some of these
1203 are needed to use GCC fully, namely
<code>SUNWarc
</code>,
1204 <code>SUNWbtool
</code>,
<code>SUNWesu
</code>,
<code>SUNWhea
</code>,
<code>SUNWlibm
</code>,
1205 <code>SUNWsprot
</code>, and
<code>SUNWtoo
</code>. If you did not install all
1206 optional packages when installing Solaris
2, you will need to verify that
1207 the packages that GCC needs are installed.
1209 <p>To check whether an optional package is installed, use
1210 the
<span class=
"command">pkginfo
</span> command. To add an optional package, use the
1211 <span class=
"command">pkgadd
</span> command. For further details, see the Solaris
2
1214 <p>Trying to use the linker and other tools in
1215 <span class=
"file">/usr/ucb
</span> to install GCC has been observed to cause trouble.
1216 For example, the linker may hang indefinitely. The fix is to remove
1217 <span class=
"file">/usr/ucb
</span> from your
<span class=
"env">PATH
</span>.
1219 <p>The build process works more smoothly with the legacy Sun tools so, if you
1220 have
<span class=
"file">/usr/xpg4/bin
</span> in your
<span class=
"env">PATH
</span>, we recommend that you place
1221 <span class=
"file">/usr/bin
</span> before
<span class=
"file">/usr/xpg4/bin
</span> for the duration of the build.
1223 <p>All releases of GNU binutils prior to
2.11.2 have known bugs on this
1224 platform. We recommend the use of GNU binutils
2.11.2 or the vendor
1225 tools (Sun
<span class=
"command">as
</span>, Sun
<span class=
"command">ld
</span>).
1227 <p>Sun bug
4296832 turns up when compiling X11 headers with GCC
2.95 or
1228 newer:
<span class=
"command">g++
</span> will complain that types are missing. These headers assume
1229 that omitting the type means
<code>int
</code>; this assumption worked for C89 but
1230 is wrong for C++, and is now wrong for C99 also.
1232 <p><span class=
"command">g++
</span> accepts such (invalid) constructs with the option
1233 <span class=
"option">-fpermissive
</span>; it
1234 will assume that any missing type is
<code>int
</code> (as defined by C89).
1236 <p>There are patches for Solaris
2.6 (
105633-
56 or newer for SPARC,
1237 106248-
42 or newer for Intel), Solaris
7 (
108376-
21 or newer for SPARC,
1238 108377-
20 for Intel), and Solaris
8 (
108652-
24 or newer for SPARC,
1239 108653-
22 for Intel) that fix this bug.
1243 <h3 class=
"heading"><a name=
"TOC50"></a><a name=
"sparc_002dsun_002dsolaris2_002a"></a>sparc-sun-solaris2*
</h3>
1245 <p>When GCC is configured to use binutils
2.11.2 or later the binaries
1246 produced are smaller than the ones produced using Sun's native tools;
1247 this difference is quite significant for binaries containing debugging
1250 <p>Sun
<span class=
"command">as
</span> 4.x is broken in that it cannot cope with long symbol names.
1251 A typical error message might look similar to the following:
1253 <pre class=
"smallexample"> /usr/ccs/bin/as:
"/var/tmp/ccMsw135.s", line
11041: error:
1254 can't compute value of an expression involving an external symbol.
1256 <p>This is Sun bug
4237974. This is fixed with patch
108908-
02 for Solaris
1257 2.6 and has been fixed in later (
5.x) versions of the assembler,
1258 starting with Solaris
7.
1260 <p>Starting with Solaris
7, the operating system is capable of executing
1261 64-bit SPARC V9 binaries. GCC
3.1 and later properly supports
1262 this; the
<span class=
"option">-m64
</span> option enables
64-bit code generation.
1263 However, if all you want is code tuned for the UltraSPARC CPU, you
1264 should try the
<span class=
"option">-mtune=ultrasparc
</span> option instead, which produces
1265 code that, unlike full
64-bit code, can still run on non-UltraSPARC
1268 <p>When configuring on a Solaris
7 or later system that is running a kernel
1269 that supports only
32-bit binaries, one must configure with
1270 <span class=
"option">--disable-multilib
</span>, since we will not be able to build the
1271 64-bit target libraries.
1273 <p>GCC
3.3 and GCC
3.4 trigger code generation bugs in earlier versions of
1274 the GNU compiler (especially GCC
3.0.x versions), which lead to the
1275 miscompilation of the stage1 compiler and the subsequent failure of the
1276 bootstrap process. A workaround is to use GCC
3.2.3 as an intermediary
1277 stage, i.e. to bootstrap that compiler with the base compiler and then
1278 use it to bootstrap the final compiler.
1280 <p>GCC
3.4 triggers a code generation bug in versions
5.4 (Sun ONE Studio
7)
1281 and
5.5 (Sun ONE Studio
8) of the Sun compiler, which causes a bootstrap
1282 failure in form of a miscompilation of the stage1 compiler by the Sun
1283 compiler. This is Sun bug
4974440. This is fixed with patch
112760-
07.
1285 <p>GCC
3.4 changed the default debugging format from STABS to DWARF-
2 for
1286 32-bit code on Solaris
7 and later. If you are using the Sun
1287 assembler, this change apparently runs afoul of Sun bug
4910101, for
1288 which (as of
2004-
05-
23) there is no fix. A symptom of the problem is
1289 that you cannot compile C++ programs like
<span class=
"command">groff
</span> 1.19.1
1290 without getting messages like
<span class=
"samp">ld: warning: relocation error:
1291 R_SPARC_UA32 ... external symbolic relocation against
1292 non-allocatable section .debug_info; cannot be processed at runtime:
1293 relocation ignored
</span>. To work around this problem, compile with
1294 <span class=
"option">-gstabs+
</span> instead of plain
<span class=
"option">-g
</span>.
1298 <h3 class=
"heading"><a name=
"TOC51"></a><a name=
"sparc_002dsun_002dsolaris2_002e7"></a>sparc-sun-solaris2.7
</h3>
1300 <p>Sun patch
107058-
01 (
1999-
01-
13) for Solaris
7/SPARC triggers a bug in
1301 the dynamic linker. This problem (Sun bug
4210064) affects GCC
2.8
1302 and later, including all EGCS releases. Sun formerly recommended
1303 107058-
01 for all Solaris
7 users, but around
1999-
09-
01 it started to
1304 recommend it only for people who use Sun's compilers.
1306 <p>Here are some workarounds to this problem:
1308 <li>Do not install Sun patch
107058-
01 until after Sun releases a
1309 complete patch for bug
4210064. This is the simplest course to take,
1310 unless you must also use Sun's C compiler. Unfortunately
107058-
01
1311 is preinstalled on some new Solaris
7-based hosts, so you may have to
1314 <li>Copy the original, unpatched Solaris
7
1315 <span class=
"command">/usr/ccs/bin/as
</span> into
1316 <span class=
"command">/usr/local/libexec/gcc/sparc-sun-solaris2.7/
3.4/as
</span>,
1317 adjusting the latter name to fit your local conventions and software
1320 <li>Install Sun patch
106950-
03 (
1999-
05-
25) or later. Nobody with
1321 both
107058-
01 and
106950-
03 installed has reported the bug with GCC
1322 and Sun's dynamic linker. This last course of action is riskiest,
1323 for two reasons. First, you must install
106950 on all hosts that
1324 run code generated by GCC; it doesn't suffice to install it only on
1325 the hosts that run GCC itself. Second, Sun says that
106950-
03 is
1326 only a partial fix for bug
4210064, but Sun doesn't know whether the
1327 partial fix is adequate for GCC. Revision -
08 or later should fix
1328 the bug. The current (as of
2004-
05-
23) revision is -
24, and is included in
1329 the Solaris
7 Recommended Patch Cluster.
1332 <p>GCC
3.3 triggers a bug in version
5.0 Alpha
03/
27/
98 of the Sun assembler,
1333 which causes a bootstrap failure when linking the
64-bit shared version of
1334 libgcc. A typical error message is:
1336 <pre class=
"smallexample"> ld: fatal: relocation error: R_SPARC_32: file libgcc/sparcv9/_muldi3.o:
1337 symbol
<unknown
>: offset
0xffffffff7ec133e7 is non-aligned.
1339 <p>This bug has been fixed in the final
5.0 version of the assembler.
1343 <h3 class=
"heading"><a name=
"TOC52"></a><a name=
"sparc_002d_002a_002dlinux_002a"></a>sparc-*-linux*
</h3>
1345 <p>GCC versions
3.0 and higher require binutils
2.11.2 and glibc
2.2.4
1346 or newer on this platform. All earlier binutils and glibc
1347 releases mishandled unaligned relocations on
<code>sparc-*-*
</code> targets.
1351 <h3 class=
"heading"><a name=
"TOC53"></a><a name=
"sparc64_002d_002a_002dsolaris2_002a"></a>sparc64-*-solaris2*
</h3>
1353 <p>The following compiler flags must be specified in the configure
1354 step in order to bootstrap this target with the Sun compiler:
1356 <pre class=
"smallexample"> %
CC=
"cc -xildoff -xarch=v9" <var>srcdir
</var>/configure [
<var>options
</var>] [
<var>target
</var>]
1358 <p><span class=
"option">-xildoff
</span> turns off the incremental linker, and
<span class=
"option">-xarch=v9
</span>
1359 specifies the SPARC-V9 architecture to the Sun linker and assembler.
1363 <h3 class=
"heading"><a name=
"TOC54"></a><a name=
"sparcv9_002d_002a_002dsolaris2_002a"></a>sparcv9-*-solaris2*
</h3>
1365 <p>This is a synonym for sparc64-*-solaris2*.
1369 <h3 class=
"heading"><a name=
"TOC55"></a><a name=
"_0023_002a_002d_002a_002dsysv_002a"></a>*-*-sysv*
</h3>
1371 <p>On System V release
3, you may get this error message
1374 <pre class=
"smallexample"> ld fatal: failed to write symbol name
<var>something
</var>
1375 in strings table for file
<var>whatever
</var>
1377 <p>This probably indicates that the disk is full or your ulimit won't allow
1378 the file to be as large as it needs to be.
1380 <p>This problem can also result because the kernel parameter
<code>MAXUMEM
</code>
1381 is too small. If so, you must regenerate the kernel and make the value
1382 much larger. The default value is reported to be
1024; a value of
32768
1383 is said to work. Smaller values may also work.
1385 <p>On System V, if you get an error like this,
1387 <pre class=
"smallexample"> /usr/local/lib/bison.simple: In function `yyparse':
1388 /usr/local/lib/bison.simple:
625: virtual memory exhausted
1390 <p class=
"noindent">that too indicates a problem with disk space, ulimit, or
<code>MAXUMEM
</code>.
1392 <p>On a System V release
4 system, make sure
<span class=
"file">/usr/bin
</span> precedes
1393 <span class=
"file">/usr/ucb
</span> in
<code>PATH
</code>. The
<span class=
"command">cc
</span> command in
1394 <span class=
"file">/usr/ucb
</span> uses libraries which have bugs.
1398 <h3 class=
"heading"><a name=
"TOC56"></a><a name=
"vax_002ddec_002dultrix"></a>vax-dec-ultrix
</h3>
1400 <p>Don't try compiling with VAX C (
<span class=
"command">vcc
</span>). It produces incorrect code
1401 in some cases (for example, when
<code>alloca
</code> is used).
1405 <h3 class=
"heading"><a name=
"TOC57"></a><a name=
"_002a_002d_002a_002dvxworks_002a"></a>*-*-vxworks*
</h3>
1407 <p>Support for VxWorks is in flux. At present GCC supports
<em>only
</em> the
1408 very recent VxWorks
5.5 (aka Tornado
2.2) release, and only on PowerPC.
1409 We welcome patches for other architectures supported by VxWorks
5.5.
1410 Support for VxWorks AE would also be welcome; we believe this is merely
1411 a matter of writing an appropriate
“configlette
” (see below). We are
1412 not interested in supporting older, a.out or COFF-based, versions of
1415 <p>VxWorks comes with an older version of GCC installed in
1416 <var>$WIND_BASE
</var><span class=
"file">/host
</span>; we recommend you do not overwrite it.
1417 Choose an installation
<var>prefix
</var> entirely outside
<var>$WIND_BASE
</var>.
1418 Before running
<span class=
"command">configure
</span>, create the directories
<var>prefix
</var>
1419 and
<var>prefix
</var><span class=
"file">/bin
</span>. Link or copy the appropriate assembler,
1420 linker, etc. into
<var>prefix
</var><span class=
"file">/bin
</span>, and set your
<var>PATH
</var> to
1421 include that directory while running both
<span class=
"command">configure
</span> and
1422 <span class=
"command">make
</span>.
1424 <p>You must give
<span class=
"command">configure
</span> the
1425 <span class=
"option">--with-headers=
</span><var>$WIND_BASE
</var><span class=
"option">/target/h
</span> switch so that it can
1426 find the VxWorks system headers. Since VxWorks is a cross compilation
1427 target only, you must also specify
<span class=
"option">--target=
</span><var>target
</var>.
1428 <span class=
"command">configure
</span> will attempt to create the directory
1429 <var>prefix
</var><span class=
"file">/
</span><var>target
</var><span class=
"file">/sys-include
</span> and copy files into it;
1430 make sure the user running
<span class=
"command">configure
</span> has sufficient privilege
1433 <p>GCC's exception handling runtime requires a special
“configlette
”
1434 module,
<span class=
"file">contrib/gthr_supp_vxw_5x.c
</span>. Follow the instructions in
1435 that file to add the module to your kernel build. (Future versions of
1436 VxWorks will incorporate this module.)
1440 <h3 class=
"heading"><a name=
"TOC58"></a><a name=
"x86_005f64_002d_002a_002d_002a"></a>x86_64-*-*, amd64-*-*
</h3>
1442 <p>GCC supports the x86-
64 architecture implemented by the AMD64 processor
1443 (amd64-*-* is an alias for x86_64-*-*) on GNU/Linux, FreeBSD and NetBSD.
1444 On GNU/Linux the default is a bi-arch compiler which is able to generate
1445 both
64-bit x86-
64 and
32-bit x86 code (via the
<span class=
"option">-m32
</span> switch).
1449 <h3 class=
"heading"><a name=
"TOC59"></a><a name=
"xtensa_002d_002a_002delf"></a>xtensa-*-elf
</h3>
1451 <p>This target is intended for embedded Xtensa systems using the
1452 <span class=
"samp">newlib
</span> C library. It uses ELF but does not support shared
1453 objects. Designed-defined instructions specified via the
1454 Tensilica Instruction Extension (TIE) language are only supported
1455 through inline assembly.
1457 <p>The Xtensa configuration information must be specified prior to
1458 building GCC. The
<span class=
"file">include/xtensa-config.h
</span> header
1459 file contains the configuration information. If you created your
1460 own Xtensa configuration with the Xtensa Processor Generator, the
1461 downloaded files include a customized copy of this header file,
1462 which you can use to replace the default header file.
1466 <h3 class=
"heading"><a name=
"TOC60"></a><a name=
"xtensa_002d_002a_002dlinux_002a"></a>xtensa-*-linux*
</h3>
1468 <p>This target is for Xtensa systems running GNU/Linux. It supports ELF
1469 shared objects and the GNU C library (glibc). It also generates
1470 position-independent code (PIC) regardless of whether the
1471 <span class=
"option">-fpic
</span> or
<span class=
"option">-fPIC
</span> options are used. In other
1472 respects, this target is the same as the
1473 <a href=
"#xtensa-*-elf"><span class=
"samp">xtensa-*-elf
</span></a> target.
1477 <h3 class=
"heading"><a name=
"TOC61"></a><a name=
"windows"></a>Microsoft Windows (
32-bit)
</h3>
1479 <p>A port of GCC
2.95.2 and
3.x is included with the
1480 <a href=
"http://www.cygwin.com/">Cygwin environment
</a>.
1482 <p>Current (as of early
2001) snapshots of GCC will build under Cygwin
1483 without modification.
1485 <p>GCC does not currently build with Microsoft's C++ compiler and there
1486 are no plans to make it do so.
1490 <h3 class=
"heading"><a name=
"TOC62"></a><a name=
"os2"></a>OS/
2</h3>
1492 <p>GCC does not currently support OS/
2. However, Andrew Zabolotny has been
1493 working on a generic OS/
2 port with pgcc. The current code can be found
1494 at
<a href=
"http://www.goof.com/pcg/os2/">http://www.goof.com/pcg/os2/
</a>.
1496 <p>An older copy of GCC
2.8.1 is included with the EMX tools available at
1497 <a href=
"ftp://ftp.leo.org/pub/comp/os/os2/leo/devtools/emx+gcc/">ftp://ftp.leo.org/pub/comp/os/os2/leo/devtools/emx+gcc/
</a>.
1501 <h3 class=
"heading"><a name=
"TOC63"></a><a name=
"older"></a>Older systems
</h3>
1503 <p>GCC contains support files for many older (
1980s and early
1504 1990s) Unix variants. For the most part, support for these systems
1505 has not been deliberately removed, but it has not been maintained for
1506 several years and may suffer from bitrot.
1508 <p>Starting with GCC
3.1, each release has a list of
“obsoleted
” systems.
1509 Support for these systems is still present in that release, but
1510 <span class=
"command">configure
</span> will fail unless the
<span class=
"option">--enable-obsolete
</span>
1511 option is given. Unless a maintainer steps forward, support for these
1512 systems will be removed from the next release of GCC.
1514 <p>Support for old systems as hosts for GCC can cause problems if the
1515 workarounds for compiler, library and operating system bugs affect the
1516 cleanliness or maintainability of the rest of GCC. In some cases, to
1517 bring GCC up on such a system, if still possible with current GCC, may
1518 require first installing an old version of GCC which did work on that
1519 system, and using it to compile a more recent GCC, to avoid bugs in the
1520 vendor compiler. Old releases of GCC
1 and GCC
2 are available in the
1521 <span class=
"file">old-releases
</span> directory on the
<a href=
"../mirrors.html">GCC mirror sites
</a>. Header bugs may generally be avoided using
1522 <span class=
"command">fixincludes
</span>, but bugs or deficiencies in libraries and the
1523 operating system may still cause problems.
1525 <p>Support for older systems as targets for cross-compilation is less
1526 problematic than support for them as hosts for GCC; if an enthusiast
1527 wishes to make such a target work again (including resurrecting any of
1528 the targets that never worked with GCC
2, starting from the last CVS
1529 version before they were removed), patches
1530 <a href=
"../contribute.html">following the usual requirements
</a> would be
1531 likely to be accepted, since they should not affect the support for more
1534 <p>For some systems, old versions of GNU binutils may also be useful,
1535 and are available from
<span class=
"file">pub/binutils/old-releases
</span> on
1536 <a href=
"http://sources.redhat.com/mirrors.html">sources.redhat.com mirror sites
</a>.
1538 <p>Some of the information on specific systems above relates to
1539 such older systems, but much of the information
1540 about GCC on such systems (which may no longer be applicable to
1541 current GCC) is to be found in the GCC texinfo manual.
1545 <h3 class=
"heading"><a name=
"TOC64"></a><a name=
"elf_005ftargets"></a>all ELF targets (SVR4, Solaris
2, etc.)
</h3>
1547 <p>C++ support is significantly better on ELF targets if you use the
1548 <a href=
"./configure.html#with-gnu-ld">GNU linker
</a>; duplicate copies of
1549 inlines, vtables and template instantiations will be discarded
1553 <p><a href=
"./index.html">Return to the GCC Installation page
</a>
1555 <!-- ***Old documentation****************************************************** -->
1556 <!-- ***GFDL******************************************************************** -->
1557 <!-- *************************************************************************** -->
1558 <!-- Part 6 The End of the Document -->