forked from pool/glibc
Accepting request 38894 from Base:System
Copy from Base:System/glibc based on submit request 38894 from user pbaudis OBS-URL: https://build.opensuse.org/request/show/38894 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/glibc?expand=0&rev=18
This commit is contained in:
parent
e85f837ddb
commit
cff896bf5c
@ -1,19 +0,0 @@
|
|||||||
Index: powerpc-cpu/sysdeps/powerpc/powerpc32/powerpc64/fpu/s_llrint.S
|
|
||||||
===================================================================
|
|
||||||
--- powerpc-cpu/sysdeps/powerpc/powerpc32/powerpc64/fpu/s_llrint.S.orig
|
|
||||||
+++ powerpc-cpu/sysdeps/powerpc/powerpc32/powerpc64/fpu/s_llrint.S
|
|
||||||
@@ -18,6 +18,7 @@
|
|
||||||
02110-1301 USA. */
|
|
||||||
|
|
||||||
#include <sysdep.h>
|
|
||||||
+#include <math_ldbl_opt.h>
|
|
||||||
|
|
||||||
/* long long int[r3, r4] __llrint (double x[fp1]) */
|
|
||||||
ENTRY (__llrint)
|
|
||||||
@@ -41,3 +42,6 @@ weak_alias (__llrint, llrint)
|
|
||||||
strong_alias (__llrint, __llrintl)
|
|
||||||
weak_alias (__llrint, llrintl)
|
|
||||||
#endif
|
|
||||||
+#if LONG_DOUBLE_COMPAT(libm, GLIBC_2_1)
|
|
||||||
+compat_symbol (libm, __llrint, llrintl, GLIBC_2_1)
|
|
||||||
+#endif
|
|
11
glibc-dl-x86-64-pc32.diff
Normal file
11
glibc-dl-x86-64-pc32.diff
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
--- sysdeps/x86_64/dl-machine.h~ 2010-03-01 18:51:13.914317000 +0100
|
||||||
|
+++ sysdeps/x86_64/dl-machine.h 2010-03-01 18:52:01.258038000 +0100
|
||||||
|
@@ -453,7 +453,7 @@
|
||||||
|
case R_X86_64_PC32:
|
||||||
|
value += reloc->r_addend - (Elf64_Addr) reloc_addr;
|
||||||
|
*(unsigned int *) reloc_addr = value;
|
||||||
|
- if (__builtin_expect (value != (unsigned int) value, 0))
|
||||||
|
+ if (__builtin_expect (value != (int) value, 0))
|
||||||
|
{
|
||||||
|
fmt = "\
|
||||||
|
%s: Symbol `%s' causes overflow in R_X86_64_PC32 relocation\n";
|
74
glibc-gai-private4.diff
Normal file
74
glibc-gai-private4.diff
Normal file
@ -0,0 +1,74 @@
|
|||||||
|
Pending acceptance upstream when this gets RFC'd:
|
||||||
|
http://sourceware.org/bugzilla/show_bug.cgi?id=11438
|
||||||
|
|
||||||
|
--- posix/gai.conf~ 2010-04-20 13:05:50.197813000 +0200
|
||||||
|
+++ posix/gai.conf 2010-04-20 13:08:46.472675000 +0200
|
||||||
|
@@ -66,3 +66,68 @@
|
||||||
|
#scopev4 ::ffff:172.16.0.0/108 5
|
||||||
|
#scopev4 ::ffff:192.168.0.0/112 5
|
||||||
|
#scopev4 ::ffff:0.0.0.0/96 14
|
||||||
|
+
|
||||||
|
+
|
||||||
|
+# Back in 2003, the sorting algorithm used by getaddrinfo() was defined in RFC
|
||||||
|
+# 3484. However, this document did not take into account (or foresee) the
|
||||||
|
+# ubiquity of IPv4 NAT on today's internet. This in turn causes some real
|
||||||
|
+# operational problems that's hindering the deployment of IPv6 for content
|
||||||
|
+# providers.
|
||||||
|
+#
|
||||||
|
+# The problem scenario is the following:
|
||||||
|
+#
|
||||||
|
+# An end user is located in a network numbered with private (RFC 1918) IPv4
|
||||||
|
+# addresses and transitional 6to4 (RFC 3056) IPv6 addresses. The network is
|
||||||
|
+# connected to the internet by a CPE/SOHO device implementing NAT for IPv4 and
|
||||||
|
+# anycasted 6to4 (RFC 3068) for IPv6.
|
||||||
|
+#
|
||||||
|
+# When the user attempts to connect to a server whose hostname has both IPv4
|
||||||
|
+# and IPv6 addresses published in DNS, an IPv6 connection using the
|
||||||
|
+# transitional 6to4 service will be preferred. This happens because the scope
|
||||||
|
+# comparsion fails for IPv4, the RFC 1918 addresses are assumed to have
|
||||||
|
+# site-local scope, which is smaller than the global scope of the server's IPv4
|
||||||
|
+# address. For IPv6, both the server's and the client's (6to4) address have
|
||||||
|
+# global scope.
|
||||||
|
+#
|
||||||
|
+# Unfortunately, the operational reality is that a transitional technique such
|
||||||
|
+# as 6to4 is much less reliable than IPv4. The relay routers might be located
|
||||||
|
+# far away from the optimal IPv4 path, and thus cause a significant latency
|
||||||
|
+# increase, or they might not even work optimally (they're usually operated by
|
||||||
|
+# voulenteering third parties on a best-effort basis), and finally some ISPs
|
||||||
|
+# simply filter away all proto-41 traffic. Transitional techniques are useful
|
||||||
|
+# to give end users with IPv4-only service a real shot at accessing IPv6-only
|
||||||
|
+# content, but it should never be preferred over IPv4 service when accessing
|
||||||
|
+# dual-stacked content.
|
||||||
|
+#
|
||||||
|
+# RFC 3484 even acknowledges this, by saying to "«avoid the use of transitional
|
||||||
|
+# addresses when native addresses are available"».
|
||||||
|
+#
|
||||||
|
+# An IETF draft document which describes the problem in a much more detailed
|
||||||
|
+# manner than I have is available here:
|
||||||
|
+#
|
||||||
|
+# http://tools.ietf.org/html/draft-denis-v6ops-nat-addrsel-00
|
||||||
|
+#
|
||||||
|
+# There's also an IETF draft that aims to revise RFC 3484 in order to fix this
|
||||||
|
+# problem (amongst others):
|
||||||
|
+#
|
||||||
|
+# http://tools.ietf.org/html/draft-arifumi-6man-rfc3484-revise-02
|
||||||
|
+#
|
||||||
|
+# Quoting from this document:
|
||||||
|
+#
|
||||||
|
+# > 2.7. To change private IPv4 address scope
|
||||||
|
+# >
|
||||||
|
+# > As detailed in Remi's draft [I-D.denis-v6ops-nat-addrsel], when a
|
||||||
|
+# > host is in NATed site, and has a private IPv4 address and
|
||||||
|
+# > transitional addresses like 6to4 and Teredo, the host chooses
|
||||||
|
+# > transitional IPv6 address to access most of the dual-stack servers.
|
||||||
|
+# >
|
||||||
|
+# > This is because private IPv4 address is defined to be site-local
|
||||||
|
+# > scope, and as in RFC 3484, the scope matching rules (Rule 2) set
|
||||||
|
+# > lower priority for private IPv4 address.
|
||||||
|
+# >
|
||||||
|
+# > By changing the address scope of private IPv4 address to global, this
|
||||||
|
+# > problem can be solved.
|
||||||
|
+
|
||||||
|
+scopev4 ::ffff:10.0.0.0/104 14
|
||||||
|
+scopev4 ::ffff:172.16.0.0/108 14
|
||||||
|
+scopev4 ::ffff:192.168.0.0/112 14
|
148
glibc-getnprocs.diff
Normal file
148
glibc-getnprocs.diff
Normal file
@ -0,0 +1,148 @@
|
|||||||
|
This bug is in reference to a bug introduced in glibc 2.11 but present in glibc
|
||||||
|
HEAD by the following patch set:
|
||||||
|
|
||||||
|
http://sourceware.org/git/?p=glibc.git;a=commitdiff;h=6a3d03ff58742430a252beac4a1917506512e319
|
||||||
|
|
||||||
|
The patch came from this bugzilla bug:
|
||||||
|
|
||||||
|
https://bugzilla.redhat.com/show_bug.cgi?id=494631
|
||||||
|
|
||||||
|
Which simply proposed the first part:
|
||||||
|
|
||||||
|
+ nl = memchr (*cp, '\n', *re - *cp);
|
||||||
|
+ while (nl == NULL && *re == buffer_end)
|
||||||
|
+ {
|
||||||
|
+ /* Truncate too long lines. */
|
||||||
|
+ *re = buffer + 3 * (buffer_end - buffer) / 4;
|
||||||
|
+ n = read_not_cancel (fd, *re, buffer_end - *re);
|
||||||
|
+ if (n < 0)
|
||||||
|
+ return NULL;
|
||||||
|
+
|
||||||
|
+ nl = memchr (*re, '\n', n);
|
||||||
|
+ **re = '\n';
|
||||||
|
+ *re += n;
|
||||||
|
+ }
|
||||||
|
}
|
||||||
|
+ else
|
||||||
|
+ nl = memchr (*cp, '\n', *re - *cp);
|
||||||
|
|
||||||
|
This was checked in with a second part:
|
||||||
|
|
||||||
|
else if (nl + 5 >= *re)
|
||||||
|
{
|
||||||
|
memmove (buffer, nl, *re - nl);
|
||||||
|
*re = buffer + (*re - nl);
|
||||||
|
nl = *cp = buffer;
|
||||||
|
|
||||||
|
ssize_t n = read_not_cancel (fd, *re, buffer_end - *re);
|
||||||
|
if (n < 0)
|
||||||
|
return NULL;
|
||||||
|
|
||||||
|
*re += n;
|
||||||
|
}
|
||||||
|
|
||||||
|
Which is meant to determine whether there's enough room at the end of the
|
||||||
|
buffer to hold "cpu*\n".
|
||||||
|
|
||||||
|
else if (nl + 5 >= *re)
|
||||||
|
{
|
||||||
|
memmove (buffer, nl, *re - nl);
|
||||||
|
*re = buffer + (*re - nl);
|
||||||
|
nl = *cp = buffer;
|
||||||
|
|
||||||
|
ssize_t n = read_not_cancel (fd, *re, buffer_end - *re);
|
||||||
|
if (n < 0)
|
||||||
|
return NULL;
|
||||||
|
|
||||||
|
*re += n;
|
||||||
|
}
|
||||||
|
|
||||||
|
*cp = nl + 1;
|
||||||
|
|
||||||
|
This second block is erroneous (and redundant). If there's not enough room to
|
||||||
|
complete a cpu[:digit:] line it'll try to move what's partially in the end of
|
||||||
|
the buffer to the front (preserving that portion) and then read in a bunch
|
||||||
|
more, assuming that a \n is in the next read.
|
||||||
|
|
||||||
|
But it actually ends up overwriting the current line with the contents of the
|
||||||
|
second line.
|
||||||
|
|
||||||
|
Consider the following line
|
||||||
|
|
||||||
|
| C | P | U | 1 | \n | C | P | U | 2 | \n | C | P | U | 3 | F | O | O | B | A |
|
||||||
|
R | F | O | O | B |
|
||||||
|
A | R | \n | ...
|
||||||
|
|
||||||
|
where sizeof(buffer) == 12.
|
||||||
|
|
||||||
|
The first time through 'buffer' is filled as follows:
|
||||||
|
|
||||||
|
| C | P | U | 1 | \n | C | P | U | 2 | \n | C | P |
|
||||||
|
|
||||||
|
and 'cpu1' is the line that is returned. The second time through 'cpu2' is the
|
||||||
|
line that is supposed to be returned but this problematic branch is hit and the
|
||||||
|
last C P is copied to the front of the buffer over top of C P U 2. Following
|
||||||
|
this U 3 F O O B A R F O is read into the rest of 'buffer':
|
||||||
|
|
||||||
|
| C | P ||| U | 3 | F | O | O | B | A | R | F | O |
|
||||||
|
|
||||||
|
This throws off the whole incrementing calculation.
|
||||||
|
|
||||||
|
This second else block isn't necessary. Jakub's first part covers the scenario
|
||||||
|
shown in the example above quite well:
|
||||||
|
|
||||||
|
The following test case:
|
||||||
|
|
||||||
|
#include<stdio.h>
|
||||||
|
#include<sys/sysinfo.h>
|
||||||
|
int main()
|
||||||
|
{
|
||||||
|
int lcpus=get_nprocs();
|
||||||
|
printf("logical cpus = %d\n",lcpus);
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
Can be run against the attached /proc/stat file which is known to reproduce the
|
||||||
|
problem:
|
||||||
|
|
||||||
|
This stat file can be used with the testcase by bind mounting it over
|
||||||
|
/proc/stat:
|
||||||
|
cp stat /dev/shm/stat
|
||||||
|
mount --bind /dev/shm/stat /proc/stat
|
||||||
|
|
||||||
|
When run this should show:
|
||||||
|
|
||||||
|
logical cpus = 1024
|
||||||
|
|
||||||
|
since cpu1024 is high cpu number. But it shows something like:
|
||||||
|
|
||||||
|
logical cpus = 137
|
||||||
|
|
||||||
|
Also attached is a patch which removes the erroneous else block.
|
||||||
|
|
||||||
|
When re-run against with this patch it reports the correct number of cpus.
|
||||||
|
|
||||||
|
Thanks to Milton Miller for describing this problem.
|
||||||
|
|
||||||
|
|
||||||
|
--- glibc-2.11.1/sysdeps/unix/sysv/linux/getsysstats.c 2010-01-18 11:01:41.000000000 -0600
|
||||||
|
+++ glibc-2.11.1-new/sysdeps/unix/sysv/linux/getsysstats.c 2010-03-23 08:00:26.000000000 -0500
|
||||||
|
@@ -117,18 +117,6 @@
|
||||||
|
if (nl == NULL)
|
||||||
|
nl = *re - 1;
|
||||||
|
}
|
||||||
|
- else if (nl + 5 >= *re)
|
||||||
|
- {
|
||||||
|
- memmove (buffer, nl, *re - nl);
|
||||||
|
- *re = buffer + (*re - nl);
|
||||||
|
- nl = *cp = buffer;
|
||||||
|
-
|
||||||
|
- ssize_t n = read_not_cancel (fd, *re, buffer_end - *re);
|
||||||
|
- if (n < 0)
|
||||||
|
- return NULL;
|
||||||
|
-
|
||||||
|
- *re += n;
|
||||||
|
- }
|
||||||
|
|
||||||
|
*cp = nl + 1;
|
||||||
|
assert (*cp <= *re);
|
39
glibc-memchr-ia64.diff
Normal file
39
glibc-memchr-ia64.diff
Normal file
@ -0,0 +1,39 @@
|
|||||||
|
2010-02-05 H.J. Lu <hongjiu.lu@intel.com>
|
||||||
|
|
||||||
|
PR libc/11230
|
||||||
|
* sysdeps/ia64/memchr.S: Don't read beyond the last byte
|
||||||
|
during recovery.
|
||||||
|
|
||||||
|
diff --git a/sysdeps/ia64/memchr.S b/sysdeps/ia64/memchr.S
|
||||||
|
index cdd71ca..56d8056 100644
|
||||||
|
--- a/sysdeps/ia64/memchr.S
|
||||||
|
+++ b/sysdeps/ia64/memchr.S
|
||||||
|
@@ -47,7 +47,7 @@
|
||||||
|
#define saved_lc r16
|
||||||
|
#define chr r17
|
||||||
|
#define len r18
|
||||||
|
-#define pos0 r20
|
||||||
|
+#define last r20
|
||||||
|
#define val r21
|
||||||
|
#define tmp r24
|
||||||
|
#define chrx8 r25
|
||||||
|
@@ -67,6 +67,7 @@ ENTRY(__memchr)
|
||||||
|
mov saved_pr = pr // save the predicates
|
||||||
|
.body
|
||||||
|
mov ret0 = str
|
||||||
|
+ add last = str, in2 // last byte
|
||||||
|
and tmp = 7, str // tmp = str % 8
|
||||||
|
cmp.ne p7, p0 = r0, r0 // clear p7
|
||||||
|
extr.u chr = in1, 0, 8 // chr = (unsigned char) in1
|
||||||
|
@@ -143,7 +144,10 @@ ENTRY(__memchr)
|
||||||
|
ld8 tmp = [ret0];; // load the first unchecked 8byte
|
||||||
|
xor aux[1] = tmp, chrx8;;
|
||||||
|
czx1.r poschr[1] = aux[1];;
|
||||||
|
- cmp.ne p7, p0 = 8, poschr[1]
|
||||||
|
+ cmp.ne p7, p0 = 8, poschr[1];;
|
||||||
|
+(p7) add ret0 = addr[MEMLAT+2], poschr[1];;
|
||||||
|
+(p7) cmp.geu p6, p7 = ret0, last // don't go over the last byte
|
||||||
|
+(p6) br.cond.spnt .notfound;;
|
||||||
|
(p7) br.cond.spnt .foundit;;
|
||||||
|
adds ret0 = 8, ret0 // load the next unchecked 8byte
|
||||||
|
br.sptk .l4;;
|
28
glibc-ppc64-vdso-time.diff
Normal file
28
glibc-ppc64-vdso-time.diff
Normal file
@ -0,0 +1,28 @@
|
|||||||
|
2010-03-04 Carlos Eduardo Seo <cseo@linux.vnet.ibm.com>
|
||||||
|
|
||||||
|
* sysdeps/unix/sysv/linux/powerpc/powerpc64/time.c: New file.
|
||||||
|
|
||||||
|
Index: src/sysdeps/unix/sysv/linux/powerpc/powerpc64/time.c
|
||||||
|
===================================================================
|
||||||
|
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||||
|
+++ src/sysdeps/unix/sysv/linux/powerpc/powerpc64/time.c 2010-03-04 20:02:23.000000000 -0300
|
||||||
|
@@ -0,0 +1,19 @@
|
||||||
|
+/* Copyright (C) 2010 Free Software Foundation, Inc.
|
||||||
|
+ This file is part of the GNU C Library.
|
||||||
|
+
|
||||||
|
+ The GNU C Library is free software; you can redistribute it and/or
|
||||||
|
+ modify it under the terms of the GNU Lesser General Public
|
||||||
|
+ License as published by the Free Software Foundation; either
|
||||||
|
+ version 2.1 of the License, or (at your option) any later version.
|
||||||
|
+
|
||||||
|
+ The GNU C Library is distributed in the hope that it will be useful,
|
||||||
|
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||||
|
+ Lesser General Public License for more details.
|
||||||
|
+
|
||||||
|
+ You should have received a copy of the GNU Lesser General Public
|
||||||
|
+ License along with the GNU C Library; if not, write to the Free
|
||||||
|
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
|
||||||
|
+ 02111-1307 USA. */
|
||||||
|
+
|
||||||
|
+#include <sysdeps/unix/time.c>
|
124
glibc-resolv-reload.diff
Normal file
124
glibc-resolv-reload.diff
Normal file
@ -0,0 +1,124 @@
|
|||||||
|
From libc-alpha-return-22754-pasky=ucw.cz@sourceware.org Tue Mar 16 00:47:00 2010
|
||||||
|
Return-Path: <libc-alpha-return-22754-pasky=ucw.cz@sourceware.org>
|
||||||
|
X-Original-To: pasky@pasky.or.cz
|
||||||
|
Delivered-To: pasky@pasky.or.cz
|
||||||
|
Received: from nikam.ms.mff.cuni.cz (nikam-dmz.ms.mff.cuni.cz [195.113.20.16])
|
||||||
|
by machine.or.cz (Postfix) with ESMTPS id C1B8586202A
|
||||||
|
for <pasky@pasky.or.cz>; Tue, 16 Mar 2010 00:47:00 +0100 (CET)
|
||||||
|
Received: by nikam.ms.mff.cuni.cz (Postfix)
|
||||||
|
id 9CDEC9AC7A4; Tue, 16 Mar 2010 00:47:00 +0100 (CET)
|
||||||
|
Delivered-To: pasky@kam.mff.cuni.cz
|
||||||
|
Received: from jabberwock.ucw.cz (jabberwock.ucw.cz [89.250.246.4])
|
||||||
|
by nikam.ms.mff.cuni.cz (Postfix) with ESMTP id 99F0E9AC77B
|
||||||
|
for <pasky@kam.mff.cuni.cz>; Tue, 16 Mar 2010 00:47:00 +0100 (CET)
|
||||||
|
Received: from sourceware.org (server1.sourceware.org [209.132.180.131])
|
||||||
|
by jabberwock.ucw.cz (Postfix) with SMTP id 14E1ACF040
|
||||||
|
for <pasky@ucw.cz>; Tue, 16 Mar 2010 00:46:59 +0100 (CET)
|
||||||
|
Received: (qmail 18956 invoked by alias); 15 Mar 2010 23:46:58 -0000
|
||||||
|
Delivered-To: moderator for libc-alpha@sourceware.org
|
||||||
|
Received: (qmail 15843 invoked by uid 22791); 15 Mar 2010 17:23:15 -0000
|
||||||
|
X-SWARE-Spam-Status: No, hits=-2.6 required=5.0
|
||||||
|
tests=BAYES_00
|
||||||
|
X-Spam-Check-By: sourceware.org
|
||||||
|
Message-ID: <4B9E6CFA.7020002@riot.org>
|
||||||
|
Date: Mon, 15 Mar 2010 18:23:06 +0100
|
||||||
|
From: Sebastian Kienzl <seb@riot.org>
|
||||||
|
User-Agent: Thunderbird 2.0.0.23 (Windows/20090812)
|
||||||
|
MIME-Version: 1.0
|
||||||
|
To: libc-alpha@sourceware.org
|
||||||
|
Subject: Reloading of /etc/resolv.conf
|
||||||
|
Content-Type: multipart/mixed;
|
||||||
|
boundary="------------060407080409020101000002"
|
||||||
|
Mailing-List: contact libc-alpha-help@sourceware.org; run by ezmlm
|
||||||
|
Precedence: bulk
|
||||||
|
List-Id: <libc-alpha.sourceware.org>
|
||||||
|
List-Unsubscribe: <mailto:libc-alpha-unsubscribe-pasky=ucw.cz@sourceware.org>
|
||||||
|
List-Subscribe: <mailto:libc-alpha-subscribe@sourceware.org>
|
||||||
|
List-Archive: <http://sourceware.org/ml/libc-alpha/>
|
||||||
|
List-Post: <mailto:libc-alpha@sourceware.org>
|
||||||
|
List-Help: <mailto:libc-alpha-help@sourceware.org>, <http://sourceware.org/ml/#faqs>
|
||||||
|
Sender: libc-alpha-owner@sourceware.org
|
||||||
|
Delivered-To: mailing list libc-alpha@sourceware.org
|
||||||
|
|
||||||
|
This is a multi-part message in MIME format.
|
||||||
|
--------------060407080409020101000002
|
||||||
|
Content-Type: text/plain; charset=ISO-8859-15; format=flowed
|
||||||
|
Content-Transfer-Encoding: 7bit
|
||||||
|
|
||||||
|
Hello!
|
||||||
|
|
||||||
|
There's a patch in the wild against the resolver which makes it reload
|
||||||
|
/etc/resolv.conf on change, see
|
||||||
|
http://sources.redhat.com/ml/libc-alpha/2004-09/msg00130.html
|
||||||
|
|
||||||
|
However, this patch actually doesn't work properly for multi-threaded
|
||||||
|
programs, as only one thread will notice the change and refresh its
|
||||||
|
resolver state. I've attached a proper patch. It's for 2.5 but it should
|
||||||
|
work with current versions, too.
|
||||||
|
|
||||||
|
Even though the patch may not be interesting for upstream, I decided to
|
||||||
|
let you know about this problem, since the mentioned patch seems to be
|
||||||
|
used by at least Debian and Ubuntu.
|
||||||
|
|
||||||
|
Regards,
|
||||||
|
Seb.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
--------------060407080409020101000002
|
||||||
|
Content-Type: text/plain;
|
||||||
|
name="glibc-2.5-resolvconf.patch"
|
||||||
|
Content-Transfer-Encoding: 7bit
|
||||||
|
Content-Disposition: inline;
|
||||||
|
filename="glibc-2.5-resolvconf.patch"
|
||||||
|
|
||||||
|
diff -ur resolv.orig/res_libc.c resolv/res_libc.c
|
||||||
|
--- resolv.orig/res_libc.c 2005-11-01 01:06:40.000000000 +0100
|
||||||
|
+++ resolv/res_libc.c 2010-03-15 14:13:18.000000000 +0100
|
||||||
|
@@ -22,7 +22,7 @@
|
||||||
|
#include <arpa/nameser.h>
|
||||||
|
#include <resolv.h>
|
||||||
|
#include <bits/libc-lock.h>
|
||||||
|
-
|
||||||
|
+#include <sys/stat.h>
|
||||||
|
|
||||||
|
/* The following bit is copied from res_data.c (where it is #ifdef'ed
|
||||||
|
out) since res_init() should go into libc.so but the rest of that
|
||||||
|
@@ -89,12 +89,34 @@
|
||||||
|
return (__res_vinit(&_res, 1));
|
||||||
|
}
|
||||||
|
|
||||||
|
+static time_t resconf_mtime;
|
||||||
|
+__libc_lock_define_initialized (static, resconf_mtime_lock);
|
||||||
|
+
|
||||||
|
+/* Check if the modification time of resolv.conf has changed.
|
||||||
|
+ If so, have all threads re-initialize their resolver states */
|
||||||
|
+static void
|
||||||
|
+__res_check_resconf (void)
|
||||||
|
+{
|
||||||
|
+ struct stat statbuf;
|
||||||
|
+ if (stat (_PATH_RESCONF, &statbuf) == 0) {
|
||||||
|
+ __libc_lock_lock (resconf_mtime_lock);
|
||||||
|
+ if (statbuf.st_mtime != resconf_mtime) {
|
||||||
|
+ resconf_mtime = statbuf.st_mtime;
|
||||||
|
+ atomicinclock (lock);
|
||||||
|
+ atomicinc (__res_initstamp);
|
||||||
|
+ atomicincunlock (lock);
|
||||||
|
+ }
|
||||||
|
+ __libc_lock_unlock (resconf_mtime_lock);
|
||||||
|
+ }
|
||||||
|
+}
|
||||||
|
+
|
||||||
|
/* Initialize resp if RES_INIT is not yet set or if res_init in some other
|
||||||
|
thread requested re-initializing. */
|
||||||
|
int
|
||||||
|
__res_maybe_init (res_state resp, int preinit)
|
||||||
|
{
|
||||||
|
if (resp->options & RES_INIT) {
|
||||||
|
+ __res_check_resconf ();
|
||||||
|
if (__res_initstamp != resp->_u._ext.initstamp) {
|
||||||
|
if (resp->nscount > 0)
|
||||||
|
__res_iclose (resp, true);
|
||||||
|
|
||||||
|
|
||||||
|
--------------060407080409020101000002--
|
11
glibc-sap-captialsharps.diff
Normal file
11
glibc-sap-captialsharps.diff
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
--- localedata/locales/i18n~ 2010-01-19 03:51:14.208960000 +0100
|
||||||
|
+++ localedata/locales/i18n 2010-01-19 03:51:24.444040000 +0100
|
||||||
|
@@ -928,7 +928,7 @@
|
||||||
|
(<U006D>,<U004D>);(<U006E>,<U004E>);(<U006F>,<U004F>);(<U0070>,<U0050>);/
|
||||||
|
(<U0071>,<U0051>);(<U0072>,<U0052>);(<U0073>,<U0053>);(<U0074>,<U0054>);/
|
||||||
|
(<U0075>,<U0055>);(<U0076>,<U0056>);(<U0077>,<U0057>);(<U0078>,<U0058>);/
|
||||||
|
- (<U0079>,<U0059>);(<U007A>,<U005A>);(<U00B5>,<U039C>);(<U00DF>,<U1E9E>);/
|
||||||
|
+ (<U0079>,<U0059>);(<U007A>,<U005A>);(<U00B5>,<U039C>);/
|
||||||
|
(<U00E0>,<U00C0>);/
|
||||||
|
(<U00E1>,<U00C1>);(<U00E2>,<U00C2>);(<U00E3>,<U00C3>);(<U00E4>,<U00C4>);/
|
||||||
|
(<U00E5>,<U00C5>);(<U00E6>,<U00C6>);(<U00E7>,<U00C7>);(<U00E8>,<U00C8>);/
|
12
glibc-statfs64-ia64.diff
Normal file
12
glibc-statfs64-ia64.diff
Normal file
@ -0,0 +1,12 @@
|
|||||||
|
--- sysdeps/unix/sysv/linux/statfs64.c~ 2010-01-27 02:47:32.884315000 +0100
|
||||||
|
+++ sysdeps/unix/sysv/linux/statfs64.c 2010-01-27 02:49:17.943657000 +0100
|
||||||
|
@@ -24,6 +24,9 @@
|
||||||
|
#include <sysdep.h>
|
||||||
|
#include <kernel-features.h>
|
||||||
|
|
||||||
|
+/* On IA64, ia32el does not provide wrapper for statfs64() for some reason.
|
||||||
|
+ Force the compatibility code to get compiled in. [bnc#534828] */
|
||||||
|
+#undef __ASSUME_STATFS64
|
||||||
|
|
||||||
|
# if __ASSUME_STATFS64 == 0
|
||||||
|
int __no_statfs64 attribute_hidden;
|
84
glibc-utf-s390.diff
Normal file
84
glibc-utf-s390.diff
Normal file
@ -0,0 +1,84 @@
|
|||||||
|
Hi,
|
||||||
|
|
||||||
|
unfortunately it turned out that the UTF-16 to UTF-32 and UTF-16 to
|
||||||
|
UTF-8 conversion instructions fail to recognize certain conditions if
|
||||||
|
the input stream is corrupted.
|
||||||
|
|
||||||
|
The attached patch disables these instructions and adjusts the
|
||||||
|
software implementation in order to take care of the error condition.
|
||||||
|
Hopefully we can re-enable them if a millicode fix becomes available.
|
||||||
|
|
||||||
|
Tested without regressions on s390x.
|
||||||
|
|
||||||
|
Please apply if you think it is ok.
|
||||||
|
|
||||||
|
Bye,
|
||||||
|
|
||||||
|
-Andreas-
|
||||||
|
|
||||||
|
|
||||||
|
2010-02-11 Andreas Krebbel <Andreas.Krebbel@de.ibm.com>
|
||||||
|
|
||||||
|
* sysdeps/s390/s390-64/utf8-utf16-z9.c: Disable hardware
|
||||||
|
instructions cu21 and cu24. Add well-formedness checking
|
||||||
|
parameter and adjust the software implementation.
|
||||||
|
* sysdeps/s390/s390-64/utf16-utf32-z9.c: Likewise.
|
||||||
|
|
||||||
|
|
||||||
|
Index: libc/sysdeps/s390/s390-64/utf8-utf16-z9.c
|
||||||
|
===================================================================
|
||||||
|
--- libc.orig/sysdeps/s390/s390-64/utf8-utf16-z9.c
|
||||||
|
+++ libc/sysdeps/s390/s390-64/utf8-utf16-z9.c
|
||||||
|
@@ -345,9 +345,12 @@ gconv_end (struct __gconv_step *data)
|
||||||
|
Operation. */
|
||||||
|
#define BODY \
|
||||||
|
{ \
|
||||||
|
- if (GLRO (dl_hwcap) & HWCAP_S390_ETF3EH) \
|
||||||
|
+ /* The hardware instruction currently fails to report an error for \
|
||||||
|
+ isolated low surrogates so we have to disable the instruction \
|
||||||
|
+ until this gets resolved. */ \
|
||||||
|
+ if (0) /* (GLRO (dl_hwcap) & HWCAP_S390_ETF3EH) */ \
|
||||||
|
{ \
|
||||||
|
- HARDWARE_CONVERT ("cu21 %0, %1"); \
|
||||||
|
+ HARDWARE_CONVERT ("cu21 %0, %1, 1"); \
|
||||||
|
if (inptr != inend) \
|
||||||
|
{ \
|
||||||
|
/* Check if the third byte is \
|
||||||
|
@@ -388,7 +391,7 @@ gconv_end (struct __gconv_step *data)
|
||||||
|
\
|
||||||
|
outptr += 2; \
|
||||||
|
} \
|
||||||
|
- else if (c >= 0x0800 && c <= 0xd7ff) \
|
||||||
|
+ else if ((c >= 0x0800 && c <= 0xd7ff) || c > 0xdfff) \
|
||||||
|
{ \
|
||||||
|
/* Three byte UTF-8 char. */ \
|
||||||
|
\
|
||||||
|
Index: libc/sysdeps/s390/s390-64/utf16-utf32-z9.c
|
||||||
|
===================================================================
|
||||||
|
--- libc.orig/sysdeps/s390/s390-64/utf16-utf32-z9.c
|
||||||
|
+++ libc/sysdeps/s390/s390-64/utf16-utf32-z9.c
|
||||||
|
@@ -203,7 +203,10 @@ gconv_end (struct __gconv_step *data)
|
||||||
|
swapping). */
|
||||||
|
#define BODY \
|
||||||
|
{ \
|
||||||
|
- if (GLRO (dl_hwcap) & HWCAP_S390_ETF3EH) \
|
||||||
|
+ /* The hardware instruction currently fails to report an error for \
|
||||||
|
+ isolated low surrogates so we have to disable the instruction \
|
||||||
|
+ until this gets resolved. */ \
|
||||||
|
+ if (0) /* (GLRO (dl_hwcap) & HWCAP_S390_ETF3EH) */ \
|
||||||
|
{ \
|
||||||
|
HARDWARE_CONVERT ("cu24 %0, %1, 1"); \
|
||||||
|
if (inptr != inend) \
|
||||||
|
@@ -229,6 +232,12 @@ gconv_end (struct __gconv_step *data)
|
||||||
|
} \
|
||||||
|
else \
|
||||||
|
{ \
|
||||||
|
+ /* An isolated low-surrogate was found. This has to be \
|
||||||
|
+ considered ill-formed. */ \
|
||||||
|
+ if (__builtin_expect (u1 >= 0xdc00, 0)) \
|
||||||
|
+ { \
|
||||||
|
+ STANDARD_FROM_LOOP_ERR_HANDLER (2); \
|
||||||
|
+ } \
|
||||||
|
/* It's a surrogate character. At least the first word says \
|
||||||
|
it is. */ \
|
||||||
|
if (__builtin_expect (inptr + 4 > inend, 0)) \
|
32
glibc-valloc-assert.diff
Normal file
32
glibc-valloc-assert.diff
Normal file
@ -0,0 +1,32 @@
|
|||||||
|
Index: glibc-2.11.1/malloc/malloc.c
|
||||||
|
===================================================================
|
||||||
|
--- glibc-2.11.1.orig/malloc/malloc.c 2010-01-18 18:01:41.000000000 +0100
|
||||||
|
+++ glibc-2.11.1/malloc/malloc.c 2010-02-23 13:47:59.000000000 +0100
|
||||||
|
@@ -3933,9 +3933,10 @@ public_vALLOc(size_t bytes)
|
||||||
|
if(!p) {
|
||||||
|
/* Maybe the failure is due to running out of mmapped areas. */
|
||||||
|
if(ar_ptr != &main_arena) {
|
||||||
|
- (void)mutex_lock(&main_arena.mutex);
|
||||||
|
- p = _int_memalign(&main_arena, pagesz, bytes);
|
||||||
|
- (void)mutex_unlock(&main_arena.mutex);
|
||||||
|
+ ar_ptr = &main_arena;
|
||||||
|
+ (void)mutex_lock(&ar_ptr->mutex);
|
||||||
|
+ p = _int_memalign(ar_ptr, pagesz, bytes);
|
||||||
|
+ (void)mutex_unlock(&ar_ptr->mutex);
|
||||||
|
} else {
|
||||||
|
#if USE_ARENAS
|
||||||
|
/* ... or sbrk() has failed and there is still a chance to mmap() */
|
||||||
|
@@ -3978,9 +3979,10 @@ public_pVALLOc(size_t bytes)
|
||||||
|
if(!p) {
|
||||||
|
/* Maybe the failure is due to running out of mmapped areas. */
|
||||||
|
if(ar_ptr != &main_arena) {
|
||||||
|
- (void)mutex_lock(&main_arena.mutex);
|
||||||
|
- p = _int_memalign(&main_arena, pagesz, rounded_bytes);
|
||||||
|
- (void)mutex_unlock(&main_arena.mutex);
|
||||||
|
+ ar_ptr = &main_arena;
|
||||||
|
+ (void)mutex_lock(&ar_ptr->mutex);
|
||||||
|
+ p = _int_memalign(ar_ptr, pagesz, rounded_bytes);
|
||||||
|
+ (void)mutex_unlock(&ar_ptr->mutex);
|
||||||
|
} else {
|
||||||
|
#if USE_ARENAS
|
||||||
|
/* ... or sbrk() has failed and there is still a chance to mmap() */
|
@ -1,8 +1,105 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Mon Apr 26 22:09:40 CEST 2010 - pbaudis@suse.cz
|
||||||
|
|
||||||
|
- Remove stale resolv.dynamic.diff patch file
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Thu Apr 22 08:30:50 CEST 2010 - meissner@suse.de
|
||||||
|
|
||||||
|
- for powerpc32 build a generic library and also a power4 library
|
||||||
|
to allow older 32bit powerpc to work. bnc#596271
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Tue Apr 20 13:15:19 CEST 2010 - pbaudis@suse.cz
|
||||||
|
|
||||||
|
- Consider private IPv4 addresses as global-scope in gai.conf [bnc#597616]
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Wed Mar 24 13:04:12 CET 2010 - pbaudis@suse.cz
|
||||||
|
|
||||||
|
- Fix get_nprocs() large CPU count handling [bnc#590665]
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Tue Mar 23 15:09:09 CET 2010 - pbaudis@suse.cz
|
||||||
|
|
||||||
|
- Fix interference of STB_GNU_UNIQUE and prelink [bnc#586979]
|
||||||
|
- Make time() use VDSO on PPC64 [bnc#590216]
|
||||||
|
- Make pthread_cond_timedway() use VDSO on PPC64 [bnc#590517]
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Thu Mar 18 14:45:34 CET 2010 - pbaudis@suse.cz
|
||||||
|
|
||||||
|
- Add PreReq for cat to glibc-locale [bnc#588997]
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Thu Mar 18 14:29:42 CET 2010 - pbaudis@suse.cz
|
||||||
|
|
||||||
|
- Fix /etc/resolv.conf change detection for multi-threaded applications
|
||||||
|
(by Sebastian Kienzl)
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Fri Mar 5 12:59:44 CET 2010 - pbaudis@suse.cz
|
||||||
|
|
||||||
|
- Fix spurious mapping from lowercase sharp s to uppercase sharp S
|
||||||
|
which is less standard and causes problems for ISO encodings [bnc#541773]
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Mon Mar 1 18:55:37 CET 2010 - pbaudis@suse.cz
|
||||||
|
|
||||||
|
- Fix spurious overflow messages on some R_X86_64_PC32 relocations,
|
||||||
|
patch by Richard Guenther [bnc#583019]
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Wed Feb 24 11:53:41 CET 2010 - pbaudis@suse.cz
|
||||||
|
|
||||||
|
- Fix assertion failures within valloc(), patch by Michael Matz
|
||||||
|
[bnc#581391]
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Wed Feb 17 12:02:24 CET 2010 - pbaudis@suse.cz
|
||||||
|
|
||||||
|
- S/390: Disable two UTF conversion instructions due to the hardware
|
||||||
|
mishandling some error conditions in the input stream [bnc#579871]
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Mon Feb 15 22:34:29 CET 2010 - pbaudis@suse.cz
|
||||||
|
|
||||||
|
- Further fix previous power5 fix
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Sun Feb 14 15:33:33 CET 2010 - rguenther@suse.de
|
Sun Feb 14 15:33:33 CET 2010 - rguenther@suse.de
|
||||||
|
|
||||||
- avoid spurious differences in nscd on rebuilds.
|
- avoid spurious differences in nscd on rebuilds.
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Thu Feb 11 21:36:32 CET 2010 - pbaudis@suse.cz
|
||||||
|
|
||||||
|
- Fix another upgrade problem on power5 and older - correctly remove
|
||||||
|
the old optimized libraries; found out by matz@suse.de [bnc#563978]
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Fri Feb 5 21:07:54 CET 2010 - pbaudis@suse.cz
|
||||||
|
|
||||||
|
- Final fix for memchr() overflow on IA64 provided by upstream
|
||||||
|
[bnc#567516]
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Thu Jan 28 17:11:59 CET 2010 - pbaudis@suse.cz
|
||||||
|
|
||||||
|
- Fix another memchr() overflow on IA64; another known one still
|
||||||
|
remains a mystery [bnc#567516]
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Wed Jan 27 02:49:46 CET 2010 - pbaudis@suse.cz
|
||||||
|
|
||||||
|
- Remove now-obsolete powerpc-cpu addon usage [bnc#572819]
|
||||||
|
- Fix statfs64() on IA64 in 32-bit mode ia32el [bnc#534828]
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Tue Jan 26 03:33:38 CET 2010 - pbaudis@suse.cz
|
||||||
|
|
||||||
|
- Fix upgrade from previous distributions on power5 and older [bnc#563978]
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Mon Jan 25 17:35:25 CET 2010 - meissner@suse.de
|
Mon Jan 25 17:35:25 CET 2010 - meissner@suse.de
|
||||||
|
|
||||||
|
98
glibc.spec
98
glibc.spec
@ -28,8 +28,15 @@ BuildRequires: libselinux-devel
|
|||||||
%define enable_stackguard_randomization 1
|
%define enable_stackguard_randomization 1
|
||||||
%ifarch ppc ppc64
|
%ifarch ppc ppc64
|
||||||
%define optimize_power 1
|
%define optimize_power 1
|
||||||
|
%ifarch ppc
|
||||||
|
%define powerpc_optimize_base power3
|
||||||
|
%define powerpc_optimize_tune power3
|
||||||
|
%define powerpc_optimize_cpu_power4 1
|
||||||
|
%else
|
||||||
%define powerpc_optimize_base power4
|
%define powerpc_optimize_base power4
|
||||||
%define powerpc_optimize_tune power5
|
%define powerpc_optimize_tune power5
|
||||||
|
%define powerpc_optimize_cpu_power4 0
|
||||||
|
%endif
|
||||||
# We are not building Power CPU specific optimizations for openSUSE.
|
# We are not building Power CPU specific optimizations for openSUSE.
|
||||||
%define powerpc_optimize_cpu_power6 0
|
%define powerpc_optimize_cpu_power6 0
|
||||||
%define powerpc_optimize_cpu_power7 0
|
%define powerpc_optimize_cpu_power7 0
|
||||||
@ -37,11 +44,12 @@ BuildRequires: libselinux-devel
|
|||||||
%else
|
%else
|
||||||
%define optimize_power 0
|
%define optimize_power 0
|
||||||
%define powerpc_optimize_base 0
|
%define powerpc_optimize_base 0
|
||||||
|
%define powerpc_optimize_cpu_power4 0
|
||||||
%define powerpc_optimize_cpu_power6 0
|
%define powerpc_optimize_cpu_power6 0
|
||||||
%define powerpc_optimize_cpu_power7 0
|
%define powerpc_optimize_cpu_power7 0
|
||||||
%define powerpc_optimize_cpu_cell 0
|
%define powerpc_optimize_cpu_cell 0
|
||||||
%endif # ppc, ppc64
|
%endif # ppc, ppc64
|
||||||
License: BSD3c(or similar) ; GPLv2+ ; LGPLv2.1+
|
License: GPLv2+
|
||||||
Summary: Standard Shared Libraries (from the GNU C Library)
|
Summary: Standard Shared Libraries (from the GNU C Library)
|
||||||
Group: System/Libraries
|
Group: System/Libraries
|
||||||
Obsoletes: ngpt <= 2.2.2 ngpt-devel <= 2.2.2
|
Obsoletes: ngpt <= 2.2.2 ngpt-devel <= 2.2.2
|
||||||
@ -56,7 +64,7 @@ Obsoletes: glibc-32bit
|
|||||||
Provides: rtld(GNU_HASH)
|
Provides: rtld(GNU_HASH)
|
||||||
AutoReqProv: on
|
AutoReqProv: on
|
||||||
Version: 2.11.1
|
Version: 2.11.1
|
||||||
Release: 2
|
Release: 3
|
||||||
Url: http://www.gnu.org/software/libc/libc.html
|
Url: http://www.gnu.org/software/libc/libc.html
|
||||||
PreReq: filesystem
|
PreReq: filesystem
|
||||||
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
||||||
@ -70,7 +78,6 @@ Source9: nscd.init
|
|||||||
Source10: bindresvport.blacklist
|
Source10: bindresvport.blacklist
|
||||||
Source11: ctype_b.c
|
Source11: ctype_b.c
|
||||||
Source12: glibc_post_upgrade.c
|
Source12: glibc_post_upgrade.c
|
||||||
Source14: powerpc-cpu.tar.bz2
|
|
||||||
Source15: glibc.rpmlintrc
|
Source15: glibc.rpmlintrc
|
||||||
Source16: baselibs.conf
|
Source16: baselibs.conf
|
||||||
%if %_target_cpu == "i686"
|
%if %_target_cpu == "i686"
|
||||||
@ -82,7 +89,7 @@ NoSource: 0
|
|||||||
Patch0: glibc-2.3-SuSE.diff
|
Patch0: glibc-2.3-SuSE.diff
|
||||||
Patch1: glibc-2.3.90-noversion.diff
|
Patch1: glibc-2.3.90-noversion.diff
|
||||||
Patch2: glibc-2.3.90-fnmatch.diff
|
Patch2: glibc-2.3.90-fnmatch.diff
|
||||||
Patch3: resolv.dynamic.diff
|
Patch3: glibc-resolv-reload.diff
|
||||||
Patch4: glibc-2.3.locales.diff.bz2
|
Patch4: glibc-2.3.locales.diff.bz2
|
||||||
Patch5: crypt_blowfish-1.0-suse.diff
|
Patch5: crypt_blowfish-1.0-suse.diff
|
||||||
Patch7: glibc-version.diff
|
Patch7: glibc-version.diff
|
||||||
@ -106,7 +113,6 @@ Patch24: glibc-2.3.3-nscd-db-path.diff
|
|||||||
Patch25: glibc-2.3.5-nscd-zeronegtimeout.diff
|
Patch25: glibc-2.3.5-nscd-zeronegtimeout.diff
|
||||||
Patch26: glibc-2.3.90-langpackdir.diff
|
Patch26: glibc-2.3.90-langpackdir.diff
|
||||||
Patch27: glibc-nptl-2.4-nofixsyscallnr.diff
|
Patch27: glibc-nptl-2.4-nofixsyscallnr.diff
|
||||||
Patch29: glibc-2.5-ppc-llrintl.diff
|
|
||||||
Patch30: glibc-2.6-configure.diff
|
Patch30: glibc-2.6-configure.diff
|
||||||
Patch31: glibc-2.2-sunrpc.diff
|
Patch31: glibc-2.2-sunrpc.diff
|
||||||
Patch32: glibc-2.8-getconf.diff
|
Patch32: glibc-2.8-getconf.diff
|
||||||
@ -125,6 +131,17 @@ Patch46: glibc-2.10.99-ia64-include.diff
|
|||||||
Patch47: libm-x86-64-exceptions.diff
|
Patch47: libm-x86-64-exceptions.diff
|
||||||
Patch48: glibc-uio-cell.diff
|
Patch48: glibc-uio-cell.diff
|
||||||
Patch50: glibc-nameserver-localhost.diff
|
Patch50: glibc-nameserver-localhost.diff
|
||||||
|
Patch54: glibc-statfs64-ia64.diff
|
||||||
|
Patch55: glibc-memchr-ia64.diff
|
||||||
|
Patch56: glibc-utf-s390.diff
|
||||||
|
Patch57: glibc-valloc-assert.diff
|
||||||
|
Patch58: glibc-dl-x86-64-pc32.diff
|
||||||
|
Patch59: glibc-sap-captialsharps.diff
|
||||||
|
Patch60: ld-prelink-unique.diff
|
||||||
|
Patch61: glibc-ppc64-vdso-time.diff
|
||||||
|
Patch62: nptl-ppc64-vdso-timedwait.diff
|
||||||
|
Patch63: glibc-getnprocs.diff
|
||||||
|
Patch64: glibc-gai-private4.diff
|
||||||
Patch500: ARM_glibc-2.10.1-local-eabi-wchar.diff
|
Patch500: ARM_glibc-2.10.1-local-eabi-wchar.diff
|
||||||
Patch501: ARM_glibc-2.10.1-local-hwcap-updates.diff
|
Patch501: ARM_glibc-2.10.1-local-hwcap-updates.diff
|
||||||
Patch502: ARM_glibc-2.10.1-local-lowlevellock.diff
|
Patch502: ARM_glibc-2.10.1-local-lowlevellock.diff
|
||||||
@ -184,6 +201,7 @@ License: GPLv2+ ; LGPLv2.1+
|
|||||||
Summary: Locale Data for Localized Programs
|
Summary: Locale Data for Localized Programs
|
||||||
Group: System/Libraries
|
Group: System/Libraries
|
||||||
Requires: glibc = %{version}
|
Requires: glibc = %{version}
|
||||||
|
PreReq: /bin/cat
|
||||||
AutoReqProv: on
|
AutoReqProv: on
|
||||||
# bug437293
|
# bug437293
|
||||||
%ifarch ppc64
|
%ifarch ppc64
|
||||||
@ -278,10 +296,10 @@ versions of your software.
|
|||||||
# add glibc-ports for arm
|
# add glibc-ports for arm
|
||||||
# this is CURRENTLY BROKEN; ARM-interested contributors need to provide
|
# this is CURRENTLY BROKEN; ARM-interested contributors need to provide
|
||||||
# new tested glibc-ports source
|
# new tested glibc-ports source
|
||||||
%setup -n glibc-%{version} -q -a 2 -a 3 -a 4 -a 14
|
%setup -n glibc-%{version} -q -a 2 -a 3 -a 4
|
||||||
%else
|
%else
|
||||||
# any other leave out ports
|
# any other leave out ports
|
||||||
%setup -n glibc-%{version} -q -a 3 -a 4 -a 14
|
%setup -n glibc-%{version} -q -a 3 -a 4
|
||||||
%endif
|
%endif
|
||||||
%patch0
|
%patch0
|
||||||
# libNoVersion part is only active on ix86
|
# libNoVersion part is only active on ix86
|
||||||
@ -320,7 +338,6 @@ touch -r nscd/s-stamp nscd/nscd_stat.c
|
|||||||
rm nscd/s-stamp
|
rm nscd/s-stamp
|
||||||
%patch26
|
%patch26
|
||||||
%patch27
|
%patch27
|
||||||
%patch29
|
|
||||||
%patch30
|
%patch30
|
||||||
%patch31
|
%patch31
|
||||||
%patch32
|
%patch32
|
||||||
@ -339,6 +356,17 @@ rm nscd/s-stamp
|
|||||||
%patch47
|
%patch47
|
||||||
%patch48 -p1
|
%patch48 -p1
|
||||||
%patch50 -p1
|
%patch50 -p1
|
||||||
|
%patch54
|
||||||
|
%patch55 -p1
|
||||||
|
%patch56 -p1
|
||||||
|
%patch57 -p1
|
||||||
|
%patch58
|
||||||
|
%patch59
|
||||||
|
%patch60 -p1
|
||||||
|
%patch61 -p1
|
||||||
|
%patch62 -p1
|
||||||
|
%patch63 -p1
|
||||||
|
%patch64
|
||||||
%ifarch %arm armv5tel armv7l
|
%ifarch %arm armv5tel armv7l
|
||||||
%patch500
|
%patch500
|
||||||
%patch501
|
%patch501
|
||||||
@ -364,6 +392,7 @@ rm nscd/s-stamp
|
|||||||
#
|
#
|
||||||
rm -fv sysdeps/powerpc/powerpc32/power4/hp-timing.c sysdeps/powerpc/powerpc32/power4/hp-timing.h
|
rm -fv sysdeps/powerpc/powerpc32/power4/hp-timing.c sysdeps/powerpc/powerpc32/power4/hp-timing.h
|
||||||
find . -name configure | xargs touch
|
find . -name configure | xargs touch
|
||||||
|
|
||||||
#######################################################################
|
#######################################################################
|
||||||
###
|
###
|
||||||
### BUILD
|
### BUILD
|
||||||
@ -441,6 +470,7 @@ PARALLEL="%{?jobs:-j%jobs}"
|
|||||||
# fails to build otherwise - need to recheck and fix
|
# fails to build otherwise - need to recheck and fix
|
||||||
%define enable_stackguard_randomization 0
|
%define enable_stackguard_randomization 0
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
configure_and_build_glibc() {
|
configure_and_build_glibc() {
|
||||||
local dirname="$1"; shift
|
local dirname="$1"; shift
|
||||||
local cflags="$1"; shift
|
local cflags="$1"; shift
|
||||||
@ -464,6 +494,7 @@ configure_and_build_glibc() {
|
|||||||
make $PARALLEL
|
make $PARALLEL
|
||||||
cd ..
|
cd ..
|
||||||
}
|
}
|
||||||
|
|
||||||
%if !%{optimize_power}
|
%if !%{optimize_power}
|
||||||
#
|
#
|
||||||
# Build base glibc
|
# Build base glibc
|
||||||
@ -475,9 +506,17 @@ configure_and_build_glibc() {
|
|||||||
#
|
#
|
||||||
# First, base build:
|
# First, base build:
|
||||||
pBuildFlags="$BuildFlags -mcpu=%{powerpc_optimize_base} -mtune=%{powerpc_optimize_tune}"
|
pBuildFlags="$BuildFlags -mcpu=%{powerpc_optimize_base} -mtune=%{powerpc_optimize_tune}"
|
||||||
configure_and_build_glibc base "$pBuildFlags" "$add_ons,powerpc-cpu" --with-cpu=%{powerpc_optimize_base}
|
%if %{powerpc_optimize_base} != "power3"
|
||||||
|
configure_and_build_glibc base "$pBuildFlags" "$add_ons" --with-cpu=%{powerpc_optimize_base}
|
||||||
|
%else
|
||||||
|
# Use no default CPU
|
||||||
|
configure_and_build_glibc base "$pBuildFlags" "$add_ons"
|
||||||
|
%endif
|
||||||
# Then other power variants:
|
# Then other power variants:
|
||||||
for pcpu in \
|
for pcpu in \
|
||||||
|
%if %{powerpc_optimize_cpu_power4}
|
||||||
|
power4 \
|
||||||
|
%endif
|
||||||
%if %{powerpc_optimize_cpu_power6}
|
%if %{powerpc_optimize_cpu_power6}
|
||||||
power6 \
|
power6 \
|
||||||
%endif
|
%endif
|
||||||
@ -485,7 +524,7 @@ configure_and_build_glibc() {
|
|||||||
power7 \
|
power7 \
|
||||||
%endif
|
%endif
|
||||||
; do
|
; do
|
||||||
configure_and_build_glibc $pcpu "$BuildFlags -mcpu=$pcpu" "$add_ons,powerpc-cpu" \
|
configure_and_build_glibc $pcpu "$BuildFlags -mcpu=$pcpu" "$add_ons" \
|
||||||
--with-cpu=$pcpu --disable-runbinaries
|
--with-cpu=$pcpu --disable-runbinaries
|
||||||
done
|
done
|
||||||
# Eventually, special Cell variant:
|
# Eventually, special Cell variant:
|
||||||
@ -493,17 +532,22 @@ configure_and_build_glibc() {
|
|||||||
configure_and_build_glibc ppc-cell-be "$BuildFlags -mcpu=cell" "$add_ons" --disable-runbinaries
|
configure_and_build_glibc ppc-cell-be "$BuildFlags -mcpu=cell" "$add_ons" --disable-runbinaries
|
||||||
%endif
|
%endif
|
||||||
%endif # optimize_power
|
%endif # optimize_power
|
||||||
|
|
||||||
#
|
#
|
||||||
# Build html documentation
|
# Build html documentation
|
||||||
#
|
#
|
||||||
make -C cc-base html
|
make -C cc-base html
|
||||||
|
|
||||||
#
|
#
|
||||||
# Build glibc_post_upgrade binary
|
# Build glibc_post_upgrade binary
|
||||||
#
|
#
|
||||||
$BuildCC -static -Os -g $RPM_SOURCE_DIR/glibc_post_upgrade.c -o glibc_post_upgrade \
|
$BuildCC -static -Os -g $RPM_SOURCE_DIR/glibc_post_upgrade.c -o glibc_post_upgrade \
|
||||||
-Lcc-base -Bcc-base/csu \
|
-Lcc-base -Bcc-base/csu \
|
||||||
'-DREMOVE_TLS_DIRS' \
|
'-DREMOVE_TLS_DIRS' '-DREMOVE_PPC_OPTIMIZE_POWER5' \
|
||||||
%ifarch ppc ppc64
|
%ifarch ppc ppc64
|
||||||
|
%if !%{powerpc_optimize_cpu_power4}
|
||||||
|
'-DREMOVE_PPC_OPTIMIZE_POWER4' \
|
||||||
|
%endif
|
||||||
%if !%{powerpc_optimize_cpu_power6}
|
%if !%{powerpc_optimize_cpu_power6}
|
||||||
'-DREMOVE_PPC_OPTIMIZE_POWER6' \
|
'-DREMOVE_PPC_OPTIMIZE_POWER6' \
|
||||||
%endif
|
%endif
|
||||||
@ -515,6 +559,7 @@ $BuildCC -static -Os -g $RPM_SOURCE_DIR/glibc_post_upgrade.c -o glibc_post_upgra
|
|||||||
%endif
|
%endif
|
||||||
%endif
|
%endif
|
||||||
'-DLIBDIR="/%{_lib}"' '-DGCONV_MODULES_DIR="%{_prefix}/%{_lib}/gconv"'
|
'-DLIBDIR="/%{_lib}"' '-DGCONV_MODULES_DIR="%{_prefix}/%{_lib}/gconv"'
|
||||||
|
|
||||||
#######################################################################
|
#######################################################################
|
||||||
###
|
###
|
||||||
### CHECK
|
### CHECK
|
||||||
@ -536,6 +581,7 @@ $BuildCC -static -Os -g $RPM_SOURCE_DIR/glibc_post_upgrade.c -o glibc_post_upgra
|
|||||||
%endif
|
%endif
|
||||||
%endif
|
%endif
|
||||||
make -C cc-base check-abi || echo check-abi failed
|
make -C cc-base check-abi || echo check-abi failed
|
||||||
|
|
||||||
#######################################################################
|
#######################################################################
|
||||||
###
|
###
|
||||||
### INSTALL
|
### INSTALL
|
||||||
@ -553,12 +599,15 @@ make -C cc-base check-abi || echo check-abi failed
|
|||||||
# debugging tools currently require these sections directly inside the main
|
# debugging tools currently require these sections directly inside the main
|
||||||
# files - specifically valgrind and PurifyPlus.
|
# files - specifically valgrind and PurifyPlus.
|
||||||
export STRIP_KEEP_SYMTAB=*.so*
|
export STRIP_KEEP_SYMTAB=*.so*
|
||||||
|
|
||||||
# Make sure we will create the gconv-modules.cache
|
# Make sure we will create the gconv-modules.cache
|
||||||
mkdir -p $RPM_BUILD_ROOT%{_libdir}/gconv
|
mkdir -p $RPM_BUILD_ROOT%{_libdir}/gconv
|
||||||
touch $RPM_BUILD_ROOT%{_libdir}/gconv/gconv-modules.cache
|
touch $RPM_BUILD_ROOT%{_libdir}/gconv/gconv-modules.cache
|
||||||
|
|
||||||
# Install base glibc
|
# Install base glibc
|
||||||
# Do not install in parallel, timezone Makefile will fail
|
# Do not install in parallel, timezone Makefile will fail
|
||||||
make install_root=$RPM_BUILD_ROOT install -C cc-base
|
make install_root=$RPM_BUILD_ROOT install -C cc-base
|
||||||
|
|
||||||
# Install power-optimized glibc
|
# Install power-optimized glibc
|
||||||
%if %{optimize_power}
|
%if %{optimize_power}
|
||||||
# run ldconfig to create the library symlinks
|
# run ldconfig to create the library symlinks
|
||||||
@ -566,6 +615,9 @@ make install_root=$RPM_BUILD_ROOT install -C cc-base
|
|||||||
# it may contain instructions not suitable for the cpu on the builhost
|
# it may contain instructions not suitable for the cpu on the builhost
|
||||||
my_ldconfig=/sbin/ldconfig
|
my_ldconfig=/sbin/ldconfig
|
||||||
for pcpu in \
|
for pcpu in \
|
||||||
|
%if %{powerpc_optimize_cpu_power4}
|
||||||
|
power4 \
|
||||||
|
%endif
|
||||||
%if %{powerpc_optimize_cpu_power6}
|
%if %{powerpc_optimize_cpu_power6}
|
||||||
power6 \
|
power6 \
|
||||||
%endif
|
%endif
|
||||||
@ -597,6 +649,7 @@ make install_root=$RPM_BUILD_ROOT install -C cc-base
|
|||||||
fi
|
fi
|
||||||
%endif
|
%endif
|
||||||
%endif # optimize_power
|
%endif # optimize_power
|
||||||
|
|
||||||
# Install locales
|
# Install locales
|
||||||
%if %{build_locales}
|
%if %{build_locales}
|
||||||
# Do not install locales in parallel!
|
# Do not install locales in parallel!
|
||||||
@ -606,31 +659,43 @@ make install_root=$RPM_BUILD_ROOT install -C cc-base
|
|||||||
%endif
|
%endif
|
||||||
# Create file list for glibc-locale package
|
# Create file list for glibc-locale package
|
||||||
%{find_lang} libc
|
%{find_lang} libc
|
||||||
|
|
||||||
# Prepare obsolete/, used only on some architectures:
|
# Prepare obsolete/, used only on some architectures:
|
||||||
export RPM_BUILD_ROOT
|
export RPM_BUILD_ROOT
|
||||||
mkdir -p $RPM_BUILD_ROOT/%{_lib}/obsolete
|
mkdir -p $RPM_BUILD_ROOT/%{_lib}/obsolete
|
||||||
|
|
||||||
# NPTL <bits/stdio-lock.h> is not usable outside of glibc, so include
|
# NPTL <bits/stdio-lock.h> is not usable outside of glibc, so include
|
||||||
# the generic one (RH#162634)
|
# the generic one (RH#162634)
|
||||||
cp -av bits/stdio-lock.h $RPM_BUILD_ROOT%{_prefix}/include/bits/stdio-lock.h
|
cp -av bits/stdio-lock.h $RPM_BUILD_ROOT%{_prefix}/include/bits/stdio-lock.h
|
||||||
|
|
||||||
%ifarch s390x
|
%ifarch s390x
|
||||||
# s390x is different ...
|
# s390x is different ...
|
||||||
mkdir $RPM_BUILD_ROOT/lib
|
mkdir $RPM_BUILD_ROOT/lib
|
||||||
ln -sf ../%{_lib}/ld-%{version}.so $RPM_BUILD_ROOT/lib/ld64.so.1
|
ln -sf ../%{_lib}/ld-%{version}.so $RPM_BUILD_ROOT/lib/ld64.so.1
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
# Miscelanna:
|
# Miscelanna:
|
||||||
|
|
||||||
install -m 0700 glibc_post_upgrade $RPM_BUILD_ROOT%{_sbindir}
|
install -m 0700 glibc_post_upgrade $RPM_BUILD_ROOT%{_sbindir}
|
||||||
|
|
||||||
install -m 644 $RPM_SOURCE_DIR/bindresvport.blacklist $RPM_BUILD_ROOT/etc
|
install -m 644 $RPM_SOURCE_DIR/bindresvport.blacklist $RPM_BUILD_ROOT/etc
|
||||||
install -m 644 $RPM_SOURCE_DIR/nsswitch.conf $RPM_BUILD_ROOT/etc
|
install -m 644 $RPM_SOURCE_DIR/nsswitch.conf $RPM_BUILD_ROOT/etc
|
||||||
install -m 644 posix/gai.conf $RPM_BUILD_ROOT/etc
|
install -m 644 posix/gai.conf $RPM_BUILD_ROOT/etc
|
||||||
|
|
||||||
mkdir -p $RPM_BUILD_ROOT/etc/default
|
mkdir -p $RPM_BUILD_ROOT/etc/default
|
||||||
install -m 644 nis/nss $RPM_BUILD_ROOT/etc/default/
|
install -m 644 nis/nss $RPM_BUILD_ROOT/etc/default/
|
||||||
|
|
||||||
mkdir -p $RPM_BUILD_ROOT/usr/include/resolv
|
mkdir -p $RPM_BUILD_ROOT/usr/include/resolv
|
||||||
install -m 0644 resolv/mapv4v6addr.h $RPM_BUILD_ROOT/usr/include/resolv/
|
install -m 0644 resolv/mapv4v6addr.h $RPM_BUILD_ROOT/usr/include/resolv/
|
||||||
install -m 0644 resolv/mapv4v6hostent.h $RPM_BUILD_ROOT/usr/include/resolv/
|
install -m 0644 resolv/mapv4v6hostent.h $RPM_BUILD_ROOT/usr/include/resolv/
|
||||||
|
|
||||||
mkdir -p $RPM_BUILD_ROOT/usr/share/doc/glibc
|
mkdir -p $RPM_BUILD_ROOT/usr/share/doc/glibc
|
||||||
cp -p manual/libc/*.html $RPM_BUILD_ROOT/usr/share/doc/glibc
|
cp -p manual/libc/*.html $RPM_BUILD_ROOT/usr/share/doc/glibc
|
||||||
|
|
||||||
cd manpages; make install_root=$RPM_BUILD_ROOT install; cd ..
|
cd manpages; make install_root=$RPM_BUILD_ROOT install; cd ..
|
||||||
|
|
||||||
# nscd tools:
|
# nscd tools:
|
||||||
|
|
||||||
cp nscd/nscd.conf $RPM_BUILD_ROOT/etc
|
cp nscd/nscd.conf $RPM_BUILD_ROOT/etc
|
||||||
mkdir -p $RPM_BUILD_ROOT/etc/apparmor.d
|
mkdir -p $RPM_BUILD_ROOT/etc/apparmor.d
|
||||||
cp $RPM_SOURCE_DIR/usr.sbin.nscd $RPM_BUILD_ROOT/etc/apparmor.d
|
cp $RPM_SOURCE_DIR/usr.sbin.nscd $RPM_BUILD_ROOT/etc/apparmor.d
|
||||||
@ -640,6 +705,7 @@ ln -sf /etc/init.d/nscd $RPM_BUILD_ROOT/usr/sbin/rcnscd
|
|||||||
mkdir -p $RPM_BUILD_ROOT/var/run/nscd
|
mkdir -p $RPM_BUILD_ROOT/var/run/nscd
|
||||||
touch $RPM_BUILD_ROOT/var/run/nscd/{passwd,group,hosts}
|
touch $RPM_BUILD_ROOT/var/run/nscd/{passwd,group,hosts}
|
||||||
touch $RPM_BUILD_ROOT/var/run/nscd/{socket,nscd.pid}
|
touch $RPM_BUILD_ROOT/var/run/nscd/{socket,nscd.pid}
|
||||||
|
|
||||||
#
|
#
|
||||||
# Create ld.so.conf
|
# Create ld.so.conf
|
||||||
#
|
#
|
||||||
@ -679,23 +745,28 @@ mkdir -p $RPM_BUILD_ROOT/var/cache/ldconfig
|
|||||||
# Empty the ld.so.cache:
|
# Empty the ld.so.cache:
|
||||||
rm -f $RPM_BUILD_ROOT/etc/ld.so.cache
|
rm -f $RPM_BUILD_ROOT/etc/ld.so.cache
|
||||||
touch $RPM_BUILD_ROOT/etc/ld.so.cache
|
touch $RPM_BUILD_ROOT/etc/ld.so.cache
|
||||||
|
|
||||||
# libNoVersion belongs only to glibc-obsolete:
|
# libNoVersion belongs only to glibc-obsolete:
|
||||||
%ifarch %ix86
|
%ifarch %ix86
|
||||||
rm -f $RPM_BUILD_ROOT%{_libdir}/libNoVersion*
|
rm -f $RPM_BUILD_ROOT%{_libdir}/libNoVersion*
|
||||||
mkdir -p $RPM_BUILD_ROOT/%{_lib}/obsolete/noversion
|
mkdir -p $RPM_BUILD_ROOT/%{_lib}/obsolete/noversion
|
||||||
mv -v $RPM_BUILD_ROOT/%{_lib}/libNoVersion* $RPM_BUILD_ROOT/%{_lib}/obsolete/noversion/
|
mv -v $RPM_BUILD_ROOT/%{_lib}/libNoVersion* $RPM_BUILD_ROOT/%{_lib}/obsolete/noversion/
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
# Don't look at ldd! We don't wish a /bin/sh requires
|
# Don't look at ldd! We don't wish a /bin/sh requires
|
||||||
chmod 644 $RPM_BUILD_ROOT/usr/bin/ldd
|
chmod 644 $RPM_BUILD_ROOT/usr/bin/ldd
|
||||||
|
|
||||||
# Remove timezone data, now coming in standalone package:
|
# Remove timezone data, now coming in standalone package:
|
||||||
for i in sbin/sln usr/bin/tzselect usr/sbin/zic usr/sbin/zdump etc/localtime; do
|
for i in sbin/sln usr/bin/tzselect usr/sbin/zic usr/sbin/zdump etc/localtime; do
|
||||||
rm -f $RPM_BUILD_ROOT/$i
|
rm -f $RPM_BUILD_ROOT/$i
|
||||||
done
|
done
|
||||||
rm -rf $RPM_BUILD_ROOT/usr/share/zoneinfo
|
rm -rf $RPM_BUILD_ROOT/usr/share/zoneinfo
|
||||||
|
|
||||||
# Remove the buildflags tracking section and the build-id
|
# Remove the buildflags tracking section and the build-id
|
||||||
for o in $RPM_BUILD_ROOT/%{_libdir}/crt[1in].o $RPM_BUILD_ROOT/%{_libdir}/lib*_nonshared.a; do
|
for o in $RPM_BUILD_ROOT/%{_libdir}/crt[1in].o $RPM_BUILD_ROOT/%{_libdir}/lib*_nonshared.a; do
|
||||||
objcopy -R ".comment.SUSE.OPTs" -R ".note.gnu.build-id" $o
|
objcopy -R ".comment.SUSE.OPTs" -R ".note.gnu.build-id" $o
|
||||||
done
|
done
|
||||||
|
|
||||||
#######################################################################
|
#######################################################################
|
||||||
###
|
###
|
||||||
### ...
|
### ...
|
||||||
@ -732,11 +803,13 @@ done
|
|||||||
%restart_on_update nscd
|
%restart_on_update nscd
|
||||||
%insserv_cleanup
|
%insserv_cleanup
|
||||||
exit 0
|
exit 0
|
||||||
|
|
||||||
#######################################################################
|
#######################################################################
|
||||||
###
|
###
|
||||||
### FILES
|
### FILES
|
||||||
###
|
###
|
||||||
#######################################################################
|
#######################################################################
|
||||||
|
|
||||||
# glibc
|
# glibc
|
||||||
|
|
||||||
%files
|
%files
|
||||||
@ -833,6 +906,9 @@ exit 0
|
|||||||
/%{_lib}/%1/librt.so.1\
|
/%{_lib}/%1/librt.so.1\
|
||||||
/%{_lib}/%1/libthread_db-1.0.so\
|
/%{_lib}/%1/libthread_db-1.0.so\
|
||||||
/%{_lib}/%1/libthread_db.so.1
|
/%{_lib}/%1/libthread_db.so.1
|
||||||
|
%if %{powerpc_optimize_cpu_power4}
|
||||||
|
%{optimized_libs power4}
|
||||||
|
%endif
|
||||||
%if %{powerpc_optimize_cpu_power6}
|
%if %{powerpc_optimize_cpu_power6}
|
||||||
%{optimized_libs power6}
|
%{optimized_libs power6}
|
||||||
%{optimized_libs power6x}
|
%{optimized_libs power6x}
|
||||||
|
@ -34,6 +34,9 @@ main (void)
|
|||||||
char initpath[256];
|
char initpath[256];
|
||||||
struct stat root, init_root;
|
struct stat root, init_root;
|
||||||
|
|
||||||
|
/* First, get rid of platform-optimized libraries. We remove any we have
|
||||||
|
ever built, since otherwise we might end up using some old leftover
|
||||||
|
libraries when new ones aren't installed in their place anymore. */
|
||||||
#ifdef REMOVE_TLS_DIRS
|
#ifdef REMOVE_TLS_DIRS
|
||||||
const char *library[] = {"libc.so.6", "libc.so.6.1", "libm.so.6",
|
const char *library[] = {"libc.so.6", "libc.so.6.1", "libm.so.6",
|
||||||
"libm.so.6.1", "librt.so.1", "librtkaio.so.1",
|
"libm.so.6.1", "librt.so.1", "librtkaio.so.1",
|
||||||
@ -43,6 +46,14 @@ main (void)
|
|||||||
"/lib/i686/",
|
"/lib/i686/",
|
||||||
#endif
|
#endif
|
||||||
#ifdef __powerpc64__
|
#ifdef __powerpc64__
|
||||||
|
#ifdef REMOVE_PPC_OPTIMIZE_POWER4
|
||||||
|
"/lib64/power4/",
|
||||||
|
"/lib64/ppc970/",
|
||||||
|
#endif
|
||||||
|
#ifdef REMOVE_PPC_OPTIMIZE_POWER5
|
||||||
|
"/lib64/power5/",
|
||||||
|
"/lib64/power5+/",
|
||||||
|
#endif
|
||||||
#ifdef REMOVE_PPC_OPTIMIZE_POWER6
|
#ifdef REMOVE_PPC_OPTIMIZE_POWER6
|
||||||
"/lib64/power6/",
|
"/lib64/power6/",
|
||||||
"/lib64/power6x/",
|
"/lib64/power6x/",
|
||||||
@ -55,6 +66,14 @@ main (void)
|
|||||||
#endif
|
#endif
|
||||||
#endif /* __powerpc64__ */
|
#endif /* __powerpc64__ */
|
||||||
#ifdef __powerpc__
|
#ifdef __powerpc__
|
||||||
|
#ifdef REMOVE_PPC_OPTIMIZE_POWER4
|
||||||
|
"/lib/power4/",
|
||||||
|
"/lib/ppc970/",
|
||||||
|
#endif
|
||||||
|
#ifdef REMOVE_PPC_OPTIMIZE_POWER5
|
||||||
|
"/lib/power5/",
|
||||||
|
"/lib/power5+/",
|
||||||
|
#endif
|
||||||
#ifdef REMOVE_PPC_OPTIMIZE_POWER6
|
#ifdef REMOVE_PPC_OPTIMIZE_POWER6
|
||||||
"/lib/power6/",
|
"/lib/power6/",
|
||||||
"/lib/power6x/",
|
"/lib/power6x/",
|
||||||
|
57
ld-prelink-unique.diff
Normal file
57
ld-prelink-unique.diff
Normal file
@ -0,0 +1,57 @@
|
|||||||
|
2010-03-23 Jakub Jelinek <jakub@redhat.com>
|
||||||
|
|
||||||
|
* elf/dl-lookup.c (do_lookup_x): If tab->entries is NULL,
|
||||||
|
but tab->size != 0, just unlock and goto success, without
|
||||||
|
allocating anything or entering anything into the hash table.
|
||||||
|
(_dl_debug_bindings): Temporarily set tab->entries to NULL
|
||||||
|
around do_lookup_x in undef_map->l_local_scope[0].
|
||||||
|
|
||||||
|
--- libc/elf/dl-lookup.c.jj 2009-12-16 00:10:37.000000000 +0100
|
||||||
|
+++ libc/elf/dl-lookup.c 2010-03-23 11:03:45.850560036 +0100
|
||||||
|
@@ -1,5 +1,6 @@
|
||||||
|
/* Look up a symbol in the loaded objects.
|
||||||
|
- Copyright (C) 1995-2005, 2006, 2007, 2009 Free Software Foundation, Inc.
|
||||||
|
+ Copyright (C) 1995-2005, 2006, 2007, 2009, 2010
|
||||||
|
+ Free Software Foundation, Inc.
|
||||||
|
This file is part of the GNU C Library.
|
||||||
|
|
||||||
|
The GNU C Library is free software; you can redistribute it and/or
|
||||||
|
@@ -414,6 +415,20 @@ do_lookup_x (const char *undef_name, uin
|
||||||
|
assert (!RTLD_CHECK_FOREIGN_CALL);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
+#ifdef SHARED
|
||||||
|
+ /* If tab->entries is NULL, but tab->size is not, it means
|
||||||
|
+ this is the second, conflict finding, lookup for
|
||||||
|
+ LD_TRACE_PRELINKING in _dl_debug_bindings. Don't
|
||||||
|
+ allocate anything and don't enter anything into the
|
||||||
|
+ hash table. */
|
||||||
|
+ if (__builtin_expect (tab->size, 0))
|
||||||
|
+ {
|
||||||
|
+ assert (GLRO(dl_debug_mask) & DL_DEBUG_PRELINK);
|
||||||
|
+ __rtld_lock_unlock_recursive (tab->lock);
|
||||||
|
+ goto success;
|
||||||
|
+ }
|
||||||
|
+#endif
|
||||||
|
+
|
||||||
|
#define INITIAL_NUNIQUE_SYM_TABLE 31
|
||||||
|
size = INITIAL_NUNIQUE_SYM_TABLE;
|
||||||
|
entries = calloc (sizeof (struct unique_sym), size);
|
||||||
|
@@ -917,13 +932,17 @@ _dl_debug_bindings (const char *undef_na
|
||||||
|
{
|
||||||
|
const uint_fast32_t new_hash = dl_new_hash (undef_name);
|
||||||
|
unsigned long int old_hash = 0xffffffff;
|
||||||
|
+ struct unique_sym *saved_entries
|
||||||
|
+ = GL(dl_ns)[LM_ID_BASE]._ns_unique_sym_table.entries;
|
||||||
|
|
||||||
|
+ GL(dl_ns)[LM_ID_BASE]._ns_unique_sym_table.entries = NULL;
|
||||||
|
do_lookup_x (undef_name, new_hash, &old_hash, *ref, &val,
|
||||||
|
undef_map->l_local_scope[0], 0, version, 0, NULL,
|
||||||
|
type_class, undef_map);
|
||||||
|
|
||||||
|
if (val.s != value->s || val.m != value->m)
|
||||||
|
conflict = 1;
|
||||||
|
+ GL(dl_ns)[LM_ID_BASE]._ns_unique_sym_table.entries = saved_entries;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (value->s)
|
29
nptl-ppc64-vdso-timedwait.diff
Normal file
29
nptl-ppc64-vdso-timedwait.diff
Normal file
@ -0,0 +1,29 @@
|
|||||||
|
Index: glibc-2.11.1/nptl/pthread_cond_timedwait.c
|
||||||
|
===================================================================
|
||||||
|
--- glibc-2.11.1.old/nptl/pthread_cond_timedwait.c
|
||||||
|
+++ glibc-2.11.1/nptl/pthread_cond_timedwait.c
|
||||||
|
@@ -27,6 +27,15 @@
|
||||||
|
|
||||||
|
#include <shlib-compat.h>
|
||||||
|
|
||||||
|
+#ifndef HAVE_CLOCK_GETTIME_VSYSCALL
|
||||||
|
+# undef INTERNAL_VSYSCALL
|
||||||
|
+# define INTERNAL_VSYSCALL INTERNAL_SYSCALL
|
||||||
|
+# undef INLINE_VSYSCALL
|
||||||
|
+# define INLINE_VSYSCALL INLINE_SYSCALL
|
||||||
|
+#else
|
||||||
|
+# include <bits/libc-vdso.h>
|
||||||
|
+#endif
|
||||||
|
+
|
||||||
|
|
||||||
|
/* Cleanup handler, defined in pthread_cond_wait.c. */
|
||||||
|
extern void __condvar_cleanup (void *arg)
|
||||||
|
@@ -102,7 +111,7 @@ __pthread_cond_timedwait (cond, mutex, a
|
||||||
|
#ifdef __NR_clock_gettime
|
||||||
|
INTERNAL_SYSCALL_DECL (err);
|
||||||
|
int ret;
|
||||||
|
- ret = INTERNAL_SYSCALL (clock_gettime, err, 2,
|
||||||
|
+ ret = INTERNAL_VSYSCALL (clock_gettime, err, 2,
|
||||||
|
(cond->__data.__nwaiters
|
||||||
|
& ((1 << COND_NWAITERS_SHIFT) - 1)),
|
||||||
|
&rt);
|
@ -1,3 +0,0 @@
|
|||||||
version https://git-lfs.github.com/spec/v1
|
|
||||||
oid sha256:c59f80e38c9f6ad339d72bbfbc454364659686567b7689d33483b9cb4a12bf2a
|
|
||||||
size 36248
|
|
@ -1,33 +0,0 @@
|
|||||||
Index: resolv/res_libc.c
|
|
||||||
===================================================================
|
|
||||||
--- resolv/res_libc.c.orig
|
|
||||||
+++ resolv/res_libc.c
|
|
||||||
@@ -22,6 +22,7 @@
|
|
||||||
#include <arpa/nameser.h>
|
|
||||||
#include <resolv.h>
|
|
||||||
#include <bits/libc-lock.h>
|
|
||||||
+#include <sys/stat.h>
|
|
||||||
|
|
||||||
|
|
||||||
/* The following bit is copied from res_data.c (where it is #ifdef'ed
|
|
||||||
@@ -95,6 +96,20 @@ int
|
|
||||||
__res_maybe_init (res_state resp, int preinit)
|
|
||||||
{
|
|
||||||
if (resp->options & RES_INIT) {
|
|
||||||
+ static time_t last_mtime, last_check;
|
|
||||||
+ time_t now;
|
|
||||||
+ struct stat statbuf;
|
|
||||||
+
|
|
||||||
+ time (&now);
|
|
||||||
+ if (now != last_check) {
|
|
||||||
+ last_check = now;
|
|
||||||
+ if (stat (_PATH_RESCONF, &statbuf) == 0 && last_mtime != statbuf.st_mtime) {
|
|
||||||
+ last_mtime = statbuf.st_mtime;
|
|
||||||
+ atomicinclock (lock);
|
|
||||||
+ atomicinc (__res_initstamp);
|
|
||||||
+ atomicincunlock (lock);
|
|
||||||
+ }
|
|
||||||
+ }
|
|
||||||
if (__res_initstamp != resp->_u._ext.initstamp) {
|
|
||||||
if (resp->nscount > 0)
|
|
||||||
__res_iclose (resp, true);
|
|
Loading…
Reference in New Issue
Block a user