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