prerequisites.html   [plain text]


<html lang="en">
<head>
<title>Prerequisites for GCC</title>
<meta http-equiv="Content-Type" content="text/html">
<meta name="description" content="Prerequisites for GCC">
<meta name="generator" content="makeinfo 4.7">
<link title="Top" rel="top" href="#Top">
<link href="http://www.gnu.org/software/texinfo/" rel="generator-home" title="Texinfo Homepage">
<!--
Copyright (C) 1988, 1989, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
1999, 2000, 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc.

   Permission is granted to copy, distribute and/or modify this document
under the terms of the GNU Free Documentation License, Version 1.2 or
any later version published by the Free Software Foundation; with no
Invariant Sections, the Front-Cover texts being (a) (see below), and
with the Back-Cover Texts being (b) (see below).  A copy of the
license is included in the section entitled "GNU Free Documentation License".

(a) The FSF's Front-Cover Text is:

     A GNU Manual

(b) The FSF's Back-Cover Text is:

     You have freedom to copy and modify this GNU Manual, like GNU
     software.  Copies published by the Free Software Foundation raise
     funds for GNU development.-->
<meta http-equiv="Content-Style-Type" content="text/css">
<style type="text/css"><!--
  pre.display { font-family:inherit }
  pre.format  { font-family:inherit }
  pre.smalldisplay { font-family:inherit; font-size:smaller }
  pre.smallformat  { font-family:inherit; font-size:smaller }
  pre.smallexample { font-size:smaller }
  pre.smalllisp    { font-size:smaller }
  span.sc { font-variant:small-caps }
  span.roman { font-family: serif; font-weight: normal; } 
--></style>
</head>
<body>
<h1 class="settitle">Prerequisites for GCC</h1>
<a name="index-Prerequisites-1"></a>
GCC requires that various tools and packages be available for use in the
build procedure.  Modifying GCC sources requires additional tools
described below.

<h3 class="heading"><a name="TOC0"></a>Tools/packages necessary for building GCC</h3>

     <dl>
<dt>ISO C90 compiler<dd>Necessary to bootstrap the GCC package, although versions of GCC prior
to 3.4 also allow bootstrapping with a traditional (K&amp;R) C compiler.

     <p>To make all languages in a cross-compiler or other configuration where
3-stage bootstrap is not performed, you need to start with an existing
GCC binary (version 2.95 or later) because source code for language
frontends other than C might use GCC extensions.

     <br><dt>GNAT<dd>
In order to build the Ada compiler (GNAT) you must already have GNAT
installed because portions of the Ada frontend are written in Ada (with
GNAT extensions.)  Refer to the Ada installation instructions for more
specific information.

     <br><dt>A &ldquo;working&rdquo; POSIX compatible shell, or GNU bash<dd>
Necessary when running <span class="command">configure</span> because some
<span class="command">/bin/sh</span> shells have bugs and may crash when configuring the
target libraries.  In other cases, <span class="command">/bin/sh</span> or even some
<span class="command">ksh</span> have disastrous corner-case performance problems.  This
can cause target <span class="command">configure</span> runs to literally take days to
complete in some cases.

     <p>So on some platforms <span class="command">/bin/ksh</span> is sufficient, on others it
isn't.  See the host/target specific instructions for your platform, or
use <span class="command">bash</span> to be sure.  Then set <span class="env">CONFIG_SHELL</span> in your
environment to your &ldquo;good&rdquo; shell prior to running
<span class="command">configure</span>/<span class="command">make</span>.

     <p><span class="command">zsh</span> is not a fully compliant POSIX shell and will not
work when configuring GCC.

     <br><dt>GNU binutils<dd>
Necessary in some circumstances, optional in others.  See the
host/target specific instructions for your platform for the exact
requirements.

     <br><dt>gzip version 1.2.4 (or later) or<dt>bzip2 version 1.0.2 (or later)<dd>
Necessary to uncompress GCC <span class="command">tar</span> files when source code is
obtained via FTP mirror sites.

     <br><dt>GNU make version 3.79.1 (or later)<dd>
You must have GNU make installed to build GCC.

     <br><dt>GNU tar version 1.12 (or later)<dd>
Necessary (only on some platforms) to untar the source code.  Many
systems' <span class="command">tar</span> programs will also work, only try GNU
<span class="command">tar</span> if you have problems.

     <br><dt>GNU Multiple Precision Library (GMP) version 4.0 (or later)<dd>
Necessary to build the Fortran frontend.  If you don't have it
installed in your library search path, you will have to configure with
the <span class="option">--with-gmp</span> or <span class="option">--with-gmp-dir</span> configure option.

     <br><dt>MPFR Library<dd>
Necessary to build the Fortran frontend.  It can be downloaded from
<a href="http://www.mpfr.org/">http://www.mpfr.org/</a>.  It is also included in the current GMP
release (4.1.3) when configured with <span class="option">--enable-mpfr</span>.

     <p>The <span class="option">--with-mpfr</span> or <span class="option">--with-mpfr-dir</span> configure option should
