mirror of
https://github.com/archlinuxarm/PKGBUILDs.git
synced 2024-11-08 22:45:43 +00:00
core/glibc to 2.15-3
This commit is contained in:
parent
9d41e40f9e
commit
4eb204fce2
7 changed files with 482 additions and 111 deletions
|
@ -1,4 +1,4 @@
|
|||
# $Id: PKGBUILD 141373 2011-10-30 06:48:26Z allan $
|
||||
# $Id: PKGBUILD 145916 2012-01-04 01:25:04Z allan $
|
||||
# Maintainer: Allan McRae <allan@archlinux.org>
|
||||
|
||||
# toolchain build order: linux-api-headers->glibc->binutils->gcc->binutils->glibc
|
||||
|
@ -8,62 +8,65 @@
|
|||
# - Added source file for glibc-ports, needed for building on ARM
|
||||
# - Symlink glibc-ports source dir to ports dir in glibc directory
|
||||
# - Changed configure to enable ports add-on, specify our build host type
|
||||
# - Disabled distcc and ccache, make -j1 for v5, -j2 for v7
|
||||
# - Disabled distcc, make -j1 for v5, -j2 for v7
|
||||
|
||||
plugrel=1
|
||||
noautobuild=1
|
||||
|
||||
pkgname=glibc
|
||||
pkgver=2.14.1
|
||||
pkgrel=2
|
||||
_glibcdate=20111025
|
||||
pkgver=2.15
|
||||
pkgrel=3
|
||||
_glibcdate=20111227
|
||||
pkgdesc="GNU C Library"
|
||||
arch=('i686' 'x86_64')
|
||||
url="http://www.gnu.org/software/libc"
|
||||
license=('GPL' 'LGPL')
|
||||
groups=('base')
|
||||
depends=('linux-api-headers>=3.1' 'tzdata')
|
||||
depends=('linux-api-headers>=3.1.6' 'tzdata')
|
||||
makedepends=('gcc>=4.6')
|
||||
backup=(etc/gai.conf
|
||||
etc/locale.gen
|
||||
etc/nscd.conf)
|
||||
options=('!strip' '!distcc' '!ccache')
|
||||
options=('!strip' '!distcc')
|
||||
install=glibc.install
|
||||
source=(ftp://ftp.archlinux.org/other/glibc/${pkgname}-${pkgver}_${_glibcdate}.tar.xz
|
||||
ftp://ftp.gnu.org/gnu/glibc/glibc-ports-${pkgver}.tar.xz
|
||||
http://archlinuxarm.org/builder/src/glibc-ports-2.15-20120104.tar.bz2
|
||||
glibc-2.10-dont-build-timezone.patch
|
||||
glibc-2.10-bz4781.patch
|
||||
glibc-__i686.patch
|
||||
glibc-2.12.1-static-shared-getpagesize.patch
|
||||
glibc-2.12.2-ignore-origin-of-privileged-program.patch
|
||||
glibc-2.13-futex.patch
|
||||
glibc-2.14-libdl-crash.patch
|
||||
glibc-2.14-revert-4768ae77.patch
|
||||
glibc-2.14-reexport-rpc-interface.patch
|
||||
glibc-2.14-reinstall-nis-rpc-headers.patch
|
||||
glibc-2.15-lddebug-scopes.patch
|
||||
glibc-2.15-revert-c5a0802a.patch
|
||||
glibc-2.15-math64crash.patch
|
||||
nscd
|
||||
locale.gen.txt
|
||||
locale-gen)
|
||||
md5sums=('c52a15134dfa9f2c94f2ccd4cb155cf1'
|
||||
md5sums=('6ffdf5832192b92f98bdd125317c0dfc'
|
||||
'837e7be231f0cf1804e590b85132ac86'
|
||||
'4dadb9203b69a3210d53514bb46f41c3'
|
||||
'0c5540efc51c0b93996c51b57a8540ae'
|
||||
'40cd342e21f71f5e49e32622b25acc52'
|
||||
'a3ac6f318d680347bb6e2805d42b73b2'
|
||||
'b042647ea7d6f22ad319e12e796bd13e'
|
||||
'7d0154b7e17ea218c9fa953599d24cc4'
|
||||
'6970bcfeb3bf88913436d5112d16f588'
|
||||
'7da8c554a3b591c7401d7023b1928afc'
|
||||
'c5de2a946215d647c8af5432ec4b0da0'
|
||||
'55febbb72139ac7b65757df085024b83'
|
||||
'3c219ddfb619b6df903cac4cc42c611d'
|
||||
'7ae3e426251ae33e73dbad71f9c91378'
|
||||
'dc7550e659ddd685bd78a930d15a01f2'
|
||||
'b587ee3a70c9b3713099295609afde49'
|
||||
'07ac979b6ab5eeb778d55f041529d623'
|
||||
'476e9113489f93b348b21e144b6a8fcf')
|
||||
|
||||
|
||||
mksource() {
|
||||
git clone git://sourceware.org/git/glibc.git
|
||||
pushd glibc
|
||||
git checkout -b glibc-2.14-arch origin/release/2.14/master
|
||||
#git checkout -b glibc-2.15-arch origin/release/2.15/master
|
||||
git checkout -b glibc-2.15-arch origin/master
|
||||
popd
|
||||
tar -cvJf glibc-${pkgver}_${_glibcdate}.tar.xz glibc/*
|
||||
}
|
||||
|
@ -84,24 +87,17 @@ build() {
|
|||
# http://sourceware.org/ml/libc-alpha/2009-07/msg00072.html
|
||||
patch -Np1 -i ${srcdir}/glibc-__i686.patch
|
||||
|
||||
# http://sourceware.org/bugzilla/show_bug.cgi?id=11929
|
||||
# using Fedora "fix" as patch in that bug report causes breakages...
|
||||
patch -Np1 -i ${srcdir}/glibc-2.12.1-static-shared-getpagesize.patch
|
||||
|
||||
# http://www.exploit-db.com/exploits/15274/
|
||||
# http://sourceware.org/git/?p=glibc.git;a=patch;h=d14e6b09 (only fedora branch...)
|
||||
patch -Np1 -i ${srcdir}/glibc-2.12.2-ignore-origin-of-privileged-program.patch
|
||||
|
||||
# http://sourceware.org/bugzilla/show_bug.cgi?id=12403
|
||||
patch -Np1 -i ${srcdir}/glibc-2.13-futex.patch
|
||||
|
||||
# http://sourceware.org/git/?p=glibc.git;a=commitdiff;h=675155e9 (only fedora branch...)
|
||||
# http://sourceware.org/ml/libc-alpha/2011-06/msg00006.html
|
||||
patch -Np1 -i ${srcdir}/glibc-2.14-libdl-crash.patch
|
||||
|
||||
# Revert commit causing issues with crappy DNS servers...
|
||||
# Will be removed when workaround becomes annoying to maintain - USE A BETTER DNS SERVER!
|
||||
# Note that both these patches do not fix the issue completely:
|
||||
# Note that both these patches appear not to fix the issue completely:
|
||||
# http://sourceware.org/bugzilla/show_bug.cgi?id=13013
|
||||
# http://sourceware.org/git/?p=glibc.git;a=commitdiff;h=032c0ee3 (only fedora branch...)
|
||||
patch -Np1 -i ${srcdir}/glibc-2.14-revert-4768ae77.patch
|
||||
|
@ -112,6 +108,18 @@ build() {
|
|||
# http://sourceware.org/git/?p=glibc.git;a=commitdiff;h=bdd816a3 (only fedora branch...)
|
||||
patch -Np1 -i ${srcdir}/glibc-2.14-reinstall-nis-rpc-headers.patch
|
||||
|
||||
# propriety nvidia crash - https://bugzilla.redhat.com/show_bug.cgi?id=737223
|
||||
# http://sourceware.org/git/?p=glibc.git;a=commitdiff;h=0c95ab64 (only fedora branch...)
|
||||
patch -Np1 -i ${srcdir}/glibc-2.15-lddebug-scopes.patch
|
||||
|
||||
# revert commit c5a0802a - causes various hangs
|
||||
# https://bugzilla.redhat.com/show_bug.cgi?id=769421
|
||||
patch -Np1 -i ${srcdir}/glibc-2.15-revert-c5a0802a.patch
|
||||
|
||||
# revert optimized math routines that can cause crashes (FS#27736, FS#27743)
|
||||
# obviously not a real fix...
|
||||
patch -Np1 -i ${srcdir}/glibc-2.15-math64crash.patch
|
||||
|
||||
install -dm755 ${pkgdir}/etc
|
||||
touch ${pkgdir}/etc/ld.so.conf
|
||||
|
||||
|
@ -198,39 +206,26 @@ package() {
|
|||
ln -v -s ../lib/ld* .
|
||||
fi
|
||||
|
||||
# manually strip files as stripping libpthread-*.so and libthread_db.so
|
||||
# with the default $STRIP_SHARED breaks gdb and stripping ld-*.so breaks
|
||||
# valgrind on x86_64
|
||||
# Do not strip the following files for improved debugging support
|
||||
# ("improved" as in not breaking gdb and valgrind...):
|
||||
# ld-${pkgver}.so
|
||||
# libc-${pkgver}.so
|
||||
# libpthread-${pkgver}.so
|
||||
# libthread_db-1.0.so
|
||||
|
||||
cd $pkgdir
|
||||
strip $STRIP_BINARIES sbin/{ldconfig,sln} \
|
||||
usr/bin/{gencat,getconf,getent,iconv,locale} \
|
||||
usr/bin/{localedef,pcprofiledump,rpcgen,sprof} \
|
||||
usr/bin/{gencat,getconf,getent,iconv,locale,localedef} \
|
||||
usr/bin/{makedb,pcprofiledump,pldd,rpcgen,sprof} \
|
||||
usr/lib/getconf/* \
|
||||
usr/sbin/{iconvconfig,nscd}
|
||||
[[ $CARCH = "i686" ]] && strip $STRIP_BINARIES usr/bin/lddlibc4
|
||||
|
||||
strip $STRIP_STATIC usr/lib/*.a \
|
||||
lib/{{ld,libpthread}-${pkgver},libthread_db-1.0}.so
|
||||
strip $STRIP_STATIC usr/lib/*.a
|
||||
|
||||
strip $STRIP_SHARED lib/{libanl,libBrokenLocale,libc,libcidn,libcrypt}-${pkgver}.so \
|
||||
lib/libnss_{compat,dns,files,hesiod,nis,nisplus}-${pkgver}.so \
|
||||
strip $STRIP_SHARED lib/{libanl,libBrokenLocale,libcidn,libcrypt}-${pkgver}.so \
|
||||
lib/libnss_{compat,db,dns,files,hesiod,nis,nisplus}-${pkgver}.so \
|
||||
lib/{libdl,libm,libnsl,libresolv,librt,libutil}-${pkgver}.so \
|
||||
lib/{libmemusage,libpcprofile,libSegFault}.so \
|
||||
usr/lib/{pt_chown,{audit,gconv}/*.so}
|
||||
}
|
||||
md5sums=('c52a15134dfa9f2c94f2ccd4cb155cf1'
|
||||
'3b3afcb6b99fea9e3a2474cc4778ec88'
|
||||
'4dadb9203b69a3210d53514bb46f41c3'
|
||||
'0c5540efc51c0b93996c51b57a8540ae'
|
||||
'40cd342e21f71f5e49e32622b25acc52'
|
||||
'a3ac6f318d680347bb6e2805d42b73b2'
|
||||
'b042647ea7d6f22ad319e12e796bd13e'
|
||||
'7d0154b7e17ea218c9fa953599d24cc4'
|
||||
'6970bcfeb3bf88913436d5112d16f588'
|
||||
'7da8c554a3b591c7401d7023b1928afc'
|
||||
'c5de2a946215d647c8af5432ec4b0da0'
|
||||
'55febbb72139ac7b65757df085024b83'
|
||||
'b587ee3a70c9b3713099295609afde49'
|
||||
'07ac979b6ab5eeb778d55f041529d623'
|
||||
'476e9113489f93b348b21e144b6a8fcf')
|
||||
|
|
|
@ -1,11 +0,0 @@
|
|||
--- glibc-2.12-192-g7c08a05/sysdeps/unix/sysv/linux/getpagesize.c
|
||||
+++ glibc-2.12.90-17/sysdeps/unix/sysv/linux/getpagesize.c
|
||||
@@ -28,7 +28,7 @@
|
||||
int
|
||||
__getpagesize ()
|
||||
{
|
||||
-#ifdef __ASSUME_AT_PAGESIZE
|
||||
+#if 0 && defined __ASSUME_AT_PAGESIZE
|
||||
assert (GLRO(dl_pagesize) != 0);
|
||||
return GLRO(dl_pagesize);
|
||||
#else
|
|
@ -1,31 +0,0 @@
|
|||
--- a/nptl/sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedrdlock.S
|
||||
+++ a/nptl/sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedrdlock.S
|
||||
@@ -210,7 +210,7 @@ pthread_rwlock_timedrdlock:
|
||||
cfi_restore(%r12)
|
||||
retq
|
||||
|
||||
-#ifdef __ASSUME_PRIVATE_FUTEX
|
||||
+#ifdef __ASSUME_FUTEX_CLOCK_REALTIME
|
||||
cfi_adjust_cfa_offset(16)
|
||||
cfi_rel_offset(%r12, 8)
|
||||
cfi_rel_offset(%r13, 0)
|
||||
--- a/nptl/sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedwrlock.S
|
||||
+++ a/nptl/sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedwrlock.S
|
||||
@@ -192,7 +192,7 @@ pthread_rwlock_timedwrlock:
|
||||
|
||||
7: movq %rdx, %rax
|
||||
|
||||
-#ifndef __ASSUME_PRIVATE_FUTEX
|
||||
+#ifndef __ASSUME_FUTEX_CLOCK_REALTIME
|
||||
addq $16, %rsp
|
||||
cfi_adjust_cfa_offset(-16)
|
||||
popq %r14
|
||||
@@ -207,7 +207,7 @@ pthread_rwlock_timedwrlock:
|
||||
cfi_restore(%r12)
|
||||
retq
|
||||
|
||||
-#ifdef __ASSUME_PRIVATE_FUTEX
|
||||
+#ifdef __ASSUME_FUTEX_CLOCK_REALTIME
|
||||
cfi_adjust_cfa_offset(16)
|
||||
cfi_rel_offset(%r12, 8)
|
||||
cfi_rel_offset(%r13, 0)
|
|
@ -1,22 +0,0 @@
|
|||
diff --git a/resolv/res_send.c b/resolv/res_send.c
|
||||
index 97142b7..a001c1e 100644
|
||||
--- a/resolv/res_send.c
|
||||
+++ b/resolv/res_send.c
|
||||
@@ -549,7 +549,7 @@ __libc_res_nsend(res_state statp, const u_char *buf, int buflen,
|
||||
ns, ansp, ansp2, nansp2, resplen2);
|
||||
if (n < 0)
|
||||
return (-1);
|
||||
- if (n == 0 && (buf2 == NULL || resplen2 == 0))
|
||||
+ if (n == 0 && (buf2 == NULL || *resplen2 == 0))
|
||||
goto next_ns;
|
||||
} else {
|
||||
/* Use datagrams. */
|
||||
@@ -559,7 +559,7 @@ __libc_res_nsend(res_state statp, const u_char *buf, int buflen,
|
||||
ansp2, nansp2, resplen2);
|
||||
if (n < 0)
|
||||
return (-1);
|
||||
- if (n == 0 && (buf2 == NULL || resplen2 == 0))
|
||||
+ if (n == 0 && (buf2 == NULL || *resplen2 == 0))
|
||||
goto next_ns;
|
||||
if (v_circuit)
|
||||
// XXX Check whether both requests failed or
|
27
core/glibc/glibc-2.15-lddebug-scopes.patch
Normal file
27
core/glibc/glibc-2.15-lddebug-scopes.patch
Normal file
|
@ -0,0 +1,27 @@
|
|||
From 0c95ab64cb4ec0d22bb222647d9d20c7b4903e38 Mon Sep 17 00:00:00 2001
|
||||
From: Andreas Schwab <schwab@redhat.com>
|
||||
Date: Fri, 7 Oct 2011 09:31:27 +0200
|
||||
Subject: [PATCH] Horrible workaround for horribly broken software
|
||||
|
||||
---
|
||||
elf/rtld.c | 4 +++-
|
||||
1 files changed, 3 insertions(+), 1 deletions(-)
|
||||
|
||||
diff --git a/elf/rtld.c b/elf/rtld.c
|
||||
index 978c609..8422b9f 100644
|
||||
--- a/elf/rtld.c
|
||||
+++ b/elf/rtld.c
|
||||
@@ -1393,7 +1393,9 @@ of this helper program; chances are you did not intend to run this program.\n\
|
||||
char *copy = malloc (len);
|
||||
if (copy == NULL)
|
||||
_dl_fatal_printf ("out of memory\n");
|
||||
- l->l_libname->name = l->l_name = memcpy (copy, dsoname, len);
|
||||
+ l->l_libname->name = memcpy (copy, dsoname, len);
|
||||
+ if (GLRO(dl_debug_mask))
|
||||
+ l->l_name = copy;
|
||||
}
|
||||
|
||||
/* Add the vDSO to the object list. */
|
||||
--
|
||||
1.7.3.4
|
||||
|
184
core/glibc/glibc-2.15-math64crash.patch
Normal file
184
core/glibc/glibc-2.15-math64crash.patch
Normal file
|
@ -0,0 +1,184 @@
|
|||
diff --git a/sysdeps/x86_64/fpu/multiarch/Makefile b/sysdeps/x86_64/fpu/multiarch/Makefile
|
||||
index be68903..a032da8 100644
|
||||
--- a/sysdeps/x86_64/fpu/multiarch/Makefile
|
||||
+++ b/sysdeps/x86_64/fpu/multiarch/Makefile
|
||||
@@ -1,5 +1,5 @@
|
||||
ifeq ($(subdir),math)
|
||||
-libm-sysdep_routines += s_floor-c s_ceil-c s_floorf-c s_ceilf-c \
|
||||
+libm-sysdep_routines += s_floorf-c s_ceilf-c \
|
||||
s_rint-c s_rintf-c s_nearbyint-c s_nearbyintf-c
|
||||
|
||||
ifeq ($(have-mfma4),yes)
|
||||
diff --git a/sysdeps/x86_64/fpu/multiarch/s_ceil-c.c b/sysdeps/x86_64/fpu/multiarch/s_ceil-c.c
|
||||
deleted file mode 100644
|
||||
index 6a5ea3f..0000000
|
||||
--- a/sysdeps/x86_64/fpu/multiarch/s_ceil-c.c
|
||||
+++ /dev/null
|
||||
@@ -1,2 +0,0 @@
|
||||
-#define __ceil __ceil_c
|
||||
-#include <sysdeps/ieee754/dbl-64/wordsize-64/s_ceil.c>
|
||||
diff --git a/sysdeps/x86_64/fpu/multiarch/s_ceil.S b/sysdeps/x86_64/fpu/multiarch/s_ceil.S
|
||||
deleted file mode 100644
|
||||
index d0f8da3..0000000
|
||||
--- a/sysdeps/x86_64/fpu/multiarch/s_ceil.S
|
||||
+++ /dev/null
|
||||
@@ -1,40 +0,0 @@
|
||||
-/* Copyright (C) 2011 Free Software Foundation, Inc.
|
||||
- This file is part of the GNU C Library.
|
||||
- Contributed by Ulrich Drepper <drepper@gmail.come>, 2011.
|
||||
-
|
||||
- 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 <machine/asm.h>
|
||||
-#include <init-arch.h>
|
||||
-
|
||||
-
|
||||
-ENTRY(__ceil)
|
||||
- .type __ceil, @gnu_indirect_function
|
||||
- call __get_cpu_features@plt
|
||||
- movq %rax, %rdx
|
||||
- leaq __ceil_sse41(%rip), %rax
|
||||
- testl $bit_SSE4_1, CPUID_OFFSET+index_SSE4_1(%rdx)
|
||||
- jnz 2f
|
||||
- leaq __ceil_c(%rip), %rax
|
||||
-2: ret
|
||||
-END(__ceil)
|
||||
-weak_alias (__ceil, ceil)
|
||||
-
|
||||
-
|
||||
-ENTRY(__ceil_sse41)
|
||||
- roundsd $2, %xmm0, %xmm0
|
||||
- ret
|
||||
-END(__ceil_sse41)
|
||||
diff --git a/sysdeps/x86_64/fpu/multiarch/s_floor-c.c b/sysdeps/x86_64/fpu/multiarch/s_floor-c.c
|
||||
deleted file mode 100644
|
||||
index 68733b6..0000000
|
||||
--- a/sysdeps/x86_64/fpu/multiarch/s_floor-c.c
|
||||
+++ /dev/null
|
||||
@@ -1,3 +0,0 @@
|
||||
-#undef __floor
|
||||
-#define __floor __floor_c
|
||||
-#include <sysdeps/ieee754/dbl-64/wordsize-64/s_floor.c>
|
||||
diff --git a/sysdeps/x86_64/fpu/multiarch/s_floor.S b/sysdeps/x86_64/fpu/multiarch/s_floor.S
|
||||
deleted file mode 100644
|
||||
index 514ea95..0000000
|
||||
--- a/sysdeps/x86_64/fpu/multiarch/s_floor.S
|
||||
+++ /dev/null
|
||||
@@ -1,40 +0,0 @@
|
||||
-/* Copyright (C) 2011 Free Software Foundation, Inc.
|
||||
- This file is part of the GNU C Library.
|
||||
- Contributed by Ulrich Drepper <drepper@gmail.come>, 2011.
|
||||
-
|
||||
- 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 <machine/asm.h>
|
||||
-#include <init-arch.h>
|
||||
-
|
||||
-
|
||||
-ENTRY(__floor)
|
||||
- .type __floor, @gnu_indirect_function
|
||||
- call __get_cpu_features@plt
|
||||
- movq %rax, %rdx
|
||||
- leaq __floor_sse41(%rip), %rax
|
||||
- testl $bit_SSE4_1, CPUID_OFFSET+index_SSE4_1(%rdx)
|
||||
- jnz 2f
|
||||
- leaq __floor_c(%rip), %rax
|
||||
-2: ret
|
||||
-END(__floor)
|
||||
-weak_alias (__floor, floor)
|
||||
-
|
||||
-
|
||||
-ENTRY(__floor_sse41)
|
||||
- roundsd $1, %xmm0, %xmm0
|
||||
- ret
|
||||
-END(__floor_sse41)
|
||||
diff --git a/sysdeps/x86_64/fpu/multiarch/s_sin.c b/sysdeps/x86_64/fpu/multiarch/s_sin.c
|
||||
deleted file mode 100644
|
||||
index 1ba9dbc..0000000
|
||||
--- a/sysdeps/x86_64/fpu/multiarch/s_sin.c
|
||||
+++ /dev/null
|
||||
@@ -1,31 +0,0 @@
|
||||
-#if defined HAVE_FMA4_SUPPORT || defined HAVE_AVX_SUPPORT
|
||||
-# include <init-arch.h>
|
||||
-# include <math.h>
|
||||
-# undef NAN
|
||||
-
|
||||
-extern double __cos_sse2 (double);
|
||||
-extern double __sin_sse2 (double);
|
||||
-extern double __cos_avx (double);
|
||||
-extern double __sin_avx (double);
|
||||
-# ifdef HAVE_FMA4_SUPPORT
|
||||
-extern double __cos_fma4 (double);
|
||||
-extern double __sin_fma4 (double);
|
||||
-# else
|
||||
-# undef HAS_FMA4
|
||||
-# define HAS_FMA4 0
|
||||
-# define __cos_fma4 ((void *) 0)
|
||||
-# define __sin_fma4 ((void *) 0)
|
||||
-# endif
|
||||
-
|
||||
-libm_ifunc (__cos, HAS_FMA4 ? __cos_fma4 : HAS_AVX ? __cos_avx : __cos_sse2);
|
||||
-weak_alias (__cos, cos)
|
||||
-
|
||||
-libm_ifunc (__sin, HAS_FMA4 ? __sin_fma4 : HAS_AVX ? __sin_avx : __sin_sse2);
|
||||
-weak_alias (__sin, sin)
|
||||
-
|
||||
-# define __cos __cos_sse2
|
||||
-# define __sin __sin_sse2
|
||||
-#endif
|
||||
-
|
||||
-
|
||||
-#include <sysdeps/ieee754/dbl-64/s_sin.c>
|
||||
diff --git a/sysdeps/x86_64/fpu/multiarch/s_tan.c b/sysdeps/x86_64/fpu/multiarch/s_tan.c
|
||||
deleted file mode 100644
|
||||
index 8f6601e..0000000
|
||||
--- a/sysdeps/x86_64/fpu/multiarch/s_tan.c
|
||||
+++ /dev/null
|
||||
@@ -1,21 +0,0 @@
|
||||
-#if defined HAVE_FMA4_SUPPORT || defined HAVE_AVX_SUPPORT
|
||||
-# include <init-arch.h>
|
||||
-# include <math.h>
|
||||
-
|
||||
-extern double __tan_sse2 (double);
|
||||
-extern double __tan_avx (double);
|
||||
-# ifdef HAVE_FMA4_SUPPORT
|
||||
-extern double __tan_fma4 (double);
|
||||
-# else
|
||||
-# undef HAS_FMA4
|
||||
-# define HAS_FMA4 0
|
||||
-# define __tan_fma4 ((void *) 0)
|
||||
-# endif
|
||||
-
|
||||
-libm_ifunc (tan, HAS_FMA4 ? __tan_fma4 : HAS_AVX ? __tan_avx : __tan_sse2);
|
||||
-
|
||||
-# define tan __tan_sse2
|
||||
-#endif
|
||||
-
|
||||
-
|
||||
-#include <sysdeps/ieee754/dbl-64/s_tan.c>
|
229
core/glibc/glibc-2.15-revert-c5a0802a.patch
Normal file
229
core/glibc/glibc-2.15-revert-c5a0802a.patch
Normal file
|
@ -0,0 +1,229 @@
|
|||
diff -rup a/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S b/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S
|
||||
--- a/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S 2011-12-22 18:04:12.937212834 +0000
|
||||
+++ b/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S 2011-12-22 18:04:42.104222278 +0000
|
||||
@@ -137,7 +137,6 @@ __pthread_cond_wait:
|
||||
cmpl $PI_BIT, %eax
|
||||
jne 18f
|
||||
|
||||
-90:
|
||||
movl $(FUTEX_WAIT_REQUEUE_PI|FUTEX_PRIVATE_FLAG), %ecx
|
||||
movl %ebp, %edx
|
||||
xorl %esi, %esi
|
||||
@@ -151,9 +150,6 @@ __pthread_cond_wait:
|
||||
sete 16(%esp)
|
||||
je 19f
|
||||
|
||||
- cmpl $-EAGAIN, %eax
|
||||
- je 91f
|
||||
-
|
||||
/* Normal and PI futexes dont mix. Use normal futex functions only
|
||||
if the kernel does not support the PI futex functions. */
|
||||
cmpl $-ENOSYS, %eax
|
||||
@@ -398,78 +394,6 @@ __pthread_cond_wait:
|
||||
#endif
|
||||
call __lll_unlock_wake
|
||||
jmp 11b
|
||||
-
|
||||
-91:
|
||||
-.LcleanupSTART2:
|
||||
- /* FUTEX_WAIT_REQUEUE_PI returned EAGAIN. We need to
|
||||
- call it again. */
|
||||
-
|
||||
- /* Get internal lock. */
|
||||
- movl $1, %edx
|
||||
- xorl %eax, %eax
|
||||
- LOCK
|
||||
-#if cond_lock == 0
|
||||
- cmpxchgl %edx, (%ebx)
|
||||
-#else
|
||||
- cmpxchgl %edx, cond_lock(%ebx)
|
||||
-#endif
|
||||
- jz 92f
|
||||
-
|
||||
-#if cond_lock == 0
|
||||
- movl %ebx, %edx
|
||||
-#else
|
||||
- leal cond_lock(%ebx), %edx
|
||||
-#endif
|
||||
-#if (LLL_SHARED-LLL_PRIVATE) > 255
|
||||
- xorl %ecx, %ecx
|
||||
-#endif
|
||||
- cmpl $-1, dep_mutex(%ebx)
|
||||
- setne %cl
|
||||
- subl $1, %ecx
|
||||
- andl $(LLL_SHARED-LLL_PRIVATE), %ecx
|
||||
-#if LLL_PRIVATE != 0
|
||||
- addl $LLL_PRIVATE, %ecx
|
||||
-#endif
|
||||
- call __lll_lock_wait
|
||||
-
|
||||
-92:
|
||||
- /* Increment the cond_futex value again, so it can be used as a new
|
||||
- expected value. */
|
||||
- addl $1, cond_futex(%ebx)
|
||||
- movl cond_futex(%ebx), %ebp
|
||||
-
|
||||
- /* Unlock. */
|
||||
- LOCK
|
||||
-#if cond_lock == 0
|
||||
- subl $1, (%ebx)
|
||||
-#else
|
||||
- subl $1, cond_lock(%ebx)
|
||||
-#endif
|
||||
- je 93f
|
||||
-#if cond_lock == 0
|
||||
- movl %ebx, %eax
|
||||
-#else
|
||||
- leal cond_lock(%ebx), %eax
|
||||
-#endif
|
||||
-#if (LLL_SHARED-LLL_PRIVATE) > 255
|
||||
- xorl %ecx, %ecx
|
||||
-#endif
|
||||
- cmpl $-1, dep_mutex(%ebx)
|
||||
- setne %cl
|
||||
- subl $1, %ecx
|
||||
- andl $(LLL_SHARED-LLL_PRIVATE), %ecx
|
||||
-#if LLL_PRIVATE != 0
|
||||
- addl $LLL_PRIVATE, %ecx
|
||||
-#endif
|
||||
- call __lll_unlock_wake
|
||||
-
|
||||
-93:
|
||||
- /* Set the rest of SYS_futex args for FUTEX_WAIT_REQUEUE_PI. */
|
||||
- xorl %ecx, %ecx
|
||||
- movl dep_mutex(%ebx), %edi
|
||||
- jmp 90b
|
||||
-.LcleanupEND2:
|
||||
-
|
||||
.size __pthread_cond_wait, .-__pthread_cond_wait
|
||||
versioned_symbol (libpthread, __pthread_cond_wait, pthread_cond_wait,
|
||||
GLIBC_2_3_2)
|
||||
@@ -642,10 +566,6 @@ __condvar_w_cleanup:
|
||||
.long .LcleanupEND-.Lsub_cond_futex
|
||||
.long __condvar_w_cleanup-.LSTARTCODE
|
||||
.uleb128 0
|
||||
- .long .LcleanupSTART2-.LSTARTCODE
|
||||
- .long .LcleanupEND2-.LcleanupSTART2
|
||||
- .long __condvar_w_cleanup-.LSTARTCODE
|
||||
- .uleb128 0
|
||||
.long .LcallUR-.LSTARTCODE
|
||||
.long .LENDCODE-.LcallUR
|
||||
.long 0
|
||||
Only in b/nptl/sysdeps/unix/sysv/linux/i386/i486: pthread_cond_wait.S.orig
|
||||
diff -rup a/nptl/sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S b/nptl/sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S
|
||||
--- a/nptl/sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S 2011-12-22 18:04:12.941212837 +0000
|
||||
+++ b/nptl/sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S 2011-12-22 18:05:05.155229737 +0000
|
||||
@@ -23,7 +23,6 @@
|
||||
#include <lowlevelcond.h>
|
||||
#include <tcb-offsets.h>
|
||||
#include <pthread-pi-defines.h>
|
||||
-#include <pthread-errnos.h>
|
||||
|
||||
#include <kernel-features.h>
|
||||
|
||||
@@ -137,14 +136,11 @@ __pthread_cond_wait:
|
||||
cmpl $PI_BIT, %eax
|
||||
jne 61f
|
||||
|
||||
-90:
|
||||
movl $(FUTEX_WAIT_REQUEUE_PI|FUTEX_PRIVATE_FLAG), %esi
|
||||
movl $SYS_futex, %eax
|
||||
syscall
|
||||
|
||||
movl $1, %r8d
|
||||
- cmpq $-EAGAIN, %rax
|
||||
- je 91f
|
||||
#ifdef __ASSUME_REQUEUE_PI
|
||||
jmp 62f
|
||||
#else
|
||||
@@ -331,70 +327,6 @@ __pthread_cond_wait:
|
||||
|
||||
13: movq %r10, %rax
|
||||
jmp 14b
|
||||
-
|
||||
-91:
|
||||
-.LcleanupSTART2:
|
||||
- /* FUTEX_WAIT_REQUEUE_PI returned EAGAIN. We need to
|
||||
- call it again. */
|
||||
- movq 8(%rsp), %rdi
|
||||
-
|
||||
- /* Get internal lock. */
|
||||
- movl $1, %esi
|
||||
- xorl %eax, %eax
|
||||
- LOCK
|
||||
-#if cond_lock == 0
|
||||
- cmpxchgl %esi, (%rdi)
|
||||
-#else
|
||||
- cmpxchgl %esi, cond_lock(%rdi)
|
||||
-#endif
|
||||
- jz 92f
|
||||
-
|
||||
-#if cond_lock != 0
|
||||
- addq $cond_lock, %rdi
|
||||
-#endif
|
||||
- cmpq $-1, dep_mutex-cond_lock(%rdi)
|
||||
- movl $LLL_PRIVATE, %eax
|
||||
- movl $LLL_SHARED, %esi
|
||||
- cmovne %eax, %esi
|
||||
- callq __lll_lock_wait
|
||||
-#if cond_lock != 0
|
||||
- subq $cond_lock, %rdi
|
||||
-#endif
|
||||
-92:
|
||||
- /* Increment the cond_futex value again, so it can be used as a new
|
||||
- expected value. */
|
||||
- incl cond_futex(%rdi)
|
||||
- movl cond_futex(%rdi), %edx
|
||||
-
|
||||
- /* Release internal lock. */
|
||||
- LOCK
|
||||
-#if cond_lock == 0
|
||||
- decl (%rdi)
|
||||
-#else
|
||||
- decl cond_lock(%rdi)
|
||||
-#endif
|
||||
- jz 93f
|
||||
-
|
||||
-#if cond_lock != 0
|
||||
- addq $cond_lock, %rdi
|
||||
-#endif
|
||||
- cmpq $-1, dep_mutex-cond_lock(%rdi)
|
||||
- movl $LLL_PRIVATE, %eax
|
||||
- movl $LLL_SHARED, %esi
|
||||
- cmovne %eax, %esi
|
||||
- /* The call preserves %rdx. */
|
||||
- callq __lll_unlock_wake
|
||||
-#if cond_lock != 0
|
||||
- subq $cond_lock, %rdi
|
||||
-#endif
|
||||
-93:
|
||||
- /* Set the rest of SYS_futex args for FUTEX_WAIT_REQUEUE_PI. */
|
||||
- xorq %r10, %r10
|
||||
- movq dep_mutex(%rdi), %r8
|
||||
- leaq cond_futex(%rdi), %rdi
|
||||
- jmp 90b
|
||||
-.LcleanupEND2:
|
||||
-
|
||||
.size __pthread_cond_wait, .-__pthread_cond_wait
|
||||
versioned_symbol (libpthread, __pthread_cond_wait, pthread_cond_wait,
|
||||
GLIBC_2_3_2)
|
||||
@@ -547,15 +479,11 @@ __condvar_cleanup1:
|
||||
.uleb128 .LcleanupSTART-.LSTARTCODE
|
||||
.uleb128 .LcleanupEND-.LcleanupSTART
|
||||
.uleb128 __condvar_cleanup1-.LSTARTCODE
|
||||
- .uleb128 0
|
||||
- .uleb128 .LcleanupSTART2-.LSTARTCODE
|
||||
- .uleb128 .LcleanupEND2-.LcleanupSTART2
|
||||
- .uleb128 __condvar_cleanup1-.LSTARTCODE
|
||||
- .uleb128 0
|
||||
+ .uleb128 0
|
||||
.uleb128 .LcallUR-.LSTARTCODE
|
||||
.uleb128 .LENDCODE-.LcallUR
|
||||
.uleb128 0
|
||||
- .uleb128 0
|
||||
+ .uleb128 0
|
||||
.Lcstend:
|
||||
|
||||
|
||||
Only in b/nptl/sysdeps/unix/sysv/linux/x86_64: pthread_cond_wait.S.orig
|
||||
Only in b/nptl/sysdeps/unix/sysv/linux/x86_64: pthread_cond_wait.S.rej
|
Loading…
Reference in a new issue