Subversion Repositories svn LFS-FR

Rev

Go to most recent revision | Blame | Compare with Previous | Last modification | View Log | RSS feed

<?xml version="1.0" encoding="ISO-8859-1"?>
<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
 "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
 <!ENTITY % general-entities SYSTEM "../../general.ent">
  %general-entities;
]>

<sect1 id="ch-cross-tools-binutils" role="wrap">
  <?dbhtml filename="binutils.html"?>

  <title>Cross Binutils-&binutils-version;</title>

  <indexterm zone="ch-cross-tools-binutils">
    <primary sortas="a-Binutils">Binutils</primary>
    <secondary>cross tools</secondary>
  </indexterm>

  <xi:include xmlns:xi="http://www.w3.org/2003/XInclude"
 href="../../final-system/common/binutils.xml"
 xpointer="xpointer(//*[@role='package'])"/>

  <sect2 role="installation">
    <title>Installation of Cross Binutils</title>

    <para os="da">It is important that Binutils be the first package compiled
    because both EGLIBC and GCC perform various tests on the available
    linker and assembler to determine which of their own features to
    enable.</para>

    <xi:include xmlns:xi="http://www.w3.org/2003/XInclude"
   href="../../final-system/common/binutils.xml"
   xpointer="xpointer(//*[@os='p3'])"/>

    <xi:include xmlns:xi="http://www.w3.org/2003/XInclude"
   href="../../final-system/common/binutils.xml"
   xpointer="xpointer(//*[@os='p4'])"/>

    <xi:include xmlns:xi="http://www.w3.org/2003/XInclude"
   href="../../final-system/common/binutils.xml"
   xpointer="xpointer(//*[@os='a'])"/>

    <xi:include xmlns:xi="http://www.w3.org/2003/XInclude"
   href="../../final-system/common/binutils.xml"
   xpointer="xpointer(//*[@os='b'])"/>

    <xi:include xmlns:xi="http://www.w3.org/2003/XInclude"
   href="../../final-system/common/binutils.xml"
   xpointer="xpointer(//*[@os='c'])"/>

<screen os="bc"><userinput>AR=ar AS=as ../binutils-&binutils-version;/configure --prefix=${CLFS}/cross-tools \
   --host=${CLFS_HOST} --target=${CLFS_TARGET} --with-sysroot=${CLFS} \
   --disable-nls --enable-shared --disable-multilib</userinput></screen>

    <variablelist os="bd">
      <title>The meaning of the configure options:</title>

      <varlistentry os="bd1">
        <term><parameter>--prefix=${CLFS}/cross-tools</parameter></term>
        <listitem>
          <para>This tells the configure script to prepare to install the
          package in the <filename class="directory">${CLFS}/cross-tools</filename>
          directory.</para>
        </listitem>
      </varlistentry>

      <varlistentry os="bd2">
        <term><parameter>--host=${CLFS_HOST}</parameter></term>
        <listitem>
          <para>When used with --target, this creates a cross-architecture
          executable that creates files for ${CLFS_TARGET} but runs on
          ${CLFS_HOST}.</para>
        </listitem>
      </varlistentry>

      <varlistentry os="bd3">
        <term><parameter>--target=${CLFS_TARGET}</parameter></term>
        <listitem>
          <para>When used with --host, this creates a cross-architecture
          executable that creates files for ${CLFS_TARGET} but runs on
          ${CLFS_HOST}.</para>
        </listitem>
      </varlistentry>

      <varlistentry os="bd4">
        <term><parameter>--with-sysroot=${CLFS}</parameter></term>
        <listitem>
          <para>This tells configure that ${CLFS} is going to be the root
          of our system. It will now use the specified sysroot, ${CLFS}, as
          a prefix of the default search paths.</para>
        </listitem>
      </varlistentry>

      <varlistentry os="bd5">
        <term><parameter>--disable-nls</parameter></term>
        <listitem>
          <para>This disables internationalization as i18n is not needed for the
          cross-compile tools.</para>
        </listitem>
      </varlistentry>

      <varlistentry os="bd6">
        <term><parameter>--enable-shared</parameter></term>
        <listitem>
          <para>Enable the creation of the shared libraries.</para>
        </listitem>
      </varlistentry>

      <varlistentry os="bd7">
        <term><parameter>--disable-multilib</parameter></term>
        <listitem>
          <para>This option disables the building of a multilib
          capable Binutils.</para>
        </listitem>
      </varlistentry>

    </variablelist>

    <para os="be">Compile the package:</para>

<screen os="bf"><userinput>make configure-host
make</userinput></screen>

    <variablelist os="bg">
      <title>The meaning of the make options:</title>

      <varlistentry os="bg1">
        <term><parameter>configure-host</parameter></term>
        <listitem>
          <para>This checks the host environment and makes sure all the
          necessary tools are available to compile Binutils.</para>
        </listitem>
      </varlistentry>

    </variablelist>

    <para os="bh">Install the package:</para>

<screen os="bi"><userinput>make install</userinput></screen>

    <para os="bj">Install the <filename class="headerfile">libiberty</filename> header
    file that is needed by some packages:</para>

<screen os="bk"><userinput>cp -v ../binutils-&binutils-version;/include/libiberty.h ${CLFS}/usr/include</userinput></screen>

  </sect2>

  <sect2 role="content">
    <title/>

    <para>Details on this package are located in <xref
   linkend="contents-binutils" role="."/></para>

  </sect2>

</sect1>