[bf8c11f] | 1 | <?xml version="1.0" encoding="ISO-8859-1"?>
|
---|
| 2 | <!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN"
|
---|
| 3 | "http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd" [
|
---|
| 4 | <!ENTITY % general-entities SYSTEM "../../general.ent">
|
---|
| 5 | %general-entities;
|
---|
| 6 | ]>
|
---|
| 7 |
|
---|
| 8 | <sect1 id="ch-cross-tools-binutils" role="wrap">
|
---|
| 9 | <?dbhtml filename="binutils.html"?>
|
---|
| 10 |
|
---|
| 11 | <title>Cross Binutils-&binutils-version;</title>
|
---|
| 12 |
|
---|
| 13 | <indexterm zone="ch-cross-tools-binutils">
|
---|
| 14 | <primary sortas="a-Binutils">Binutils</primary>
|
---|
| 15 | <secondary>cross tools</secondary>
|
---|
| 16 | </indexterm>
|
---|
| 17 |
|
---|
[48f8316] | 18 | <xi:include xmlns:xi="http://www.w3.org/2003/XInclude"
|
---|
| 19 | href="../../final-system/common/binutils.xml"
|
---|
| 20 | xpointer="xpointer(//*[@role='package'])"/>
|
---|
[bf8c11f] | 21 |
|
---|
| 22 | <sect2 role="installation">
|
---|
| 23 | <title>Installation of Cross Binutils</title>
|
---|
| 24 |
|
---|
| 25 | <para os="ba">To make sure that the proper syntax is used for a couple of
|
---|
| 26 | tools, apply the following patch:</para>
|
---|
| 27 |
|
---|
| 28 | <screen os="bb"><userinput>patch -Np1 -i ../&binutils-posix-patch;</userinput></screen>
|
---|
| 29 |
|
---|
| 30 | <xi:include xmlns:xi="http://www.w3.org/2003/XInclude"
|
---|
| 31 | href="../../final-system/common/binutils.xml"
|
---|
| 32 | xpointer="xpointer(//*[@os='g'])"/>
|
---|
| 33 |
|
---|
| 34 | <xi:include xmlns:xi="http://www.w3.org/2003/XInclude"
|
---|
| 35 | href="../../final-system/common/binutils.xml"
|
---|
| 36 | xpointer="xpointer(//*[@os='h'])"/>
|
---|
| 37 |
|
---|
| 38 | <xi:include xmlns:xi="http://www.w3.org/2003/XInclude"
|
---|
| 39 | href="../../final-system/common/binutils.xml"
|
---|
| 40 | xpointer="xpointer(//*[@os='i'])"/>
|
---|
| 41 |
|
---|
| 42 | <screen os="bc"><userinput>../binutils-&binutils-version;/configure --prefix=/cross-tools \
|
---|
| 43 | --host=${LFS_HOST} --target=${LFS_TARGET} --with-lib-path=/tools/lib \
|
---|
| 44 | --disable-nls --enable-shared --enable-64-bit-bfd</userinput></screen>
|
---|
| 45 |
|
---|
| 46 | <variablelist os="bd">
|
---|
| 47 | <title>The meaning of the configure options:</title>
|
---|
| 48 |
|
---|
| 49 | <varlistentry os="bd1">
|
---|
| 50 | <term><parameter>--prefix=/cross-tools</parameter></term>
|
---|
| 51 | <listitem>
|
---|
| 52 | <para>This tells the configure script to prepare to install the
|
---|
| 53 | package in the <filename class="directory">/cross-tools</filename>
|
---|
| 54 | directory.</para>
|
---|
| 55 | </listitem>
|
---|
| 56 | </varlistentry>
|
---|
| 57 |
|
---|
| 58 | <varlistentry os="bd2">
|
---|
| 59 | <term><parameter>--host=${LFS_HOST}</parameter></term>
|
---|
| 60 | <listitem>
|
---|
| 61 | <para>This do ...</para>
|
---|
| 62 | </listitem>
|
---|
| 63 | </varlistentry>
|
---|
| 64 |
|
---|
| 65 | <varlistentry os="bd3">
|
---|
| 66 | <term><parameter>--target=${LFS_TARGET}</parameter></term>
|
---|
| 67 | <listitem>
|
---|
| 68 | <para>This do ...</para>
|
---|
| 69 | </listitem>
|
---|
| 70 | </varlistentry>
|
---|
| 71 |
|
---|
| 72 | <varlistentry os="bd4">
|
---|
| 73 | <term><parameter>--with-lib-path=/tools/lib</parameter></term>
|
---|
| 74 | <listitem>
|
---|
| 75 | <para>This tells the configure script to specify the library
|
---|
| 76 | search path during the compilation of Binutils, resulting in
|
---|
| 77 | <filename class="directory">/tools/lib</filename> being passed
|
---|
| 78 | to the linker. This prevents the linker from searching through
|
---|
| 79 | library directories on the host.</para>
|
---|
| 80 | </listitem>
|
---|
| 81 | </varlistentry>
|
---|
| 82 |
|
---|
| 83 | <varlistentry os="bd5">
|
---|
| 84 | <term><parameter>--disable-nls</parameter></term>
|
---|
| 85 | <listitem>
|
---|
| 86 | <para>This disables internationalization as i18n is not needed for the
|
---|
| 87 | cross-compile tools.</para>
|
---|
| 88 | </listitem>
|
---|
| 89 | </varlistentry>
|
---|
| 90 |
|
---|
| 91 | <varlistentry os="bd6">
|
---|
| 92 | <term><parameter>--enable-shared</parameter></term>
|
---|
| 93 | <listitem>
|
---|
| 94 | <para>Enable the creation of the shared libraries.</para>
|
---|
| 95 | </listitem>
|
---|
| 96 | </varlistentry>
|
---|
| 97 |
|
---|
| 98 | <varlistentry os="bd7">
|
---|
| 99 | <term><parameter>--enable-64-bit-bfd</parameter></term>
|
---|
| 100 | <listitem>
|
---|
| 101 | <para>This adds 64 bit support to our toolchain.</para>
|
---|
| 102 | </listitem>
|
---|
| 103 | </varlistentry>
|
---|
| 104 |
|
---|
| 105 | </variablelist>
|
---|
| 106 |
|
---|
| 107 | <para os="be">Compile the package:</para>
|
---|
| 108 |
|
---|
| 109 | <screen os="bf"><userinput>make configure-host
|
---|
| 110 | make</userinput></screen>
|
---|
| 111 |
|
---|
| 112 | <variablelist os="bf1">
|
---|
| 113 | <title>The meaning of the make options:</title>
|
---|
| 114 |
|
---|
| 115 | <varlistentry>
|
---|
| 116 | <term><parameter>configure-host</parameter></term>
|
---|
| 117 | <listitem>
|
---|
| 118 | <para>This do ...</para>
|
---|
| 119 | </listitem>
|
---|
| 120 | </varlistentry>
|
---|
| 121 |
|
---|
| 122 | <varlistentry>
|
---|
| 123 | <term><parameter>headers -C bfd</parameter></term>
|
---|
| 124 | <listitem>
|
---|
| 125 | <para>This do ...</para>
|
---|
| 126 | </listitem>
|
---|
| 127 | </varlistentry>
|
---|
| 128 |
|
---|
| 129 | </variablelist>
|
---|
| 130 |
|
---|
| 131 | <para os="bg">Install the package:</para>
|
---|
| 132 |
|
---|
| 133 | <screen os="bh"><userinput>make install</userinput></screen>
|
---|
| 134 |
|
---|
| 135 | <para os="bi">Copy <filename class="headerfile">libiberty.h</filename> file to
|
---|
| 136 | <filename class="directory">/tools/include</filename> directory:</para>
|
---|
| 137 |
|
---|
| 138 | <screen os="bj"><userinput>cp ../binutils-&binutils-version;/include/libiberty.h /tools/include</userinput></screen>
|
---|
| 139 |
|
---|
| 140 | </sect2>
|
---|
| 141 |
|
---|
| 142 | <sect2 role="content">
|
---|
| 143 | <title/>
|
---|
| 144 |
|
---|
| 145 | <para>Details on this package are located in <xref
|
---|
| 146 | linkend="contents-binutils" role="."/></para>
|
---|
| 147 |
|
---|
| 148 | </sect2>
|
---|
| 149 |
|
---|
| 150 | </sect1>
|
---|