Ignore:
Timestamp:
Apr 27, 2004, 8:39:34 PM (21 years ago)
Author:
bird
Message:

GCC v3.3.3 sources.

Location:
branches/GNU/src/gcc
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/GNU/src/gcc

    • Property svn:ignore
      •  

        old new  
        2626configure.vr
        2727configure.vrs
         28dir.info
        2829Makefile
        29 dir.info
        3030lost+found
        3131update.out
  • branches/GNU/src/gcc/INSTALL/configure.html

    • Property cvs2svn:cvs-rev changed from 1.1 to 1.1.1.2
    r1390 r1391  
    1 <html lang="en"><head>
     1   <html lang="en">
     2<head>
    23<title>Installing GCC: Configuration</title>
    34<meta http-equiv="Content-Type" content="text/html">
    4 <meta name=description content="Installing GCC: Configuration">
    5 <meta name=generator content="makeinfo 4.0">
    6 <link href="http://texinfo.org/" rel=generator-home>
    7 </head><body>
    8 
    9 <p>L<p>ike most GNU software, GCC must be configured before it can be built.
     5<meta name="description" content="Installing GCC: Configuration">
     6<meta name="generator" content="makeinfo 4.6">
     7<!--
     8Copyright &copy; 1988, 1989, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
     91999, 2000, 2001, 2002, 2003 Free Software Foundation, Inc.
     10<br><p>
     11   <p>Permission is granted to copy, distribute and/or modify this document
     12under the terms of the GNU Free Documentation License, Version 1.2 or
     13any later version published by the Free Software Foundation; with no
     14Invariant Sections, the Front-Cover texts being (a) (see below), and
     15with the Back-Cover Texts being (b) (see below).  A copy of the
     16license is included in the section entitled "<a href="./gfdl.html">GNU Free Documentation License</a>".
     17
     18   <p>(a) The FSF's Front-Cover Text is:
     19
     20   <p>A GNU Manual
     21
     22   <p>(b) The FSF's Back-Cover Text is:
     23
     24   <p>You have freedom to copy and modify this GNU Manual, like GNU
     25     software.  Copies published by the Free Software Foundation raise
     26     funds for GNU development.-->
     27<meta http-equiv="Content-Style-Type" content="text/css">
     28<style type="text/css"><!--
     29  pre.display { font-family:inherit }
     30  pre.format  { font-family:inherit }
     31  pre.smalldisplay { font-family:inherit; font-size:smaller }
     32  pre.smallformat  { font-family:inherit; font-size:smaller }
     33  pre.smallexample { font-size:smaller }
     34  pre.smalllisp    { font-size:smaller }
     35--></style>
     36</head>
     37<body>
     38<h1 class="settitle">Installing GCC: Configuration</h1>
     39Like most GNU software, GCC must be configured before it can be built.
    1040This document describes the recommended configuration procedure
    1141for both native and cross targets.
    1242
    13 <p>We use <var>srcdir</var> to refer to the toplevel source directory for
     43   <p>We use <var>srcdir</var> to refer to the toplevel source directory for
    1444GCC; we use <var>objdir</var> to refer to the toplevel build/object directory.
    1545
    16 <p>If you obtained the sources via CVS, <var>srcdir</var> must refer to the top
     46   <p>If you obtained the sources via CVS, <var>srcdir</var> must refer to the top
    1747<code>gcc</code> directory, the one where the <code>MAINTAINERS</code> can be found,
    1848and not its <code>gcc</code> subdirectory, otherwise the build will fail.
    1949
    20 <p>First, we <strong>highly</strong> recommend that GCC be built into a
     50   <p>If either <var>srcdir</var> or <var>objdir</var> is located on an automounted NFS
     51file system, the shell's built-in <code>pwd</code> command will return
     52temporary pathnames.  Using these can lead to various sorts of build
     53problems.  To avoid this issue, set the <code>PWDCMD</code> environment
     54variable to an automounter-aware <code>pwd</code> command, e.g.,
     55<code>pawd</code> or <code>amq -w</code>, during the configuration and build
     56phases.
     57
     58   <p>First, we <strong>highly</strong> recommend that GCC be built into a
    2159separate directory than the sources which does <strong>not</strong> reside
    2260within the source tree.  This is how we generally build GCC; building
     
    2563of <var>srcdir</var> is unsupported.
    2664
    27 <p>If you have previously built GCC in the same directory for a
     65   <p>If you have previously built GCC in the same directory for a
    2866different target machine, do <code>make distclean</code> to delete all files
    29 that might be invalid.  One of the files this deletes is
    30 <code>Makefile</code>; if <code>make distclean</code> complains that <code>Makefile</code>
    31 does not exist, it probably means that the directory is already suitably
    32 clean.  However, with the recommended method of building in a separate
    33 <var>objdir</var>, you should simply use a different <var>objdir</var> for each
    34 target.
    35 
    36 <p>Second, when configuring a native system, either <code>cc</code> or
     67that might be invalid.  One of the files this deletes is <code>Makefile</code>;
     68if <code>make distclean</code> complains that <code>Makefile</code> does not exist
     69or issues a message like "don't know how to make distclean" it probably
     70means that the directory is already suitably clean.  However, with the
     71recommended method of building in a separate <var>objdir</var>, you should
     72simply use a different <var>objdir</var> for each target.
     73
     74   <p>Second, when configuring a native system, either <code>cc</code> or
    3775<code>gcc</code> must be in your path or you must set <code>CC</code> in
    3876your environment before running configure.  Otherwise the configuration
    3977scripts may fail.
    4078
    41 <p>Note that the bootstrap compiler and the resulting GCC must be link
     79   <p>Note that the bootstrap compiler and the resulting GCC must be link
    4280compatible, else the bootstrap will fail with linker errors about
    4381incompatible object file formats.  Several multilibed targets are
     
    4583<a href="specific.html">host/target specific installation notes</a>.
    4684
    47 <p>To configure GCC:
    48 
    49 <pre>   % mkdir <var>objdir</var>
    50    % cd <var>objdir</var>
    51    % <var>srcdir</var>/configure [<var>options</var>] [<var>target</var>]
    52 </pre>
    53 
    54 <h2><a name="TOC0">Target specification</h2>
    55 
    56 <ul>
     85   <p>To configure GCC:
     86
     87<pre class="example">        % mkdir <var>objdir</var>
     88        % cd <var>objdir</var>
     89        % <var>srcdir</var>/configure [<var>options</var>] [<var>target</var>]
     90     </pre>
     91
     92<h3 class="heading"><a name="TOC0"></a>Target specification</h3>
     93
     94     <ul>
    5795<li>GCC has code to correctly determine the correct value for <var>target</var>
    5896for nearly all native systems.  Therefore, we highly recommend you not
    5997provide a configure target when configuring a native compiler.
    6098
    61 <li><var>target</var> must be specified as <code>--target=<var>target</var></code>
     99     <li><var>target</var> must be specified as <code>--target=</code><var>target</var><code></code>
    62100when configuring a cross compiler; examples of valid targets would be
    63101i960-rtems, m68k-coff, sh-elf, etc.
    64102
    65 <li>Specifying just <var>target</var> instead of <code>--target=<var>target</var></code>
     103     <li>Specifying just <var>target</var> instead of <code>--target=</code><var>target</var><code></code>
    66104implies that the host defaults to <var>target</var>.
    67105</ul>
    68106
    69 <h2><a name="TOC1">Options specification</h2>
     107<h3 class="heading"><a name="TOC1"></a>Options specification</h3>
    70108
    71109<p>Use <var>options</var> to override several configure time options for
     
    74112work and should not normally be used.
    75113
    76 <dl>
    77 <dt><code>--prefix=<var>dirname</var></code>
    78 <dd>Specify the toplevel installation
     114     <dl>
     115<dt><code>--prefix=</code><var>dirname</var><code></code>
     116     <dd>Specify the toplevel installation
    79117directory.  This is the recommended way to install the tools into a directory
    80118other than the default.  The toplevel installation directory defaults to
    81119<code>/usr/local</code>.
    82120
    83 <p>We <strong>highly</strong> recommend against <var>dirname</var> being the same or a
    84 subdirectory of <var>objdir</var> or vice versa.
    85 
    86 <p>These additional options control where certain parts of the distribution
     121     <p>We <strong>highly</strong> recommend against <var>dirname</var> being the same or a
     122subdirectory of <var>objdir</var> or vice versa.  If specifying a directory
     123beneath a user's home directory tree, some shells will not expand
     124<var>dirname</var> correctly if it contains the <code>~</code> metacharacter; use
     125<code>$HOME</code> instead.
     126
     127     <p>These additional options control where certain parts of the distribution
    87128are installed.  Normally you should not need to use these options.
    88 <dl>
    89 <dt><code>--exec-prefix=<var>dirname</var></code>
    90 <dd>Specify the toplevel installation directory for architecture-dependent
    91 files.  The default is <code><var>prefix</var></code>.
    92 
    93 <br><dt><code>--bindir=<var>dirname</var></code>
    94 <dd>Specify the installation directory for the executables called by users
     129          <dl>
     130<dt><code>--exec-prefix=</code><var>dirname</var><code></code>
     131          <dd>Specify the toplevel installation directory for architecture-dependent
     132files.  The default is <code></code><var>prefix</var><code></code>.
     133
     134          <br><dt><code>--bindir=</code><var>dirname</var><code></code>
     135          <dd>Specify the installation directory for the executables called by users
    95136(such as <code>gcc</code> and <code>g++</code>).  The default is
    96 <code><var>exec-prefix</var>/bin</code>.
    97 
    98 <br><dt><code>--libdir=<var>dirname</var></code>
    99 <dd>Specify the installation directory for object code libraries and
    100 internal parts of GCC.  The default is <code><var>exec-prefix</var>/lib</code>.
    101 
    102 <br><dt><code>--with-slibdir=<var>dirname</var></code>
    103 <dd>Specify the installation directory for the shared libgcc library.  The
    104 default is <code><var>libdir</var></code>.
    105 
    106 <br><dt><code>--infodir=<var>dirname</var></code>
    107 <dd>Specify the installation directory for documentation in info format.
    108 The default is <code><var>prefix</var>/info</code>.
    109 
    110 <br><dt><code>--mandir=<var>dirname</var></code>
    111 <dd>Specify the installation directory for manual pages.  The default is
    112 <code><var>prefix</var>/man</code>.  (Note that the manual pages are only extracts from
    113 the full GCC manuals, which are provided in Texinfo format.  The
    114 <code>g77</code> manpage is unmaintained and may be out of date; the others
     137<code></code><var>exec-prefix</var><code>/bin</code>.
     138
     139          <br><dt><code>--libdir=</code><var>dirname</var><code></code>
     140          <dd>Specify the installation directory for object code libraries and
     141internal parts of GCC.  The default is <code></code><var>exec-prefix</var><code>/lib</code>.
     142
     143          <br><dt><code>--with-slibdir=</code><var>dirname</var><code></code>
     144          <dd>Specify the installation directory for the shared libgcc library.  The
     145default is <code></code><var>libdir</var><code></code>.
     146
     147          <br><dt><code>--infodir=</code><var>dirname</var><code></code>
     148          <dd>Specify the installation directory for documentation in info format.
     149The default is <code></code><var>prefix</var><code>/info</code>.
     150
     151          <br><dt><code>--datadir=</code><var>dirname</var><code></code>
     152          <dd>Specify the installation directory for some architecture-independent
     153data files referenced by GCC.  The default is <code></code><var>prefix</var><code>/share</code>.
     154
     155          <br><dt><code>--mandir=</code><var>dirname</var><code></code>
     156          <dd>Specify the installation directory for manual pages.  The default is
     157<code></code><var>prefix</var><code>/man</code>.  (Note that the manual pages are only extracts from
     158the full GCC manuals, which are provided in Texinfo format.  The manpages
    115159are derived by an automatic conversion process from parts of the full
    116160manual.)
    117161
    118 <br><dt><code>--with-gxx-include-dir=<var>dirname</var></code>
    119 <dd>Specify
     162          <br><dt><code>--with-gxx-include-dir=</code><var>dirname</var><code></code>
     163          <dd>Specify
    120164the installation directory for G++ header files.  The default is
    121 <code><var>prefix</var>/include/g++-v3</code>.
    122 
    123 </dl>
    124 
    125 <br><dt><code>--program-prefix=<var>prefix</var></code>
    126 <dd>GCC supports some transformations of the names of its programs when
     165<code></code><var>prefix</var><code>/include/g++-v3</code>.
     166
     167     </dl>
     168
     169     <br><dt><code>--program-prefix=</code><var>prefix</var><code></code>
     170     <dd>GCC supports some transformations of the names of its programs when
    127171installing them. This option prepends <var>prefix</var> to the names of
    128172programs to install in <var>bindir</var> (see above). For example, specifying
     
    130174being installed as <code>/usr/local/bin/foo-gcc</code>.
    131175
    132 <br><dt><code>--program-suffix=<var>suffix</var></code>
    133 <dd>Appends <var>suffix</var> to the names of programs to install in <var>bindir</var>
     176     <br><dt><code>--program-suffix=</code><var>suffix</var><code></code>
     177     <dd>Appends <var>suffix</var> to the names of programs to install in <var>bindir</var>
    134178(see above). For example, specifying <code>--program-suffix=-3.1</code>
    135179would result in <code>gcc</code> being installed as
    136180<code>/usr/local/bin/gcc-3.1</code>.
    137181
    138 <br><dt><code>--program-transform-name=<var>pattern</var></code>
    139 <dd>Applies the <code>sed</code> script <var>pattern</var> to be applied to the names
     182     <br><dt><code>--program-transform-name=</code><var>pattern</var><code></code>
     183     <dd>Applies the <code>sed</code> script <var>pattern</var> to be applied to the names
    140184of programs to install in <var>bindir</var> (see above). <var>pattern</var> has to
    141185consist of one or more basic <code>sed</code> editing commands, separated by
     
    148192to achieve this effect.
    149193
    150 <p>All three options can be combined and used together, resulting in more
     194     <p>All three options can be combined and used together, resulting in more
    151195complex conversion patterns. As a basic rule, <var>prefix</var> (and
    152196<var>suffix</var>) are prepended (appended) before further transformations
    153197can happen with a special transformation script <var>pattern</var>.
    154198
    155 <p>As currently implemented, these options only take effect for native
     199     <p>As currently implemented, this option only takes effect for native
    156200builds; cross compiler binaries' names are not transformed even when a
    157201transformation is explicitly asked for by one of these options.
    158202
    159 <p>For native builds, some of the installed programs are also installed
     203     <p>For native builds, some of the installed programs are also installed
    160204with the target alias in front of their name, as in
    161205<code>i686-pc-linux-gnu-gcc</code>. All of the above transformations happen
     
    165209<code>/usr/local/bin/i686-pc-linux-gnu-foo-gcc-3.1</code>.
    166210
    167 <p>As a last shortcoming, none of the installed Ada programs are
     211     <p>As a last shortcoming, none of the installed Ada programs are
    168212transformed yet, which will be fixed in some time.
    169213
    170 <br><dt><code>--with-local-prefix=<var>dirname</var></code>
    171 <dd>Specify the
     214     <br><dt><code>--with-local-prefix=</code><var>dirname</var><code></code>
     215     <dd>Specify the
    172216installation directory for local include files.  The default is
    173217<code>/usr/local</code>.  Specify this option if you want the compiler to
    174 search directory <code><var>dirname</var>/include</code> for locally installed
     218search directory <code></code><var>dirname</var><code>/include</code> for locally installed
    175219header files <em>instead</em> of <code>/usr/local/include</code>.
    176220
    177 <p>You should specify <code>--with-local-prefix</code> <strong>only</strong> if your
     221     <p>You should specify <code>--with-local-prefix</code> <strong>only</strong> if your
    178222site has a different convention (not <code>/usr/local</code>) for where to put
    179223site-specific files.
    180224
    181 <p>The default value for <code>--with-local-prefix</code> is <code>/usr/local</code>
     225     <p>The default value for <code>--with-local-prefix</code> is <code>/usr/local</code>
    182226regardless of the value of <code>--prefix</code>.  Specifying
    183227<code>--prefix</code> has no effect on which directory GCC searches for
     
    185229logical.
    186230
    187 <p>The purpose of <code>--prefix</code> is to specify where to <em>install
     231     <p>The purpose of <code>--prefix</code> is to specify where to <em>install
    188232GCC</em>.  The local header files in <code>/usr/local/include</code>--if you put
    189233any in that directory--are not part of GCC.  They are part of other
     
    191235another directory which is based on the <code>--prefix</code> value.)
    192236
    193 <p>Both the local-prefix include directory and the GCC-prefix include
     237     <p>Both the local-prefix include directory and the GCC-prefix include
    194238directory are part of GCC's "system include" directories.  Although these
    195239two directories are not fixed, they need to be searched in the proper
     
    199243is that pedantic warnings are turned off for headers in these directories.
    200244
    201 <p>Some autoconf macros add <code>-I <var>directory</var></code> options to the
     245     <p>Some autoconf macros add <code>-I </code><var>directory</var><code></code> options to the
    202246compiler command line, to ensure that directories containing installed
    203247packages' headers are searched.  When <var>directory</var> is one of GCC's
     
    207251directory will still be searched.
    208252
    209 <p>GCC automatically searches for ordinary libraries using
     253     <p>GCC automatically searches for ordinary libraries using
    210254<code>GCC_EXEC_PREFIX</code>.  Thus, when the same installation prefix is
    211255used for both GCC and packages, GCC will automatically search for
     
    214258installed as a system compiler in <code>/usr</code>.
    215259
    216 <p>Sites that need to install multiple versions of GCC may not want to
     260     <p>Sites that need to install multiple versions of GCC may not want to
    217261use the above simple configuration.  It is possible to use the
    218262<code>--program-prefix</code>, <code>--program-suffix</code> and
     
    224268(e.g., with <code>LIBRARY_PATH</code>).
    225269
    226 <p>The same value can be used for both <code>--with-local-prefix</code> and
     270     <p>The same value can be used for both <code>--with-local-prefix</code> and
    227271<code>--prefix</code> provided it is not <code>/usr</code>.  This can be used
    228272to avoid the default search of <code>/usr/local/include</code>.
    229273
    230 <p><strong>Do not</strong> specify <code>/usr</code> as the <code>--with-local-prefix</code>!
     274     <p><strong>Do not</strong> specify <code>/usr</code> as the <code>--with-local-prefix</code>!
    231275The directory you use for <code>--with-local-prefix</code> <strong>must not</strong>
    232276contain any of the system's standard header files.  If it did contain
     
    235279file corrections made by the <code>fixincludes</code> script.
    236280
    237 <p>Indications are that people who use this option use it based on mistaken
     281     <p>Indications are that people who use this option use it based on mistaken
    238282ideas of what it is for.  People use it as if it specified where to
    239283install part of GCC.  Perhaps they make this assumption because
    240284installing GCC creates the directory.
    241285
    242 <br><dt><code>--enable-shared[=<var>package</var>[,<small>...</small>]]</code>
    243 <dd>Build shared versions of libraries, if shared libraries are supported on
     286     <br><dt><code>--enable-shared[=</code><var>package</var><code>[,...]]</code>
     287     <dd>Build shared versions of libraries, if shared libraries are supported on
    244288the target platform.  Unlike GCC 2.95.x and earlier, shared libraries
    245289are enabled by default on all platforms that support shared libraries,
     
    247291default.
    248292
    249 <p>If a list of packages is given as an argument, build shared libraries
     293     <p>If a list of packages is given as an argument, build shared libraries
    250294only for the listed packages.  For other packages, only static libraries
    251295will be built.  Package names currently recognized in the GCC tree are
     
    257301<code>libiberty</code> do not support shared libraries at all.
    258302
    259 <p>Use <code>--disable-shared</code> to build only static libraries.  Note that
     303     <p>Use <code>--disable-shared</code> to build only static libraries.  Note that
    260304<code>--disable-shared</code> does not accept a list of package names as
    261305argument, only <code>--enable-shared</code> does.
    262306
    263 <br><dt><code><a name="with-gnu-as"></a>--with-gnu-as</code>
    264 <dd>Specify that the compiler should assume that the
     307     <br><dt><code><a name="with-gnu-as"></a>--with-gnu-as</code>
     308     <dd>Specify that the compiler should assume that the
    265309assembler it finds is the GNU assembler.  However, this does not modify
    266 the rules to find an assembler and will result in confusion if found
    267 assembler is not actually the GNU assembler.  (Confusion will also
     310the rules to find an assembler and will result in confusion if the
     311assembler found is not actually the GNU assembler.  (Confusion may also
    268312result if the compiler finds the GNU assembler but has not been
    269313configured with <code>--with-gnu-as</code>.)  If you have more than one
    270314assembler installed on your system, you may want to use this option in
    271 connection with <code>--with-as=<var>pathname</var></code>.
    272 
    273 <p>The following systems are the only ones where it makes a difference
     315connection with <code>--with-as=</code><var>pathname</var><code></code>.
     316
     317     <p>The following systems are the only ones where it makes a difference
    274318whether you use the GNU assembler.  On any other system,
    275319<code>--with-gnu-as</code> has no effect.
    276320
    277 <ul>
    278 <li><code>hppa1.0-<var>any</var>-<var>any</var></code>
    279 <li><code>hppa1.1-<var>any</var>-<var>any</var></code>
    280 <li><code>i386-<var>any</var>-sysv</code>
    281 <li><code>i386-<var>any</var>-isc</code>
    282 <li><code>i860-<var>any</var>-bsd</code>
     321          <ul>
     322<li><code>hppa1.0-</code><var>any</var><code>-</code><var>any</var><code></code>
     323<li><code>hppa1.1-</code><var>any</var><code>-</code><var>any</var><code></code>
     324<li><code>i386-</code><var>any</var><code>-sysv</code>
    283325<li><code>m68k-bull-sysv</code>
    284326<li><code>m68k-hp-hpux</code>
    285 <li><code>m68k-sony-bsd</code>
    286 <li><code>m68k-altos-sysv</code>
    287327<li><code>m68000-hp-hpux</code>
    288328<li><code>m68000-att-sysv</code>
    289 <li><code><var>any</var>-lynx-lynxos</code>
    290 <li><code>mips-<var>any</var></code>
     329<li><code></code><var>any</var><code>-lynx-lynxos</code>
     330<li><code>mips-</code><var>any</var><code></code>
     331<li><code>sparc-sun-solaris2.</code><var>any</var><code></code>
     332<li><code>sparc64-</code><var>any</var><code>-solaris2.</code><var>any</var><code></code>
    291333</ul>
    292334
    293 <p>On the systems listed above (except for the HP-PA, for ISC on the
    294 386, and for <code>mips-sgi-irix5.*</code>), if you use the GNU assembler,
     335     <p>On the systems listed above (except for the HP-PA, the SPARC, for ISC on
     336the 386, and for <code>mips-sgi-irix5.*</code>), if you use the GNU assembler,
    295337you should also use the GNU linker (and specify <code>--with-gnu-ld</code>).
    296338
    297 <br><dt><code>--with-as=<var>pathname</var></code>
    298 <dd>Specify that the
     339     <br><dt><code><a name="with-as"></a>--with-as=</code><var>pathname</var><code></code>
     340     <dd>Specify that the
    299341compiler should use the assembler pointed to by <var>pathname</var>, rather
    300342than the one found by the standard rules to find an assembler, which
    301343are:
    302 <ul>
     344          <ul>
    303345<li>Check the
    304 <code><var>exec_prefix</var>/lib/gcc-lib/<var>target</var>/<var>version</var></code>
     346<code></code><var>exec_prefix</var><code>/lib/gcc-lib/</code><var>target</var><code>/</code><var>version</var><code></code>
    305347directory, where <var>exec_prefix</var> defaults to <var>prefix</var> which
    306348defaults to <code>/usr/local</code> unless overridden by the
    307 <code>--prefix=<var>pathname</var></code> switch described above. <var>target</var> is the
     349<code>--prefix=</code><var>pathname</var><code></code> switch described above. <var>target</var> is the
    308350target system triple, such as <code>sparc-sun-solaris2.7</code>, and
    309351<var>version</var> denotes the GCC version, such as 3.0.
     
    311353Sun Solaris 2).
    312354</ul>
    313 Note that these rules do not check for the value of <code>PATH</code>.  You may
     355     Note that these rules do not check for the value of <code>PATH</code>.  You may
    314356want to use <code>--with-as</code> if no assembler is installed in the
    315357directories listed above, or if you have multiple assemblers installed
    316358and want to choose one that is not found by the above rules.
    317359
    318 <br><dt><code><a name="with-gnu-ld"></a>--with-gnu-ld</code>
    319 <dd>Same as <a href="#with-gnu-as"><code>--with-gnu-as</code></a>
    320 but for linker.
    321 
    322 <br><dt><code>--with-ld=<var>pathname</var></code>
    323 <dd>Same as
    324 <code>--with-as</code>, but for the linker.
    325 
    326 <br><dt><code>--with-stabs</code>
    327 <dd>Specify that stabs debugging
     360     <br><dt><code><a name="with-gnu-ld"></a>--with-gnu-ld</code>
     361     <dd>Same as <a href="#with-gnu-as"><code>--with-gnu-as</code></a>
     362but for the linker.
     363
     364     <br><dt><code>--with-ld=</code><var>pathname</var><code></code>
     365     <dd>Same as <a href="#with-as"><code>--with-as</code></a>
     366but for the linker.
     367
     368     <br><dt><code>--with-stabs</code>
     369     <dd>Specify that stabs debugging
    328370information should be used instead of whatever format the host normally
    329371uses.  Normally GCC uses the same debug format as the host system.
    330372
    331 <p>On MIPS based systems and on Alphas, you must specify whether you want
     373     <p>On MIPS based systems and on Alphas, you must specify whether you want
    332374GCC to create the normal ECOFF debugging format, or to use BSD-style
    333375stabs passed through the ECOFF symbol table.  The normal ECOFF debug
     
    335377handle other languages, but it only works with the GNU debugger GDB.
    336378
    337 <p>Normally, GCC uses the ECOFF debugging format by default; if you
     379     <p>Normally, GCC uses the ECOFF debugging format by default; if you
    338380prefer BSD stabs, specify <code>--with-stabs</code> when you configure GCC.
    339381
    340 <p>No matter which default you choose when you configure GCC, the user
     382     <p>No matter which default you choose when you configure GCC, the user
    341383can use the <code>-gcoff</code> and <code>-gstabs+</code> options to specify explicitly
    342384the debug format for a particular compilation.
    343385
    344 <p><code>--with-stabs</code> is meaningful on the ISC system on the 386, also, if
     386     <p><code>--with-stabs</code> is meaningful on the ISC system on the 386, also, if
    345387<code>--with-gas</code> is used.  It selects use of stabs debugging
    346388information embedded in COFF output.  This kind of debugging information
    347389supports C++ well; ordinary COFF debugging information does not.
    348390
    349 <p><code>--with-stabs</code> is also meaningful on 386 systems running SVR4.  It
     391     <p><code>--with-stabs</code> is also meaningful on 386 systems running SVR4.  It
    350392selects use of stabs debugging information embedded in ELF output.  The
    351393C++ compiler currently (2.6.0) does not support the DWARF debugging
     
    354396tools can not generate or interpret stabs.
    355397
    356 <br><dt><code>--disable-multilib</code>
    357 <dd>Specify that multiple target
     398     <br><dt><code>--disable-multilib</code>
     399     <dd>Specify that multiple target
    358400libraries to support different target variants, calling
    359401conventions, etc should not be built.  The default is to build a
    360402predefined set of them.
    361403
    362 <p>Some targets provide finer-grained control over which multilibs are built
     404     <p>Some targets provide finer-grained control over which multilibs are built
    363405(e.g., <code>--disable-softfloat</code>):
    364 <dl>
     406          <dl>
    365407<dt><code>arc-*-elf*</code>
    366 <dd>biendian.
    367 
    368 <br><dt><code>arm-*-*</code>
    369 <dd>fpu, 26bit, underscore, interwork, biendian, nofmult.
    370 
    371 <br><dt><code>m68*-*-*</code>
    372 <dd>softfloat, m68881, m68000, m68020.
    373 
    374 <br><dt><code>mips*-*-*</code>
    375 <dd>single-float, biendian, softfloat.
    376 
    377 <br><dt><code>powerpc*-*-*, rs6000*-*-*</code>
    378 <dd>aix64, pthread, softfloat, powercpu, powerpccpu, powerpcos, biendian,
     408          <dd>biendian.
     409
     410          <br><dt><code>arm-*-*</code>
     411          <dd>fpu, 26bit, underscore, interwork, biendian, nofmult.
     412
     413          <br><dt><code>m68*-*-*</code>
     414          <dd>softfloat, m68881, m68000, m68020.
     415
     416          <br><dt><code>mips*-*-*</code>
     417          <dd>single-float, biendian, softfloat.
     418
     419          <br><dt><code>powerpc*-*-*, rs6000*-*-*</code>
     420          <dd>aix64, pthread, softfloat, powercpu, powerpccpu, powerpcos, biendian,
    379421sysv, aix.
    380422
    381 </dl>
    382 
    383 <br><dt><code>--enable-threads</code>
    384 <dd>Specify that the target
     423     </dl>
     424
     425     <br><dt><code>--enable-threads</code>
     426     <dd>Specify that the target
    385427supports threads.  This affects the Objective-C compiler and runtime
    386428library, and exception handling for other languages like C++ and Java.
    387429On some systems, this is the default.
    388430
    389 <p>In general, the best (and, in many cases, the only known) threading
     431     <p>In general, the best (and, in many cases, the only known) threading
    390432model available will be configured for use.  Beware that on some
    391433systems, gcc has not been taught what threading models are generally
     
    393435alias for <code>--enable-threads=single</code>.
    394436
    395 <br><dt><code>--disable-threads</code>
    396 <dd>Specify that threading support should be disabled for the system.
     437     <br><dt><code>--disable-threads</code>
     438     <dd>Specify that threading support should be disabled for the system.
    397439This is an alias for <code>--enable-threads=single</code>.
    398440
    399 <br><dt><code>--enable-threads=<var>lib</var></code>
    400 <dd>Specify that
     441     <br><dt><code>--enable-threads=</code><var>lib</var><code></code>
     442     <dd>Specify that
    401443<var>lib</var> is the thread support library.  This affects the Objective-C
    402444compiler and runtime library, and exception handling for other languages
    403445like C++ and Java.  The possibilities for <var>lib</var> are:
    404446
    405 <dl>
     447          <dl>
    406448<dt><code>aix</code>
    407 <dd>AIX thread support.
     449          <dd>AIX thread support.
    408450<br><dt><code>dce</code>
    409 <dd>DCE thread support.
     451          <dd>DCE thread support.
    410452<br><dt><code>mach</code>
    411 <dd>Generic MACH thread support, known to work on NeXTSTEP.  (Please note
     453          <dd>Generic MACH thread support, known to work on NeXTSTEP.  (Please note
    412454that the file needed to support this configuration, <code>gthr-mach.h</code>, is
    413455missing and thus this setting will cause a known bootstrap failure.)
    414456<br><dt><code>no</code>
    415 <dd>This is an alias for <code>single</code>.
     457          <dd>This is an alias for <code>single</code>.
    416458<br><dt><code>posix</code>
    417 <dd>Generic POSIX thread support.
     459          <dd>Generic POSIX thread support.
    418460<br><dt><code>pthreads</code>
    419 <dd>Same as <code>posix</code> on arm*-*-linux*, *-*-chorusos* and *-*-freebsd*
     461          <dd>Same as <code>posix</code> on arm*-*-linux*, *-*-chorusos* and *-*-freebsd*
    420462only.  A future release of gcc might remove this alias or extend it
    421463to all platforms.
    422464<br><dt><code>rtems</code>
    423 <dd>RTEMS thread support.
     465          <dd>RTEMS thread support.
    424466<br><dt><code>single</code>
    425 <dd>Disable thread support, should work for all platforms.
     467          <dd>Disable thread support, should work for all platforms.
    426468<br><dt><code>solaris</code>
    427 <dd>Sun Solaris 2 thread support.
     469          <dd>Sun Solaris 2 thread support.
    428470<br><dt><code>vxworks</code>
    429 <dd>VxWorks thread support.
     471          <dd>VxWorks thread support.
    430472<br><dt><code>win32</code>
    431 <dd>Microsoft Win32 API thread support.
     473          <dd>Microsoft Win32 API thread support.
    432474</dl>
    433475
    434 <br><dt><code>--with-cpu=<var>cpu</var></code>
    435 <dd>Specify which cpu variant the
     476     <br><dt><code>--with-cpu=</code><var>cpu</var><code></code>
     477     <dd>Specify which cpu variant the
    436478compiler should generate code for by default.  This is currently
    437 only supported on the some ports, specifically arm, powerpc, and
     479only supported on some ports, specifically arm, powerpc, and
    438480SPARC.  If configure does not recognize the model name (e.g. arm700,
    439 603e, or ultrasparc) you provide, please check the configure script
    440 for a complete list of supported models.
    441 
    442 <br><dt><code>--enable-altivec</code>
    443 <dd>Specify that the target supports AltiVec vector enhancements.  This
     481603e, or ultrasparc) you provide, please check the
     482<code>gcc/config.gcc</code> script for a complete list of supported models.
     483
     484     <br><dt><code>--enable-altivec</code>
     485     <dd>Specify that the target supports AltiVec vector enhancements.  This
    444486option will adjust the ABI for AltiVec enhancements, as well as generate
    445487AltiVec code when appropriate.  This option is only available for
    446488PowerPC systems.
    447489
    448 <br><dt><code>--enable-target-optspace</code>
    449 <dd>Specify that target
     490     <br><dt><code>--enable-target-optspace</code>
     491     <dd>Specify that target
    450492libraries should be optimized for code space instead of code speed.
    451493This is the default for the m32r platform.
    452494
    453 <br><dt><code>--disable-cpp</code>
    454 <dd>Specify that a user visible <code>cpp</code> program should not be installed.
    455 
    456 <br><dt><code>--with-cpp-install-dir=<var>dirname</var></code>
    457 <dd>Specify that the user visible <code>cpp</code> program should be installed
    458 in <code><var>prefix</var>/<var>dirname</var>/cpp</code>, in addition to <var>bindir</var>.
    459 
    460 <br><dt><code>--enable-maintainer-mode</code>
    461 <dd>The build rules that
     495     <br><dt><code>--disable-cpp</code>
     496     <dd>Specify that a user visible <code>cpp</code> program should not be installed.
     497
     498     <br><dt><code>--with-cpp-install-dir=</code><var>dirname</var><code></code>
     499     <dd>Specify that the user visible <code>cpp</code> program should be installed
     500in <code></code><var>prefix</var><code>/</code><var>dirname</var><code>/cpp</code>, in addition to <var>bindir</var>.
     501
     502     <br><dt><code>--enable-initfini-array</code>
     503     <dd>Force the use of sections <code>.init_array</code> and <code>.fini_array</code>
     504(instead of <code>.init</code> and <code>.fini</code>) for constructors and
     505destructors.  Option <code>--disable-initfini-array</code> has the
     506opposite effect.  If neither option is specified, the configure script
     507will try to guess whether the <code>.init_array</code> and
     508<code>.fini_array</code> sections are supported and, if they are, use them.
     509
     510     <br><dt><code>--enable-maintainer-mode</code>
     511     <dd>The build rules that
    462512regenerate the GCC master message catalog <code>gcc.pot</code> are normally
    463513disabled.  This is because it can only be rebuilt if the complete source
     
    467517to do so.
    468518
    469 <br><dt><code>--enable-version-specific-runtime-libs</code>
    470 <dd>Specify
     519     <br><dt><code>--enable-version-specific-runtime-libs</code>
     520     <dd>Specify
    471521that runtime libraries should be installed in the compiler specific
    472 subdirectory (<code><var>libsubdir</var></code>) rather than the usual places.  In
     522subdirectory (<code></code><var>libsubdir</var><code></code>) rather than the usual places.  In
    473523addition, <code>libstdc++</code>'s include files will be installed in
    474 <code><var>libsubdir</var>/include/g++</code> unless you overruled it by using
    475 <code>--with-gxx-include-dir=<var>dirname</var></code>.  Using this option is
     524<code></code><var>libsubdir</var><code>/include/g++</code> unless you overruled it by using
     525<code>--with-gxx-include-dir=</code><var>dirname</var><code></code>.  Using this option is
    476526particularly useful if you intend to use several versions of GCC in
    477527parallel. This is currently supported by <code>libf2c</code> and
     
    479529changed in this case.
    480530
    481 <br><dt><code>--enable-languages=<var>lang1</var>,<var>lang2</var>,<small>...</small></code>
    482 <dd>Specify that only a particular subset of compilers and
     531     <br><dt><code>--enable-languages=</code><var>lang1</var><code>,</code><var>lang2</var><code>,...</code>
     532     <dd>Specify that only a particular subset of compilers and
    483533their runtime libraries should be built.  For a list of valid values for
    484534<var>langN</var> you can issue the following command in the
    485535<code>gcc</code> directory of your GCC source tree:<br>
    486 <pre>grep language= */config-lang.in
    487 </pre>
    488 Currently, you can use any of the following:
     536     <pre class="example">          grep language= */config-lang.in
     537          </pre>
     538     Currently, you can use any of the following:
    489539<code>ada</code>, <code>c</code>, <code>c++</code>, <code>f77</code>, <code>java</code>, <code>objc</code>.
    490540Building the Ada compiler has special requirements, see below.<br>
     
    494544language sub-directories might not have been configured!
    495545
    496 <br><dt><code>--disable-libgcj</code>
    497 <dd>Specify that the run-time libraries
     546     <br><dt><code>--disable-libgcj</code>
     547     <dd>Specify that the run-time libraries
    498548used by GCJ should not be built.  This is useful in case you intend
    499549to use GCJ with some other run-time, or you're going to install it
     
    506556you may use <code>--enable-libgcj</code> to override the default.
    507557
    508 <br><dt><code>--with-dwarf2</code>
    509 <dd>Specify that the compiler should
     558     <br><dt><code>--with-dwarf2</code>
     559     <dd>Specify that the compiler should
    510560use DWARF 2 debugging information as the default.
    511561
    512 <br><dt><code>--enable-win32-registry</code>
    513 <dt><code>--enable-win32-registry=<var>key</var></code>
    514 <dt><code>--disable-win32-registry</code>
    515 <dd>The <code>--enable-win32-registry</code> option enables Windows-hosted GCC
     562     <br><dt><code>--enable-win32-registry</code>
     563     <dd><dt><code>--enable-win32-registry=</code><var>key</var><code></code>
     564     <dd><dt><code>--disable-win32-registry</code>
     565     <dd>The <code>--enable-win32-registry</code> option enables Windows-hosted GCC
    516566to look up installations paths in the registry using the following key:
    517567
    518 <pre><code>HKEY_LOCAL_MACHINE\SOFTWARE\Free Software Foundation\<var>key</var></code>
    519 </pre>
    520 
    521 <p><var>key</var> defaults to GCC version number, and can be overridden by the
    522 <code>--enable-win32-registry=<var>key</var></code> option. Vendors and distributors
     568     <pre class="smallexample">          <code>HKEY_LOCAL_MACHINE\SOFTWARE\Free Software Foundation\</code><var>key</var><code></code>
     569          </pre>
     570
     571     <p><var>key</var> defaults to GCC version number, and can be overridden by the
     572<code>--enable-win32-registry=</code><var>key</var><code></code> option. Vendors and distributors
    523573who use custom installers are encouraged to provide a different key,
    524574perhaps one comprised of vendor name and GCC version number, to
     
    527577option.  This option has no effect on the other hosts.
    528578
    529 <br><dt><code>--nfp</code>
    530 <dd>Specify that the machine does not have a floating point unit.  This
    531 option only applies to <code>m68k-sun-sunos<var>n</var></code> and
    532 <code>m68k-isi-bsd</code>.  On any other system, <code>--nfp</code> has no effect.
    533 
    534 <br><dt><code>--enable-checking</code>
    535 <dt><code>--enable-checking=<var>list</var></code>
    536 <dd>When you specify this option, the compiler is built to perform checking
     579     <br><dt><code>--nfp</code>
     580     <dd>Specify that the machine does not have a floating point unit.  This
     581option only applies to <code>m68k-sun-sunos</code><var>n</var><code></code>.  On any other
     582system, <code>--nfp</code> has no effect.
     583
     584     <br><dt><code>--enable-checking</code>
     585     <dd><dt><code>--enable-checking=</code><var>list</var><code></code>
     586     <dd>When you specify this option, the compiler is built to perform checking
    537587of tree node types when referencing fields of that node, and some other
    538588internal consistency checks.  This does not change the generated code,
     
    542592but off for releases.  More control over the checks may be had by
    543593specifying <var>list</var>; the categories of checks available are
    544 <code>misc</code>, <code>tree</code>, <code>gc</code>, <code>rtl</code> and <code>gcac</code>.  The
    545 default when <var>list</var> is not specified is <code>misc,tree,gc</code>; the
    546 checks <code>rtl</code> and <code>gcac</code> are very expensive.
    547 
    548 <br><dt><code>--enable-nls</code>
    549 <dt><code>--disable-nls</code>
    550 <dd>The <code>--enable-nls</code> option enables Native Language Support (NLS),
     594<code>misc</code>, <code>tree</code>, <code>gc</code>, <code>rtl</code>, <code>rtlflag</code>,
     595<code>gcac</code> and <code>valgrind</code>.  The check <code>valgrind</code> requires the
     596external <code>valgrind</code> simulator, available from
     597<a href="http://developer.kde.org/~sewardj/">http://developer.kde.org/~sewardj/</a>.  The default when <var>list</var> is
     598not specified is <code>misc,tree,gc,rtlflag</code>; the checks <code>rtl</code>,
     599<code>gcac</code> and <code>valgrind</code> are very expensive.
     600
     601     <br><dt><code>--enable-coverage</code>
     602     <dd><dt><code>--enable-coverage=</code><var>level</var><code></code>
     603     <dd>With this option, the compiler is built to collect self coverage
     604information, every time it is run. This is for internal development
     605purposes, and only works when the compiler is being built with gcc. The
     606<var>level</var> argument controls whether the compiler is built optimized or
     607not, values are <code>opt</code> and <code>noopt</code>. For coverage analysis you
     608want to disable optimization, for performance analysis you want to
     609enable optimization. When coverage is enabled, the default level is
     610without optimization.
     611
     612     <br><dt><code>--enable-nls</code>
     613     <dd><dt><code>--disable-nls</code>
     614     <dd>The <code>--enable-nls</code> option enables Native Language Support (NLS),
    551615which lets GCC output diagnostics in languages other than American
    552616English.  Native Language Support is enabled by default if not doing a
    553617canadian cross build.  The <code>--disable-nls</code> option disables NLS.
    554618
    555 <br><dt><code>--with-included-gettext</code>
    556 <dd>If NLS is enabled, the <code>--with-included-gettext</code> option causes the build
     619     <br><dt><code>--with-included-gettext</code>
     620     <dd>If NLS is enabled, the <code>--with-included-gettext</code> option causes the build
    557621procedure to prefer its copy of GNU <code>gettext</code>.
    558622
    559 <br><dt><code>--with-catgets</code>
    560 <dd>If NLS is enabled, and if the host lacks <code>gettext</code> but has the
     623     <br><dt><code>--with-catgets</code>
     624     <dd>If NLS is enabled, and if the host lacks <code>gettext</code> but has the
    561625inferior <code>catgets</code> interface, the GCC build procedure normally
    562626ignores <code>catgets</code> and instead uses GCC's copy of the GNU
     
    564628build procedure to use the host's <code>catgets</code> in this situation.
    565629
    566 <br><dt><code>--with-libiconv-prefix=<var>dir</var></code>
    567 <dd>Search for libiconv header files in <code><var>dir</var>/include</code> and
    568 libiconv library files in <code><var>dir</var>/lib</code>.
    569 
    570 <br><dt><code>--with-system-zlib</code>
    571 <dd>Use installed zlib rather than that included with GCC.  This option
     630     <br><dt><code>--with-libiconv-prefix=</code><var>dir</var><code></code>
     631     <dd>Search for libiconv header files in <code></code><var>dir</var><code>/include</code> and
     632libiconv library files in <code></code><var>dir</var><code>/lib</code>.
     633
     634     <br><dt><code>--with-system-zlib</code>
     635     <dd>Use installed zlib rather than that included with GCC.  This option
    572636only applies if the Java front end is being built.
    573637
    574 <br><dt><code>--enable-obsolete</code>
    575 <dd>Enable configuration for an obsoleted system.  If you attempt to
     638     <br><dt><code>--enable-obsolete</code>
     639     <dd>Enable configuration for an obsoleted system.  If you attempt to
    576640configure GCC for a system (build, host, or target) which has been
    577641obsoleted, and you do not specify this flag, configure will halt with an
    578642error message.
    579643
    580 <p>All support for systems which have been obsoleted in one release of GCC
     644     <p>All support for systems which have been obsoleted in one release of GCC
    581645is removed entirely in the next major release, unless someone steps
    582646forward to maintain the port.
    583647</dl>
    584648
    585 <p>Some options which only apply to building cross compilers:
    586 <dl>
    587 <dt><code>--with-headers=<var>dir</var></code>
    588 <dd>Specifies a directory
    589 which has target include files.
    590 <em>This option is required</em> when building a cross
    591 compiler, if <code><var>prefix</var>/<var>target</var>/sys-include</code> doesn't pre-exist.
    592 These include files will be copied into the <code>gcc</code> install directory.
    593 <code>fixincludes</code> will be run on these files to make them compatible with
    594 GCC.
    595 <br><dt><code>--with-libs=``<var>dir1</var> <var>dir2</var> <small>...</small> <var>dirN</var>''</code>
    596 <dd>Specifies a list of directories which contain the target runtime
     649   <p>Some options which only apply to building cross compilers:
     650     <dl>
     651<dt><code>--with-sysroot</code>
     652     <dd><dt><code>--with-sysroot=</code><var>dir</var><code></code>
     653     <dd>Tells GCC to consider <var>dir</var> as the root of a tree that contains a
     654(subset of) the root filesystem of the target operating system.
     655Target system headers, libraries and run-time object files will be
     656searched in there.  The specified directory is not copied into the
     657install tree, unlike the options <code>--with-headers</code> and
     658<code>--with-libs</code> that this option obsoletes.  The default value,
     659in case <code>--with-sysroot</code> is not given an argument, is
     660<code>${gcc_tooldir}/sys-root</code>.  If the specified directory is a
     661subdirectory of <code>${exec_prefix}</code>, then it will be found relative to
     662the GCC binaries if the installation tree is moved.
     663
     664     <br><dt><code>--with-headers</code>
     665     <dd><dt><code>--with-headers=</code><var>dir</var><code></code>
     666     <dd>Deprecated in favor of <code>--with-sysroot</code>.
     667Specifies that target headers are available when building a cross compiler.
     668The <var>dir</var> argument specifies a directory which has the target include
     669files.  These include files will be copied into the <code>gcc</code> install
     670directory.  <em>This option with the </em><var>dir</var><em> argument is required</em> when
     671building a cross compiler, if <code></code><var>prefix</var><code>/</code><var>target</var><code>/sys-include</code>
     672doesn't pre-exist.  If <code></code><var>prefix</var><code>/</code><var>target</var><code>/sys-include</code> does
     673pre-exist, the <var>dir</var> argument may be omitted.  <code>fixincludes</code>
     674will be run on these files to make them compatible with GCC.
     675<br><dt><code>--with-libs</code>
     676     <dd><dt><code>--with-libs=``</code><var>dir1</var><code> </code><var>dir2</var><code> ... </code><var>dirN</var><code>''</code>
     677     <dd>Deprecated in favor of <code>--with-sysroot</code>.
     678Specifies a list of directories which contain the target runtime
    597679libraries.  These libraries will be copied into the <code>gcc</code> install
    598 directory.
     680directory.  If the directory list is omitted, this option has no
     681effect.
    599682<br><dt><code>--with-newlib</code>
    600 <dd>Specifies that <code>newlib</code> is
     683     <dd>Specifies that <code>newlib</code> is
    601684being used as the target C library.  This causes <code>__eprintf</code> to be
    602685omitted from <code>libgcc.a</code> on the assumption that it will be provided by
     
    604687</dl>
    605688
    606 <p>Note that each <code>--enable</code> option has a corresponding
     689   <p>Note that each <code>--enable</code> option has a corresponding
    607690<code>--disable</code> option and that each <code>--with</code> option has a
    608691corresponding <code>--without</code> option.
    609692
    610 <hr />
     693   <hr />
    611694<p>
    612695<a href="./index.html">Return to the GCC Installation page</a>
    613696
    614 </body></html>
    615 
     697   </body></html>
     698
Note: See TracChangeset for help on using the changeset viewer.