be used if your MPFR Library is not installed in your library search path.

</dl>

<h3 class="heading"><a name="TOC1"></a>Tools/packages necessary for modifying GCC</h3>

     <dl>
<dt>autoconf versions 2.13 and 2.59<dt>GNU m4 version 1.4 (or later)<dd>
Necessary when modifying <span class="file">configure.ac</span>, <span class="file">aclocal.m4</span>, etc. 
to regenerate <span class="file">configure</span> and <span class="file">config.in</span> files.  Most
directories require autoconf 2.59 (exactly), but the toplevel
still requires autoconf 2.13 (exactly).

     <br><dt>automake versions 1.9.3<dd>
Necessary when modifying a <span class="file">Makefile.am</span> file to regenerate its
associated <span class="file">Makefile.in</span>.

     <p>Much of GCC does not use automake, so directly edit the <span class="file">Makefile.in</span>
file.  Specifically this applies to the <span class="file">gcc</span>, <span class="file">intl</span>,
<span class="file">libcpp</span>, <span class="file">libiberty</span>, <span class="file">libobjc</span> directories as well
as any of their subdirectories.

     <p>For directories that use automake, GCC requires the latest release in
the 1.9.x series, which is currently 1.9.3.  When regenerating a directory
to a newer version, please update all the directories using an older 1.9.x
to the latest released version.

     <br><dt>gettext version 0.12 (or later)<dd>
Needed to regenerate <span class="file">gcc.pot</span>.

     <br><dt>gperf version 2.7.2 (or later)<dd>
Necessary when modifying <span class="command">gperf</span> input files, e.g. 
<span class="file">gcc/cp/cfns.gperf</span> to regenerate its associated header file, e.g. 
<span class="file">gcc/cp/cfns.h</span>.

     <br><dt>expect version ???<dt>tcl version ???<dt>dejagnu version 1.4.4 (or later)<dd>
Necessary to run the GCC testsuite.

     <br><dt>autogen version 5.5.4 (or later) and<dt>guile version 1.4.1 (or later)<dd>
Necessary to regenerate <span class="file">fixinc/fixincl.x</span> from
<span class="file">fixinc/inclhack.def</span> and <span class="file">fixinc/*.tpl</span>.

     <p>Necessary to run the <span class="file">fixinc</span> <span class="command">make check</span>.

     <p>Necessary to regenerate the top level <span class="file">Makefile.in</span> file from
<span class="file">Makefile.tpl</span> and <span class="file">Makefile.def</span>.

     <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
than for java.

     <p>Necessary when modifying <span class="file">*.y</span> files.

     <p>Necessary to build GCC during development because the generated output
files are not included in the CVS repository.  They are included in
releases.

     <br><dt>Flex version 2.5.4 (or later)<dd>
Necessary when modifying <span class="file">*.l</span> files.

     <p>Necessary to build GCC during development because the generated output
files are not included in the CVS repository.  They are included in
releases.

     <br><dt>Texinfo version 4.2 (or later)<dd>
Necessary for running <span class="command">makeinfo</span> when modifying <span class="file">*.texi</span>
files to test your changes.

     <p>Necessary to build GCC documentation during development because the
generated output files are not included in the CVS repository.  They are
included in releases.

     <br><dt>TeX (any working version)<dd>
Necessary for running <span class="command">texi2dvi</span>, used when running
<span class="command">make dvi</span> to create DVI files.

     <br><dt>cvs version 1.10 (or later)<dt>ssh (any version)<dd>
Necessary to access the CVS repository.  Public releases and weekly
snapshots of the development sources are also available via FTP.

     <br><dt>perl version 5.6.1 (or later)<dd>
Necessary when regenerating <span class="file">Makefile</span> dependencies in libiberty. 
Necessary when regenerating <span class="file">libiberty/functions.texi</span>. 
Necessary when generating manpages from Texinfo manuals. 
Used by various scripts to generate some files included in CVS (mainly
Unicode-related and rarely changing) from source tables.

     <br><dt>GNU diffutils version 2.7 (or later)<dd>
Necessary when creating changes to GCC source code to submit for review.

     <br><dt>patch version 2.5.4 (or later)<dd>
Necessary when applying patches, created with <span class="command">diff</span>, to one's
own sources.

</dl>

   <p><hr />
<p><a href="./index.html">Return to the GCC Installation page</a>

<!-- ***Downloading the source************************************************** -->
<!-- ***Configuration*********************************************************** -->
<!-- ***Building**************************************************************** -->
<!-- ***Testing***************************************************************** -->
<!-- ***Final install*********************************************************** -->
<!-- ***Binaries**************************************************************** -->
<!-- ***Specific**************************************************************** -->
<!-- ***Old documentation****************************************************** -->
<!-- ***GFDL******************************************************************** -->
<!-- *************************************************************************** -->
<!-- Part 6 The End of the Document -->
</body></html>