3 <title>Prerequisites for GCC
</title>
4 <meta http-equiv=
"Content-Type" content=
"text/html">
5 <meta name=
"description" content=
"Prerequisites 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">Prerequisites for GCC
</h1>
43 <a name=
"index-Prerequisites-1"></a>
44 GCC requires that various tools and packages be available for use in the
45 build procedure. Modifying GCC sources requires additional tools
48 <h3 class=
"heading"><a name=
"TOC0"></a>Tools/packages necessary for building GCC
</h3>
51 <dt>ISO C90 compiler
<dd>Necessary to bootstrap the GCC package, although versions of GCC prior
52 to
3.4 also allow bootstrapping with a traditional (K
&R) C compiler.
54 <p>To make all languages in a cross-compiler or other configuration where
55 3-stage bootstrap is not performed, you need to start with an existing
56 GCC binary (version
2.95 or later) because source code for language
57 frontends other than C might use GCC extensions.
60 In order to build the Ada compiler (GNAT) you must already have GNAT
61 installed because portions of the Ada frontend are written in Ada (with
62 GNAT extensions.) Refer to the Ada installation instructions for more
65 <br><dt>A
“working
” POSIX compatible shell, or GNU bash
<dd>
66 Necessary when running
<span class=
"command">configure
</span> because some
67 <span class=
"command">/bin/sh
</span> shells have bugs and may crash when configuring the
68 target libraries. In other cases,
<span class=
"command">/bin/sh
</span> or even some
69 <span class=
"command">ksh
</span> have disastrous corner-case performance problems. This
70 can cause target
<span class=
"command">configure
</span> runs to literally take days to
71 complete in some cases.
73 <p>So on some platforms
<span class=
"command">/bin/ksh
</span> is sufficient, on others it
74 isn't. See the host/target specific instructions for your platform, or
75 use
<span class=
"command">bash
</span> to be sure. Then set
<span class=
"env">CONFIG_SHELL
</span> in your
76 environment to your
“good
” shell prior to running
77 <span class=
"command">configure
</span>/
<span class=
"command">make
</span>.
79 <p><span class=
"command">zsh
</span> is not a fully compliant POSIX shell and will not
80 work when configuring GCC.
82 <br><dt>GNU binutils
<dd>
83 Necessary in some circumstances, optional in others. See the
84 host/target specific instructions for your platform for the exact
87 <br><dt>gzip version
1.2.4 (or later) or
<dt>bzip2 version
1.0.2 (or later)
<dd>
88 Necessary to uncompress GCC
<span class=
"command">tar
</span> files when source code is
89 obtained via FTP mirror sites.
91 <br><dt>GNU make version
3.79.1 (or later)
<dd>
92 You must have GNU make installed to build GCC.
94 <br><dt>GNU tar version
1.12 (or later)
<dd>
95 Necessary (only on some platforms) to untar the source code. Many
96 systems'
<span class=
"command">tar
</span> programs will also work, only try GNU
97 <span class=
"command">tar
</span> if you have problems.
101 <h3 class=
"heading"><a name=
"TOC1"></a>Tools/packages necessary for modifying GCC
</h3>
104 <dt>autoconf versions
2.13 and
2.57<dt>GNU m4 version
1.4 (or later)
<dd>
105 Necessary when modifying
<span class=
"file">configure.in
</span>,
<span class=
"file">aclocal.m4
</span>, etc.
106 to regenerate
<span class=
"file">configure
</span> and
<span class=
"file">config.in
</span> files. Most
107 directories require autoconf
2.13 (exactly), but
<span class=
"file">libiberty
</span>,
108 <span class=
"file">fastjar
</span>,
<span class=
"file">libstdc++-v3
</span>,
<span class=
"file">libjava/libltdl
</span>, and
<span class=
"file">gcc
</span>
109 require autoconf
2.57 (exactly).
111 <br><dt>automake versions
1.4-gcj and
1.7.9<dd>
112 Necessary when modifying a
<span class=
"file">Makefile.am
</span> file to regenerate its
113 associated
<span class=
"file">Makefile.in
</span>.
115 <p>Much of GCC does not use automake, so directly edit the
<span class=
"file">Makefile.in
</span>
116 file. Specifically this applies to the
<span class=
"file">gcc
</span>,
<span class=
"file">intl
</span>,
117 <span class=
"file">libf2c
</span>,
<span class=
"file">libiberty
</span>,
<span class=
"file">libobjc
</span> directories as well as any
118 of their subdirectories.
120 <p>The
<span class=
"file">libstdc++-v3
</span>,
<span class=
"file">libjava/libltdl
</span>, and
<span class=
"file">fastjar
</span>
121 directories require automake
1.7.9. However, the Java directories, which
122 include
<span class=
"file">boehm-gc
</span>,
<span class=
"file">libffi
</span>,
<span class=
"file">libjava
</span>, and
<span class=
"file">zlib
</span>,
123 require a modified version of automake
1.4 downloadable from
124 <a href=
"ftp://gcc.gnu.org/pub/java/automake-gcj-1.4.tar.gz">ftp://gcc.gnu.org/pub/java/automake-gcj-
1.4.tar.gz
</a>.
126 <br><dt>gettext version
0.12 (or later)
<dd>
127 Needed to regenerate
<span class=
"file">gcc.pot
</span>.
129 <br><dt>gperf version
2.7.2 (or later)
<dd>
130 Necessary when modifying
<span class=
"command">gperf
</span> input files, e.g.
131 <span class=
"file">gcc/cp/cfns.gperf
</span> to regenerate its associated header file, e.g.
132 <span class=
"file">gcc/cp/cfns.h
</span>.
134 <br><dt>expect version ???
<dt>tcl version ???
<dt>dejagnu version ???
<dd>
135 Necessary to run the GCC testsuite.
137 <br><dt>autogen version
5.5.4 (or later) and
<dt>guile version
1.4.1 (or later)
<dd>
138 Necessary to regenerate
<span class=
"file">fixinc/fixincl.x
</span> from
139 <span class=
"file">fixinc/inclhack.def
</span> and
<span class=
"file">fixinc/*.tpl
</span>.
141 <p>Necessary to run the
<span class=
"file">fixinc
</span> <span class=
"command">make check
</span>.
143 <p>Necessary to regenerate the top level
<span class=
"file">Makefile.in
</span> file from
144 <span class=
"file">Makefile.tpl
</span> and
<span class=
"file">Makefile.def
</span>.
146 <br><dt>GNU Bison version
1.28 (or later)
<dd>Berkeley
<span class=
"command">yacc
</span> (
<span class=
"command">byacc
</span>) is also reported to work other
149 <p>Necessary when modifying
<span class=
"file">*.y
</span> files.
151 <p>Necessary to build GCC during development because the generated output
152 files are not included in the CVS repository. They are included in
155 <br><dt>Flex version
2.5.4 (or later)
<dd>
156 Necessary when modifying
<span class=
"file">*.l
</span> files.
158 <p>Necessary to build GCC during development because the generated output
159 files are not included in the CVS repository. They are included in
162 <br><dt>Texinfo version
4.2 (or later)
<dd>
163 Necessary for running
<span class=
"command">makeinfo
</span> when modifying
<span class=
"file">*.texi
</span>
164 files to test your changes.
166 <p>Necessary to build GCC documentation during development because the
167 generated output files are not included in the CVS repository. They are
168 included in releases.
170 <br><dt>TeX (any working version)
<dd>
171 Necessary for running
<span class=
"command">texi2dvi
</span>, used when running
172 <span class=
"command">make dvi
</span> to create DVI files.
174 <br><dt>cvs version
1.10 (or later)
<dt>ssh (any version)
<dd>
175 Necessary to access the CVS repository. Public releases and weekly
176 snapshots of the development sources are also available via FTP.
178 <br><dt>perl version
5.6.1 (or later)
<dd>
179 Necessary when regenerating
<span class=
"file">Makefile
</span> dependencies in libiberty.
180 Necessary when regenerating
<span class=
"file">libiberty/functions.texi
</span>.
181 Necessary when generating manpages from Texinfo manuals.
182 Used by various scripts to generate some files included in CVS (mainly
183 Unicode-related and rarely changing) from source tables.
185 <br><dt>GNU diffutils version
2.7 (or later)
<dd>
186 Necessary when creating changes to GCC source code to submit for review.
188 <br><dt>patch version
2.5.4 (or later)
<dd>
189 Necessary when applying patches, created with
<span class=
"command">diff
</span>, to one's
195 <p><a href=
"./index.html">Return to the GCC Installation page
</a>
197 <!-- ***Downloading the source************************************************** -->
198 <!-- ***Configuration*********************************************************** -->
199 <!-- ***Building**************************************************************** -->
200 <!-- ***Testing***************************************************************** -->
201 <!-- ***Final install*********************************************************** -->
202 <!-- ***Binaries**************************************************************** -->
203 <!-- ***Specific**************************************************************** -->
204 <!-- ***Old documentation****************************************************** -->
205 <!-- ***GFDL******************************************************************** -->
206 <!-- *************************************************************************** -->
207 <!-- Part 6 The End of the Document -->