Retro68/gcc/INSTALL/finalinstall.html

228 lines
8.7 KiB
HTML
Raw Normal View History

2018-12-28 15:30:48 +00:00
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
2019-06-02 15:48:37 +00:00
<!-- Copyright (C) 1988-2019 Free Software Foundation, Inc.
2012-03-27 23:13:14 +00:00
2018-12-28 15:30:48 +00:00
Permission is granted to copy, distribute and/or modify this document
2012-03-27 23:13:14 +00:00
under the terms of the GNU Free Documentation License, Version 1.3 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
2018-12-28 15:30:48 +00:00
license is included in the section entitled "GNU
Free Documentation License".
2012-03-27 23:13:14 +00:00
(a) The FSF's Front-Cover Text is:
2018-12-28 15:30:48 +00:00
A GNU Manual
2012-03-27 23:13:14 +00:00
(b) The FSF's Back-Cover Text is:
2018-12-28 15:30:48 +00:00
You have freedom to copy and modify this GNU Manual, like GNU
2012-03-27 23:13:14 +00:00
software. Copies published by the Free Software Foundation raise
2018-12-28 15:30:48 +00:00
funds for GNU development. -->
2019-06-02 15:48:37 +00:00
<!-- Created by GNU Texinfo 6.5, http://www.gnu.org/software/texinfo/ -->
2018-12-28 15:30:48 +00:00
<head>
2019-06-02 15:48:37 +00:00
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
2018-12-28 15:30:48 +00:00
<title>Installing GCC</title>
<meta name="description" content="Installing GCC">
<meta name="keywords" content="Installing GCC">
<meta name="resource-type" content="document">
<meta name="distribution" content="global">
<meta name="Generator" content="makeinfo">
<style type="text/css">
<!--
a.summary-letter {text-decoration: none}
blockquote.indentedblock {margin-right: 0em}
blockquote.smallindentedblock {margin-right: 0em; font-size: smaller}
blockquote.smallquotation {font-size: smaller}
div.display {margin-left: 3.2em}
div.example {margin-left: 3.2em}
div.lisp {margin-left: 3.2em}
div.smalldisplay {margin-left: 3.2em}
div.smallexample {margin-left: 3.2em}
div.smalllisp {margin-left: 3.2em}
kbd {font-style: oblique}
pre.display {font-family: inherit}
pre.format {font-family: inherit}
pre.menu-comment {font-family: serif}
pre.menu-preformatted {font-family: serif}
pre.smalldisplay {font-family: inherit; font-size: smaller}
pre.smallexample {font-size: smaller}
pre.smallformat {font-family: inherit; font-size: smaller}
pre.smalllisp {font-size: smaller}
span.nolinebreak {white-space: nowrap}
span.roman {font-family: initial; font-weight: normal}
span.sansserif {font-family: sans-serif; font-weight: normal}
ul.no-bullet {list-style: none}
-->
</style>
2012-03-27 23:13:14 +00:00
</head>
2018-12-28 15:30:48 +00:00
<body lang="en">
<h1 class="settitle" align="center">Installing GCC</h1>
<p>Now that GCC has been built (and optionally tested), you can install it with
</p><div class="smallexample">
<pre class="smallexample">cd <var>objdir</var> &amp;&amp; make install
</pre></div>
<p>We strongly recommend to install into a target directory where there is
2012-03-27 23:13:14 +00:00
no previous version of GCC present. Also, the GNAT runtime should not
be stripped, as this would break certain features of the debugger that
depend on this debugging information (catching Ada exceptions for
instance).
2018-12-28 15:30:48 +00:00
</p>
<p>That step completes the installation of GCC; user level binaries can
be found in <samp><var>prefix</var>/bin</samp> where <var>prefix</var> is the value
you specified with the <samp>--prefix</samp> to configure (or
<samp>/usr/local</samp> by default). (If you specified <samp>--bindir</samp>,
2012-03-27 23:13:14 +00:00
that directory will be used instead; otherwise, if you specified
2018-12-28 15:30:48 +00:00
<samp>--exec-prefix</samp>, <samp><var>exec-prefix</var>/bin</samp> will be used.)
Headers for the C++ library are installed in
2018-12-28 15:30:48 +00:00
<samp><var>prefix</var>/include</samp>; libraries in <samp><var>libdir</var></samp>
(normally <samp><var>prefix</var>/lib</samp>); internal parts of the compiler in
<samp><var>libdir</var>/gcc</samp> and <samp><var>libexecdir</var>/gcc</samp>; documentation
2012-03-27 23:13:14 +00:00
in info format in <samp><var>infodir</var></samp> (normally
2018-12-28 15:30:48 +00:00
<samp><var>prefix</var>/info</samp>).
</p>
<p>When installing cross-compilers, GCC&rsquo;s executables
2012-03-27 23:13:14 +00:00
are not only installed into <samp><var>bindir</var></samp>, that
2018-12-28 15:30:48 +00:00
is, <samp><var>exec-prefix</var>/bin</samp>, but additionally into
<samp><var>exec-prefix</var>/<var>target-alias</var>/bin</samp>, if that directory
exists. Typically, such <em>tooldirs</em> hold target-specific
2012-03-27 23:13:14 +00:00
binutils, including assembler and linker.
2018-12-28 15:30:48 +00:00
</p>
<p>Installation into a temporary staging area or into a <code>chroot</code>
2012-03-27 23:13:14 +00:00
jail can be achieved with the command
2018-12-28 15:30:48 +00:00
</p>
<div class="smallexample">
<pre class="smallexample">make DESTDIR=<var>path-to-rootdir</var> install
</pre></div>
2012-03-27 23:13:14 +00:00
2018-12-28 15:30:48 +00:00
<p>where <var>path-to-rootdir</var> is the absolute path of
2012-03-27 23:13:14 +00:00
a directory relative to which all installation paths will be
interpreted. Note that the directory specified by <code>DESTDIR</code>
need not exist yet; it will be created if necessary.
2018-12-28 15:30:48 +00:00
</p>
<p>There is a subtle point with tooldirs and <code>DESTDIR</code>:
2012-03-27 23:13:14 +00:00
If you relocate a cross-compiler installation with
2018-12-28 15:30:48 +00:00
e.g. &lsquo;<samp>DESTDIR=<var>rootdir</var></samp>&rsquo;, then the directory
<samp><var>rootdir</var>/<var>exec-prefix</var>/<var>target-alias</var>/bin</samp> will
2012-03-27 23:13:14 +00:00
be filled with duplicated GCC executables only if it already exists,
it will not be created otherwise. This is regarded as a feature,
not as a bug, because it gives slightly more control to the packagers
using the <code>DESTDIR</code> feature.
2018-12-28 15:30:48 +00:00
</p>
<p>You can install stripped programs and libraries with
</p>
<div class="smallexample">
<pre class="smallexample">make install-strip
</pre></div>
<p>If you are bootstrapping a released version of GCC then please
2012-03-27 23:13:14 +00:00
quickly review the build status page for your release, available from
2018-12-28 15:30:48 +00:00
<a href="http://gcc.gnu.org/buildstat.html">http://gcc.gnu.org/buildstat.html</a>.
2012-03-27 23:13:14 +00:00
If your system is not listed for the version of GCC that you built,
send a note to
<a href="mailto:gcc@gcc.gnu.org">gcc@gcc.gnu.org</a> indicating
2018-12-28 15:30:48 +00:00
that you successfully built and installed GCC.
2012-03-27 23:13:14 +00:00
Include the following information:
2018-12-28 15:30:48 +00:00
</p>
<ul>
<li> Output from running <samp><var>srcdir</var>/config.guess</samp>. Do not send
2012-03-27 23:13:14 +00:00
that file itself, just the one-line output from running it.
2018-12-28 15:30:48 +00:00
</li><li> The output of &lsquo;<samp>gcc -v</samp>&rsquo; for your newly installed <code>gcc</code>.
2012-03-27 23:13:14 +00:00
This tells us which version of GCC you built and the options you passed to
configure.
2018-12-28 15:30:48 +00:00
</li><li> Whether you enabled all languages or a subset of them. If you used a
2012-03-27 23:13:14 +00:00
full distribution then this information is part of the configure
2018-12-28 15:30:48 +00:00
options in the output of &lsquo;<samp>gcc -v</samp>&rsquo;, but if you downloaded the
&ldquo;core&rdquo; compiler plus additional front ends then it isn&rsquo;t apparent
2012-03-27 23:13:14 +00:00
which ones you built unless you tell us about it.
2018-12-28 15:30:48 +00:00
</li><li> If the build was for GNU/Linux, also include:
<ul>
<li> The distribution name and version (e.g., Red Hat 7.1 or Debian 2.2.3);
this information should be available from <samp>/etc/issue</samp>.
2012-03-27 23:13:14 +00:00
2018-12-28 15:30:48 +00:00
</li><li> The version of the Linux kernel, available from &lsquo;<samp>uname --version</samp>&rsquo;
or &lsquo;<samp>uname -a</samp>&rsquo;.
2012-03-27 23:13:14 +00:00
2018-12-28 15:30:48 +00:00
</li><li> The version of glibc you used; for RPM-based systems like Red Hat,
Mandrake, and SuSE type &lsquo;<samp>rpm -q glibc</samp>&rsquo; to get the glibc version,
and on systems like Debian and Progeny use &lsquo;<samp>dpkg -l libc6</samp>&rsquo;.
</li></ul>
<p>For other systems, you can include similar information if you think it is
2012-03-27 23:13:14 +00:00
relevant.
2018-12-28 15:30:48 +00:00
</p>
</li><li> Any other information that you think would be useful to people building
2012-03-27 23:13:14 +00:00
GCC on the same configuration. The new entry in the build status list
2018-12-28 15:30:48 +00:00
will include a link to the archived copy of your message.
</li></ul>
2012-03-27 23:13:14 +00:00
2018-12-28 15:30:48 +00:00
<p>We&rsquo;d also like to know if the
2012-03-27 23:13:14 +00:00
<a href="specific.html">host/target specific installation notes</a>
2018-12-28 15:30:48 +00:00
didn&rsquo;t include your host/target information or if that information is
2012-03-27 23:13:14 +00:00
incomplete or out of date. Send a note to
<a href="mailto:gcc@gcc.gnu.org">gcc@gcc.gnu.org</a> detailing how the information should be changed.
2018-12-28 15:30:48 +00:00
</p>
<p>If you find a bug, please report it following the
2012-03-27 23:13:14 +00:00
<a href="../bugs/">bug reporting guidelines</a>.
2018-12-28 15:30:48 +00:00
</p>
<p>If you want to print the GCC manuals, do &lsquo;<samp>cd <var>objdir</var>; make
dvi</samp>&rsquo;. You will need to have <code>texi2dvi</code> (version at least 4.7)
and TeX installed. This creates a number of <samp>.dvi</samp> files in
2012-03-27 23:13:14 +00:00
subdirectories of <samp><var>objdir</var></samp>; these may be converted for
2018-12-28 15:30:48 +00:00
printing with programs such as <code>dvips</code>. Alternately, by using
&lsquo;<samp>make pdf</samp>&rsquo; in place of &lsquo;<samp>make dvi</samp>&rsquo;, you can create documentation
in the form of <samp>.pdf</samp> files; this requires <code>texi2pdf</code>, which
2012-03-27 23:13:14 +00:00
is included with Texinfo version 4.8 and later. You can also
2018-12-28 15:30:48 +00:00
<a href="https://shop.fsf.org/">buy printed manuals from the
Free Software Foundation</a>, though such manuals may not be for the most
2012-03-27 23:13:14 +00:00
recent version of GCC.
2018-12-28 15:30:48 +00:00
</p>
<p>If you would like to generate online HTML documentation, do &lsquo;<samp>cd
<var>objdir</var>; make html</samp>&rsquo; and HTML will be generated for the gcc manuals in
<samp><var>objdir</var>/gcc/HTML</samp>.
</p>
<hr />
<p>
<p><a href="./index.html">Return to the GCC Installation page</a>
</p>
2012-03-27 23:13:14 +00:00
2018-12-28 15:30:48 +00:00
</body>
</html>