[a9e389d] | 1 | <?xml version="1.0" encoding="ISO-8859-1"?>
|
---|
[bd48e48] | 2 | <!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
|
---|
| 3 | "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
|
---|
[a9e389d] | 4 | <!ENTITY % general-entities SYSTEM "../../general.ent">
|
---|
| 5 | %general-entities;
|
---|
| 6 | ]>
|
---|
| 7 |
|
---|
[bd0ad10] | 8 | <!-- Common GCC-Final -->
|
---|
| 9 |
|
---|
[a9e389d] | 10 | <sect1 id="ch-cross-tools-gcc-final" role="wrap">
|
---|
| 11 | <?dbhtml filename="gcc-final.html"?>
|
---|
| 12 |
|
---|
| 13 | <title>GCC-&gcc-version; - Cross Compiler Final</title>
|
---|
| 14 |
|
---|
| 15 | <indexterm zone="ch-cross-tools-gcc-final">
|
---|
| 16 | <primary sortas="a-GCC">GCC</primary>
|
---|
| 17 | <secondary>cross tools, final</secondary>
|
---|
| 18 | </indexterm>
|
---|
| 19 |
|
---|
[bd0ad10] | 20 | <xi:include role="package" xmlns:xi="http://www.w3.org/2003/XInclude"
|
---|
[a9e389d] | 21 | href="gcc-static.xml"
|
---|
| 22 | xpointer="xpointer(//*[@role='package'])"/>
|
---|
| 23 |
|
---|
| 24 | <sect2 role="installation">
|
---|
| 25 | <title>Installation of GCC Cross Compiler</title>
|
---|
| 26 |
|
---|
[2b9574b] | 27 | <para os="b">GCC requires the GMP, MPFR, and MPC packages to either be
|
---|
| 28 | present on the host or to be present in source form within the gcc source
|
---|
| 29 | tree. Unpack these into the GCC directory after unpacking GCC:</para>
|
---|
| 30 |
|
---|
| 31 | <screen os="ba"><userinput>tar xf ../mpfr-&mpfr-version;.tar.bz2
|
---|
| 32 | mv -v mpfr-&mpfr-version; mpfr
|
---|
| 33 | tar xf ../gmp-&gmp-version;.tar.bz2
|
---|
| 34 | mv -v gmp-&gmp-version; gmp
|
---|
| 35 | tar xf ../mpc-&mpc-version;.tar.gz
|
---|
| 36 | mv -v mpc-&mpc-version; mpc</userinput></screen>
|
---|
| 37 |
|
---|
[bd0ad10] | 38 | <xi:include os="c" xmlns:xi="http://www.w3.org/2003/XInclude"
|
---|
[a9e389d] | 39 | href="gcc-static.xml"
|
---|
| 40 | xpointer="xpointer(//*[@os='c'])"/>
|
---|
| 41 |
|
---|
[bd0ad10] | 42 | <xi:include os="d" xmlns:xi="http://www.w3.org/2003/XInclude"
|
---|
[a9e389d] | 43 | href="gcc-static.xml"
|
---|
| 44 | xpointer="xpointer(//*[@os='d'])"/>
|
---|
| 45 |
|
---|
[bd0ad10] | 46 | <xi:include os="e" xmlns:xi="http://www.w3.org/2003/XInclude"
|
---|
[a9e389d] | 47 | href="gcc-static.xml"
|
---|
| 48 | xpointer="xpointer(//*[@os='e'])"/>
|
---|
| 49 |
|
---|
[d38764e] | 50 | <note os="f"><para>If you would like to build a C++ compiler in addition
|
---|
| 51 | to the C compiler, change the following --enable-languages=c option to be
|
---|
[3961d27] | 52 | --enable-languages=c,c++ instead. A C++ compiler is not required for
|
---|
[d38764e] | 53 | any of the software included in this book.</para></note>
|
---|
| 54 |
|
---|
[bd0ad10] | 55 | <!-- This is the common configure line for GCC-Final -->
|
---|
| 56 | <!-- It's not actually used by any arch but is here for reference. -->
|
---|
[146587b] | 57 | <screen os="ae"><userinput>../gcc-&gcc-version;/configure \
|
---|
[54fde8f] | 58 | --prefix=${CLFS}/cross-tools \
|
---|
| 59 | --build=${CLFS_HOST} \
|
---|
| 60 | --target=${CLFS_TARGET} \
|
---|
| 61 | --host=${CLFS_HOST} \
|
---|
[13d7c4f] | 62 | --with-sysroot=${CLFS}/cross-tools/sysroot \
|
---|
[54fde8f] | 63 | --disable-nls \
|
---|
| 64 | --enable-languages=c \
|
---|
| 65 | --enable-c99 \
|
---|
| 66 | --enable-long-long \
|
---|
[2bb7576] | 67 | --disable-libmudflap \
|
---|
[54fde8f] | 68 | --with-mpfr=${CLFS}/cross-tools \
|
---|
| 69 | --with-gmp=${CLFS}/cross-tools \
|
---|
| 70 | --with-mpc=${CLFS}/cross-tools \
|
---|
| 71 | --disable-multilib</userinput></screen>
|
---|
[a9e389d] | 72 |
|
---|
| 73 | <variablelist os="af">
|
---|
[65b296c] | 74 | <title>The meaning of the configure options not used previously:</title>
|
---|
[a9e389d] | 75 |
|
---|
| 76 | <varlistentry os="af2">
|
---|
| 77 | <term><parameter>--enable-c99</parameter></term>
|
---|
| 78 | <listitem>
|
---|
| 79 | <para>Enable C99 support for C programs.</para>
|
---|
| 80 | </listitem>
|
---|
| 81 | </varlistentry>
|
---|
| 82 |
|
---|
[e1b2402] | 83 | <varlistentry os="af3">
|
---|
[a9e389d] | 84 | <term><parameter>--enable-long-long</parameter></term>
|
---|
| 85 | <listitem>
|
---|
| 86 | <para>Enables long long support in the compiler.</para>
|
---|
| 87 | </listitem>
|
---|
| 88 | </varlistentry>
|
---|
| 89 |
|
---|
| 90 | </variablelist>
|
---|
| 91 |
|
---|
[bd0ad10] | 92 | <xi:include os="ah" xmlns:xi="http://www.w3.org/2003/XInclude"
|
---|
[a9e389d] | 93 | href="gcc-static.xml"
|
---|
[ae51e2a] | 94 | xpointer="xpointer(//*[@os='ah'])"/>
|
---|
[a9e389d] | 95 |
|
---|
[bd0ad10] | 96 | <screen os="ai"><userinput>make</userinput></screen>
|
---|
[a9e389d] | 97 |
|
---|
[bd0ad10] | 98 | <xi:include os="aj" xmlns:xi="http://www.w3.org/2003/XInclude"
|
---|
[a9e389d] | 99 | href="gcc-static.xml"
|
---|
[ae51e2a] | 100 | xpointer="xpointer(//*[@os='aj'])"/>
|
---|
[a9e389d] | 101 |
|
---|
[bd0ad10] | 102 | <screen os="ak"><userinput>make install</userinput></screen>
|
---|
[a9e389d] | 103 |
|
---|
| 104 | </sect2>
|
---|
| 105 |
|
---|
| 106 | <sect2 id="contents-gcc" role="content">
|
---|
| 107 | <title>Contents of GCC</title>
|
---|
| 108 |
|
---|
| 109 | <segmentedlist>
|
---|
| 110 | <segtitle>Installed programs</segtitle>
|
---|
| 111 | <segtitle>Installed libraries</segtitle>
|
---|
| 112 |
|
---|
| 113 | <seglistitem>
|
---|
[9228651] | 114 | <seg>gcc, and gcov</seg>
|
---|
[2bb7576] | 115 | <seg>libgcc.a, libgcc_eh.a, and libgcc_s.so</seg>
|
---|
[a9e389d] | 116 | </seglistitem>
|
---|
| 117 | </segmentedlist>
|
---|
| 118 |
|
---|
| 119 | <variablelist>
|
---|
| 120 | <bridgehead renderas="sect3">Short Descriptions</bridgehead>
|
---|
| 121 | <?dbfo list-presentation="list"?>
|
---|
| 122 | <?dbhtml list-presentation="table"?>
|
---|
| 123 |
|
---|
| 124 | <varlistentry id="gcc">
|
---|
| 125 | <term><command>gcc</command></term>
|
---|
| 126 | <listitem>
|
---|
| 127 | <para>The C compiler</para>
|
---|
[6561a0f] | 128 | <indexterm zone="ch-cross-tools-gcc-final gcc">
|
---|
[a9e389d] | 129 | <primary sortas="b-gcc">gcc</primary>
|
---|
| 130 | </indexterm>
|
---|
| 131 | </listitem>
|
---|
| 132 | </varlistentry>
|
---|
| 133 |
|
---|
| 134 | <varlistentry id="gcov">
|
---|
| 135 | <term><command>gcov</command></term>
|
---|
| 136 | <listitem>
|
---|
| 137 | <para>A coverage testing tool; it is used to analyze programs to
|
---|
| 138 | determine where optimizations will have the most effect</para>
|
---|
[6561a0f] | 139 | <indexterm zone="ch-cross-tools-gcc-final gcov">
|
---|
[a9e389d] | 140 | <primary sortas="b-gcov">gcov</primary>
|
---|
| 141 | </indexterm>
|
---|
| 142 | </listitem>
|
---|
| 143 | </varlistentry>
|
---|
| 144 |
|
---|
| 145 | <varlistentry id="libgcc">
|
---|
| 146 | <term><filename class="libraryfile">libgcc</filename></term>
|
---|
| 147 | <listitem>
|
---|
| 148 | <para>Contains run-time support for <command>gcc</command></para>
|
---|
[6561a0f] | 149 | <indexterm zone="ch-cross-tools-gcc-final libgcc">
|
---|
[a9e389d] | 150 | <primary sortas="c-libgcc*">libgcc*</primary>
|
---|
| 151 | </indexterm>
|
---|
| 152 | </listitem>
|
---|
| 153 | </varlistentry>
|
---|
| 154 |
|
---|
| 155 | </variablelist>
|
---|
| 156 |
|
---|
| 157 | </sect2>
|
---|
| 158 |
|
---|
| 159 | </sect1>
|
---|