source: BOOK/cross-tools/alpha/eglibc-headers.xml@ 6b4dba7

clfs-3.0.0-systemd clfs-3.0.0-sysvinit systemd sysvinit
Last change on this file since 6b4dba7 was 00a58649, checked in by William Harrington <kb0iic@…>, 11 years ago

Add a sed for eglibc to detect Make-4.x

  • Property mode set to 100644
File size: 6.8 KB
RevLine 
[3f8be484]1<?xml version="1.0" encoding="ISO-8859-1"?>
[aa18ac0]2<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
3 "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
[3f8be484]4 <!ENTITY % general-entities SYSTEM "../../general.ent">
5 %general-entities;
6]>
7
[093b0e8]8<sect1 id="ch-cross-tools-eglibc-headers" role="wrap">
9 <?dbhtml filename="eglibc-headers.html"?>
[3f8be484]10
[093b0e8]11 <title>EGLIBC-&eglibc-version; Headers</title>
[3f8be484]12
[093b0e8]13 <indexterm zone="ch-cross-tools-eglibc-headers">
14 <primary sortas="a-EGLIBC">EGLIBC</primary>
[3f8be484]15 <secondary>cross tools, headers</secondary>
16 </indexterm>
17
[dabbced]18 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
[093b0e8]19 href="../../final-system/common/eglibc.xml"
[cf66ceae]20 xpointer="xpointer(//*[@role='package'])"/>
[3f8be484]21
22 <sect2 role="installation">
[093b0e8]23 <title>Installation of EGLIBC Headers</title>
[3f8be484]24
[54c2a21]25 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
26 href="../common/eglibc.xml"
27 xpointer="xpointer(//*[@os='da'])"/>
28
[093b0e8]29 <para os="s1">EGLIBC's <filename>configure</filename> script checks the
30 version of GCC, and will fail if it's less than 3.4. The next EGLIBC build
[9f5a80a]31 will use the GCC that will be installed into
32 <filename class="directory">/cross-tools</filename> in the next step.
[093b0e8]33 However, in this step only the EGLIBC headers are being installed - no
[9f5a80a]34 compiling is taking place - so the GCC version isn't important. The
35 following sed removes the dependency of GCC 3.4.x:</para>
[d018b81]36
[661d1a4]37<screen os="s2"><userinput>cp -v configure{,.orig}
[1b274255]38sed -e 's/3.4/3.[0-9]/g' configure.orig &gt; configure</userinput></screen>
[3f8be484]39
[00a58649]40 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
41 href="../../final-system/common/eglibc.xml"
42 xpointer="xpointer(//*[@os='s1'])"/>
43
44 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
45 href="../../final-system/common/eglibc.xml"
46 xpointer="xpointer(//*[@os='s2'])"/>
47
[dabbced]48 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
[093b0e8]49 href="../../final-system/common/eglibc.xml"
[3f8be484]50 xpointer="xpointer(//*[@os='e'])"/>
51
[dabbced]52 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
[093b0e8]53 href="../../final-system/common/eglibc.xml"
[3f8be484]54 xpointer="xpointer(//*[@os='f'])"/>
55
[dabbced]56 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
[093b0e8]57 href="../common/eglibc.xml"
[c4d5e29]58 xpointer="xpointer(//*[@os='dd'])"/>
59
[c768003]60<screen os="de"><userinput>cat &gt; config.cache &lt;&lt; "EOF"
61libc_cv_forced_unwind=yes
62libc_cv_c_cleanup=yes
63libc_cv_mlong_double_128=yes
64libc_cv_alpha_tls=yes
[bd01f75]65libc_cv_gnu89_inline=yes
[5e4b3b4]66libc_cv_ssp=no
[c768003]67EOF</userinput></screen>
[f0ed7ed]68
[dabbced]69 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
[093b0e8]70 href="../../final-system/common/eglibc.xml"
[3f8be484]71 xpointer="xpointer(//*[@os='g'])"/>
72
[093b0e8]73<screen os="s3"><userinput>CC=gcc ../eglibc-&eglibc-version;/configure --prefix=/tools \
[07114c98]74 --host=${CLFS_TARGET} --build=${CLFS_HOST} \
[65ab9ce]75 --disable-sanity-checks --enable-kernel=2.6.32 \
[52ed4da]76 --with-headers=/tools/include --enable-obsolete-rpc \
77 --cache-file=config.cache \
[bc2e3fa]78 --with-binutils=/cross-tools/${CLFS_TARGET}/bin</userinput></screen>
[7482ad3]79
[040521bc]80 <note os="e1">
[7482ad3]81 <para><emphasis>Any</emphasis> error message you see about nptl at this point
82 can safely be ignored.</para>
[040521bc]83 </note>
[7482ad3]84
85 <variablelist os="ca">
86 <title>The meaning of the configure options:</title>
[d018b81]87
[7482ad3]88 <varlistentry os="ca1">
89 <term><parameter>CC=gcc</parameter></term>
90 <listitem>
[093b0e8]91 <para>Tells EGLIBC to use the host's GCC compiler.</para>
[7482ad3]92 </listitem>
93 </varlistentry>
[d018b81]94
[7482ad3]95 <varlistentry os="ca2">
96 <term><parameter>--prefix=/tools</parameter></term>
97 <listitem>
98 <para>This tells the configure script to prepare to install the
[e3196bd]99 package in the <filename class="directory">/tools</filename>
100 directory.</para>
[7482ad3]101 </listitem>
102 </varlistentry>
[d018b81]103
[7482ad3]104 <varlistentry os="ca3">
[07114c98]105 <term><parameter>--build=${CLFS_HOST}</parameter></term>
[7482ad3]106 <listitem>
107 <para>When used with --host, this creates a cross-architecture
[3c06a53]108 executable that creates files for ${CLFS_TARGET} but runs on ${CLFS_HOST}.</para>
[7482ad3]109 </listitem>
110 </varlistentry>
[d018b81]111
[7482ad3]112 <varlistentry os="ca4">
[07114c98]113 <term><parameter>--host=${CLFS_TARGET}</parameter></term>
[7482ad3]114 <listitem>
115 <para>When used with --build, this creates a cross-architecture
[3c06a53]116 executable that creates files for ${CLFS_TARGET} but runs on ${CLFS_HOST}.</para>
[7482ad3]117 </listitem>
118 </varlistentry>
[d018b81]119
[7482ad3]120 <varlistentry os="ca5">
121 <term><parameter>--disable-sanity-checks</parameter></term>
122 <listitem>
123 <para>This switch disables any checks that are in place.</para>
124 </listitem>
125 </varlistentry>
[d018b81]126
[7482ad3]127 <varlistentry os="ca6">
[65ab9ce]128 <term><parameter>--enable-kernel=2.6.32</parameter></term>
[7482ad3]129 <listitem>
[093b0e8]130 <para>This tells EGLIBC to compile the library with support
[65ab9ce]131 for 2.6.32 and later Linux kernels.</para>
[7482ad3]132 </listitem>
133 </varlistentry>
[d018b81]134
[7482ad3]135 <varlistentry os="ca7">
[bc2e3fa]136 <term><parameter>--with-headers=/tools/include</parameter></term>
[7482ad3]137 <listitem>
[093b0e8]138 <para>This tells EGLIBC to compile itself against the headers
[bc2e3fa]139 recently installed to the <filename class="directory">/tools</filename>
[7482ad3]140 directory, so that it knows exactly what features the kernel has
141 and can optimize itself accordingly.</para>
142 </listitem>
143 </varlistentry>
[d018b81]144
[7482ad3]145 <varlistentry os="ca8">
[bc2e3fa]146 <term><parameter>--with-binutils=/cross-tools/${CLFS_TARGET}/bin</parameter></term>
[7482ad3]147 <listitem>
[093b0e8]148 <para>This tells EGLIBC to use the Binutils for our specific target architecture.</para>
[7482ad3]149 </listitem>
150 </varlistentry>
[d018b81]151
[7482ad3]152 </variablelist>
[d018b81]153
[7482ad3]154 <para os="cb">Now, install the headers:</para>
155
156<screen os="cd"><userinput>make install-headers</userinput></screen>
157
[42754a9]158 <para os="ce">Some files aren't installed by the above command, so
159 we will copy the additional header files we need.</para>
[7482ad3]160
[d018b81]161 <para os="cf">First we will copy a common file over to <filename
[bc2e3fa]162 class="directory">/tools/include</filename>:</para>
[7482ad3]163
[bc2e3fa]164<screen os="cg"><userinput>install -dv /tools/include/bits
165cp -v bits/stdio_lim.h /tools/include/bits</userinput></screen>
[7482ad3]166
167 <para os="ch">Now we will create a blank stub file:</para>
168
[bc2e3fa]169<screen os="ci"><userinput>touch /tools/include/gnu/stubs.h</userinput></screen>
[7482ad3]170
[42754a9]171 <para os="cj">Another header is needed for NPTL:</para>
[d018b81]172
[093b0e8]173<screen><userinput>cp -v ../eglibc-&eglibc-version;/nptl/sysdeps/unix/sysv/linux/alpha/bits/pthreadtypes.h \
[d018b81]174 /tools/include/bits/</userinput></screen>
[3f8be484]175
176 </sect2>
177
178 <sect2 role="content">
179 <title/>
180
181 <para>Details on this package are located in <xref
[093b0e8]182 linkend="contents-eglibc" role="."/></para>
[3f8be484]183
184 </sect2>
185
186</sect1>
Note: See TracBrowser for help on using the repository browser.