source: BOOK/cross-tools/alpha/eglibc-headers.xml@ 121626c

clfs-2.1 clfs-3.0.0-systemd clfs-3.0.0-sysvinit systemd sysvinit
Last change on this file since 121626c was 54c2a21, checked in by William Harrington <kb0iic@…>, 12 years ago

Add entries for eglibc ports extraction and link disabling to libgcc_eh to eglibc-headers and eglibc.

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