2004-09-03 10:43:18 +08:00
|
|
|
<?xml version="1.0" encoding="ISO-8859-1"?>
|
2005-04-04 04:52:42 +08:00
|
|
|
<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN"
|
|
|
|
"http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd" [
|
2004-09-03 10:43:18 +08:00
|
|
|
<!ENTITY % general-entities SYSTEM "../../general.ent">
|
|
|
|
%general-entities;
|
|
|
|
|
2005-01-11 12:19:19 +08:00
|
|
|
<!ENTITY gcc3-download-http "http://ftp.gnu.org/gnu/gcc/gcc-&gcc3-version;/gcc-&gcc3-version;.tar.bz2">
|
2005-02-02 02:29:34 +08:00
|
|
|
<!ENTITY gcc3-download-ftp "ftp://ftp.gnu.org/gnu/gcc/gcc-&gcc3-version;/gcc-&gcc3-version;.tar.bz2">
|
2005-08-18 00:33:20 +08:00
|
|
|
<!ENTITY gcc3-md5sum "6936616a967da5a0b46f1e7424a06414">
|
|
|
|
<!ENTITY gcc3-size "24 MB">
|
|
|
|
<!ENTITY gcc3-buildsize "433 MB (includes running the test suite)">
|
|
|
|
<!ENTITY gcc3-time "5.2 SBU (additional 11.2 SBU to run the test suite)">
|
2004-09-03 10:43:18 +08:00
|
|
|
]>
|
|
|
|
|
|
|
|
<sect1 id="gcc3" xreflabel="GCC-&gcc3-version;">
|
2005-05-05 05:21:53 +08:00
|
|
|
<?dbhtml filename="gcc3.html" ?>
|
|
|
|
|
|
|
|
<sect1info>
|
|
|
|
<othername>$LastChangedBy$</othername>
|
|
|
|
<date>$Date$</date>
|
2005-12-03 03:19:41 +08:00
|
|
|
<keywordset>
|
|
|
|
<keyword role="package">gcc-&gcc3-version;.tar</keyword>
|
2005-12-09 04:34:05 +08:00
|
|
|
<keyword role="ftpdir">gcc</keyword>
|
2005-12-03 03:19:41 +08:00
|
|
|
</keywordset>
|
2005-05-05 05:21:53 +08:00
|
|
|
</sect1info>
|
|
|
|
|
|
|
|
<title>GCC-&gcc3-version;</title>
|
|
|
|
|
|
|
|
<indexterm zone="gcc3">
|
|
|
|
<primary sortas="a-GCC-3-3">GCC-&gcc3-version;</primary>
|
|
|
|
</indexterm>
|
|
|
|
|
|
|
|
<sect2 role="package">
|
|
|
|
<title>Introduction to GCC-&gcc3-version;</title>
|
|
|
|
|
2005-05-31 05:38:32 +08:00
|
|
|
<para>The reason for installing
|
|
|
|
<application>GCC</application>-&gcc3-version; is that
|
2005-08-18 00:33:20 +08:00
|
|
|
some packages have not been updated to be compiled by
|
|
|
|
<application>GCC</application>-&gcc-version;. Additionally,
|
2005-05-31 05:38:32 +08:00
|
|
|
some pre-compiled packages may require the
|
2005-08-18 00:33:20 +08:00
|
|
|
<application>GCC</application>-&gcc3-version; libraries at run-time.</para>
|
2005-05-05 05:21:53 +08:00
|
|
|
|
|
|
|
<bridgehead renderas="sect3">Package Information</bridgehead>
|
|
|
|
<itemizedlist spacing="compact">
|
|
|
|
<listitem>
|
|
|
|
<para>Download (HTTP): <ulink url="&gcc3-download-http;"/></para>
|
|
|
|
</listitem>
|
|
|
|
<listitem>
|
|
|
|
<para>Download (FTP): <ulink url="&gcc3-download-ftp;"/></para>
|
|
|
|
</listitem>
|
|
|
|
<listitem>
|
|
|
|
<para>Download MD5 sum: &gcc3-md5sum;</para>
|
|
|
|
</listitem>
|
|
|
|
<listitem>
|
|
|
|
<para>Download size: &gcc3-size;</para>
|
|
|
|
</listitem>
|
|
|
|
<listitem>
|
|
|
|
<para>Estimated disk space required: &gcc3-buildsize;</para>
|
|
|
|
</listitem>
|
|
|
|
<listitem>
|
|
|
|
<para>Estimated build time: &gcc3-time;</para>
|
|
|
|
</listitem>
|
|
|
|
</itemizedlist>
|
|
|
|
|
|
|
|
<bridgehead renderas="sect3">Additional Downloads</bridgehead>
|
|
|
|
<itemizedlist spacing='compact'>
|
|
|
|
<listitem>
|
2005-05-31 05:38:32 +08:00
|
|
|
<para>Required patch: <ulink
|
2005-05-05 05:21:53 +08:00
|
|
|
url="&patch-root;/gcc-&gcc3-version;-no_fixincludes-1.patch"/></para>
|
|
|
|
</listitem>
|
|
|
|
<listitem>
|
2005-05-31 05:38:32 +08:00
|
|
|
<para>Required patch: <ulink
|
2005-05-05 05:21:53 +08:00
|
|
|
url="&patch-root;/gcc-&gcc3-version;-linkonce-1.patch"/></para>
|
|
|
|
</listitem>
|
|
|
|
</itemizedlist>
|
|
|
|
|
|
|
|
<bridgehead renderas="sect3">GCC-&gcc3-version; Dependencies</bridgehead>
|
2005-12-03 03:19:41 +08:00
|
|
|
|
|
|
|
<bridgehead renderas="sect4">Optional</bridgehead>
|
|
|
|
<para role="optional"><xref linkend="dejagnu"/> (required to run the full test suite)</para>
|
2005-05-05 05:21:53 +08:00
|
|
|
|
|
|
|
</sect2>
|
|
|
|
|
|
|
|
<sect2 role="installation">
|
|
|
|
<title>Installation of GCC-&gcc3-version;</title>
|
|
|
|
|
2005-05-31 05:38:32 +08:00
|
|
|
<para>Install <application>GCC</application>-&gcc3-version; by running
|
2005-05-05 05:21:53 +08:00
|
|
|
the following commands:</para>
|
|
|
|
|
|
|
|
<screen><userinput>patch -Np1 -i ../gcc-&gcc3-version;-no_fixincludes-1.patch &&
|
2005-01-11 12:19:19 +08:00
|
|
|
patch -Np1 -i ../gcc-&gcc3-version;-linkonce-1.patch &&
|
|
|
|
mkdir ../gcc-build &&
|
|
|
|
cd ../gcc-build &&
|
2005-08-18 00:33:20 +08:00
|
|
|
../gcc-&gcc3-version;/configure --prefix=/opt/gcc-&gcc3-version; \
|
|
|
|
--enable-shared --enable-languages=c,c++ --enable-threads=posix &&
|
2005-05-05 05:21:53 +08:00
|
|
|
make bootstrap</userinput></screen>
|
2005-01-31 01:59:50 +08:00
|
|
|
|
2005-05-31 05:38:32 +08:00
|
|
|
<para>If desired, run the test suite using the following commands. The
|
|
|
|
<command>test_summary</command> commands create log files which can be
|
|
|
|
compared to known good results located at <ulink
|
2005-08-18 00:33:20 +08:00
|
|
|
url="http://linuxfromscratch.org/~randy/gcc-336_LFS-6.1_test.txt"/>.</para>
|
2005-02-28 10:21:57 +08:00
|
|
|
|
2005-05-05 05:21:53 +08:00
|
|
|
<screen><userinput>make -k check &&
|
2005-08-18 00:33:20 +08:00
|
|
|
../gcc-&gcc3-version;/contrib/test_summary >test_summary.log 2>&1 &&
|
|
|
|
../gcc-&gcc3-version;/contrib/test_summary | \
|
2005-05-05 05:21:53 +08:00
|
|
|
grep -A7 Summ >test_summary_short.log 2>&1</userinput></screen>
|
2005-02-28 10:21:57 +08:00
|
|
|
|
2005-05-05 05:21:53 +08:00
|
|
|
<para>Now, as the <systemitem class="username">root</systemitem> user:</para>
|
2005-01-31 01:59:50 +08:00
|
|
|
|
2005-05-05 05:21:53 +08:00
|
|
|
<screen role="root"><userinput>make install &&
|
2005-05-05 05:27:00 +08:00
|
|
|
mv -v /opt/gcc-&gcc3-version;/lib/libstdc++.so.5* /usr/lib &&
|
2005-08-18 00:33:20 +08:00
|
|
|
ln -v -sf /usr/lib/libstdc++.so.5.0.7 /opt/gcc-&gcc3-version;/lib &&
|
|
|
|
ln -v -sf libstdc++.so.5.0.7 /opt/gcc-&gcc3-version;/lib/libstdc++.so.5 &&
|
2005-05-05 05:27:00 +08:00
|
|
|
chown -v -R root:root \
|
2005-05-05 05:21:53 +08:00
|
|
|
/opt/gcc-&gcc3-version;/lib/gcc-lib/i686-pc-linux-gnu/&gcc3-version;/include</userinput></screen>
|
2005-01-11 12:19:19 +08:00
|
|
|
|
2005-05-05 05:21:53 +08:00
|
|
|
</sect2>
|
2004-09-03 10:43:18 +08:00
|
|
|
|
2005-05-05 05:21:53 +08:00
|
|
|
<sect2 role="commands">
|
|
|
|
<title>Command Explanations</title>
|
2004-09-03 10:43:18 +08:00
|
|
|
|
2005-05-31 05:38:32 +08:00
|
|
|
<para><command>mkdir ../gcc-build; cd ../gcc-build</command>: The
|
|
|
|
<application>GCC</application> development team recommends
|
2005-05-05 05:21:53 +08:00
|
|
|
building in a separate directory.</para>
|
2004-09-03 10:43:18 +08:00
|
|
|
|
2005-05-31 05:38:32 +08:00
|
|
|
<para><parameter>--enable-shared --enable-languages=c,c++
|
|
|
|
--enable-threads=posix</parameter>: Configures
|
|
|
|
<application>GCC</application> to build the
|
2005-08-18 00:33:20 +08:00
|
|
|
<application>C</application> and <application>C++</application> compilers
|
|
|
|
and enable the related <application>C++</application> options.</para>
|
2004-09-03 10:43:18 +08:00
|
|
|
|
2005-05-31 05:38:32 +08:00
|
|
|
<para><command>mv -v /opt/gcc-&gcc3-version;/lib/libstdc++.so.5*
|
2005-08-18 00:33:20 +08:00
|
|
|
/usr/lib</command>: Moves the <application>C++</application> library to the
|
2005-05-31 05:38:32 +08:00
|
|
|
standard lib directory to avoid having to add
|
|
|
|
<userinput>/opt/gcc-&gcc3-version;/lib</userinput> to
|
2005-05-05 05:21:53 +08:00
|
|
|
<filename>/etc/ld.so.conf</filename>.</para>
|
2004-09-03 10:43:18 +08:00
|
|
|
|
2005-05-05 05:21:53 +08:00
|
|
|
</sect2>
|
2004-09-03 10:43:18 +08:00
|
|
|
|
2005-05-05 05:21:53 +08:00
|
|
|
<sect2 role="configuration">
|
|
|
|
<title>Configuring GCC-&gcc3-version;</title>
|
2004-09-03 10:43:18 +08:00
|
|
|
|
2005-05-05 05:21:53 +08:00
|
|
|
<sect3>
|
|
|
|
<title>Configuration information</title>
|
2004-09-03 10:43:18 +08:00
|
|
|
|
2005-05-05 05:21:53 +08:00
|
|
|
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="../../lib-config.xml"/>
|
2004-09-03 10:43:18 +08:00
|
|
|
|
2005-08-18 00:33:20 +08:00
|
|
|
<para>If you only need the GCC-&gcc3-version; C++ library, you may delete
|
2005-05-05 05:21:53 +08:00
|
|
|
<filename>/opt/gcc-&gcc3-version;</filename>.</para>
|
2004-09-03 10:43:18 +08:00
|
|
|
|
2005-05-05 05:21:53 +08:00
|
|
|
<para>Whenever you need to use GCC-&gcc3-version; instead of your system
|
|
|
|
installed compiler, add
|
2005-05-31 05:38:32 +08:00
|
|
|
<filename class="directory">/opt/gcc-&gcc3-version;/bin</filename> to the
|
2005-05-05 05:21:53 +08:00
|
|
|
front of your <envar>PATH</envar> or (preferably) set the <envar>CC</envar>
|
|
|
|
environment variable before compiling the concerned package.</para>
|
2004-09-03 10:43:18 +08:00
|
|
|
|
2005-05-05 05:21:53 +08:00
|
|
|
</sect3>
|
2004-09-03 10:43:18 +08:00
|
|
|
|
2005-05-05 05:21:53 +08:00
|
|
|
</sect2>
|
2004-09-03 10:43:18 +08:00
|
|
|
|
2005-05-05 05:21:53 +08:00
|
|
|
<sect2 role="content">
|
|
|
|
<title>Contents</title>
|
2004-09-03 10:43:18 +08:00
|
|
|
|
2005-05-05 05:21:53 +08:00
|
|
|
<segmentedlist>
|
|
|
|
<segtitle>Installed Programs</segtitle>
|
|
|
|
<segtitle>Installed Libraries</segtitle>
|
2005-07-28 04:49:55 +08:00
|
|
|
<segtitle>Installed Directory</segtitle>
|
2005-01-11 12:19:19 +08:00
|
|
|
|
2005-05-05 05:21:53 +08:00
|
|
|
<seglistitem>
|
2005-05-31 05:38:32 +08:00
|
|
|
<seg>c++, cpp, g++, gcc, gccbug, gcov, and architecture specific
|
2005-05-05 05:21:53 +08:00
|
|
|
names of these programs.</seg>
|
2005-05-31 05:38:32 +08:00
|
|
|
<seg>libgcc_s.so, libiberty.a, libstdc++.[a,so], libsupc++.a, and other
|
2005-05-05 05:21:53 +08:00
|
|
|
support libraries and files.</seg>
|
|
|
|
<seg>/opt/gcc-&gcc3-version;</seg>
|
|
|
|
</seglistitem>
|
|
|
|
</segmentedlist>
|
2004-09-03 10:43:18 +08:00
|
|
|
|
2005-05-05 05:21:53 +08:00
|
|
|
<bridgehead renderas="sect3">Short Descriptions</bridgehead>
|
|
|
|
|
|
|
|
<para>The GCC-&gcc3-version; package contains the
|
|
|
|
<command>gcc</command>-&gcc3-version; <application>C</application> and
|
2005-07-28 04:49:55 +08:00
|
|
|
<application>C++</application> compilers and the GCC-&gcc3-version;
|
|
|
|
<filename>libstdc++.so</filename> library that is required by some
|
|
|
|
commercial and pre-compiled packages.</para>
|
2005-05-05 05:21:53 +08:00
|
|
|
|
|
|
|
</sect2>
|
2004-09-03 10:43:18 +08:00
|
|
|
|
|
|
|
</sect1>
|