summaryrefslogtreecommitdiffstats
path: root/meta/packages/glibc
diff options
context:
space:
mode:
authorRichard Purdie <rpurdie@linux.intel.com>2010-08-27 15:14:24 +0100
committerRichard Purdie <rpurdie@linux.intel.com>2010-08-27 15:29:45 +0100
commit29d6678fd546377459ef75cf54abeef5b969b5cf (patch)
tree8edd65790e37a00d01c3f203f773fe4b5012db18 /meta/packages/glibc
parentda49de6885ee1bc424e70bc02f21f6ab920efb55 (diff)
downloadpoky-29d6678fd546377459ef75cf54abeef5b969b5cf.tar.gz
Major layout change to the packages directory
Having one monolithic packages directory makes it hard to find things and is generally overwhelming. This commit splits it into several logical sections roughly based on function, recipes.txt gives more information about the classifications used. The opportunity is also used to switch from "packages" to "recipes" as used in OpenEmbedded as the term "packages" can be confusing to people and has many different meanings. Not all recipes have been classified yet, this is just a first pass at separating things out. Some packages are moved to meta-extras as they're no longer actively used or maintained. Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
Diffstat (limited to 'meta/packages/glibc')
-rw-r--r--meta/packages/glibc/glibc-2.10.1/arm-check-pf.patch14
-rw-r--r--meta/packages/glibc/glibc-2.10.1/arm-longlong.patch58
-rw-r--r--meta/packages/glibc/glibc-2.10.1/arm-lowlevellock-include-tls.patch12
-rw-r--r--meta/packages/glibc/glibc-2.10.1/arm-memcpy.patch758
-rw-r--r--meta/packages/glibc/glibc-2.10.1/dl-cache-libcmp.patch10
-rw-r--r--meta/packages/glibc/glibc-2.10.1/etc/ld.so.conf2
-rw-r--r--meta/packages/glibc/glibc-2.10.1/fhs-linux-paths.patch11
-rw-r--r--meta/packages/glibc/glibc-2.10.1/generate-supported.mk11
-rw-r--r--meta/packages/glibc/glibc-2.10.1/generic-bits_select.h35
-rw-r--r--meta/packages/glibc/glibc-2.10.1/generic-bits_time.h75
-rw-r--r--meta/packages/glibc/glibc-2.10.1/generic-bits_types.h200
-rw-r--r--meta/packages/glibc/glibc-2.10.1/generic-bits_typesizes.h66
-rw-r--r--meta/packages/glibc/glibc-2.10.1/glibc-2.9-enable-binutils-2.2.patch35
-rw-r--r--meta/packages/glibc/glibc-2.10.1/glibc-arm-IO-acquire-lock-fix.diff13
-rw-r--r--meta/packages/glibc/glibc-2.10.1/glibc-arm-no-asm-page.patch15
-rw-r--r--meta/packages/glibc/glibc-2.10.1/glibc-check_pf.patch343
-rw-r--r--meta/packages/glibc/glibc-2.10.1/ldd-unbash.patch11
-rw-r--r--meta/packages/glibc/glibc-2.10.1/ldsocache-varrun.patch18
-rw-r--r--meta/packages/glibc/glibc-2.10.1/local-args6.diff12
-rw-r--r--meta/packages/glibc/glibc-2.10.1/march-i686.patch38
-rw-r--r--meta/packages/glibc/glibc-2.10.1/nptl-crosscompile.patch26
-rw-r--r--meta/packages/glibc/glibc-2.10.1/nscd-init.patch39
-rw-r--r--meta/packages/glibc/glibc-2.10.1/powerpc-sqrt-hack.diff25
-rw-r--r--meta/packages/glibc/glibc-2.10.1/rulesfix.patch13
-rw-r--r--meta/packages/glibc/glibc-initial.inc53
-rw-r--r--meta/packages/glibc/glibc-initial_2.10.1.bb6
-rw-r--r--meta/packages/glibc/glibc-package.inc84
-rw-r--r--meta/packages/glibc/glibc-stage.inc0
-rw-r--r--meta/packages/glibc/glibc.inc42
-rw-r--r--meta/packages/glibc/glibc_2.10.1.bb161
-rw-r--r--meta/packages/glibc/ldconfig-native-2.5/32and64bit.patch289
-rw-r--r--meta/packages/glibc/ldconfig-native-2.5/ldconfig-native-2.5.tar.bz2bin19454 -> 0 bytes
-rw-r--r--meta/packages/glibc/ldconfig-native-2.5/ldconfig.patch460
-rw-r--r--meta/packages/glibc/ldconfig-native_2.5.bb20
34 files changed, 0 insertions, 2955 deletions
diff --git a/meta/packages/glibc/glibc-2.10.1/arm-check-pf.patch b/meta/packages/glibc/glibc-2.10.1/arm-check-pf.patch
deleted file mode 100644
index b9c72262f2..0000000000
--- a/meta/packages/glibc/glibc-2.10.1/arm-check-pf.patch
+++ /dev/null
@@ -1,14 +0,0 @@
1Index: glibc-2.9/ports/sysdeps/unix/sysv/linux/arm/check_pf.c
2===================================================================
3--- glibc-2.9.orig/ports/sysdeps/unix/sysv/linux/arm/check_pf.c 2009-06-19 20:45:32.451372131 +0400
4+++ glibc-2.9/ports/sysdeps/unix/sysv/linux/arm/check_pf.c 2009-06-19 20:45:51.351313426 +0400
5@@ -207,9 +207,6 @@
6 newp->info.flags = (((ifam->ifa_flags & IFA_F_DEPRECATED)
7 ? in6ai_deprecated : 0)
8 | ((ifam->ifa_flags
9- & IFA_F_TEMPORARY)
10- ? in6ai_temporary : 0)
11- | ((ifam->ifa_flags
12 & IFA_F_HOMEADDRESS)
13 ? in6ai_homeaddress : 0));
14 memcpy (newp->info.addr, address ?: local,
diff --git a/meta/packages/glibc/glibc-2.10.1/arm-longlong.patch b/meta/packages/glibc/glibc-2.10.1/arm-longlong.patch
deleted file mode 100644
index 28aca83dff..0000000000
--- a/meta/packages/glibc/glibc-2.10.1/arm-longlong.patch
+++ /dev/null
@@ -1,58 +0,0 @@
1--- glibc-2.4/stdlib/longlong.h.ark 2006-03-11 22:49:27.000000000 +0100
2+++ glibc-2.4/stdlib/longlong.h 2006-03-11 22:55:12.000000000 +0100
3@@ -206,6 +206,14 @@
4 "rI" ((USItype) (bh)), \
5 "r" ((USItype) (al)), \
6 "rI" ((USItype) (bl)) __CLOBBER_CC)
7+/* v3m and all higher arches have long multiply support. */
8+#if !defined(__ARM_ARCH_2__) && !defined(__ARM_ARCH_3__)
9+#define umul_ppmm(xh, xl, a, b) \
10+ __asm__ ("umull %0,%1,%2,%3" : "=&r" (xl), "=&r" (xh) : "r" (a), "r" (b))
11+#define UMUL_TIME 5
12+#define smul_ppmm(xh, xl, a, b) \
13+ __asm__ ("smull %0,%1,%2,%3" : "=&r" (xl), "=&r" (xh) : "r" (a), "r" (b))
14+#else
15 #define umul_ppmm(xh, xl, a, b) \
16 {register USItype __t0, __t1, __t2; \
17 __asm__ ("%@ Inlined umul_ppmm\n" \
18@@ -227,7 +235,13 @@
19 : "r" ((USItype) (a)), \
20 "r" ((USItype) (b)) __CLOBBER_CC );}
21 #define UMUL_TIME 20
22+#endif
23 #define UDIV_TIME 100
24+#if defined(__ARM_ARCH_5__) || defined(__ARM_ARCH_5T__) || defined(__ARM_ARCH_5TE__)
25+#define count_leading_zeros(COUNT,X) ((COUNT) = __builtin_clz (X))
26+#define COUNT_LEADING_ZEROS_0 32
27+#endif
28+
29 #endif /* __arm__ */
30
31 #if defined (__hppa) && W_TYPE_SIZE == 32
32--- glibc-2.4/ports/sysdeps/arm/mp_clz_tab.c.ark 2006-03-11 22:56:43.000000000 +0100
33+++ glibc-2.4/ports/sysdeps/arm/mp_clz_tab.c 2006-03-11 22:58:19.000000000 +0100
34@@ -0,0 +1,24 @@
35+/* __clz_tab -- support for longlong.h
36+ Copyright (C) 2004 Free Software Foundation, Inc.
37+ This file is part of the GNU C Library.
38+
39+ The GNU C Library is free software; you can redistribute it and/or
40+ modify it under the terms of the GNU Lesser General Public
41+ License as published by the Free Software Foundation; either
42+ version 2.1 of the License, or (at your option) any later version.
43+
44+ The GNU C Library is distributed in the hope that it will be useful,
45+ but WITHOUT ANY WARRANTY; without even the implied warranty of
46+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
47+ Lesser General Public License for more details.
48+
49+ You should have received a copy of the GNU Lesser General Public
50+ License along with the GNU C Library; if not, write to the Free
51+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
52+ 02111-1307 USA. */
53+
54+#if defined(__ARM_ARCH_5__) || defined(__ARM_ARCH_5T__) || defined(__ARM_ARCH_5TE__)
55+/* Nothing required. */
56+#else
57+#include <stdlib/mp_clz_tab.c>
58+#endif
diff --git a/meta/packages/glibc/glibc-2.10.1/arm-lowlevellock-include-tls.patch b/meta/packages/glibc/glibc-2.10.1/arm-lowlevellock-include-tls.patch
deleted file mode 100644
index 5c8062ecee..0000000000
--- a/meta/packages/glibc/glibc-2.10.1/arm-lowlevellock-include-tls.patch
+++ /dev/null
@@ -1,12 +0,0 @@
1Index: glibc-2.9/ports/sysdeps/unix/sysv/linux/arm/nptl/lowlevellock.h
2===================================================================
3--- glibc-2.9.orig/ports/sysdeps/unix/sysv/linux/arm/nptl/lowlevellock.h 2009-06-19 20:54:35.446686910 +0400
4+++ glibc-2.9/ports/sysdeps/unix/sysv/linux/arm/nptl/lowlevellock.h 2009-06-19 20:54:43.774683370 +0400
5@@ -25,6 +25,7 @@
6 #include <atomic.h>
7 #include <sysdep.h>
8 #include <kernel-features.h>
9+#include <tls.h>
10
11 #define FUTEX_WAIT 0
12 #define FUTEX_WAKE 1
diff --git a/meta/packages/glibc/glibc-2.10.1/arm-memcpy.patch b/meta/packages/glibc/glibc-2.10.1/arm-memcpy.patch
deleted file mode 100644
index bc2b3dab84..0000000000
--- a/meta/packages/glibc/glibc-2.10.1/arm-memcpy.patch
+++ /dev/null
@@ -1,758 +0,0 @@
1--- /dev/null 2004-02-02 20:32:13.000000000 +0000
2+++ sysdeps/arm/memmove.S 2004-03-20 18:37:23.000000000 +0000
3@@ -0,0 +1,251 @@
4+/*
5+ * Optimized memmove implementation for ARM processors
6+ *
7+ * Author: Nicolas Pitre
8+ * Created: Dec 23, 2003
9+ * Copyright: (C) MontaVista Software, Inc.
10+ *
11+ * This file is free software; you can redistribute it and/or
12+ * modify it under the terms of the GNU Lesser General Public
13+ * License as published by the Free Software Foundation; either
14+ * version 2.1 of the License, or (at your option) any later version.
15+ *
16+ * This file is distributed in the hope that it will be useful,
17+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
18+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
19+ * Lesser General Public License for more details.
20+ */
21+
22+#include <sysdep.h>
23+
24+
25+/*
26+ * Endian independent macros for shifting bytes within registers.
27+ */
28+#ifndef __ARMEB__
29+#define pull lsr
30+#define push lsl
31+#else
32+#define pull lsl
33+#define push lsr
34+#endif
35+
36+/*
37+ * Enable data preload for architectures that support it (ARMv5 and above)
38+ */
39+#if defined(__ARM_ARCH_5__) || \
40+ defined(__ARM_ARCH_5T__) || \
41+ defined(__ARM_ARCH_5TE__)
42+#define PLD(code...) code
43+#else
44+#define PLD(code...)
45+#endif
46+
47+
48+/* char * memmove (char *dst, const char *src) */
49+ENTRY(memmove)
50+ subs ip, r0, r1
51+ cmphi r2, ip
52+ bls memcpy(PLT)
53+
54+ stmfd sp!, {r0, r4, lr}
55+ add r1, r1, r2
56+ add r0, r0, r2
57+ subs r2, r2, #4
58+ blt 25f
59+ ands ip, r0, #3
60+ PLD( pld [r1, #-4] )
61+ bne 26f
62+ ands ip, r1, #3
63+ bne 27f
64+
65+19: subs r2, r2, #4
66+ blt 24f
67+ subs r2, r2, #8
68+ blt 23f
69+ subs r2, r2, #16
70+ blt 22f
71+
72+ PLD( pld [r1, #-32] )
73+ PLD( subs r2, r2, #96 )
74+ stmfd sp!, {r5 - r8}
75+ PLD( blt 21f )
76+
77+ PLD( @ cache alignment )
78+ PLD( ands ip, r1, #31 )
79+ PLD( pld [r1, #-64] )
80+ PLD( beq 20f )
81+ PLD( cmp r2, ip )
82+ PLD( pld [r1, #-96] )
83+ PLD( blt 20f )
84+ PLD( cmp ip, #16 )
85+ PLD( sub r2, r2, ip )
86+ PLD( ldmgedb r1!, {r3 - r6} )
87+ PLD( stmgedb r0!, {r3 - r6} )
88+ PLD( beq 20f )
89+ PLD( and ip, ip, #15 )
90+ PLD( cmp ip, #8 )
91+ PLD( ldr r3, [r1, #-4]! )
92+ PLD( ldrge r4, [r1, #-4]! )
93+ PLD( ldrgt r5, [r1, #-4]! )
94+ PLD( str r3, [r0, #-4]! )
95+ PLD( strge r4, [r0, #-4]! )
96+ PLD( strgt r5, [r0, #-4]! )
97+
98+20: PLD( pld [r1, #-96] )
99+ PLD( pld [r1, #-128] )
100+21: ldmdb r1!, {r3, r4, ip, lr}
101+ subs r2, r2, #32
102+ stmdb r0!, {r3, r4, ip, lr}
103+ ldmdb r1!, {r3, r4, ip, lr}
104+ stmgedb r0!, {r3, r4, ip, lr}
105+ ldmgedb r1!, {r3, r4, ip, lr}
106+ stmgedb r0!, {r3, r4, ip, lr}
107+ ldmgedb r1!, {r3, r4, ip, lr}
108+ subges r2, r2, #32
109+ stmdb r0!, {r3, r4, ip, lr}
110+ bge 20b
111+ PLD( cmn r2, #96 )
112+ PLD( bge 21b )
113+ PLD( add r2, r2, #96 )
114+ tst r2, #31
115+ ldmfd sp!, {r5 - r8}
116+ ldmeqfd sp!, {r0, r4, pc}
117+
118+ tst r2, #16
119+22: ldmnedb r1!, {r3, r4, ip, lr}
120+ stmnedb r0!, {r3, r4, ip, lr}
121+
122+ tst r2, #8
123+23: ldmnedb r1!, {r3, r4}
124+ stmnedb r0!, {r3, r4}
125+
126+ tst r2, #4
127+24: ldrne r3, [r1, #-4]!
128+ strne r3, [r0, #-4]!
129+
130+25: ands r2, r2, #3
131+ ldmeqfd sp!, {r0, r4, pc}
132+
133+ cmp r2, #2
134+ ldrb r3, [r1, #-1]
135+ ldrgeb r4, [r1, #-2]
136+ ldrgtb ip, [r1, #-3]
137+ strb r3, [r0, #-1]
138+ strgeb r4, [r0, #-2]
139+ strgtb ip, [r0, #-3]
140+ ldmfd sp!, {r0, r4, pc}
141+
142+26: cmp ip, #2
143+ ldrb r3, [r1, #-1]!
144+ ldrgeb r4, [r1, #-1]!
145+ ldrgtb lr, [r1, #-1]!
146+ strb r3, [r0, #-1]!
147+ strgeb r4, [r0, #-1]!
148+ strgtb lr, [r0, #-1]!
149+ subs r2, r2, ip
150+ blt 25b
151+ ands ip, r1, #3
152+ beq 19b
153+
154+27: bic r1, r1, #3
155+ cmp ip, #2
156+ ldr r3, [r1]
157+ beq 35f
158+ blt 36f
159+
160+
161+ .macro backward_copy_shift push pull
162+
163+ cmp r2, #12
164+ PLD( pld [r1, #-4] )
165+ blt 33f
166+ subs r2, r2, #28
167+ stmfd sp!, {r5 - r9}
168+ blt 31f
169+
170+ PLD( subs r2, r2, #96 )
171+ PLD( pld [r1, #-32] )
172+ PLD( blt 30f )
173+ PLD( pld [r1, #-64] )
174+
175+ PLD( @ cache alignment )
176+ PLD( ands ip, r1, #31 )
177+ PLD( pld [r1, #-96] )
178+ PLD( beq 29f )
179+ PLD( cmp r2, ip )
180+ PLD( pld [r1, #-128] )
181+ PLD( blt 29f )
182+ PLD( sub r2, r2, ip )
183+28: PLD( mov r4, r3, push #\push )
184+ PLD( ldr r3, [r1, #-4]! )
185+ PLD( subs ip, ip, #4 )
186+ PLD( orr r4, r4, r3, pull #\pull )
187+ PLD( str r4, [r0, #-4]! )
188+ PLD( bgt 28b )
189+
190+29: PLD( pld [r1, #-128] )
191+30: mov lr, r3, push #\push
192+ ldmdb r1!, {r3 - r9, ip}
193+ subs r2, r2, #32
194+ orr lr, lr, ip, pull #\pull
195+ mov ip, ip, push #\push
196+ orr ip, ip, r9, pull #\pull
197+ mov r9, r9, push #\push
198+ orr r9, r9, r8, pull #\pull
199+ mov r8, r8, push #\push
200+ orr r8, r8, r7, pull #\pull
201+ mov r7, r7, push #\push
202+ orr r7, r7, r6, pull #\pull
203+ mov r6, r6, push #\push
204+ orr r6, r6, r5, pull #\pull
205+ mov r5, r5, push #\push
206+ orr r5, r5, r4, pull #\pull
207+ mov r4, r4, push #\push
208+ orr r4, r4, r3, pull #\pull
209+ stmdb r0!, {r4 - r9, ip, lr}
210+ bge 29b
211+ PLD( cmn r2, #96 )
212+ PLD( bge 30b )
213+ PLD( add r2, r2, #96 )
214+ cmn r2, #16
215+ blt 32f
216+31: mov r7, r3, push #\push
217+ ldmdb r1!, {r3 - r6}
218+ sub r2, r2, #16
219+ orr r7, r7, r6, pull #\pull
220+ mov r6, r6, push #\push
221+ orr r6, r6, r5, pull #\pull
222+ mov r5, r5, push #\push
223+ orr r5, r5, r4, pull #\pull
224+ mov r4, r4, push #\push
225+ orr r4, r4, r3, pull #\pull
226+ stmdb r0!, {r4 - r7}
227+32: adds r2, r2, #28
228+ ldmfd sp!, {r5 - r9}
229+ blt 34f
230+33: mov r4, r3, push #\push
231+ ldr r3, [r1, #-4]!
232+ subs r2, r2, #4
233+ orr r4, r4, r3, pull #\pull
234+ str r4, [r0, #-4]!
235+ bge 33b
236+34:
237+ .endm
238+
239+
240+ backward_copy_shift push=8 pull=24
241+ add r1, r1, #3
242+ b 25b
243+
244+35: backward_copy_shift push=16 pull=16
245+ add r1, r1, #2
246+ b 25b
247+
248+36: backward_copy_shift push=24 pull=8
249+ add r1, r1, #1
250+ b 25b
251+
252+ .size memmove, . - memmove
253+END(memmove)
254+libc_hidden_builtin_def (memmove)
255--- /dev/null 2004-02-02 20:32:13.000000000 +0000
256+++ sysdeps/arm/bcopy.S 2004-03-20 18:37:48.000000000 +0000
257@@ -0,0 +1,255 @@
258+/*
259+ * Optimized memmove implementation for ARM processors
260+ *
261+ * Author: Nicolas Pitre
262+ * Created: Dec 23, 2003
263+ * Copyright: (C) MontaVista Software, Inc.
264+ *
265+ * This file is free software; you can redistribute it and/or
266+ * modify it under the terms of the GNU Lesser General Public
267+ * License as published by the Free Software Foundation; either
268+ * version 2.1 of the License, or (at your option) any later version.
269+ *
270+ * This file is distributed in the hope that it will be useful,
271+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
272+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
273+ * Lesser General Public License for more details.
274+ */
275+
276+#include <sysdep.h>
277+
278+
279+/*
280+ * Endian independent macros for shifting bytes within registers.
281+ */
282+#ifndef __ARMEB__
283+#define pull lsr
284+#define push lsl
285+#else
286+#define pull lsl
287+#define push lsr
288+#endif
289+
290+/*
291+ * Enable data preload for architectures that support it (ARMv5 and above)
292+ */
293+#if defined(__ARM_ARCH_5__) || \
294+ defined(__ARM_ARCH_5T__) || \
295+ defined(__ARM_ARCH_5TE__)
296+#define PLD(code...) code
297+#else
298+#define PLD(code...)
299+#endif
300+
301+dst .req r1
302+src .req r0
303+
304+/* void *bcopy (const char *src, char *dst, size_t size) */
305+ENTRY(bcopy)
306+ subs ip, dst, src
307+ cmphi r2, ip
308+ movls r3, r0
309+ movls r0, r1
310+ movls r1, r3
311+ bls memcpy(PLT)
312+
313+ stmfd sp!, {r4, lr}
314+ add src, src, r2
315+ add dst, dst, r2
316+ subs r2, r2, #4
317+ blt 25f
318+ ands ip, dst, #3
319+ PLD( pld [src, #-4] )
320+ bne 26f
321+ ands ip, src, #3
322+ bne 27f
323+
324+19: subs r2, r2, #4
325+ blt 24f
326+ subs r2, r2, #8
327+ blt 23f
328+ subs r2, r2, #16
329+ blt 22f
330+
331+ PLD( pld [src, #-32] )
332+ PLD( subs r2, r2, #96 )
333+ stmfd sp!, {r5 - r8}
334+ PLD( blt 21f )
335+
336+ PLD( @ cache alignment )
337+ PLD( ands ip, src, #31 )
338+ PLD( pld [src, #-64] )
339+ PLD( beq 20f )
340+ PLD( cmp r2, ip )
341+ PLD( pld [src, #-96] )
342+ PLD( blt 20f )
343+ PLD( cmp ip, #16 )
344+ PLD( sub r2, r2, ip )
345+ PLD( ldmgedb src!, {r3 - r6} )
346+ PLD( stmgedb dst!, {r3 - r6} )
347+ PLD( beq 20f )
348+ PLD( and ip, ip, #15 )
349+ PLD( cmp ip, #8 )
350+ PLD( ldr r3, [src, #-4]! )
351+ PLD( ldrge r4, [src, #-4]! )
352+ PLD( ldrgt r5, [src, #-4]! )
353+ PLD( str r3, [dst, #-4]! )
354+ PLD( strge r4, [dst, #-4]! )
355+ PLD( strgt r5, [dst, #-4]! )
356+
357+20: PLD( pld [src, #-96] )
358+ PLD( pld [src, #-128] )
359+21: ldmdb src!, {r3, r4, ip, lr}
360+ subs r2, r2, #32
361+ stmdb dst!, {r3, r4, ip, lr}
362+ ldmdb src!, {r3, r4, ip, lr}
363+ stmgedb dst!, {r3, r4, ip, lr}
364+ ldmgedb src!, {r3, r4, ip, lr}
365+ stmgedb dst!, {r3, r4, ip, lr}
366+ ldmgedb src!, {r3, r4, ip, lr}
367+ subges r2, r2, #32
368+ stmdb dst!, {r3, r4, ip, lr}
369+ bge 20b
370+ PLD( cmn r2, #96 )
371+ PLD( bge 21b )
372+ PLD( add r2, r2, #96 )
373+ tst r2, #31
374+ ldmfd sp!, {r5 - r8}
375+ ldmeqfd sp!, {r4, pc}
376+
377+ tst r2, #16
378+22: ldmnedb src!, {r3, r4, ip, lr}
379+ stmnedb dst!, {r3, r4, ip, lr}
380+
381+ tst r2, #8
382+23: ldmnedb src!, {r3, r4}
383+ stmnedb dst!, {r3, r4}
384+
385+ tst r2, #4
386+24: ldrne r3, [src, #-4]!
387+ strne r3, [dst, #-4]!
388+
389+25: ands r2, r2, #3
390+ ldmeqfd sp!, {dst, r4, pc}
391+
392+ cmp r2, #2
393+ ldrb r3, [src, #-1]
394+ ldrgeb r4, [src, #-2]
395+ ldrgtb ip, [src, #-3]
396+ strb r3, [dst, #-1]
397+ strgeb r4, [dst, #-2]
398+ strgtb ip, [dst, #-3]
399+ ldmfd sp!, {dst, r4, pc}
400+
401+26: cmp ip, #2
402+ ldrb r3, [src, #-1]!
403+ ldrgeb r4, [src, #-1]!
404+ ldrgtb lr, [src, #-1]!
405+ strb r3, [dst, #-1]!
406+ strgeb r4, [dst, #-1]!
407+ strgtb lr, [dst, #-1]!
408+ subs r2, r2, ip
409+ blt 25b
410+ ands ip, src, #3
411+ beq 19b
412+
413+27: bic src, src, #3
414+ cmp ip, #2
415+ ldr r3, [src]
416+ beq 35f
417+ blt 36f
418+
419+
420+ .macro backward_copy_shift push pull
421+
422+ cmp r2, #12
423+ PLD( pld [src, #-4] )
424+ blt 33f
425+ subs r2, r2, #28
426+ stmfd sp!, {r5 - r9}
427+ blt 31f
428+
429+ PLD( subs r2, r2, #96 )
430+ PLD( pld [src, #-32] )
431+ PLD( blt 30f )
432+ PLD( pld [src, #-64] )
433+
434+ PLD( @ cache alignment )
435+ PLD( ands ip, src, #31 )
436+ PLD( pld [src, #-96] )
437+ PLD( beq 29f )
438+ PLD( cmp r2, ip )
439+ PLD( pld [src, #-128] )
440+ PLD( blt 29f )
441+ PLD( sub r2, r2, ip )
442+28: PLD( mov r4, r3, push #\push )
443+ PLD( ldr r3, [src, #-4]! )
444+ PLD( subs ip, ip, #4 )
445+ PLD( orr r4, r4, r3, pull #\pull )
446+ PLD( str r4, [dst, #-4]! )
447+ PLD( bgt 28b )
448+
449+29: PLD( pld [src, #-128] )
450+30: mov lr, r3, push #\push
451+ ldmdb src!, {r3 - r9, ip}
452+ subs r2, r2, #32
453+ orr lr, lr, ip, pull #\pull
454+ mov ip, ip, push #\push
455+ orr ip, ip, r9, pull #\pull
456+ mov r9, r9, push #\push
457+ orr r9, r9, r8, pull #\pull
458+ mov r8, r8, push #\push
459+ orr r8, r8, r7, pull #\pull
460+ mov r7, r7, push #\push
461+ orr r7, r7, r6, pull #\pull
462+ mov r6, r6, push #\push
463+ orr r6, r6, r5, pull #\pull
464+ mov r5, r5, push #\push
465+ orr r5, r5, r4, pull #\pull
466+ mov r4, r4, push #\push
467+ orr r4, r4, r3, pull #\pull
468+ stmdb dst!, {r4 - r9, ip, lr}
469+ bge 29b
470+ PLD( cmn r2, #96 )
471+ PLD( bge 30b )
472+ PLD( add r2, r2, #96 )
473+ cmn r2, #16
474+ blt 32f
475+31: mov r7, r3, push #\push
476+ ldmdb src!, {r3 - r6}
477+ sub r2, r2, #16
478+ orr r7, r7, r6, pull #\pull
479+ mov r6, r6, push #\push
480+ orr r6, r6, r5, pull #\pull
481+ mov r5, r5, push #\push
482+ orr r5, r5, r4, pull #\pull
483+ mov r4, r4, push #\push
484+ orr r4, r4, r3, pull #\pull
485+ stmdb dst!, {r4 - r7}
486+32: adds r2, r2, #28
487+ ldmfd sp!, {r5 - r9}
488+ blt 34f
489+33: mov r4, r3, push #\push
490+ ldr r3, [src, #-4]!
491+ subs r2, r2, #4
492+ orr r4, r4, r3, pull #\pull
493+ str r4, [dst, #-4]!
494+ bge 33b
495+34:
496+ .endm
497+
498+
499+ backward_copy_shift push=8 pull=24
500+ add src, src, #3
501+ b 25b
502+
503+35: backward_copy_shift push=16 pull=16
504+ add src, src, #2
505+ b 25b
506+
507+36: backward_copy_shift push=24 pull=8
508+ add src, src, #1
509+ b 25b
510+
511+ .size bcopy, . - bcopy
512+END(bcopy)
513
514--- /dev/null 2004-02-02 20:32:13.000000000 +0000
515+++ sysdeps/arm/memcpy.S 2004-05-02 14:33:22.000000000 +0100
516@@ -0,0 +1,242 @@
517+/*
518+ * Optimized memcpy implementation for ARM processors
519+ *
520+ * Author: Nicolas Pitre
521+ * Created: Dec 23, 2003
522+ * Copyright: (C) MontaVista Software, Inc.
523+ *
524+ * This file is free software; you can redistribute it and/or
525+ * modify it under the terms of the GNU Lesser General Public
526+ * License as published by the Free Software Foundation; either
527+ * version 2.1 of the License, or (at your option) any later version.
528+ *
529+ * This file is distributed in the hope that it will be useful,
530+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
531+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
532+ * Lesser General Public License for more details.
533+ */
534+
535+#include <sysdep.h>
536+
537+
538+/*
539+ * Endian independent macros for shifting bytes within registers.
540+ */
541+#ifndef __ARMEB__
542+#define pull lsr
543+#define push lsl
544+#else
545+#define pull lsl
546+#define push lsr
547+#endif
548+
549+/*
550+ * Enable data preload for architectures that support it (ARMv5 and above)
551+ */
552+#if defined(__ARM_ARCH_5__) || \
553+ defined(__ARM_ARCH_5T__) || \
554+ defined(__ARM_ARCH_5TE__)
555+#define PLD(code...) code
556+#else
557+#define PLD(code...)
558+#endif
559+
560+
561+/* char * memcpy (char *dst, const char *src) */
562+
563+ENTRY(memcpy)
564+ subs r2, r2, #4
565+ stmfd sp!, {r0, r4, lr}
566+ blt 7f
567+ ands ip, r0, #3
568+ PLD( pld [r1, #0] )
569+ bne 8f
570+ ands ip, r1, #3
571+ bne 9f
572+
573+1: subs r2, r2, #4
574+ blt 6f
575+ subs r2, r2, #8
576+ blt 5f
577+ subs r2, r2, #16
578+ blt 4f
579+
580+ PLD( subs r2, r2, #65 )
581+ stmfd sp!, {r5 - r8}
582+ PLD( blt 3f )
583+ PLD( pld [r1, #32] )
584+
585+ PLD( @ cache alignment )
586+ PLD( ands ip, r1, #31 )
587+ PLD( pld [r1, #64] )
588+ PLD( beq 2f )
589+ PLD( rsb ip, ip, #32 )
590+ PLD( cmp r2, ip )
591+ PLD( pld [r1, #96] )
592+ PLD( blt 2f )
593+ PLD( cmp ip, #16 )
594+ PLD( sub r2, r2, ip )
595+ PLD( ldmgeia r1!, {r3 - r6} )
596+ PLD( stmgeia r0!, {r3 - r6} )
597+ PLD( beq 2f )
598+ PLD( and ip, ip, #15 )
599+ PLD( cmp ip, #8 )
600+ PLD( ldr r3, [r1], #4 )
601+ PLD( ldrge r4, [r1], #4 )
602+ PLD( ldrgt r5, [r1], #4 )
603+ PLD( str r3, [r0], #4 )
604+ PLD( strge r4, [r0], #4 )
605+ PLD( strgt r5, [r0], #4 )
606+
607+2: PLD( pld [r1, #96] )
608+3: ldmia r1!, {r3 - r8, ip, lr}
609+ subs r2, r2, #32
610+ stmia r0!, {r3 - r8, ip, lr}
611+ bge 2b
612+ PLD( cmn r2, #65 )
613+ PLD( bge 3b )
614+ PLD( add r2, r2, #65 )
615+ tst r2, #31
616+ ldmfd sp!, {r5 - r8}
617+ ldmeqfd sp!, {r0, r4, pc}
618+
619+ tst r2, #16
620+4: ldmneia r1!, {r3, r4, ip, lr}
621+ stmneia r0!, {r3, r4, ip, lr}
622+
623+ tst r2, #8
624+5: ldmneia r1!, {r3, r4}
625+ stmneia r0!, {r3, r4}
626+
627+ tst r2, #4
628+6: ldrne r3, [r1], #4
629+ strne r3, [r0], #4
630+
631+7: ands r2, r2, #3
632+ ldmeqfd sp!, {r0, r4, pc}
633+
634+ cmp r2, #2
635+ ldrb r3, [r1], #1
636+ ldrgeb r4, [r1], #1
637+ ldrgtb ip, [r1]
638+ strb r3, [r0], #1
639+ strgeb r4, [r0], #1
640+ strgtb ip, [r0]
641+ ldmfd sp!, {r0, r4, pc}
642+
643+8: rsb ip, ip, #4
644+ cmp ip, #2
645+ ldrb r3, [r1], #1
646+ ldrgeb r4, [r1], #1
647+ ldrgtb lr, [r1], #1
648+ strb r3, [r0], #1
649+ strgeb r4, [r0], #1
650+ strgtb lr, [r0], #1
651+ subs r2, r2, ip
652+ blt 7b
653+ ands ip, r1, #3
654+ beq 1b
655+
656+9: bic r1, r1, #3
657+ cmp ip, #2
658+ ldr lr, [r1], #4
659+ beq 17f
660+ bgt 18f
661+
662+
663+ .macro forward_copy_shift pull push
664+
665+ cmp r2, #12
666+ PLD( pld [r1, #0] )
667+ blt 15f
668+ subs r2, r2, #28
669+ stmfd sp!, {r5 - r9}
670+ blt 13f
671+
672+ PLD( subs r2, r2, #97 )
673+ PLD( blt 12f )
674+ PLD( pld [r1, #32] )
675+
676+ PLD( @ cache alignment )
677+ PLD( rsb ip, r1, #36 )
678+ PLD( pld [r1, #64] )
679+ PLD( ands ip, ip, #31 )
680+ PLD( pld [r1, #96] )
681+ PLD( beq 11f )
682+ PLD( cmp r2, ip )
683+ PLD( pld [r1, #128] )
684+ PLD( blt 11f )
685+ PLD( sub r2, r2, ip )
686+10: PLD( mov r3, lr, pull #\pull )
687+ PLD( ldr lr, [r1], #4 )
688+ PLD( subs ip, ip, #4 )
689+ PLD( orr r3, r3, lr, push #\push )
690+ PLD( str r3, [r0], #4 )
691+ PLD( bgt 10b )
692+
693+11: PLD( pld [r1, #128] )
694+12: mov r3, lr, pull #\pull
695+ ldmia r1!, {r4 - r9, ip, lr}
696+ subs r2, r2, #32
697+ orr r3, r3, r4, push #\push
698+ mov r4, r4, pull #\pull
699+ orr r4, r4, r5, push #\push
700+ mov r5, r5, pull #\pull
701+ orr r5, r5, r6, push #\push
702+ mov r6, r6, pull #\pull
703+ orr r6, r6, r7, push #\push
704+ mov r7, r7, pull #\pull
705+ orr r7, r7, r8, push #\push
706+ mov r8, r8, pull #\pull
707+ orr r8, r8, r9, push #\push
708+ mov r9, r9, pull #\pull
709+ orr r9, r9, ip, push #\push
710+ mov ip, ip, pull #\pull
711+ orr ip, ip, lr, push #\push
712+ stmia r0!, {r3 - r9, ip}
713+ bge 11b
714+ PLD( cmn r2, #97 )
715+ PLD( bge 12b )
716+ PLD( add r2, r2, #97 )
717+ cmn r2, #16
718+ blt 14f
719+13: mov r3, lr, pull #\pull
720+ ldmia r1!, {r4 - r6, lr}
721+ sub r2, r2, #16
722+ orr r3, r3, r4, push #\push
723+ mov r4, r4, pull #\pull
724+ orr r4, r4, r5, push #\push
725+ mov r5, r5, pull #\pull
726+ orr r5, r5, r6, push #\push
727+ mov r6, r6, pull #\pull
728+ orr r6, r6, lr, push #\push
729+ stmia r0!, {r3 - r6}
730+14: adds r2, r2, #28
731+ ldmfd sp!, {r5 - r9}
732+ blt 16f
733+15: mov r3, lr, pull #\pull
734+ ldr lr, [r1], #4
735+ subs r2, r2, #4
736+ orr r3, r3, lr, push #\push
737+ str r3, [r0], #4
738+ bge 15b
739+16:
740+ .endm
741+
742+
743+ forward_copy_shift pull=8 push=24
744+ sub r1, r1, #3
745+ b 7b
746+
747+17: forward_copy_shift pull=16 push=16
748+ sub r1, r1, #2
749+ b 7b
750+
751+18: forward_copy_shift pull=24 push=8
752+ sub r1, r1, #1
753+ b 7b
754+
755+ .size memcpy, . - memcpy
756+END(memcpy)
757+libc_hidden_builtin_def (memcpy)
758+
diff --git a/meta/packages/glibc/glibc-2.10.1/dl-cache-libcmp.patch b/meta/packages/glibc/glibc-2.10.1/dl-cache-libcmp.patch
deleted file mode 100644
index 2fedfa6db0..0000000000
--- a/meta/packages/glibc/glibc-2.10.1/dl-cache-libcmp.patch
+++ /dev/null
@@ -1,10 +0,0 @@
1--- glibc-2.4/elf/Versions.ark 2006-03-11 23:30:09.000000000 +0100
2+++ glibc-2.4/elf/Versions 2006-03-11 23:31:44.000000000 +0100
3@@ -63,5 +63,7 @@
4 _dl_debug_state;
5 # Pointer protection.
6 __pointer_chk_guard;
7+ # for ldconfig
8+ _dl_cache_libcmp;
9 }
10 }
diff --git a/meta/packages/glibc/glibc-2.10.1/etc/ld.so.conf b/meta/packages/glibc/glibc-2.10.1/etc/ld.so.conf
deleted file mode 100644
index ddd777db2a..0000000000
--- a/meta/packages/glibc/glibc-2.10.1/etc/ld.so.conf
+++ /dev/null
@@ -1,2 +0,0 @@
1/usr/local/lib
2include /etc/ld.so.conf.d/*
diff --git a/meta/packages/glibc/glibc-2.10.1/fhs-linux-paths.patch b/meta/packages/glibc/glibc-2.10.1/fhs-linux-paths.patch
deleted file mode 100644
index 1f32f6d7f2..0000000000
--- a/meta/packages/glibc/glibc-2.10.1/fhs-linux-paths.patch
+++ /dev/null
@@ -1,11 +0,0 @@
1--- glibc-2.1.1/sysdeps/unix/sysv/linux/paths.h~ Thu May 27 13:16:33 1999
2+++ glibc-2.1.1/sysdeps/unix/sysv/linux/paths.h Thu May 27 13:17:55 1999
3@@ -71,7 +71,7 @@
4 /* Provide trailing slash, since mostly used for building pathnames. */
5 #define _PATH_DEV "/dev/"
6 #define _PATH_TMP "/tmp/"
7-#define _PATH_VARDB "/var/db/"
8+#define _PATH_VARDB "/var/lib/misc/"
9 #define _PATH_VARRUN "/var/run/"
10 #define _PATH_VARTMP "/var/tmp/"
11
diff --git a/meta/packages/glibc/glibc-2.10.1/generate-supported.mk b/meta/packages/glibc/glibc-2.10.1/generate-supported.mk
deleted file mode 100644
index d2a28c2dc6..0000000000
--- a/meta/packages/glibc/glibc-2.10.1/generate-supported.mk
+++ /dev/null
@@ -1,11 +0,0 @@
1#!/usr/bin/make
2
3include $(IN)
4
5all:
6 rm -f $(OUT)
7 touch $(OUT)
8 for locale in $(SUPPORTED-LOCALES); do \
9 [ $$locale = true ] && continue; \
10 echo $$locale | sed 's,/, ,' >> $(OUT); \
11 done
diff --git a/meta/packages/glibc/glibc-2.10.1/generic-bits_select.h b/meta/packages/glibc/glibc-2.10.1/generic-bits_select.h
deleted file mode 100644
index 47e7dedc30..0000000000
--- a/meta/packages/glibc/glibc-2.10.1/generic-bits_select.h
+++ /dev/null
@@ -1,35 +0,0 @@
1/* Copyright (C) 1997, 1998, 2001 Free Software Foundation, Inc.
2 This file is part of the GNU C Library.
3
4 The GNU C Library is free software; you can redistribute it and/or
5 modify it under the terms of the GNU Lesser General Public
6 License as published by the Free Software Foundation; either
7 version 2.1 of the License, or (at your option) any later version.
8
9 The GNU C Library is distributed in the hope that it will be useful,
10 but WITHOUT ANY WARRANTY; without even the implied warranty of
11 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 Lesser General Public License for more details.
13
14 You should have received a copy of the GNU Lesser General Public
15 License along with the GNU C Library; if not, write to the Free
16 Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
17 02111-1307 USA. */
18
19#ifndef _SYS_SELECT_H
20# error "Never use <bits/select.h> directly; include <sys/select.h> instead."
21#endif
22
23
24/* We don't use `memset' because this would require a prototype and
25 the array isn't too big. */
26#define __FD_ZERO(s) \
27 do { \
28 unsigned int __i; \
29 fd_set *__arr = (s); \
30 for (__i = 0; __i < sizeof (fd_set) / sizeof (__fd_mask); ++__i) \
31 __FDS_BITS (__arr)[__i] = 0; \
32 } while (0)
33#define __FD_SET(d, s) (__FDS_BITS (s)[__FDELT(d)] |= __FDMASK(d))
34#define __FD_CLR(d, s) (__FDS_BITS (s)[__FDELT(d)] &= ~__FDMASK(d))
35#define __FD_ISSET(d, s) ((__FDS_BITS (s)[__FDELT(d)] & __FDMASK(d)) != 0)
diff --git a/meta/packages/glibc/glibc-2.10.1/generic-bits_time.h b/meta/packages/glibc/glibc-2.10.1/generic-bits_time.h
deleted file mode 100644
index b3184d1de9..0000000000
--- a/meta/packages/glibc/glibc-2.10.1/generic-bits_time.h
+++ /dev/null
@@ -1,75 +0,0 @@
1/* System-dependent timing definitions. Generic version.
2 Copyright (C) 1996,1997,1999-2002,2003 Free Software Foundation, Inc.
3 This file is part of the GNU C Library.
4
5 The GNU C Library is free software; you can redistribute it and/or
6 modify it under the terms of the GNU Lesser General Public
7 License as published by the Free Software Foundation; either
8 version 2.1 of the License, or (at your option) any later version.
9
10 The GNU C Library is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 Lesser General Public License for more details.
14
15 You should have received a copy of the GNU Lesser General Public
16 License along with the GNU C Library; if not, write to the Free
17 Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
18 02111-1307 USA. */
19
20/*
21 * Never include this file directly; use <time.h> instead.
22 */
23
24#ifndef __need_timeval
25# ifndef _BITS_TIME_H
26# define _BITS_TIME_H 1
27
28/* ISO/IEC 9899:1990 7.12.1: <time.h>
29 The macro `CLOCKS_PER_SEC' is the number per second of the value
30 returned by the `clock' function. */
31/* CAE XSH, Issue 4, Version 2: <time.h>
32 The value of CLOCKS_PER_SEC is required to be 1 million on all
33 XSI-conformant systems. */
34# define CLOCKS_PER_SEC 1000000l
35
36# if !defined __STRICT_ANSI__ && !defined __USE_XOPEN2K
37/* Even though CLOCKS_PER_SEC has such a strange value CLK_TCK
38 presents the real value for clock ticks per second for the system. */
39# include <bits/types.h>
40extern long int __sysconf (int);
41# define CLK_TCK ((__clock_t) __sysconf (2)) /* 2 is _SC_CLK_TCK */
42# endif
43
44# ifdef __USE_POSIX199309
45/* Identifier for system-wide realtime clock. */
46# define CLOCK_REALTIME 0
47/* Monotonic system-wide clock. */
48# define CLOCK_MONOTONIC 1
49/* High-resolution timer from the CPU. */
50# define CLOCK_PROCESS_CPUTIME_ID 2
51/* Thread-specific CPU-time clock. */
52# define CLOCK_THREAD_CPUTIME_ID 3
53
54/* Flag to indicate time is absolute. */
55# define TIMER_ABSTIME 1
56# endif
57
58# endif /* bits/time.h */
59#endif
60
61#ifdef __need_timeval
62# undef __need_timeval
63# ifndef _STRUCT_TIMEVAL
64# define _STRUCT_TIMEVAL 1
65# include <bits/types.h>
66
67/* A time value that is accurate to the nearest
68 microsecond but also has a range of years. */
69struct timeval
70 {
71 __time_t tv_sec; /* Seconds. */
72 __suseconds_t tv_usec; /* Microseconds. */
73 };
74# endif /* struct timeval */
75#endif /* need timeval */
diff --git a/meta/packages/glibc/glibc-2.10.1/generic-bits_types.h b/meta/packages/glibc/glibc-2.10.1/generic-bits_types.h
deleted file mode 100644
index 65c8a9fe90..0000000000
--- a/meta/packages/glibc/glibc-2.10.1/generic-bits_types.h
+++ /dev/null
@@ -1,200 +0,0 @@
1/* bits/types.h -- definitions of __*_t types underlying *_t types.
2 Copyright (C) 2002, 2003, 2004, 2005 Free Software Foundation, Inc.
3 This file is part of the GNU C Library.
4
5 The GNU C Library is free software; you can redistribute it and/or
6 modify it under the terms of the GNU Lesser General Public
7 License as published by the Free Software Foundation; either
8 version 2.1 of the License, or (at your option) any later version.
9
10 The GNU C Library is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 Lesser General Public License for more details.
14
15 You should have received a copy of the GNU Lesser General Public
16 License along with the GNU C Library; if not, write to the Free
17 Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
18 02111-1307 USA. */
19
20/*
21 * Never include this file directly; use <sys/types.h> instead.
22 */
23
24#ifndef _BITS_TYPES_H
25#define _BITS_TYPES_H 1
26
27#include <features.h>
28#include <bits/wordsize.h>
29
30#define __need_size_t
31#include <stddef.h>
32
33/* Convenience types. */
34typedef unsigned char __u_char;
35typedef unsigned short int __u_short;
36typedef unsigned int __u_int;
37typedef unsigned long int __u_long;
38
39/* Fixed-size types, underlying types depend on word size and compiler. */
40typedef signed char __int8_t;
41typedef unsigned char __uint8_t;
42typedef signed short int __int16_t;
43typedef unsigned short int __uint16_t;
44typedef signed int __int32_t;
45typedef unsigned int __uint32_t;
46#if __WORDSIZE == 64
47typedef signed long int __int64_t;
48typedef unsigned long int __uint64_t;
49#elif defined __GLIBC_HAVE_LONG_LONG
50__extension__ typedef signed long long int __int64_t;
51__extension__ typedef unsigned long long int __uint64_t;
52#endif
53
54/* quad_t is also 64 bits. */
55#if __WORDSIZE == 64
56typedef long int __quad_t;
57typedef unsigned long int __u_quad_t;
58#elif defined __GLIBC_HAVE_LONG_LONG
59__extension__ typedef long long int __quad_t;
60__extension__ typedef unsigned long long int __u_quad_t;
61#else
62typedef struct
63{
64 long __val[2];
65} __quad_t;
66typedef struct
67{
68 __u_long __val[2];
69} __u_quad_t;
70#endif
71
72
73/* The machine-dependent file <bits/typesizes.h> defines __*_T_TYPE
74 macros for each of the OS types we define below. The definitions
75 of those macros must use the following macros for underlying types.
76 We define __S<SIZE>_TYPE and __U<SIZE>_TYPE for the signed and unsigned
77 variants of each of the following integer types on this machine.
78
79 16 -- "natural" 16-bit type (always short)
80 32 -- "natural" 32-bit type (always int)
81 64 -- "natural" 64-bit type (long or long long)
82 LONG32 -- 32-bit type, traditionally long
83 QUAD -- 64-bit type, always long long
84 WORD -- natural type of __WORDSIZE bits (int or long)
85 LONGWORD -- type of __WORDSIZE bits, traditionally long
86
87 We distinguish WORD/LONGWORD, 32/LONG32, and 64/QUAD so that the
88 conventional uses of `long' or `long long' type modifiers match the
89 types we define, even when a less-adorned type would be the same size.
90 This matters for (somewhat) portably writing printf/scanf formats for
91 these types, where using the appropriate l or ll format modifiers can
92 make the typedefs and the formats match up across all GNU platforms. If
93 we used `long' when it's 64 bits where `long long' is expected, then the
94 compiler would warn about the formats not matching the argument types,
95 and the programmer changing them to shut up the compiler would break the
96 program's portability.
97
98 Here we assume what is presently the case in all the GCC configurations
99 we support: long long is always 64 bits, long is always word/address size,
100 and int is always 32 bits. */
101
102#define __S16_TYPE short int
103#define __U16_TYPE unsigned short int
104#define __S32_TYPE int
105#define __U32_TYPE unsigned int
106#define __SLONGWORD_TYPE long int
107#define __ULONGWORD_TYPE unsigned long int
108#if __WORDSIZE == 32
109# define __SQUAD_TYPE __quad_t
110# define __UQUAD_TYPE __u_quad_t
111# define __SWORD_TYPE int
112# define __UWORD_TYPE unsigned int
113# define __SLONG32_TYPE long int
114# define __ULONG32_TYPE unsigned long int
115# define __S64_TYPE __quad_t
116# define __U64_TYPE __u_quad_t
117/* We want __extension__ before typedef's that use nonstandard base types
118 such as `long long' in C89 mode. */
119# define __STD_TYPE __extension__ typedef
120#elif __WORDSIZE == 64
121# define __SQUAD_TYPE long int
122# define __UQUAD_TYPE unsigned long int
123# define __SWORD_TYPE long int
124# define __UWORD_TYPE unsigned long int
125# define __SLONG32_TYPE int
126# define __ULONG32_TYPE unsigned int
127# define __S64_TYPE long int
128# define __U64_TYPE unsigned long int
129/* No need to mark the typedef with __extension__. */
130# define __STD_TYPE typedef
131#else
132# error
133#endif
134#include <bits/typesizes.h> /* Defines __*_T_TYPE macros. */
135
136
137__STD_TYPE __DEV_T_TYPE __dev_t; /* Type of device numbers. */
138__STD_TYPE __UID_T_TYPE __uid_t; /* Type of user identifications. */
139__STD_TYPE __GID_T_TYPE __gid_t; /* Type of group identifications. */
140__STD_TYPE __INO_T_TYPE __ino_t; /* Type of file serial numbers. */
141__STD_TYPE __INO64_T_TYPE __ino64_t; /* Type of file serial numbers (LFS).*/
142__STD_TYPE __MODE_T_TYPE __mode_t; /* Type of file attribute bitmasks. */
143__STD_TYPE __NLINK_T_TYPE __nlink_t; /* Type of file link counts. */
144__STD_TYPE __OFF_T_TYPE __off_t; /* Type of file sizes and offsets. */
145__STD_TYPE __OFF64_T_TYPE __off64_t; /* Type of file sizes and offsets (LFS). */
146__STD_TYPE __PID_T_TYPE __pid_t; /* Type of process identifications. */
147__STD_TYPE __FSID_T_TYPE __fsid_t; /* Type of file system IDs. */
148__STD_TYPE __CLOCK_T_TYPE __clock_t; /* Type of CPU usage counts. */
149__STD_TYPE __RLIM_T_TYPE __rlim_t; /* Type for resource measurement. */
150__STD_TYPE __RLIM64_T_TYPE __rlim64_t; /* Type for resource measurement (LFS). */
151__STD_TYPE __ID_T_TYPE __id_t; /* General type for IDs. */
152__STD_TYPE __TIME_T_TYPE __time_t; /* Seconds since the Epoch. */
153__STD_TYPE __USECONDS_T_TYPE __useconds_t; /* Count of microseconds. */
154__STD_TYPE __SUSECONDS_T_TYPE __suseconds_t; /* Signed count of microseconds. */
155
156__STD_TYPE __DADDR_T_TYPE __daddr_t; /* The type of a disk address. */
157__STD_TYPE __SWBLK_T_TYPE __swblk_t; /* Type of a swap block maybe? */
158__STD_TYPE __KEY_T_TYPE __key_t; /* Type of an IPC key. */
159
160/* Clock ID used in clock and timer functions. */
161__STD_TYPE __CLOCKID_T_TYPE __clockid_t;
162
163/* Timer ID returned by `timer_create'. */
164__STD_TYPE __TIMER_T_TYPE __timer_t;
165
166/* Type to represent block size. */
167__STD_TYPE __BLKSIZE_T_TYPE __blksize_t;
168
169/* Types from the Large File Support interface. */
170
171/* Type to count number of disk blocks. */
172__STD_TYPE __BLKCNT_T_TYPE __blkcnt_t;
173__STD_TYPE __BLKCNT64_T_TYPE __blkcnt64_t;
174
175/* Type to count file system blocks. */
176__STD_TYPE __FSBLKCNT_T_TYPE __fsblkcnt_t;
177__STD_TYPE __FSBLKCNT64_T_TYPE __fsblkcnt64_t;
178
179/* Type to count file system nodes. */
180__STD_TYPE __FSFILCNT_T_TYPE __fsfilcnt_t;
181__STD_TYPE __FSFILCNT64_T_TYPE __fsfilcnt64_t;
182
183__STD_TYPE __SSIZE_T_TYPE __ssize_t; /* Type of a byte count, or error. */
184
185/* These few don't really vary by system, they always correspond
186 to one of the other defined types. */
187typedef __off64_t __loff_t; /* Type of file sizes and offsets (LFS). */
188typedef __quad_t *__qaddr_t;
189typedef char *__caddr_t;
190
191/* Duplicates info from stdint.h but this is used in unistd.h. */
192__STD_TYPE __SWORD_TYPE __intptr_t;
193
194/* Duplicate info from sys/socket.h. */
195__STD_TYPE __U32_TYPE __socklen_t;
196
197
198#undef __STD_TYPE
199
200#endif /* bits/types.h */
diff --git a/meta/packages/glibc/glibc-2.10.1/generic-bits_typesizes.h b/meta/packages/glibc/glibc-2.10.1/generic-bits_typesizes.h
deleted file mode 100644
index e9226c4174..0000000000
--- a/meta/packages/glibc/glibc-2.10.1/generic-bits_typesizes.h
+++ /dev/null
@@ -1,66 +0,0 @@
1/* bits/typesizes.h -- underlying types for *_t. Generic version.
2 Copyright (C) 2002, 2003 Free Software Foundation, Inc.
3 This file is part of the GNU C Library.
4
5 The GNU C Library is free software; you can redistribute it and/or
6 modify it under the terms of the GNU Lesser General Public
7 License as published by the Free Software Foundation; either
8 version 2.1 of the License, or (at your option) any later version.
9
10 The GNU C Library is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 Lesser General Public License for more details.
14
15 You should have received a copy of the GNU Lesser General Public
16 License along with the GNU C Library; if not, write to the Free
17 Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
18 02111-1307 USA. */
19
20#ifndef _BITS_TYPES_H
21# error "Never include <bits/typesizes.h> directly; use <sys/types.h> instead."
22#endif
23
24#ifndef _BITS_TYPESIZES_H
25#define _BITS_TYPESIZES_H 1
26
27/* See <bits/types.h> for the meaning of these macros. This file exists so
28 that <bits/types.h> need not vary across different GNU platforms. */
29
30#define __DEV_T_TYPE __UQUAD_TYPE
31#define __UID_T_TYPE __U32_TYPE
32#define __GID_T_TYPE __U32_TYPE
33#define __INO_T_TYPE __ULONGWORD_TYPE
34#define __INO64_T_TYPE __UQUAD_TYPE
35#define __MODE_T_TYPE __U32_TYPE
36#define __NLINK_T_TYPE __UWORD_TYPE
37#define __OFF_T_TYPE __SLONGWORD_TYPE
38#define __OFF64_T_TYPE __SQUAD_TYPE
39#define __PID_T_TYPE __S32_TYPE
40#define __RLIM_T_TYPE __ULONGWORD_TYPE
41#define __RLIM64_T_TYPE __UQUAD_TYPE
42#define __BLKCNT_T_TYPE __SLONGWORD_TYPE
43#define __BLKCNT64_T_TYPE __SQUAD_TYPE
44#define __FSBLKCNT_T_TYPE __ULONGWORD_TYPE
45#define __FSBLKCNT64_T_TYPE __UQUAD_TYPE
46#define __FSFILCNT_T_TYPE __ULONGWORD_TYPE
47#define __FSFILCNT64_T_TYPE __UQUAD_TYPE
48#define __ID_T_TYPE __U32_TYPE
49#define __CLOCK_T_TYPE __SLONGWORD_TYPE
50#define __TIME_T_TYPE __SLONGWORD_TYPE
51#define __USECONDS_T_TYPE __U32_TYPE
52#define __SUSECONDS_T_TYPE __SLONGWORD_TYPE
53#define __DADDR_T_TYPE __S32_TYPE
54#define __SWBLK_T_TYPE __SLONGWORD_TYPE
55#define __KEY_T_TYPE __S32_TYPE
56#define __CLOCKID_T_TYPE __S32_TYPE
57#define __TIMER_T_TYPE void *
58#define __BLKSIZE_T_TYPE __SLONGWORD_TYPE
59#define __FSID_T_TYPE struct { int __val[2]; }
60#define __SSIZE_T_TYPE __SWORD_TYPE
61
62/* Number of descriptors that can fit in an `fd_set'. */
63#define __FD_SETSIZE 1024
64
65
66#endif /* bits/typesizes.h */
diff --git a/meta/packages/glibc/glibc-2.10.1/glibc-2.9-enable-binutils-2.2.patch b/meta/packages/glibc/glibc-2.10.1/glibc-2.9-enable-binutils-2.2.patch
deleted file mode 100644
index 09200dd43b..0000000000
--- a/meta/packages/glibc/glibc-2.10.1/glibc-2.9-enable-binutils-2.2.patch
+++ /dev/null
@@ -1,35 +0,0 @@
1--- glibc-2.9.orig/configure.in 2009-10-22 15:38:13.000000000 +0200
2+++ glibc-2.9/configure.in 2009-10-22 15:37:33.000000000 +0200
3@@ -844,10 +844,10 @@
4 # Accept binutils 2.13 or newer.
5 AC_CHECK_PROG_VER(AS, $AS, --version,
6 [GNU assembler.* \([0-9]*\.[0-9.]*\)],
7- [2.1[3-9]*], AS=: critic_missing="$critic_missing as")
8+ [2.1[3-9]* | 2.2* ], AS=: critic_missing="$critic_missing as")
9 AC_CHECK_PROG_VER(LD, $LD, --version,
10 [GNU ld.* \([0-9][0-9]*\.[0-9.]*\)],
11- [2.1[3-9]*], LD=: critic_missing="$critic_missing ld")
12+ [2.1[3-9]* | 2.2* ], LD=: critic_missing="$critic_missing ld")
13
14 # We need the physical current working directory. We cannot use the
15 # "pwd -P" shell builtin since that's not portable. Instead we try to
16--- glibc-2.9.orig/configure 2009-02-26 22:28:17.000000000 +0100
17+++ glibc-2.9/configure 2009-10-22 15:43:11.000000000 +0200
18@@ -4531,7 +4531,7 @@
19 ac_prog_version=`$AS --version 2>&1 | sed -n 's/^.*GNU assembler.* \([0-9]*\.[0-9.]*\).*$/\1/p'`
20 case $ac_prog_version in
21 '') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;;
22- 2.1[3-9]*)
23+ 2.1[3-9]* | 2.2*)
24 ac_prog_version="$ac_prog_version, ok"; ac_verc_fail=no;;
25 *) ac_prog_version="$ac_prog_version, bad"; ac_verc_fail=yes;;
26
27@@ -4594,7 +4594,7 @@
28 ac_prog_version=`$LD --version 2>&1 | sed -n 's/^.*GNU ld.* \([0-9][0-9]*\.[0-9.]*\).*$/\1/p'`
29 case $ac_prog_version in
30 '') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;;
31- 2.1[3-9]*)
32+ 2.1[3-9]* | 2.2*)
33 ac_prog_version="$ac_prog_version, ok"; ac_verc_fail=no;;
34 *) ac_prog_version="$ac_prog_version, bad"; ac_verc_fail=yes;;
35
diff --git a/meta/packages/glibc/glibc-2.10.1/glibc-arm-IO-acquire-lock-fix.diff b/meta/packages/glibc/glibc-2.10.1/glibc-arm-IO-acquire-lock-fix.diff
deleted file mode 100644
index a552cf0d1f..0000000000
--- a/meta/packages/glibc/glibc-2.10.1/glibc-arm-IO-acquire-lock-fix.diff
+++ /dev/null
@@ -1,13 +0,0 @@
1Arm needs a similar fix as http://sourceware.org/ml/libc-ports/2007-12/msg00000.html
2
3--- /tmp/stdio-lock.h 2008-03-04 18:51:15.555038993 +0100
4+++ glibc-2.7/ports/sysdeps/unix/sysv/linux/arm/bits/stdio-lock.h 2008-03-04 18:51:28.445035052 +0100
5@@ -50,6 +50,8 @@
6 _IO_cleanup_region_start ((void (*) (void *)) _IO_funlockfile, (_fp)); \
7 _IO_flockfile (_fp)
8
9+# define _IO_acquire_lock_clear_flags2(_fp) _IO_acquire_lock (_fp)
10+
11 # define _IO_release_lock(_fp) \
12 _IO_funlockfile (_fp); \
13 _IO_cleanup_region_end (0)
diff --git a/meta/packages/glibc/glibc-2.10.1/glibc-arm-no-asm-page.patch b/meta/packages/glibc/glibc-2.10.1/glibc-arm-no-asm-page.patch
deleted file mode 100644
index 7eb17179ba..0000000000
--- a/meta/packages/glibc/glibc-2.10.1/glibc-arm-no-asm-page.patch
+++ /dev/null
@@ -1,15 +0,0 @@
1http://sourceware.org/ml/libc-ports/2008-04/msg00005.html
2
3
4Index: glibc-2.6.1/ports/sysdeps/unix/sysv/linux/arm/ioperm.c
5===================================================================
6--- glibc-2.6.1.orig/ports/sysdeps/unix/sysv/linux/arm/ioperm.c 2008-09-12 18:08:18.000000000 -0700
7+++ glibc-2.6.1/ports/sysdeps/unix/sysv/linux/arm/ioperm.c 2008-09-12 18:08:28.000000000 -0700
8@@ -45,7 +45,6 @@
9 #include <sys/mman.h>
10
11 #include <linux/version.h>
12-#include <asm/page.h>
13 #include <sys/sysctl.h>
14
15 #define PATH_ARM_SYSTYPE "/etc/arm_systype"
diff --git a/meta/packages/glibc/glibc-2.10.1/glibc-check_pf.patch b/meta/packages/glibc/glibc-2.10.1/glibc-check_pf.patch
deleted file mode 100644
index 3cff6bbcfa..0000000000
--- a/meta/packages/glibc/glibc-2.10.1/glibc-check_pf.patch
+++ /dev/null
@@ -1,343 +0,0 @@
1From libc-ports-return-550-listarch-libc-ports=sources dot redhat dot com at sourceware dot org Tue Oct 31 17:37:21 2006
2Return-Path: <libc-ports-return-550-listarch-libc-ports=sources dot redhat dot com at sourceware dot org>
3Delivered-To: listarch-libc-ports at sources dot redhat dot com
4Received: (qmail 17273 invoked by alias); 31 Oct 2006 17:37:20 -0000
5Received: (qmail 17262 invoked by uid 22791); 31 Oct 2006 17:37:19 -0000
6X-Spam-Status: No, hits=-2.5 required=5.0 tests=AWL,BAYES_00,TW_CP
7X-Spam-Check-By: sourceware.org
8Received: from nevyn.them.org (HELO nevyn.them.org) (66.93.172.17) by sourceware.org (qpsmtpd/0.31.1) with ESMTP; Tue, 31 Oct 2006 17:37:11 +0000
9Received: from drow by nevyn.them.org with local (Exim 4.54) id 1GexXw-0007Dj-30; Tue, 31 Oct 2006 12:37:08 -0500
10Date: Tue, 31 Oct 2006 12:37:08 -0500
11From: Daniel Jacobowitz <drow at false dot org>
12To: Mike Frysinger <vapier at gentoo dot org>
13Cc: libc-ports at sourceware dot org, Philip Balister <philip dot balister at gmail dot com>
14Subject: Re: Problem with glibc-2.5 on ARM
15Message-ID: <20061031173708.GJ20468@nevyn.them.org>
16References: <499146270610241149ibe030e0nd9d6b177a95b346e@mail.gmail.com> <499146270610241254u7cadf63ej2edf05cedbc5266f@mail.gmail.com> <20061024195837.GA20181@nevyn.them.org> <200610291954.27022.vapier@gentoo.org>
17MIME-Version: 1.0
18Content-Type: text/plain; charset=us-ascii
19Content-Disposition: inline
20In-Reply-To: <200610291954 dot 27022 dot vapier at gentoo dot org>
21User-Agent: Mutt/1.5.13 (2006-08-11)
22X-IsSubscribed: yes
23Mailing-List: contact libc-ports-help at sourceware dot org; run by ezmlm
24Precedence: bulk
25List-Subscribe: <mailto:libc-ports-subscribe at sourceware dot org>
26List-Post: <mailto:libc-ports at sourceware dot org>
27List-Help: <mailto:libc-ports-help at sourceware dot org>, <http://sourceware dot org/lists dot html#faqs>
28Sender: libc-ports-owner at sourceware dot org
29Delivered-To: mailing list libc-ports at sourceware dot org
30
31On Sun, Oct 29, 2006 at 07:54:25PM -0500, Mike Frysinger wrote:
32> On Tuesday 24 October 2006 15:58, Daniel Jacobowitz wrote:
33> > ARM is going to need a slightly different version of that file, I
34> > guess.
35>
36> would declaring req with attribute packed not help ?
37> -mike
38
39Nope. "struct rtgenmsg" would still have size 4.
40
41Philip, are you still at all interested in this for the old ABI?
42I don't have time to test this patch right now, but I think it
43will work.
44
45--
46Daniel Jacobowitz
47CodeSourcery
48
492006-10-31 Daniel Jacobowitz <dan@codesourcery.com>
50
51 * sysdeps/unix/sysv/linux/arm/check_pf.c: New file.
52 * sysdeps/unix/sysv/linux/arm/eabi/check_pf.c: New file.
53
54Index: sysdeps/unix/sysv/linux/arm/check_pf.c
55===================================================================
56RCS file: sysdeps/unix/sysv/linux/arm/check_pf.c
57diff -N sysdeps/unix/sysv/linux/arm/check_pf.c
58--- /dev/null 1 Jan 1970 00:00:00 -0000
59+++ sysdeps/unix/sysv/linux/arm/check_pf.c 31 Oct 2006 17:29:58 -0000
60@@ -0,0 +1,274 @@
61+/* Determine protocol families for which interfaces exist. ARM Linux version.
62+ Copyright (C) 2003, 2006 Free Software Foundation, Inc.
63+ This file is part of the GNU C Library.
64+
65+ The GNU C Library is free software; you can redistribute it and/or
66+ modify it under the terms of the GNU Lesser General Public
67+ License as published by the Free Software Foundation; either
68+ version 2.1 of the License, or (at your option) any later version.
69+
70+ The GNU C Library is distributed in the hope that it will be useful,
71+ but WITHOUT ANY WARRANTY; without even the implied warranty of
72+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
73+ Lesser General Public License for more details.
74+
75+ You should have received a copy of the GNU Lesser General Public
76+ License along with the GNU C Library; if not, write to the Free
77+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
78+ 02111-1307 USA. */
79+
80+#include <assert.h>
81+#include <errno.h>
82+#include <ifaddrs.h>
83+#include <netdb.h>
84+#include <stddef.h>
85+#include <string.h>
86+#include <time.h>
87+#include <unistd.h>
88+#include <sys/socket.h>
89+
90+#include <asm/types.h>
91+#include <linux/netlink.h>
92+#include <linux/rtnetlink.h>
93+
94+#include <not-cancel.h>
95+#include <kernel-features.h>
96+
97+
98+#ifndef IFA_F_TEMPORARY
99+# define IFA_F_TEMPORARY IFA_F_SECONDARY
100+#endif
101+#ifndef IFA_F_HOMEADDRESS
102+# define IFA_F_HOMEADDRESS 0
103+#endif
104+
105+
106+static int
107+make_request (int fd, pid_t pid, bool *seen_ipv4, bool *seen_ipv6,
108+ struct in6addrinfo **in6ai, size_t *in6ailen)
109+{
110+ struct req
111+ {
112+ struct nlmsghdr nlh;
113+ struct rtgenmsg g;
114+ } req;
115+ struct sockaddr_nl nladdr;
116+
117+ /* struct rtgenmsg consists of a single byte but the ARM ABI rounds
118+ it up to a word. Clear the padding explicitly here. */
119+ assert (sizeof (req.g) == 4);
120+ memset (&req.g, '\0', sizeof (req.g));
121+
122+ req.nlh.nlmsg_len = sizeof (req);
123+ req.nlh.nlmsg_type = RTM_GETADDR;
124+ req.nlh.nlmsg_flags = NLM_F_ROOT | NLM_F_MATCH | NLM_F_REQUEST;
125+ req.nlh.nlmsg_pid = 0;
126+ req.nlh.nlmsg_seq = time (NULL);
127+ req.g.rtgen_family = AF_UNSPEC;
128+
129+ memset (&nladdr, '\0', sizeof (nladdr));
130+ nladdr.nl_family = AF_NETLINK;
131+
132+ if (TEMP_FAILURE_RETRY (__sendto (fd, (void *) &req, sizeof (req), 0,
133+ (struct sockaddr *) &nladdr,
134+ sizeof (nladdr))) < 0)
135+ return -1;
136+
137+ *seen_ipv4 = false;
138+ *seen_ipv6 = false;
139+
140+ bool done = false;
141+ char buf[4096];
142+ struct iovec iov = { buf, sizeof (buf) };
143+ struct in6ailist
144+ {
145+ struct in6addrinfo info;
146+ struct in6ailist *next;
147+ } *in6ailist = NULL;
148+ size_t in6ailistlen = 0;
149+
150+ do
151+ {
152+ struct msghdr msg =
153+ {
154+ (void *) &nladdr, sizeof (nladdr),
155+ &iov, 1,
156+ NULL, 0,
157+ 0
158+ };
159+
160+ ssize_t read_len = TEMP_FAILURE_RETRY (__recvmsg (fd, &msg, 0));
161+ if (read_len < 0)
162+ return -1;
163+
164+ if (msg.msg_flags & MSG_TRUNC)
165+ return -1;
166+
167+ struct nlmsghdr *nlmh;
168+ for (nlmh = (struct nlmsghdr *) buf;
169+ NLMSG_OK (nlmh, (size_t) read_len);
170+ nlmh = (struct nlmsghdr *) NLMSG_NEXT (nlmh, read_len))
171+ {
172+ if (nladdr.nl_pid != 0 || (pid_t) nlmh->nlmsg_pid != pid
173+ || nlmh->nlmsg_seq != req.nlh.nlmsg_seq)
174+ continue;
175+
176+ if (nlmh->nlmsg_type == RTM_NEWADDR)
177+ {
178+ struct ifaddrmsg *ifam = (struct ifaddrmsg *) NLMSG_DATA (nlmh);
179+
180+ switch (ifam->ifa_family)
181+ {
182+ case AF_INET:
183+ *seen_ipv4 = true;
184+ break;
185+ case AF_INET6:
186+ *seen_ipv6 = true;
187+
188+ if (ifam->ifa_flags & (IFA_F_DEPRECATED
189+ | IFA_F_TEMPORARY
190+ | IFA_F_HOMEADDRESS))
191+ {
192+ struct rtattr *rta = IFA_RTA (ifam);
193+ size_t len = (nlmh->nlmsg_len
194+ - NLMSG_LENGTH (sizeof (*ifam)));
195+ void *local = NULL;
196+ void *address = NULL;
197+ while (RTA_OK (rta, len))
198+ {
199+ switch (rta->rta_type)
200+ {
201+ case IFA_LOCAL:
202+ local = RTA_DATA (rta);
203+ break;
204+
205+ case IFA_ADDRESS:
206+ address = RTA_DATA (rta);
207+ break;
208+ }
209+
210+ rta = RTA_NEXT (rta, len);
211+ }
212+
213+ struct in6ailist *newp = alloca (sizeof (*newp));
214+ newp->info.flags = (((ifam->ifa_flags & IFA_F_DEPRECATED)
215+ ? in6ai_deprecated : 0)
216+ | ((ifam->ifa_flags
217+ & IFA_F_TEMPORARY)
218+ ? in6ai_temporary : 0)
219+ | ((ifam->ifa_flags
220+ & IFA_F_HOMEADDRESS)
221+ ? in6ai_homeaddress : 0));
222+ memcpy (newp->info.addr, address ?: local,
223+ sizeof (newp->info.addr));
224+ newp->next = in6ailist;
225+ in6ailist = newp;
226+ ++in6ailistlen;
227+ }
228+ break;
229+ default:
230+ /* Ignore. */
231+ break;
232+ }
233+ }
234+ else if (nlmh->nlmsg_type == NLMSG_DONE)
235+ /* We found the end, leave the loop. */
236+ done = true;
237+ }
238+ }
239+ while (! done);
240+
241+ close_not_cancel_no_status (fd);
242+
243+ if (in6ailist != NULL)
244+ {
245+ *in6ai = malloc (in6ailistlen * sizeof (**in6ai));
246+ if (*in6ai == NULL)
247+ return -1;
248+
249+ *in6ailen = in6ailistlen;
250+
251+ do
252+ {
253+ (*in6ai)[--in6ailistlen] = in6ailist->info;
254+ in6ailist = in6ailist->next;
255+ }
256+ while (in6ailist != NULL);
257+ }
258+
259+ return 0;
260+}
261+
262+
263+/* We don't know if we have NETLINK support compiled in in our
264+ Kernel. */
265+#if __ASSUME_NETLINK_SUPPORT == 0
266+/* Define in ifaddrs.h. */
267+extern int __no_netlink_support attribute_hidden;
268+#else
269+# define __no_netlink_support 0
270+#endif
271+
272+
273+void
274+attribute_hidden
275+__check_pf (bool *seen_ipv4, bool *seen_ipv6,
276+ struct in6addrinfo **in6ai, size_t *in6ailen)
277+{
278+ *in6ai = NULL;
279+ *in6ailen = 0;
280+
281+ if (! __no_netlink_support)
282+ {
283+ int fd = __socket (PF_NETLINK, SOCK_RAW, NETLINK_ROUTE);
284+
285+ struct sockaddr_nl nladdr;
286+ memset (&nladdr, '\0', sizeof (nladdr));
287+ nladdr.nl_family = AF_NETLINK;
288+
289+ socklen_t addr_len = sizeof (nladdr);
290+
291+ if (fd >= 0
292+ && __bind (fd, (struct sockaddr *) &nladdr, sizeof (nladdr)) == 0
293+ && __getsockname (fd, (struct sockaddr *) &nladdr, &addr_len) == 0
294+ && make_request (fd, nladdr.nl_pid, seen_ipv4, seen_ipv6,
295+ in6ai, in6ailen) == 0)
296+ /* It worked. */
297+ return;
298+
299+ if (fd >= 0)
300+ __close (fd);
301+
302+#if __ASSUME_NETLINK_SUPPORT == 0
303+ /* Remember that there is no netlink support. */
304+ __no_netlink_support = 1;
305+#else
306+ /* We cannot determine what interfaces are available. Be
307+ pessimistic. */
308+ *seen_ipv4 = true;
309+ *seen_ipv6 = true;
310+#endif
311+ }
312+
313+#if __ASSUME_NETLINK_SUPPORT == 0
314+ /* No netlink. Get the interface list via getifaddrs. */
315+ struct ifaddrs *ifa = NULL;
316+ if (getifaddrs (&ifa) != 0)
317+ {
318+ /* We cannot determine what interfaces are available. Be
319+ pessimistic. */
320+ *seen_ipv4 = true;
321+ *seen_ipv6 = true;
322+ return;
323+ }
324+
325+ struct ifaddrs *runp;
326+ for (runp = ifa; runp != NULL; runp = runp->ifa_next)
327+ if (runp->ifa_addr->sa_family == PF_INET)
328+ *seen_ipv4 = true;
329+ else if (runp->ifa_addr->sa_family == PF_INET6)
330+ *seen_ipv6 = true;
331+
332+ (void) freeifaddrs (ifa);
333+#endif
334+}
335Index: sysdeps/unix/sysv/linux/arm/eabi/check_pf.c
336===================================================================
337RCS file: sysdeps/unix/sysv/linux/arm/eabi/check_pf.c
338diff -N sysdeps/unix/sysv/linux/arm/eabi/check_pf.c
339--- /dev/null 1 Jan 1970 00:00:00 -0000
340+++ sysdeps/unix/sysv/linux/arm/eabi/check_pf.c 31 Oct 2006 17:29:58 -0000
341@@ -0,0 +1 @@
342+#include <sysdeps/unix/sysv/linux/check_pf.c>
343
diff --git a/meta/packages/glibc/glibc-2.10.1/ldd-unbash.patch b/meta/packages/glibc/glibc-2.10.1/ldd-unbash.patch
deleted file mode 100644
index 2fb8854b49..0000000000
--- a/meta/packages/glibc/glibc-2.10.1/ldd-unbash.patch
+++ /dev/null
@@ -1,11 +0,0 @@
1--- glibc-2.5/elf/ldd.bash.in.org 2006-04-30 16:06:20.000000000 +0000
2+++ glibc-2.5/elf/ldd.bash.in 2007-03-30 19:18:57.000000000 +0000
3@@ -110,7 +110,7 @@
4 # environments where the executed program might not have permissions
5 # to write to the console/tty. But only bash 3.x supports the pipefail
6 # option, and we don't bother to handle the case for older bash versions.
7-if set -o pipefail 2> /dev/null; then
8+if false; then
9 try_trace() {
10 eval $add_env '"$@"' | cat
11 }
diff --git a/meta/packages/glibc/glibc-2.10.1/ldsocache-varrun.patch b/meta/packages/glibc/glibc-2.10.1/ldsocache-varrun.patch
deleted file mode 100644
index 9994d4f879..0000000000
--- a/meta/packages/glibc/glibc-2.10.1/ldsocache-varrun.patch
+++ /dev/null
@@ -1,18 +0,0 @@
1This patch moves ld.so.cache from /etc to /var/run. This is for devices
2where /etc is JFFS2 or CRAMFS but /var is a ramdisk.
3
4#
5# Patch managed by http://www.mn-logistik.de/unsupported/pxa250/patcher
6#
7
8--- libc/sysdeps/generic/dl-cache.h~ldsocache-varrun
9+++ libc/sysdeps/generic/dl-cache.h
10@@ -29,7 +29,7 @@
11 #endif
12
13 #ifndef LD_SO_CACHE
14-# define LD_SO_CACHE SYSCONFDIR "/ld.so.cache"
15+# define LD_SO_CACHE "/var/run/ld.so.cache"
16 #endif
17
18 #ifndef add_system_dir
diff --git a/meta/packages/glibc/glibc-2.10.1/local-args6.diff b/meta/packages/glibc/glibc-2.10.1/local-args6.diff
deleted file mode 100644
index 28c957f243..0000000000
--- a/meta/packages/glibc/glibc-2.10.1/local-args6.diff
+++ /dev/null
@@ -1,12 +0,0 @@
1--- glibc-2.7/ports/sysdeps/unix/sysv/linux/arm/nptl/sysdep-cancel.h.orig
2+++ glibc-2.7/ports/sysdeps/unix/sysv/linux/arm/nptl/sysdep-cancel.h
3@@ -73,6 +73,9 @@
4 # define DOCARGS_5 DOCARGS_4
5 # define UNDOCARGS_5 UNDOCARGS_4
6
7+# define DOCARGS_6 DOCARGS_5
8+# define UNDOCARGS_6 UNDOCARGS_5
9+
10 # ifdef IS_IN_libpthread
11 # define CENABLE bl PLTJMP(__pthread_enable_asynccancel)
12 # define CDISABLE bl PLTJMP(__pthread_disable_asynccancel)
diff --git a/meta/packages/glibc/glibc-2.10.1/march-i686.patch b/meta/packages/glibc/glibc-2.10.1/march-i686.patch
deleted file mode 100644
index 04616032ad..0000000000
--- a/meta/packages/glibc/glibc-2.10.1/march-i686.patch
+++ /dev/null
@@ -1,38 +0,0 @@
12007-02-15 Khem Raj <kraj@xxxxxxxxxx>
2
3 * sysdeps/unix/sysv/linux/i386/sysdep.h: Re-define __i686.
4 * nptl/sysdeps/pthread/pt-initfini.c: Ditto.
5
6
7
8Index: sysdeps/unix/sysv/linux/i386/sysdep.h
9===================================================================
10--- sysdeps/unix/sysv/linux/i386/sysdep.h (revision 1469)
11+++ sysdeps/unix/sysv/linux/i386/sysdep.h (working copy)
12@@ -29,6 +29,10 @@
13 #include <dl-sysdep.h>
14 #include <tls.h>
15
16+#if defined __i686 && defined __ASSEMBLER__
17+#undef __i686
18+#define __i686 __i686
19+#endif
20
21 /* For Linux we can use the system call table in the header file
22 /usr/include/asm/unistd.h
23Index: nptl/sysdeps/pthread/pt-initfini.c
24===================================================================
25--- nptl/sysdeps/pthread/pt-initfini.c (revision 1469)
26+++ nptl/sysdeps/pthread/pt-initfini.c (working copy)
27@@ -45,6 +45,11 @@
28 /* Embed an #include to pull in the alignment and .end directives. */
29 asm ("\n#include \"defs.h\"");
30
31+asm ("\n#if defined __i686 && defined __ASSEMBLER__");
32+asm ("\n#undef __i686");
33+asm ("\n#define __i686 __i686");
34+asm ("\n#endif");
35+
36 /* The initial common code ends here. */
37 asm ("\n/*@HEADER_ENDS*/");
38
diff --git a/meta/packages/glibc/glibc-2.10.1/nptl-crosscompile.patch b/meta/packages/glibc/glibc-2.10.1/nptl-crosscompile.patch
deleted file mode 100644
index 18a46ad4f1..0000000000
--- a/meta/packages/glibc/glibc-2.10.1/nptl-crosscompile.patch
+++ /dev/null
@@ -1,26 +0,0 @@
1--- glibc-2.4/nptl/sysdeps/pthread/configure.in.ark 2006-03-12 00:41:40.000000000 +0100
2+++ glibc-2.4/nptl/sysdeps/pthread/configure.in 2006-03-12 00:44:08.000000000 +0100
3@@ -45,5 +45,6 @@
4 AC_MSG_ERROR([the compiler must support C cleanup handling])
5 fi
6 else
7- AC_MSG_ERROR(forced unwind support is required)
8+ AC_MSG_WARN([forced unwind support is required, can't be verified while crosscompiling])
9+ AC_DEFINE(HAVE_FORCED_UNWIND)
10 fi
11--- glibc-2.4/nptl/sysdeps/pthread/configure.ark 2006-03-12 00:42:47.000000000 +0100
12+++ glibc-2.4/nptl/sysdeps/pthread/configure 2006-03-12 00:44:08.000000000 +0100
13@@ -153,7 +153,10 @@
14 { (exit 1); exit 1; }; }
15 fi
16 else
17- { { echo "$as_me:$LINENO: error: forced unwind support is required" >&5
18-echo "$as_me: error: forced unwind support is required" >&2;}
19- { (exit 1); exit 1; }; }
20+ { echo "$as_me:$LINENO: WARNING: forced unwind support is required, can't be verified while crosscompiling" >&5
21+echo "$as_me: WARNING: forced unwind support is required, can't be verified while crosscompiling" >&2;}
22+ cat >>confdefs.h <<\_ACEOF
23+#define HAVE_FORCED_UNWIND 1
24+_ACEOF
25+
26 fi
diff --git a/meta/packages/glibc/glibc-2.10.1/nscd-init.patch b/meta/packages/glibc/glibc-2.10.1/nscd-init.patch
deleted file mode 100644
index 884609a5a3..0000000000
--- a/meta/packages/glibc/glibc-2.10.1/nscd-init.patch
+++ /dev/null
@@ -1,39 +0,0 @@
1--- nscd/nscd.init
2+++ nscd/nscd.init
3@@ -48,9 +48,8 @@
4
5 start () {
6 [ -d /var/run/nscd ] || mkdir /var/run/nscd
7- [ -d /var/db/nscd ] || mkdir /var/db/nscd
8 echo -n $"Starting $prog: "
9- daemon /usr/sbin/nscd
10+ /usr/sbin/nscd
11 RETVAL=$?
12 echo
13 [ $RETVAL -eq 0 ] && touch /var/lock/subsys/nscd
14@@ -67,12 +66,10 @@
15 # a non-privileged user
16 rm -f /var/run/nscd/nscd.pid
17 rm -f /var/run/nscd/socket
18- success $"$prog shutdown"
19- else
20- failure $"$prog shutdown"
21 fi
22- echo
23- return $RETVAL
24+ echo "Done."
25+ # If nscd did not run, return 0 according to LSB.
26+ return 0
27 }
28
29 restart() {
30@@ -104,7 +101,8 @@
31 ;;
32 force-reload | reload)
33 echo -n $"Reloading $prog: "
34- killproc /usr/sbin/nscd -HUP
35+ # Use killall, initscripts-1.0-r115 don't support -HUP yet.
36+ killall -HUP /usr/sbin/nscd
37 RETVAL=$?
38 echo
39 ;;
diff --git a/meta/packages/glibc/glibc-2.10.1/powerpc-sqrt-hack.diff b/meta/packages/glibc/glibc-2.10.1/powerpc-sqrt-hack.diff
deleted file mode 100644
index 1046efb2a1..0000000000
--- a/meta/packages/glibc/glibc-2.10.1/powerpc-sqrt-hack.diff
+++ /dev/null
@@ -1,25 +0,0 @@
1diff -Nurd ../glibc-initial-2.5-r4/glibc-2.5/sysdeps/powerpc/fpu/e_sqrt.c glibc-2.5/sysdeps/powerpc/fpu/e_sqrt.c
2--- ../glibc-initial-2.5-r4/glibc-2.5/sysdeps/powerpc/fpu/e_sqrt.c 2006-04-14 07:44:30.000000000 +0200
3+++ glibc-2.5/sysdeps/powerpc/fpu/e_sqrt.c 2006-12-08 12:53:32.202227000 +0100
4@@ -25,6 +25,9 @@
5 #include <sysdep.h>
6 #include <ldsodefs.h>
7
8+#define __CPU_HAS_FSQRT ((GLRO(dl_hwcap) & PPC_FEATURE_64) != 0)
9+
10+
11 static const double almost_half = 0.5000000000000001; /* 0.5 + 2^-53 */
12 static const ieee_float_shape_type a_nan = {.word = 0x7fc00000 };
13 static const ieee_float_shape_type a_inf = {.word = 0x7f800000 };
14diff -Nurd ../glibc-initial-2.5-r4/glibc-2.5/sysdeps/powerpc/fpu/e_sqrtf.c glibc-2.5/sysdeps/powerpc/fpu/e_sqrtf.c
15--- ../glibc-initial-2.5-r4/glibc-2.5/sysdeps/powerpc/fpu/e_sqrtf.c 2006-04-14 07:44:30.000000000 +0200
16+++ glibc-2.5/sysdeps/powerpc/fpu/e_sqrtf.c 2006-12-08 12:53:36.992227000 +0100
17@@ -25,6 +25,8 @@
18 #include <sysdep.h>
19 #include <ldsodefs.h>
20
21+#define __CPU_HAS_FSQRT ((GLRO(dl_hwcap) & PPC_FEATURE_64) != 0)
22+
23 static const float almost_half = 0.50000006; /* 0.5 + 2^-24 */
24 static const ieee_float_shape_type a_nan = {.word = 0x7fc00000 };
25 static const ieee_float_shape_type a_inf = {.word = 0x7f800000 };
diff --git a/meta/packages/glibc/glibc-2.10.1/rulesfix.patch b/meta/packages/glibc/glibc-2.10.1/rulesfix.patch
deleted file mode 100644
index 67bfc9467d..0000000000
--- a/meta/packages/glibc/glibc-2.10.1/rulesfix.patch
+++ /dev/null
@@ -1,13 +0,0 @@
1Index: glibc-2.9/Makerules
2===================================================================
3--- glibc-2.9.orig/Makerules 2009-09-14 16:39:21.000000000 +0100
4+++ glibc-2.9/Makerules 2009-09-14 16:39:50.000000000 +0100
5@@ -173,6 +173,8 @@
6 # it's used in sysd-rules, below.
7 $(common-objpfx)%.h $(common-objpfx)%.h.d: $(..)scripts/gen-as-const.awk \
8 %.sym $(common-before-compile)
9+ rm -f $(@:.h=.h.d)
10+ rm -f $(@:.h.d=.h)
11 $(AWK) -f $< $(filter %.sym,$^) \
12 | $(CC) -S -o $(@:.h.d=.h)T3 $(CFLAGS) $(CPPFLAGS) -x c - \
13 -MD -MP -MF $(@:.h=.h.d)T -MT '$(@:.h=.h.d) $(@:.h.d=.h)'
diff --git a/meta/packages/glibc/glibc-initial.inc b/meta/packages/glibc/glibc-initial.inc
deleted file mode 100644
index 8d864db91a..0000000000
--- a/meta/packages/glibc/glibc-initial.inc
+++ /dev/null
@@ -1,53 +0,0 @@
1SECTION = "libs"
2DEPENDS = "virtual/${TARGET_PREFIX}gcc-initial linux-libc-headers"
3PROVIDES = "virtual/${TARGET_PREFIX}libc-initial"
4FILESPATH = "${@base_set_filespath([ '${FILE_DIRNAME}/glibc-${PV}', '${FILE_DIRNAME}/glibc-2.4', '${FILE_DIRNAME}/glibc', '${FILE_DIRNAME}/files', '${FILE_DIRNAME}' ], d)}"
5
6PACKAGES = ""
7PACKAGES_DYNAMIC = ""
8
9do_configure () {
10 sed -ie 's,{ (exit 1); exit 1; }; },{ (exit 0); }; },g' ${S}/configure
11 chmod +x ${S}/configure
12 find ${S} -name "configure" | xargs touch
13 ${S}/configure --host=${TARGET_SYS} --build=${BUILD_SYS} \
14 --without-cvs --disable-sanity-checks \
15 --with-headers=${STAGING_DIR_TARGET}${includedir} \
16 --enable-hacker-mode
17 if grep -q GLIBC_2.3 ${S}/ChangeLog; then
18 # glibc-2.3.x passes cross options to $(CC) when generating errlist-compat.c, which fails without a real cross-compiler.
19 # Fortunately, we don't need errlist-compat.c, since we just need .h files,
20 # so work around this by creating a fake errlist-compat.c and satisfying its dependencies.
21 # Another workaround might be to tell configure to not use any cross options to $(CC).
22 # The real fix would be to get install-headers to not generate errlist-compat.c.
23 make sysdeps/gnu/errlist.c
24 mkdir -p stdio-common
25 touch stdio-common/errlist-compat.c
26 fi
27}
28
29do_compile () {
30 :
31}
32
33do_install () {
34 oe_runmake cross-compiling=yes install_root=${D} \
35 includedir='${includedir}' prefix='${prefix}' \
36 install-bootstrap-headers=yes install-headers
37
38 oe_runmake csu/subdir_lib
39 # Two headers -- stubs.h and features.h -- aren't installed by install-headers,
40 # so do them by hand. We can tolerate an empty stubs.h for the moment.
41 # See e.g. http://gcc.gnu.org/ml/gcc/2002-01/msg00900.html
42 mkdir -p ${D}${includedir}/gnu/
43 touch ${D}${includedir}/gnu/stubs.h
44 cp ${S}/include/features.h ${D}${includedir}/features.h
45
46 if [ -e ${B}/bits/stdio_lim.h ]; then
47 cp ${B}/bits/stdio_lim.h ${D}${includedir}/bits/
48 fi
49 mkdir -p ${D}${libdir}/
50 install -m 644 csu/crt[1in].o ${D}${libdir}
51 ${CC} -nostdlib -nostartfiles -shared -x c /dev/null \
52 -o ${D}${libdir}/libc.so
53}
diff --git a/meta/packages/glibc/glibc-initial_2.10.1.bb b/meta/packages/glibc/glibc-initial_2.10.1.bb
deleted file mode 100644
index d66297090f..0000000000
--- a/meta/packages/glibc/glibc-initial_2.10.1.bb
+++ /dev/null
@@ -1,6 +0,0 @@
1require glibc_${PV}.bb
2require glibc-initial.inc
3
4do_configure_prepend () {
5 unset CFLAGS
6}
diff --git a/meta/packages/glibc/glibc-package.inc b/meta/packages/glibc/glibc-package.inc
deleted file mode 100644
index 858bc522b5..0000000000
--- a/meta/packages/glibc/glibc-package.inc
+++ /dev/null
@@ -1,84 +0,0 @@
1#
2# For now, we will skip building of a gcc package if it is a uclibc one
3# and our build is not a uclibc one, and we skip a glibc one if our build
4# is a uclibc build.
5#
6# See the note in gcc/gcc_3.4.0.oe
7#
8
9python __anonymous () {
10 import bb, re
11 uc_os = (re.match('.*uclibc*', bb.data.getVar('TARGET_OS', d, 1)) != None)
12 if uc_os:
13 raise bb.parse.SkipPackage("incompatible with target %s" %
14 bb.data.getVar('TARGET_OS', d, 1))
15}
16
17
18# Binary locales are generated at build time if ENABLE_BINARY_LOCALE_GENERATION
19# is set. The idea is to avoid running localedef on the target (at first boot)
20# to decrease initial boot time and avoid localedef being killed by the OOM
21# killer which used to effectively break i18n on machines with < 128MB RAM.
22
23# default to disabled until qemu works for everyone
24ENABLE_BINARY_LOCALE_GENERATION ?= "0"
25
26# BINARY_LOCALE_ARCHES is a space separated list of regular expressions
27BINARY_LOCALE_ARCHES ?= "arm.*"
28
29
30inherit glibc-package
31
32def get_glibc_fpu_setting(bb, d):
33 if bb.data.getVar('TARGET_FPU', d, 1) in [ 'soft' ]:
34 return "--without-fp"
35 return ""
36
37EXTRA_OECONF += "${@get_glibc_fpu_setting(bb, d)}"
38EXTRA_OEMAKE += "rootsbindir=${base_sbindir}"
39
40OVERRIDES_append = ":${TARGET_ARCH}-${TARGET_OS}"
41
42do_install() {
43 oe_runmake install_root=${D} install
44 for r in ${rpcsvc}; do
45 h=`echo $r|sed -e's,\.x$,.h,'`
46 install -m 0644 ${S}/sunrpc/rpcsvc/$h ${D}/${includedir}/rpcsvc/
47 done
48 install -m 0644 ${WORKDIR}/etc/ld.so.conf ${D}/${sysconfdir}/
49 install -d ${D}${libdir}/locale
50 make -f ${WORKDIR}/generate-supported.mk IN="${S}/localedata/SUPPORTED" OUT="${WORKDIR}/SUPPORTED"
51 # get rid of some broken files...
52 for i in ${GLIBC_BROKEN_LOCALES}; do
53 grep -v $i ${WORKDIR}/SUPPORTED > ${WORKDIR}/SUPPORTED.tmp
54 mv ${WORKDIR}/SUPPORTED.tmp ${WORKDIR}/SUPPORTED
55 done
56 rm -f ${D}{sysconfdir}/rpc
57 rm -f ${D}${includedir}/scsi/sg.h
58 rm -f ${D}${includedir}/scsi/scsi_ioctl.h
59 rm -f ${D}${includedir}/scsi/scsi.h
60}
61
62
63python __anonymous () {
64 enabled = bb.data.getVar("ENABLE_BINARY_LOCALE_GENERATION", d, 1)
65
66 if enabled and int(enabled):
67 import re
68
69 target_arch = bb.data.getVar("TARGET_ARCH", d, 1)
70 binary_arches = bb.data.getVar("BINARY_LOCALE_ARCHES", d, 1) or ""
71
72 for regexp in binary_arches.split(" "):
73 r = re.compile(regexp)
74
75 if r.match(target_arch):
76 depends = bb.data.getVar("DEPENDS", d, 1)
77 depends = "%s qemu-native" % depends
78 bb.data.setVar("DEPENDS", depends, d)
79 bb.data.setVar("GLIBC_INTERNAL_USE_BINARY_LOCALE", "compile", d)
80 break
81}
82
83
84
diff --git a/meta/packages/glibc/glibc-stage.inc b/meta/packages/glibc/glibc-stage.inc
deleted file mode 100644
index e69de29bb2..0000000000
--- a/meta/packages/glibc/glibc-stage.inc
+++ /dev/null
diff --git a/meta/packages/glibc/glibc.inc b/meta/packages/glibc/glibc.inc
deleted file mode 100644
index ecaf593b22..0000000000
--- a/meta/packages/glibc/glibc.inc
+++ /dev/null
@@ -1,42 +0,0 @@
1DESCRIPTION = "GNU C Library"
2HOMEPAGE = "http://www.gnu.org/software/libc/libc.html"
3BUGTRACKER = "http://sources.redhat.com/bugzilla/"
4SECTION = "libs"
5PRIORITY = "required"
6LICENSE = "LGPLv2.1+ & GPLv2+"
7LIC_FILES_CHKSUM = "file://COPYING;md5=393a5ca445f6965873eca0259a17f833 \
8 file://elf/cache.c;beginline=1;endline=17;md5=926aac25497b1de7d630b4749005d208 \
9 file://COPYING.LIB;md5=bbb461211a33b134d42ed5ee802b37ff \
10 file://bits/types.h;beginline=1;endline=18;md5=267938e7c0538e76f734551ec6ea908d"
11# nptl needs unwind support in gcc, which can't be built without glibc.
12DEPENDS = "virtual/${TARGET_PREFIX}gcc-intermediate linux-libc-headers"
13RDEPENDS_${PN}-dev = "linux-libc-headers-dev"
14#this leads to circular deps, so lets not add it yet
15#RDEPENDS_ldd += " bash"
16#RDEPENDS += "${@['','libgcc']['nptl' in '${GLIBC_ADDONS}']}"
17PROVIDES = "virtual/libc virtual/${TARGET_PREFIX}libc-for-gcc"
18PROVIDES += "virtual/libintl virtual/libiconv"
19
20inherit autotools
21
22GLIBC_EXTRA_OECONF ?= ""
23INHIBIT_DEFAULT_DEPS = "1"
24
25do_rig_locales() {
26 # If indicated, only build a limited selection of locales
27 if [ "x${LIMIT_BUILT_LOCALES}" != "x" ]; then
28 INFILE="${S}/localedata/SUPPORTED"
29 OUTFILE="${S}/localedata/SUPPORTED.tmp"
30 head -n 3 $INFILE > $OUTFILE
31 for i in ${LIMIT_BUILT_LOCALES}; do
32 echo
33 grep $i $INFILE >> $OUTFILE
34 done
35 head --lines=-1 $OUTFILE > $INFILE
36 tail --lines=1 $OUTFILE | sed 's#\\##' >> $INFILE
37 fi
38}
39
40addtask rig_locales before do_compile after do_configure
41
42ARM_INSTRUCTION_SET = "arm"
diff --git a/meta/packages/glibc/glibc_2.10.1.bb b/meta/packages/glibc/glibc_2.10.1.bb
deleted file mode 100644
index 2a118a4af6..0000000000
--- a/meta/packages/glibc/glibc_2.10.1.bb
+++ /dev/null
@@ -1,161 +0,0 @@
1require glibc.inc
2
3ARM_INSTRUCTION_SET = "arm"
4
5PACKAGES_DYNAMIC = "libc6*"
6RPROVIDES_${PN}-dev = "libc6-dev virtual-libc-dev"
7
8PR = "r0"
9
10# the -isystem in bitbake.conf screws up glibc do_stage
11BUILD_CPPFLAGS = "-I${STAGING_INCDIR_NATIVE}"
12TARGET_CPPFLAGS = "-I${STAGING_DIR_TARGET}${includedir}"
13
14GLIBC_ADDONS ?= "ports,nptl,libidn"
15
16GLIBC_BROKEN_LOCALES = " _ER _ET so_ET yn_ER sid_ET tr_TR mn_MN gez_ET gez_ER bn_BD te_IN"
17
18FILESPATH = "${@base_set_filespath([ '${FILE_DIRNAME}/glibc-${PV}', '${FILE_DIRNAME}/glibc-2.4', '${FILE_DIRNAME}/glibc', '${FILE_DIRNAME}/files', '${FILE_DIRNAME}' ], d)}"
19
20#
21# For now, we will skip building of a gcc package if it is a uclibc one
22# and our build is not a uclibc one, and we skip a glibc one if our build
23# is a uclibc build.
24#
25# See the note in gcc/gcc_3.4.0.oe
26#
27
28python __anonymous () {
29 import bb, re
30 uc_os = (re.match('.*uclibc$', bb.data.getVar('TARGET_OS', d, 1)) != None)
31 if uc_os:
32 raise bb.parse.SkipPackage("incompatible with target %s" %
33 bb.data.getVar('TARGET_OS', d, 1))
34}
35
36RDEPENDS_${PN}-dev = "linux-libc-headers-dev"
37
38# file://noinfo.patch;patch=1
39# file://ldconfig.patch;patch=1;pnum=0
40# file://arm-machine-gmon.patch;patch=1;pnum=0 \
41# \
42# file://arm-ioperm.patch;patch=1;pnum=0 \
43# file://ldd.patch;patch=1;pnum=0 \
44SRC_URI = "ftp://ftp.gnu.org/pub/gnu/glibc/glibc-${PV}.tar.bz2 \
45 ftp://ftp.gnu.org/pub/gnu/glibc/glibc-ports-${PV}.tar.bz2 \
46 ftp://ftp.gnu.org/pub/gnu/glibc/glibc-libidn-${PV}.tar.bz2 \
47 file://nscd-init.patch;striplevel=0 \
48 file://arm-memcpy.patch \
49 file://arm-longlong.patch \
50 file://fhs-linux-paths.patch \
51 file://dl-cache-libcmp.patch \
52 file://ldsocache-varrun.patch \
53 file://nptl-crosscompile.patch \
54 file://glibc-check_pf.patch;striplevel=0 \
55 file://ldd-unbash.patch \
56 file://glibc-arm-IO-acquire-lock-fix.diff \
57 file://generic-bits_select.h \
58 file://generic-bits_types.h \
59 file://generic-bits_typesizes.h \
60 file://generic-bits_time.h \
61 file://etc/ld.so.conf \
62 file://generate-supported.mk \
63 file://march-i686.patch;striplevel=0 \
64 file://rulesfix.patch \
65 file://glibc-2.9-enable-binutils-2.2.patch"
66
67# Build fails on sh3 and sh4 without additional patches
68SRC_URI_append_sh3 = " file://no-z-defs.patch"
69SRC_URI_append_sh4 = " file://no-z-defs.patch"
70
71#powerpc patches to add support for soft-float
72SRC_URI_append_powerpc= " file://powerpc-sqrt-hack.diff"
73
74S = "${WORKDIR}/glibc-${PV}"
75B = "${WORKDIR}/build-${TARGET_SYS}"
76
77# We need this for nativesdk
78export libc_cv_slibdir = "${base_libdir}"
79
80EXTRA_OECONF = "--enable-kernel=${OLDEST_KERNEL} \
81 --without-cvs --disable-profile --disable-debug --without-gd \
82 --enable-clocale=gnu \
83 --enable-add-ons=${GLIBC_ADDONS} \
84 --with-headers=${STAGING_INCDIR} \
85 --without-selinux \
86 ${GLIBC_EXTRA_OECONF}"
87
88EXTRA_OECONF += "${@get_glibc_fpu_setting(bb, d)}"
89
90do_munge() {
91 # Integrate ports and libidn into tree
92 mv ${WORKDIR}/glibc-ports-${PV} ${S}/ports
93 mv ${WORKDIR}/glibc-libidn-${PV} ${S}/libidn
94
95 # Ports isn't really working... Fix it
96 # Some of this is rather dirty, but it seems to be the only
97 # quick way to get this cruft to compile
98 rm -rf ${S}/ports/sysdeps/unix/sysv/linux/arm/linuxthreads
99 ln -s nptl ${S}/ports/sysdeps/unix/sysv/linux/arm/linuxthreads
100 cp ${S}/nptl/sysdeps/pthread/bits/sigthread.h ${S}/ports/sysdeps/unix/sysv/linux/arm/bits/
101 cp ${S}/sysdeps/unix/sysv/linux/i386/bits/wchar.h ${S}/ports/sysdeps/unix/sysv/linux/arm/bits/
102 cp ${S}/sysdeps/wordsize-32/bits/wordsize.h ${S}/ports/sysdeps/unix/sysv/linux/arm/bits/
103 cp ${WORKDIR}/generic-bits_select.h ${S}/ports/sysdeps/unix/sysv/linux/arm/bits/select.h
104 cp ${WORKDIR}/generic-bits_types.h ${S}/ports/sysdeps/unix/sysv/linux/arm/bits/types.h
105 cp ${WORKDIR}/generic-bits_typesizes.h ${S}/ports/sysdeps/unix/sysv/linux/arm/bits/typesizes.h
106 cp ${WORKDIR}/generic-bits_time.h ${S}/ports/sysdeps/unix/sysv/linux/arm/bits/time.h
107 # Copy in generic stuff for not yet implemented headers
108 for i in ${S}/bits/*.h; do
109 F=`basename $i`
110 [ "$F" = "local_lim.h" ] && continue
111 [ "$F" = "errno.h" ] && continue
112 test -e ${S}/ports/sysdeps/unix/sysv/linux/arm/bits/$F || test -e ${S}/ports/sysdeps/arm/bits/$F || test -e ${S}/sysdeps/unix/sysv/linux/bits/$F || test -e ${S}/sysdeps/ieee754/bits/$F || cp $i ${S}/ports/sysdeps/unix/sysv/linux/arm/bits/
113 done
114 # This is harmful; we need to get the one from nptl/sysdeps/pthreads
115 rm -f ${S}/ports/sysdeps/unix/sysv/linux/arm/bits/libc-lock.h
116 # Obsoleted by sysdeps/arm/{fpu,eabi}/bits/fenv.h
117 rm -f ${S}/ports/sysdeps/unix/sysv/linux/arm/bits/fenv.h
118 # Obsoleted by sysdeps/gnu/bits/utmp.h
119 rm -f ${S}/ports/sysdeps/unix/sysv/linux/arm/bits/utmp.h
120}
121
122addtask munge before do_patch after do_unpack
123
124
125do_configure () {
126# /var/db was not included to FHS
127 sed -i s:/var/db/nscd:/var/run/nscd: ${S}/nscd/nscd.h
128# override this function to avoid the autoconf/automake/aclocal/autoheader
129# calls for now
130# don't pass CPPFLAGS into configure, since it upsets the kernel-headers
131# version check and doesn't really help with anything
132 if [ -z "`which rpcgen`" ]; then
133 echo "rpcgen not found. Install glibc-devel."
134 exit 1
135 fi
136 (cd ${S} && gnu-configize) || die "failure in running gnu-configize"
137 CPPFLAGS="" oe_runconf
138}
139
140rpcsvc = "bootparam_prot.x nlm_prot.x rstat.x \
141 yppasswd.x klm_prot.x rex.x sm_inter.x mount.x \
142 rusers.x spray.x nfs_prot.x rquota.x key_prot.x"
143
144do_compile () {
145 # -Wl,-rpath-link <staging>/lib in LDFLAGS can cause breakage if another glibc is in staging
146 unset LDFLAGS
147 base_do_compile
148 (
149 cd ${S}/sunrpc/rpcsvc
150 for r in ${rpcsvc}; do
151 h=`echo $r|sed -e's,\.x$,.h,'`
152 rpcgen -h $r -o $h || oewarn "unable to generate header for $r"
153 done
154 )
155}
156
157require glibc-stage.inc
158
159require glibc-package.inc
160
161BBCLASSEXTEND = "nativesdk"
diff --git a/meta/packages/glibc/ldconfig-native-2.5/32and64bit.patch b/meta/packages/glibc/ldconfig-native-2.5/32and64bit.patch
deleted file mode 100644
index 4f8d3a39ca..0000000000
--- a/meta/packages/glibc/ldconfig-native-2.5/32and64bit.patch
+++ /dev/null
@@ -1,289 +0,0 @@
1Index: ldconfig-native-2.5/readelflib.c
2===================================================================
3--- ldconfig-native-2.5.orig/readelflib.c 2009-05-19 09:40:17.000000000 +0100
4+++ ldconfig-native-2.5/readelflib.c 2009-05-19 09:56:18.000000000 +0100
5@@ -40,38 +40,190 @@
6
7 /* Returns 0 if everything is ok, != 0 in case of error. */
8 int
9-process_elf_file (const char *file_name, const char *lib, int *flag,
10+process_elf_file32 (const char *file_name, const char *lib, int *flag,
11 unsigned int *osversion, char **soname, void *file_contents,
12 size_t file_length)
13 {
14 int i;
15 unsigned int j;
16- ElfW(Addr) loadaddr;
17+ Elf32_Addr loadaddr;
18 unsigned int dynamic_addr;
19 size_t dynamic_size;
20 char *program_interpreter;
21
22- ElfW(Ehdr) *elf_header;
23- ElfW(Phdr) *elf_pheader, *segment;
24- ElfW(Dyn) *dynamic_segment, *dyn_entry;
25+ Elf32_Ehdr *elf_header;
26+ Elf32_Phdr *elf_pheader, *segment;
27+ Elf32_Dyn *dynamic_segment, *dyn_entry;
28 char *dynamic_strings;
29
30- elf_header = (ElfW(Ehdr) *) file_contents;
31+ elf_header = (Elf32_Ehdr *) file_contents;
32 *osversion = 0;
33
34- if (elf_header->e_ident [EI_CLASS] != ElfW (CLASS))
35+ if (elf_header->e_type != ET_DYN)
36+ {
37+ error (0, 0, _("%s is not a shared object file (Type: %d).\n"), file_name,
38+ elf_header->e_type);
39+ return 1;
40+ }
41+
42+ /* Get information from elf program header. */
43+ elf_pheader = (Elf32_Phdr *) (elf_header->e_phoff + file_contents);
44+ check_ptr (elf_pheader);
45+
46+ /* The library is an elf library, now search for soname and
47+ libc5/libc6. */
48+ *flag = FLAG_ELF;
49+
50+ loadaddr = -1;
51+ dynamic_addr = 0;
52+ dynamic_size = 0;
53+ program_interpreter = NULL;
54+ for (i = 0, segment = elf_pheader;
55+ i < elf_header->e_phnum; i++, segment++)
56 {
57- if (opt_verbose)
58+ check_ptr (segment);
59+
60+ switch (segment->p_type)
61 {
62- if (elf_header->e_ident [EI_CLASS] == ELFCLASS32)
63- error (0, 0, _("%s is a 32 bit ELF file.\n"), file_name);
64- else if (elf_header->e_ident [EI_CLASS] == ELFCLASS64)
65- error (0, 0, _("%s is a 64 bit ELF file.\n"), file_name);
66- else
67- error (0, 0, _("Unknown ELFCLASS in file %s.\n"), file_name);
68+ case PT_LOAD:
69+ if (loadaddr == (Elf32_Addr) -1)
70+ loadaddr = segment->p_vaddr - segment->p_offset;
71+ break;
72+
73+ case PT_DYNAMIC:
74+ if (dynamic_addr)
75+ error (0, 0, _("more than one dynamic segment\n"));
76+
77+ dynamic_addr = segment->p_offset;
78+ dynamic_size = segment->p_filesz;
79+ break;
80+
81+ case PT_INTERP:
82+ program_interpreter = (char *) (file_contents + segment->p_offset);
83+ check_ptr (program_interpreter);
84+
85+ /* Check if this is enough to classify the binary. */
86+ for (j = 0; j < sizeof (interpreters) / sizeof (interpreters [0]);
87+ ++j)
88+ if (strcmp (program_interpreter, interpreters[j].soname) == 0)
89+ {
90+ *flag = interpreters[j].flag;
91+ break;
92+ }
93+ break;
94+
95+ case PT_NOTE:
96+ if (!*osversion && segment->p_filesz == 32 && segment->p_align >= 4)
97+ {
98+ Elf32_Word *abi_note = (Elf32_Word *) (file_contents
99+ + segment->p_offset);
100+ if (abi_note [0] == 4 && abi_note [1] == 16 && abi_note [2] == 1
101+ && memcmp (abi_note + 3, "GNU", 4) == 0)
102+ *osversion = (abi_note [4] << 24) |
103+ ((abi_note [5] & 0xff) << 16) |
104+ ((abi_note [6] & 0xff) << 8) |
105+ (abi_note [7] & 0xff);
106+ }
107+ break;
108+
109+ default:
110+ break;
111 }
112- return 1;
113+
114 }
115+ if (loadaddr == (Elf32_Addr) -1)
116+ {
117+ /* Very strange. */
118+ loadaddr = 0;
119+ }
120+
121+ /* Now we can read the dynamic sections. */
122+ if (dynamic_size == 0)
123+ return 1;
124+
125+ dynamic_segment = (Elf32_Dyn *) (file_contents + dynamic_addr);
126+ check_ptr (dynamic_segment);
127+
128+ /* Find the string table. */
129+ dynamic_strings = NULL;
130+ for (dyn_entry = dynamic_segment; dyn_entry->d_tag != DT_NULL;
131+ ++dyn_entry)
132+ {
133+ check_ptr (dyn_entry);
134+ if (dyn_entry->d_tag == DT_STRTAB)
135+ {
136+ dynamic_strings = (char *) (file_contents + dyn_entry->d_un.d_val - loadaddr);
137+ check_ptr (dynamic_strings);
138+ break;
139+ }
140+ }
141+
142+ if (dynamic_strings == NULL)
143+ return 1;
144+
145+ /* Now read the DT_NEEDED and DT_SONAME entries. */
146+ for (dyn_entry = dynamic_segment; dyn_entry->d_tag != DT_NULL;
147+ ++dyn_entry)
148+ {
149+ if (dyn_entry->d_tag == DT_NEEDED || dyn_entry->d_tag == DT_SONAME)
150+ {
151+ char *name = dynamic_strings + dyn_entry->d_un.d_val;
152+ check_ptr (name);
153+
154+ if (dyn_entry->d_tag == DT_NEEDED)
155+ {
156+
157+ if (*flag == FLAG_ELF)
158+ {
159+ /* Check if this is enough to classify the binary. */
160+ for (j = 0;
161+ j < sizeof (known_libs) / sizeof (known_libs [0]);
162+ ++j)
163+ if (strcmp (name, known_libs [j].soname) == 0)
164+ {
165+ *flag = known_libs [j].flag;
166+ break;
167+ }
168+ }
169+ }
170+
171+ else if (dyn_entry->d_tag == DT_SONAME)
172+ *soname = xstrdup (name);
173+
174+ /* Do we have everything we need? */
175+ if (*soname && *flag != FLAG_ELF)
176+ return 0;
177+ }
178+ }
179+
180+ /* We reach this point only if the file doesn't contain a DT_SONAME
181+ or if we can't classify the library. If it doesn't have a
182+ soname, return the name of the library. */
183+ if (*soname == NULL)
184+ *soname = xstrdup (lib);
185+
186+ return 0;
187+}
188+
189+int
190+process_elf_file64 (const char *file_name, const char *lib, int *flag,
191+ unsigned int *osversion, char **soname, void *file_contents,
192+ size_t file_length)
193+{
194+ int i;
195+ unsigned int j;
196+ Elf64_Addr loadaddr;
197+ unsigned int dynamic_addr;
198+ size_t dynamic_size;
199+ char *program_interpreter;
200+
201+ Elf64_Ehdr *elf_header;
202+ Elf64_Phdr *elf_pheader, *segment;
203+ Elf64_Dyn *dynamic_segment, *dyn_entry;
204+ char *dynamic_strings;
205+
206+ elf_header = (Elf64_Ehdr *) file_contents;
207+ *osversion = 0;
208
209 if (elf_header->e_type != ET_DYN)
210 {
211@@ -81,7 +233,7 @@
212 }
213
214 /* Get information from elf program header. */
215- elf_pheader = (ElfW(Phdr) *) (elf_header->e_phoff + file_contents);
216+ elf_pheader = (Elf64_Phdr *) (elf_header->e_phoff + file_contents);
217 check_ptr (elf_pheader);
218
219 /* The library is an elf library, now search for soname and
220@@ -100,7 +252,7 @@
221 switch (segment->p_type)
222 {
223 case PT_LOAD:
224- if (loadaddr == (ElfW(Addr)) -1)
225+ if (loadaddr == (Elf64_Addr) -1)
226 loadaddr = segment->p_vaddr - segment->p_offset;
227 break;
228
229@@ -129,7 +281,7 @@
230 case PT_NOTE:
231 if (!*osversion && segment->p_filesz == 32 && segment->p_align >= 4)
232 {
233- ElfW(Word) *abi_note = (ElfW(Word) *) (file_contents
234+ Elf64_Word *abi_note = (Elf64_Word *) (file_contents
235 + segment->p_offset);
236 if (abi_note [0] == 4 && abi_note [1] == 16 && abi_note [2] == 1
237 && memcmp (abi_note + 3, "GNU", 4) == 0)
238@@ -145,7 +297,7 @@
239 }
240
241 }
242- if (loadaddr == (ElfW(Addr)) -1)
243+ if (loadaddr == (Elf64_Addr) -1)
244 {
245 /* Very strange. */
246 loadaddr = 0;
247@@ -155,7 +307,7 @@
248 if (dynamic_size == 0)
249 return 1;
250
251- dynamic_segment = (ElfW(Dyn) *) (file_contents + dynamic_addr);
252+ dynamic_segment = (Elf64_Dyn *) (file_contents + dynamic_addr);
253 check_ptr (dynamic_segment);
254
255 /* Find the string table. */
256@@ -218,3 +370,33 @@
257
258 return 0;
259 }
260+/* Returns 0 if everything is ok, != 0 in case of error. */
261+int
262+process_elf_file (const char *file_name, const char *lib, int *flag,
263+ unsigned int *osversion, char **soname, void *file_contents,
264+ size_t file_length)
265+{
266+ int i;
267+ unsigned int j;
268+ ElfW(Addr) loadaddr;
269+ unsigned int dynamic_addr;
270+ size_t dynamic_size;
271+ char *program_interpreter;
272+
273+ ElfW(Ehdr) *elf_header;
274+ ElfW(Phdr) *elf_pheader, *segment;
275+ ElfW(Dyn) *dynamic_segment, *dyn_entry;
276+ char *dynamic_strings;
277+
278+ elf_header = (ElfW(Ehdr) *) file_contents;
279+ *osversion = 0;
280+
281+ if (elf_header->e_ident [EI_CLASS] == ELFCLASS32)
282+ return process_elf_file32(file_name, lib,flag, osversion, soname, file_contents, file_length);
283+ else if (elf_header->e_ident [EI_CLASS] == ELFCLASS64)
284+ return process_elf_file64(file_name, lib,flag, osversion, soname, file_contents, file_length);
285+ error (0, 0, _("Unknown ELFCLASS in file %s.\n"), file_name);
286+ return 1;
287+}
288+
289+
diff --git a/meta/packages/glibc/ldconfig-native-2.5/ldconfig-native-2.5.tar.bz2 b/meta/packages/glibc/ldconfig-native-2.5/ldconfig-native-2.5.tar.bz2
deleted file mode 100644
index 693b35ced2..0000000000
--- a/meta/packages/glibc/ldconfig-native-2.5/ldconfig-native-2.5.tar.bz2
+++ /dev/null
Binary files differ
diff --git a/meta/packages/glibc/ldconfig-native-2.5/ldconfig.patch b/meta/packages/glibc/ldconfig-native-2.5/ldconfig.patch
deleted file mode 100644
index d143a075f5..0000000000
--- a/meta/packages/glibc/ldconfig-native-2.5/ldconfig.patch
+++ /dev/null
@@ -1,460 +0,0 @@
1---
2 cache.c | 11 +-
3 chroot_canon.c | 7 +
4 dl-cache.c | 235 ---------------------------------------------------------
5 dl-cache.h | 3
6 ldconfig.c | 27 ++++--
7 readlib.c | 7 +
8 xstrdup.c | 11 --
9 7 files changed, 45 insertions(+), 256 deletions(-)
10
11Index: 1/cache.c
12===================================================================
13--- 1.orig/cache.c 2007-11-23 17:05:44.000000000 +0000
14+++ 1/cache.c 2007-11-23 17:05:56.000000000 +0000
15@@ -15,6 +15,9 @@
16 along with this program; if not, write to the Free Software Foundation,
17 Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
18
19+#define _LARGEFILE64_SOURCE
20+#define _GNU_SOURCE
21+
22 #include <errno.h>
23 #include <error.h>
24 #include <dirent.h>
25@@ -29,8 +32,10 @@
26 #include <sys/stat.h>
27 #include <sys/types.h>
28
29-#include <ldconfig.h>
30-#include <dl-cache.h>
31+#include "ldconfig.h"
32+#include "dl-cache.h"
33+# define N_(msgid) msgid
34+#define _(msg) msg
35
36 struct cache_entry
37 {
38@@ -230,8 +235,6 @@ init_cache (void)
39 entries = NULL;
40 }
41
42-
43-
44 static
45 int compare (const struct cache_entry *e1, const struct cache_entry *e2)
46 {
47Index: 1/chroot_canon.c
48===================================================================
49--- 1.orig/chroot_canon.c 2007-11-23 17:05:44.000000000 +0000
50+++ 1/chroot_canon.c 2007-11-23 17:05:56.000000000 +0000
51@@ -16,6 +16,9 @@
52 along with this program; if not, write to the Free Software Foundation,
53 Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
54
55+#define _LARGEFILE64_SOURCE
56+#define _GNU_SOURCE
57+
58 #include <stdlib.h>
59 #include <string.h>
60 #include <unistd.h>
61@@ -26,7 +29,9 @@
62 #include <stddef.h>
63 #include <stdint.h>
64
65-#include <ldconfig.h>
66+#include "ldconfig.h"
67+
68+#define __set_errno(Val) errno = (Val)
69
70 #ifndef PATH_MAX
71 #define PATH_MAX 1024
72Index: 1/dl-cache.c
73===================================================================
74--- 1.orig/dl-cache.c 2007-11-23 17:05:44.000000000 +0000
75+++ 1/dl-cache.c 2007-11-23 17:05:56.000000000 +0000
76@@ -19,12 +19,12 @@
77
78 #include <assert.h>
79 #include <unistd.h>
80-#include <ldsodefs.h>
81+//#include "ldsodefs.h"
82 #include <sys/mman.h>
83 #include <dl-cache.h>
84 #include <dl-procinfo.h>
85
86-#include <stdio-common/_itoa.h>
87+//#include "_itoa.h"
88
89 #ifndef _DL_PLATFORMS_COUNT
90 # define _DL_PLATFORMS_COUNT 0
91@@ -38,103 +38,7 @@ static size_t cachesize;
92 /* 1 if cache_data + PTR points into the cache. */
93 #define _dl_cache_verify_ptr(ptr) (ptr < cache_data_size)
94
95-#define SEARCH_CACHE(cache) \
96-/* We use binary search since the table is sorted in the cache file. \
97- The first matching entry in the table is returned. \
98- It is important to use the same algorithm as used while generating \
99- the cache file. */ \
100-do \
101- { \
102- left = 0; \
103- right = cache->nlibs - 1; \
104- \
105- while (left <= right) \
106- { \
107- __typeof__ (cache->libs[0].key) key; \
108- \
109- middle = (left + right) / 2; \
110- \
111- key = cache->libs[middle].key; \
112- \
113- /* Make sure string table indices are not bogus before using \
114- them. */ \
115- if (! _dl_cache_verify_ptr (key)) \
116- { \
117- cmpres = 1; \
118- break; \
119- } \
120- \
121- /* Actually compare the entry with the key. */ \
122- cmpres = _dl_cache_libcmp (name, cache_data + key); \
123- if (__builtin_expect (cmpres == 0, 0)) \
124- { \
125- /* Found it. LEFT now marks the last entry for which we \
126- know the name is correct. */ \
127- left = middle; \
128- \
129- /* There might be entries with this name before the one we \
130- found. So we have to find the beginning. */ \
131- while (middle > 0) \
132- { \
133- __typeof__ (cache->libs[0].key) key; \
134- \
135- key = cache->libs[middle - 1].key; \
136- /* Make sure string table indices are not bogus before \
137- using them. */ \
138- if (! _dl_cache_verify_ptr (key) \
139- /* Actually compare the entry. */ \
140- || _dl_cache_libcmp (name, cache_data + key) != 0) \
141- break; \
142- --middle; \
143- } \
144- \
145- do \
146- { \
147- int flags; \
148- __typeof__ (cache->libs[0]) *lib = &cache->libs[middle]; \
149- \
150- /* Only perform the name test if necessary. */ \
151- if (middle > left \
152- /* We haven't seen this string so far. Test whether the \
153- index is ok and whether the name matches. Otherwise \
154- we are done. */ \
155- && (! _dl_cache_verify_ptr (lib->key) \
156- || (_dl_cache_libcmp (name, cache_data + lib->key) \
157- != 0))) \
158- break; \
159- \
160- flags = lib->flags; \
161- if (_dl_cache_check_flags (flags) \
162- && _dl_cache_verify_ptr (lib->value)) \
163- { \
164- if (best == NULL || flags == GLRO(dl_correct_cache_id)) \
165- { \
166- HWCAP_CHECK; \
167- best = cache_data + lib->value; \
168- \
169- if (flags == GLRO(dl_correct_cache_id)) \
170- /* We've found an exact match for the shared \
171- object and no general `ELF' release. Stop \
172- searching. */ \
173- break; \
174- } \
175- } \
176- } \
177- while (++middle <= right); \
178- break; \
179- } \
180- \
181- if (cmpres < 0) \
182- left = middle + 1; \
183- else \
184- right = middle - 1; \
185- } \
186- } \
187-while (0)
188-
189-
190 int
191-internal_function
192 _dl_cache_libcmp (const char *p1, const char *p2)
193 {
194 while (*p1 != '\0')
195@@ -173,139 +77,4 @@ _dl_cache_libcmp (const char *p1, const
196 }
197
198
199-/* Look up NAME in ld.so.cache and return the file name stored there,
200- or null if none is found. */
201
202-const char *
203-internal_function
204-_dl_load_cache_lookup (const char *name)
205-{
206- int left, right, middle;
207- int cmpres;
208- const char *cache_data;
209- uint32_t cache_data_size;
210- const char *best;
211-
212- /* Print a message if the loading of libs is traced. */
213- if (__builtin_expect (GLRO(dl_debug_mask) & DL_DEBUG_LIBS, 0))
214- _dl_debug_printf (" search cache=%s\n", LD_SO_CACHE);
215-
216- if (cache == NULL)
217- {
218- /* Read the contents of the file. */
219- void *file = _dl_sysdep_read_whole_file (LD_SO_CACHE, &cachesize,
220- PROT_READ);
221-
222- /* We can handle three different cache file formats here:
223- - the old libc5/glibc2.0/2.1 format
224- - the old format with the new format in it
225- - only the new format
226- The following checks if the cache contains any of these formats. */
227- if (file != MAP_FAILED && cachesize > sizeof *cache
228- && memcmp (file, CACHEMAGIC, sizeof CACHEMAGIC - 1) == 0)
229- {
230- size_t offset;
231- /* Looks ok. */
232- cache = file;
233-
234- /* Check for new version. */
235- offset = ALIGN_CACHE (sizeof (struct cache_file)
236- + cache->nlibs * sizeof (struct file_entry));
237-
238- cache_new = (struct cache_file_new *) ((void *) cache + offset);
239- if (cachesize < (offset + sizeof (struct cache_file_new))
240- || memcmp (cache_new->magic, CACHEMAGIC_VERSION_NEW,
241- sizeof CACHEMAGIC_VERSION_NEW - 1) != 0)
242- cache_new = (void *) -1;
243- }
244- else if (file != MAP_FAILED && cachesize > sizeof *cache_new
245- && memcmp (file, CACHEMAGIC_VERSION_NEW,
246- sizeof CACHEMAGIC_VERSION_NEW - 1) == 0)
247- {
248- cache_new = file;
249- cache = file;
250- }
251- else
252- {
253- if (file != MAP_FAILED)
254- __munmap (file, cachesize);
255- cache = (void *) -1;
256- }
257-
258- assert (cache != NULL);
259- }
260-
261- if (cache == (void *) -1)
262- /* Previously looked for the cache file and didn't find it. */
263- return NULL;
264-
265- best = NULL;
266-
267- if (cache_new != (void *) -1)
268- {
269- uint64_t platform;
270-
271- /* This is where the strings start. */
272- cache_data = (const char *) cache_new;
273-
274- /* Now we can compute how large the string table is. */
275- cache_data_size = (const char *) cache + cachesize - cache_data;
276-
277- platform = _dl_string_platform (GLRO(dl_platform));
278- if (platform != (uint64_t) -1)
279- platform = 1ULL << platform;
280-
281- /* Only accept hwcap if it's for the right platform. */
282-#ifdef USE_TLS
283-# define _DL_HWCAP_TLS_MASK (1LL << 63)
284-#else
285-# define _DL_HWCAP_TLS_MASK 0
286-#endif
287-#define HWCAP_CHECK \
288- if (GLRO(dl_osversion) && lib->osversion > GLRO(dl_osversion)) \
289- continue; \
290- if (_DL_PLATFORMS_COUNT \
291- && (lib->hwcap & _DL_HWCAP_PLATFORM) != 0 \
292- && (lib->hwcap & _DL_HWCAP_PLATFORM) != platform) \
293- continue; \
294- if (lib->hwcap \
295- & ~(GLRO(dl_hwcap) | _DL_HWCAP_PLATFORM | _DL_HWCAP_TLS_MASK)) \
296- continue
297- SEARCH_CACHE (cache_new);
298- }
299- else
300- {
301- /* This is where the strings start. */
302- cache_data = (const char *) &cache->libs[cache->nlibs];
303-
304- /* Now we can compute how large the string table is. */
305- cache_data_size = (const char *) cache + cachesize - cache_data;
306-
307-#undef HWCAP_CHECK
308-#define HWCAP_CHECK do {} while (0)
309- SEARCH_CACHE (cache);
310- }
311-
312- /* Print our result if wanted. */
313- if (__builtin_expect (GLRO(dl_debug_mask) & DL_DEBUG_LIBS, 0)
314- && best != NULL)
315- _dl_debug_printf (" trying file=%s\n", best);
316-
317- return best;
318-}
319-
320-#ifndef MAP_COPY
321-/* If the system does not support MAP_COPY we cannot leave the file open
322- all the time since this would create problems when the file is replaced.
323- Therefore we provide this function to close the file and open it again
324- once needed. */
325-void
326-_dl_unload_cache (void)
327-{
328- if (cache != NULL && cache != (struct cache_file *) -1)
329- {
330- __munmap (cache, cachesize);
331- cache = NULL;
332- }
333-}
334-#endif
335Index: 1/dl-cache.h
336===================================================================
337--- 1.orig/dl-cache.h 2007-11-23 17:05:44.000000000 +0000
338+++ 1/dl-cache.h 2007-11-23 17:05:56.000000000 +0000
339@@ -101,5 +101,4 @@ struct cache_file_new
340 (((addr) + __alignof__ (struct cache_file_new) -1) \
341 & (~(__alignof__ (struct cache_file_new) - 1)))
342
343-extern int _dl_cache_libcmp (const char *p1, const char *p2)
344- internal_function;
345+extern int _dl_cache_libcmp (const char *p1, const char *p2);
346Index: 1/ldconfig.c
347===================================================================
348--- 1.orig/ldconfig.c 2007-11-23 17:05:44.000000000 +0000
349+++ 1/ldconfig.c 2007-11-23 17:05:56.000000000 +0000
350@@ -15,6 +15,9 @@
351 along with this program; if not, write to the Free Software Foundation,
352 Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
353
354+#define _LARGEFILE64_SOURCE
355+#define _GNU_SOURCE
356+
357 #define PROCINFO_CLASS static
358 #include <alloca.h>
359 #include <argp.h>
360@@ -37,10 +40,20 @@
361 #include <glob.h>
362 #include <libgen.h>
363
364-#include <ldconfig.h>
365-#include <dl-cache.h>
366+#include "ldconfig.h"
367+#include "dl-cache.h"
368+
369+#include "dl-procinfo.h"
370+
371+#include "argp.h"
372+
373+
374+#define SYSCONFDIR "/etc"
375+#define LIBDIR "/usr/lib"
376+#define SLIBDIR "/lib"
377+# define N_(msgid) msgid
378+#define _(msg) msg
379
380-#include <dl-procinfo.h>
381
382 #ifdef _DL_FIRST_PLATFORM
383 # define _DL_FIRST_EXTRA (_DL_FIRST_PLATFORM + _DL_PLATFORMS_COUNT)
384@@ -53,7 +66,7 @@
385 #endif
386
387 /* Get libc version number. */
388-#include <version.h>
389+#include "version.h"
390
391 #define PACKAGE _libc_intl_domainname
392
393@@ -143,8 +156,8 @@ static const struct argp_option options[
394 { NULL, 0, NULL, 0, NULL, 0 }
395 };
396
397-#define PROCINFO_CLASS static
398-#include <dl-procinfo.c>
399+//#define PROCINFO_CLASS static
400+//#include <dl-procinfo.c>
401
402 /* Short description of program. */
403 static const char doc[] = N_("Configure Dynamic Linker Run Time Bindings.");
404@@ -281,7 +294,7 @@ parse_opt (int key, char *arg, struct ar
405 static void
406 print_version (FILE *stream, struct argp_state *state)
407 {
408- fprintf (stream, "ldconfig (GNU %s) %s\n", PACKAGE, VERSION);
409+ fprintf (stream, "ldconfig (Hacked Poky Version)\n");
410 fprintf (stream, gettext ("\
411 Copyright (C) %s Free Software Foundation, Inc.\n\
412 This is free software; see the source for copying conditions. There is NO\n\
413Index: 1/readlib.c
414===================================================================
415--- 1.orig/readlib.c 2007-11-23 17:05:44.000000000 +0000
416+++ 1/readlib.c 2007-11-23 17:05:56.000000000 +0000
417@@ -21,6 +21,9 @@
418 development version. Besides the simplification, it has also been
419 modified to read some other file formats. */
420
421+#define _LARGEFILE64_SOURCE
422+#define _GNU_SOURCE
423+
424 #include <a.out.h>
425 #include <elf.h>
426 #include <error.h>
427@@ -34,7 +37,9 @@
428 #include <sys/stat.h>
429 #include <gnu/lib-names.h>
430
431-#include <ldconfig.h>
432+#include "ldconfig.h"
433+
434+#define _(msg) msg
435
436 #define Elf32_CLASS ELFCLASS32
437 #define Elf64_CLASS ELFCLASS64
438Index: 1/xstrdup.c
439===================================================================
440--- 1.orig/xstrdup.c 2007-11-23 17:05:44.000000000 +0000
441+++ 1/xstrdup.c 2007-11-23 17:05:56.000000000 +0000
442@@ -15,15 +15,10 @@
443 along with this program; if not, write to the Free Software Foundation,
444 Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
445
446-#ifdef HAVE_CONFIG_H
447-# include <config.h>
448-#endif
449+#define _GNU_SOURCE
450+
451+#include <string.h>
452
453-#if defined STDC_HEADERS || defined HAVE_STRING_H || _LIBC
454-# include <string.h>
455-#else
456-# include <strings.h>
457-#endif
458 void *xmalloc (size_t n) __THROW;
459 char *xstrdup (char *string) __THROW;
460
diff --git a/meta/packages/glibc/ldconfig-native_2.5.bb b/meta/packages/glibc/ldconfig-native_2.5.bb
deleted file mode 100644
index d08787af6d..0000000000
--- a/meta/packages/glibc/ldconfig-native_2.5.bb
+++ /dev/null
@@ -1,20 +0,0 @@
1DESCRIPTION = "A standalone native ldconfig build"
2
3SRC_URI = "file://ldconfig-native-2.5.tar.bz2 \
4 file://ldconfig.patch;patch=1 \
5 file://32and64bit.patch;patch=1"
6
7PR = "r1"
8
9inherit native
10
11S = "${WORKDIR}/${PN}-${PV}"
12
13do_compile () {
14 $CC ldconfig.c -std=gnu99 chroot_canon.c xmalloc.c xstrdup.c cache.c readlib.c -I. dl-cache.c -o ldconfig
15}
16
17do_install () {
18 install -d ${D}/${bindir}/
19 install ldconfig ${D}/${bindir}/
20}