source: BOOK/cross-tools/alpha/eglibc-headers.xml@ 578cf221

clfs-2.1 clfs-3.0.0-systemd clfs-3.0.0-sysvinit systemd sysvinit
Last change on this file since 578cf221 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
Line 
1<?xml version="1.0" encoding="ISO-8859-1"?>
2<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
3 "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
4 <!ENTITY % general-entities SYSTEM "../../general.ent">
5 %general-entities;
6]>
7
8<sect1 id="ch-cross-tools-eglibc-headers" role="wrap">
9 <?dbhtml filename="eglibc-headers.html"?>
10
11 <title>EGLIBC-&eglibc-version; Headers</title>
12
13 <indexterm zone="ch-cross-tools-eglibc-headers">
14 <primary sortas="a-EGLIBC">EGLIBC</primary>
15 <secondary>cross tools, headers</secondary>
16 </indexterm>
17
18 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
19 href="../../final-system/common/eglibc.xml"
20 xpointer="xpointer(//*[@role='package'])"/>
21
22 <sect2 role="installation">
23 <title>Installation of EGLIBC Headers</title>
24
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
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
48 will use the GCC that will be installed into
49 <filename class="directory">/cross-tools</filename> in the next step.
50 However, in this step only the EGLIBC headers are being installed - no
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>
53
54<screen os="s2"><userinput>cp -v configure{,.orig}
55sed -e 's/3.4/3.[0-9]/g' configure.orig &gt; configure</userinput></screen>
56
57 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
58 href="../../final-system/common/eglibc.xml"
59 xpointer="xpointer(//*[@os='e'])"/>
60
61 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
62 href="../../final-system/common/eglibc.xml"
63 xpointer="xpointer(//*[@os='f'])"/>
64
65 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
66 href="../common/eglibc.xml"
67 xpointer="xpointer(//*[@os='dd'])"/>
68
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
74libc_cv_gnu89_inline=yes
75libc_cv_ssp=no
76EOF</userinput></screen>
77
78 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
79 href="../../final-system/common/eglibc.xml"
80 xpointer="xpointer(//*[@os='g'])"/>
81
82<screen os="s3"><userinput>CC=gcc ../eglibc-&eglibc-version;/configure --prefix=/tools \
83 --host=${CLFS_TARGET} --build=${CLFS_HOST} \
84 --disable-sanity-checks --enable-kernel=2.6.32 \
85 --with-headers=/tools/include --cache-file=config.cache \
86 --with-binutils=/cross-tools/${CLFS_TARGET}/bin</userinput></screen>
87
88 <note os="e1">
89 <para><emphasis>Any</emphasis> error message you see about nptl at this point
90 can safely be ignored.</para>
91 </note>
92
93 <variablelist os="ca">
94 <title>The meaning of the configure options:</title>
95
96 <varlistentry os="ca1">
97 <term><parameter>CC=gcc</parameter></term>
98 <listitem>
99 <para>Tells EGLIBC to use the host's GCC compiler.</para>
100 </listitem>
101 </varlistentry>
102
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
107 package in the <filename class="directory">/tools</filename>
108 directory.</para>
109 </listitem>
110 </varlistentry>
111
112 <varlistentry os="ca3">
113 <term><parameter>--build=${CLFS_HOST}</parameter></term>
114 <listitem>
115 <para>When used with --host, this creates a cross-architecture
116 executable that creates files for ${CLFS_TARGET} but runs on ${CLFS_HOST}.</para>
117 </listitem>
118 </varlistentry>
119
120 <varlistentry os="ca4">
121 <term><parameter>--host=${CLFS_TARGET}</parameter></term>
122 <listitem>
123 <para>When used with --build, this creates a cross-architecture
124 executable that creates files for ${CLFS_TARGET} but runs on ${CLFS_HOST}.</para>
125 </listitem>
126 </varlistentry>
127
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>
134
135 <varlistentry os="ca6">
136 <term><parameter>--enable-kernel=2.6.32</parameter></term>
137 <listitem>
138 <para>This tells EGLIBC to compile the library with support
139 for 2.6.32 and later Linux kernels.</para>
140 </listitem>
141 </varlistentry>
142
143 <varlistentry os="ca7">
144 <term><parameter>--with-headers=/tools/include</parameter></term>
145 <listitem>
146 <para>This tells EGLIBC to compile itself against the headers
147 recently installed to the <filename class="directory">/tools</filename>
148 directory, so that it knows exactly what features the kernel has
149 and can optimize itself accordingly.</para>
150 </listitem>
151 </varlistentry>
152
153 <varlistentry os="ca8">
154 <term><parameter>--with-binutils=/cross-tools/${CLFS_TARGET}/bin</parameter></term>
155 <listitem>
156 <para>This tells EGLIBC to use the Binutils for our specific target architecture.</para>
157 </listitem>
158 </varlistentry>
159
160 </variablelist>
161
162 <para os="cb">Now, install the headers:</para>
163
164<screen os="cd"><userinput>make install-headers</userinput></screen>
165
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>
168
169 <para os="cf">First we will copy a common file over to <filename
170 class="directory">/tools/include</filename>:</para>
171
172<screen os="cg"><userinput>install -dv /tools/include/bits
173cp -v bits/stdio_lim.h /tools/include/bits</userinput></screen>
174
175 <para os="ch">Now we will create a blank stub file:</para>
176
177<screen os="ci"><userinput>touch /tools/include/gnu/stubs.h</userinput></screen>
178
179 <para os="cj">Another header is needed for NPTL:</para>
180
181<screen><userinput>cp -v ../eglibc-&eglibc-version;/nptl/sysdeps/unix/sysv/linux/alpha/bits/pthreadtypes.h \
182 /tools/include/bits/</userinput></screen>
183
184 </sect2>
185
186 <sect2 role="content">
187 <title/>
188
189 <para>Details on this package are located in <xref
190 linkend="contents-eglibc" role="."/></para>
191
192 </sect2>
193
194</sect1>
Note: See TracBrowser for help on using the repository browser.