diff options
author | Yann E. MORIN" <yann.morin.1998@anciens.enib.fr> | 2009-02-02 22:00:18 +0000 |
---|---|---|
committer | Yann E. MORIN" <yann.morin.1998@anciens.enib.fr> | 2009-02-02 22:00:18 +0000 |
commit | b60a8806c675ffeba75a61a9021f61b858c7a0b6 (patch) | |
tree | 6616365f31ca9b18820afe26afdaa88b67eac7ec /patches/glibc/2_9/400-tests-sandbox-libdl-paths.patch | |
parent | cb8cfd3d80fa3419cae04fc47da2ffd276e416a7 (diff) | |
download | crosstool-ng-b60a8806c675ffeba75a61a9021f61b858c7a0b6.tar.gz crosstool-ng-b60a8806c675ffeba75a61a9021f61b858c7a0b6.tar.bz2 crosstool-ng-b60a8806c675ffeba75a61a9021f61b858c7a0b6.zip |
Add a patchset for glibc 2_9. Vampirised from the gentoo repository.
/trunk/patches/glibc/2_9/500-ppc-glibc-2.9-atomic.patch | 414 414 0 0 ++++++++++
/trunk/patches/glibc/2_9/140-regex-BZ9697.patch | 111 111 0 0 +++
/trunk/patches/glibc/2_9/190-queue-header-updates.patch | 89 89 0 0 ++
/trunk/patches/glibc/2_9/370-hppa_glibc-2.7-hppa-nptl-carlos.patch | 249 249 0 0 ++++++
/trunk/patches/glibc/2_9/450-alpha-glibc-2.5-no-page-header.patch | 32 32 0 0 +
/trunk/patches/glibc/2_9/270-ldbl-nexttowardf.patch | 68 68 0 0 ++
/trunk/patches/glibc/2_9/330-2.3.3-china.patch | 35 35 0 0 +
/trunk/patches/glibc/2_9/340-new-valencian-locale.patch | 120 120 0 0 +++
/trunk/patches/glibc/2_9/410-2.9-fnmatch.patch | 64 64 0 0 ++
/trunk/patches/glibc/2_9/350-2.4-undefine-__i686.patch | 47 47 0 0 +
/trunk/patches/glibc/2_9/160-i386-x86_64-revert-clone-cfi.patch | 53 53 0 0 +
/trunk/patches/glibc/2_9/420-dont-build-timezone.patch | 19 19 0 0 +
/trunk/patches/glibc/2_9/150-regex-BZ697.patch | 28 28 0 0 +
/trunk/patches/glibc/2_9/290-no-inline-gmon.patch | 38 38 0 0 +
/trunk/patches/glibc/2_9/280-section-comments.patch | 29 29 0 0 +
/trunk/patches/glibc/2_9/180-math-tests.patch | 72 72 0 0 ++
/trunk/patches/glibc/2_9/120-_nss_dns_gethostbyaddr2_r-check-and-adjust-the-buffer-alignment.patch | 35 35 0 0 +
/trunk/patches/glibc/2_9/250-resolv-dynamic.patch | 44 44 0 0 +
/trunk/patches/glibc/2_9/300-2.9-check_native-headers.patch | 22 22 0 0 +
/trunk/patches/glibc/2_9/310-2.3.6-fix-pr631.patch | 50 50 0 0 +
/trunk/patches/glibc/2_9/130-add_prio-macros.patch | 26 26 0 0 +
/trunk/patches/glibc/2_9/260-fadvise64_64.patch | 30 30 0 0 +
/trunk/patches/glibc/2_9/440-alpha-glibc-2.4-xstat.patch | 249 249 0 0 ++++++
/trunk/patches/glibc/2_9/170-2.10-dns-no-gethostbyname4.patch | 35 35 0 0 +
/trunk/patches/glibc/2_9/230-2.3.3-localedef-fix-trampoline.patch | 74 74 0 0 ++
/trunk/patches/glibc/2_9/360-2.8-nscd-one-fork.patch | 45 45 0 0 +
/trunk/patches/glibc/2_9/480-alpha-glibc-2.8-cache-shape.patch | 18 18 0 0 +
/trunk/patches/glibc/2_9/210-2.9-strlen-hack.patch | 109 109 0 0 +++
/trunk/patches/glibc/2_9/320-2.9-assume-pipe2.patch | 59 59 0 0 +
/trunk/patches/glibc/2_9/100-ssp-compat.patch | 193 193 0 0 +++++
/trunk/patches/glibc/2_9/110-respect-env-CPPFLAGS.patch | 30 30 0 0 +
/trunk/patches/glibc/2_9/220-manual-no-perl.patch | 29 29 0 0 +
/trunk/patches/glibc/2_9/390-2.3.3_pre20040117-pt_pax.patch | 35 35 0 0 +
/trunk/patches/glibc/2_9/460-alpha-glibc-2.5-no-asm-elf-header.patch | 38 38 0 0 +
/trunk/patches/glibc/2_9/400-tests-sandbox-libdl-paths.patch | 198 198 0 0 +++++
/trunk/patches/glibc/2_9/240-i386-LOAD_PIC_REG.patch | 23 23 0 0 +
/trunk/patches/glibc/2_9/200-awk-in-C-locale.patch | 23 23 0 0 +
/trunk/patches/glibc/2_9/430-2.7-cross-compile-nptl.patch | 57 57 0 0 +
/trunk/patches/glibc/2_9/380-2.3.6-dl_execstack-PaX-support.patch | 71 71 0 0 ++
/trunk/patches/glibc/2_9/490-ptr-mangling.patch | 114 114 0 0 +++
/trunk/patches/glibc/2_9/470-alpha-glibc-2.8-creat.patch | 19 19 0 0 +
41 files changed, 3094 insertions(+)
Diffstat (limited to 'patches/glibc/2_9/400-tests-sandbox-libdl-paths.patch')
-rw-r--r-- | patches/glibc/2_9/400-tests-sandbox-libdl-paths.patch | 198 |
1 files changed, 198 insertions, 0 deletions
diff --git a/patches/glibc/2_9/400-tests-sandbox-libdl-paths.patch b/patches/glibc/2_9/400-tests-sandbox-libdl-paths.patch new file mode 100644 index 00000000..1d3dda4e --- /dev/null +++ b/patches/glibc/2_9/400-tests-sandbox-libdl-paths.patch @@ -0,0 +1,198 @@ +Original patch from: gentoo/src/patchsets/glibc/2.9/3020_all_glibc-tests-sandbox-libdl-paths.patch + +-= BEGIN original header =- +when glibc runs its tests, it does so by invoking the local library loader. +in Gentoo, we build/run inside of our "sandbox" which itself is linked against +libdl (so that it can load libraries and pull out symbols). the trouble +is that when you upgrade from an older glibc to the new one, often times +internal symbols change name or abi. this is normally OK as you cannot use +libc.so from say version 2.3.6 but libpthread.so from say version 2.5, so +we always say "keep all of the glibc libraries from the same build". but +when glibc runs its tests, it uses dynamic paths to point to its new local +copies of libraries. if the test doesnt use libdl, then glibc doesnt add +its path, and when sandbox triggers the loading of libdl, glibc does so +from the host system system. this gets us into the case of all libraries +are from the locally compiled version of glibc except for libdl.so. + +Fix by Wormo + +http://bugs.gentoo.org/56898 + +-= END original header =- + +diff -durN glibc-2_9.orig/grp/tst_fgetgrent.sh glibc-2_9/grp/tst_fgetgrent.sh +--- glibc-2_9.orig/grp/tst_fgetgrent.sh 2001-07-06 06:54:46.000000000 +0200 ++++ glibc-2_9/grp/tst_fgetgrent.sh 2009-02-02 22:01:23.000000000 +0100 +@@ -24,7 +24,8 @@ + rtld_installed_name=$1; shift + + testout=${common_objpfx}/grp/tst_fgetgrent.out +-library_path=${common_objpfx} ++# make sure libdl is also in path in case sandbox is in use ++library_path=${common_objpfx}:${common_objpfx}/dlfcn + + result=0 + +diff -durN glibc-2_9.orig/iconvdata/run-iconv-test.sh glibc-2_9/iconvdata/run-iconv-test.sh +--- glibc-2_9.orig/iconvdata/run-iconv-test.sh 2008-05-15 03:59:44.000000000 +0200 ++++ glibc-2_9/iconvdata/run-iconv-test.sh 2009-02-02 22:01:23.000000000 +0100 +@@ -34,7 +34,7 @@ + export GCONV_PATH + + # We have to have some directories in the library path. +-LIBPATH=$codir:$codir/iconvdata ++LIBPATH=$codir:$codir/iconvdata:$codir/dlfcn + + # How the start the iconv(1) program. + ICONV='$codir/elf/ld.so --library-path $LIBPATH --inhibit-rpath ${from}.so \ +diff -durN glibc-2_9.orig/iconvdata/tst-table.sh glibc-2_9/iconvdata/tst-table.sh +--- glibc-2_9.orig/iconvdata/tst-table.sh 2002-04-24 23:39:35.000000000 +0200 ++++ glibc-2_9/iconvdata/tst-table.sh 2009-02-02 22:01:23.000000000 +0100 +@@ -59,8 +59,11 @@ + irreversible=${charset}.irreversible + fi + ++# make sure libdl is also in path in case sandbox is in use ++library_path=${common_objpfx}:${common_objpfx}/dlfcn ++ + # iconv in one direction. +-${common_objpfx}elf/ld.so --library-path $common_objpfx \ ++${common_objpfx}elf/ld.so --library-path $library_path \ + ${objpfx}tst-table-from ${charset} \ + > ${objpfx}tst-${charset}.table + +diff -durN glibc-2_9.orig/intl/tst-codeset.sh glibc-2_9/intl/tst-codeset.sh +--- glibc-2_9.orig/intl/tst-codeset.sh 2005-04-06 04:18:35.000000000 +0200 ++++ glibc-2_9/intl/tst-codeset.sh 2009-02-02 22:01:23.000000000 +0100 +@@ -37,6 +37,9 @@ + LOCPATH=${common_objpfx}localedata + export LOCPATH + ++# make sure libdl is also in path in case sandbox is in use ++library_path=${common_objpfx}:${common_objpfx}/dlfcn ++ + ${common_objpfx}elf/ld.so --library-path $common_objpfx \ + ${objpfx}tst-codeset > ${objpfx}tst-codeset.out + +diff -durN glibc-2_9.orig/intl/tst-gettext.sh glibc-2_9/intl/tst-gettext.sh +--- glibc-2_9.orig/intl/tst-gettext.sh 2004-08-15 21:28:18.000000000 +0200 ++++ glibc-2_9/intl/tst-gettext.sh 2009-02-02 22:01:23.000000000 +0100 +@@ -51,9 +51,12 @@ + LOCPATH=${common_objpfx}localedata + export LOCPATH + ++# make sure libdl is also in path in case sandbox is in use ++library_path=${common_objpfx}:${common_objpfx}/dlfcn ++ + # Now run the test. + MALLOC_TRACE=$malloc_trace LOCPATH=${objpfx}localedir:$LOCPATH \ +-${common_objpfx}elf/ld.so --library-path $common_objpfx \ ++${common_objpfx}elf/ld.so --library-path $library_path \ + ${objpfx}tst-gettext > ${objpfx}tst-gettext.out ${objpfx}domaindir + + exit $? +diff -durN glibc-2_9.orig/intl/tst-gettext2.sh glibc-2_9/intl/tst-gettext2.sh +--- glibc-2_9.orig/intl/tst-gettext2.sh 2005-05-04 19:54:48.000000000 +0200 ++++ glibc-2_9/intl/tst-gettext2.sh 2009-02-02 22:01:23.000000000 +0100 +@@ -65,8 +65,11 @@ + LOCPATH=${objpfx}domaindir + export LOCPATH + ++# make sure libdl is also in path in case sandbox is in use ++library_path=${common_objpfx}:${common_objpfx}/dlfcn ++ + # Now run the test. +-${common_objpfx}elf/ld.so --library-path $common_objpfx \ ++${common_objpfx}elf/ld.so --library-path $library_path \ + ${objpfx}tst-gettext2 > ${objpfx}tst-gettext2.out ${objpfx}domaindir && + cmp ${objpfx}tst-gettext2.out - <<EOF + String1 - Lang1: 1st string +diff -durN glibc-2_9.orig/intl/tst-translit.sh glibc-2_9/intl/tst-translit.sh +--- glibc-2_9.orig/intl/tst-translit.sh 2005-05-04 19:56:10.000000000 +0200 ++++ glibc-2_9/intl/tst-translit.sh 2009-02-02 22:01:23.000000000 +0100 +@@ -36,7 +36,10 @@ + LOCPATH=${common_objpfx}localedata + export LOCPATH + +-${common_objpfx}elf/ld.so --library-path $common_objpfx \ ++# make sure libdl is also in path in case sandbox is in use ++library_path=${common_objpfx}:${common_objpfx}/dlfcn ++ ++${common_objpfx}elf/ld.so --library-path $library_path \ + ${objpfx}tst-translit > ${objpfx}tst-translit.out ${objpfx}domaindir + + exit $? +diff -durN glibc-2_9.orig/malloc/tst-mtrace.sh glibc-2_9/malloc/tst-mtrace.sh +--- glibc-2_9.orig/malloc/tst-mtrace.sh 2005-10-15 01:40:35.000000000 +0200 ++++ glibc-2_9/malloc/tst-mtrace.sh 2009-02-02 22:01:23.000000000 +0100 +@@ -24,9 +24,12 @@ + status=0 + trap "rm -f ${common_objpfx}malloc/tst-mtrace.leak; exit 1" 1 2 15 + ++# make sure libdl is also in path in case sandbox is in use ++library_path=${common_objpfx}:${common_objpfx}/dlfcn ++ + MALLOC_TRACE=${common_objpfx}malloc/tst-mtrace.leak \ + LOCPATH=${common_objpfx}localedata GCONV_PATH=${common_objpfx}iconvdata \ +-${common_objpfx}elf/ld.so --library-path $common_objpfx \ ++${common_objpfx}elf/ld.so --library-path $library_path \ + ${common_objpfx}malloc/tst-mtrace || status=1 + + if test $status -eq 0 && test -f ${common_objpfx}malloc/mtrace; then +diff -durN glibc-2_9.orig/nptl/tst-tls6.sh glibc-2_9/nptl/tst-tls6.sh +--- glibc-2_9.orig/nptl/tst-tls6.sh 2003-09-03 00:02:59.000000000 +0200 ++++ glibc-2_9/nptl/tst-tls6.sh 2009-02-02 22:01:23.000000000 +0100 +@@ -5,8 +5,8 @@ + rtld_installed_name=$1; shift + logfile=$common_objpfx/nptl/tst-tls6.out + +-# We have to find libc and nptl +-library_path=${common_objpfx}:${common_objpfx}nptl ++# We have to find libc and nptl (also libdl in case sandbox is in use) ++library_path=${common_objpfx}:${common_objpfx}nptl:${common_objpfx}/dlfcn + tst_tls5="${elf_objpfx}${rtld_installed_name} --library-path ${library_path} \ + ${common_objpfx}/nptl/tst-tls5" + +diff -durN glibc-2_9.orig/posix/globtest.sh glibc-2_9/posix/globtest.sh +--- glibc-2_9.orig/posix/globtest.sh 2007-02-14 20:52:33.000000000 +0100 ++++ glibc-2_9/posix/globtest.sh 2009-02-02 22:01:23.000000000 +0100 +@@ -18,7 +18,7 @@ + esac + + # We have to find the libc and the NSS modules. +-library_path=${common_objpfx}:${common_objpfx}nss:${common_objpfx}nis:${common_objpfx}db2:${common_objpfx}hesiod ++library_path=${common_objpfx}:${common_objpfx}nss:${common_objpfx}nis:${common_objpfx}db2:${common_objpfx}hesiod:${common_objpfx}/dlfcn + + # Since we use `sort' we must make sure to use the same locale everywhere. + LC_ALL=C +diff -durN glibc-2_9.orig/posix/tst-getconf.sh glibc-2_9/posix/tst-getconf.sh +--- glibc-2_9.orig/posix/tst-getconf.sh 2002-09-01 13:11:25.000000000 +0200 ++++ glibc-2_9/posix/tst-getconf.sh 2009-02-02 22:01:23.000000000 +0100 +@@ -10,7 +10,10 @@ + else + rtld_installed_name=$1; shift + runit() { +- ${elf_objpfx}${rtld_installed_name} --library-path ${common_objpfx} "$@" ++ ++ # make sure libdl is also in path in case sandbox is in use ++ library_path=${common_objpfx}:${common_objpfx}/dlfcn ++ ${elf_objpfx}${rtld_installed_name} --library-path ${library_path} "$@" + } + fi + +diff -durN glibc-2_9.orig/posix/wordexp-tst.sh glibc-2_9/posix/wordexp-tst.sh +--- glibc-2_9.orig/posix/wordexp-tst.sh 2000-10-20 18:23:30.000000000 +0200 ++++ glibc-2_9/posix/wordexp-tst.sh 2009-02-02 22:01:23.000000000 +0100 +@@ -19,8 +19,11 @@ + " + export IFS + ++# make sure libdl is also in path in case sandbox is in use ++library_path=${common_objpfx}:${common_objpfx}/dlfcn ++ + failed=0 +-${elf_objpfx}${rtld_installed_name} --library-path ${common_objpfx} \ ++${elf_objpfx}${rtld_installed_name} --library-path ${library_path} \ + ${common_objpfx}posix/wordexp-test '$*' > ${testout}1 + cat <<"EOF" | cmp - ${testout}1 >> $logfile || failed=1 + wordexp returned 0 |