diff options
Diffstat (limited to 'sys-libs/glibc/files/2.3.4/glibc-2.3.4-fedora-branch-no-force-nontls.patch')
-rw-r--r-- | sys-libs/glibc/files/2.3.4/glibc-2.3.4-fedora-branch-no-force-nontls.patch | 57 |
1 files changed, 57 insertions, 0 deletions
diff --git a/sys-libs/glibc/files/2.3.4/glibc-2.3.4-fedora-branch-no-force-nontls.patch b/sys-libs/glibc/files/2.3.4/glibc-2.3.4-fedora-branch-no-force-nontls.patch new file mode 100644 index 000000000000..ed0c993711f3 --- /dev/null +++ b/sys-libs/glibc/files/2.3.4/glibc-2.3.4-fedora-branch-no-force-nontls.patch @@ -0,0 +1,57 @@ +--- glibc-2.3.3.old/elf/rtld.c 2004-10-26 21:41:41.989117872 -0400 ++++ glibc-2.3.3/elf/rtld.c 2004-10-26 21:45:15.015732904 -0400 +@@ -1087,53 +1087,6 @@ + ++GL(dl_ns)[LM_ID_BASE]._ns_nloaded; + ++GL(dl_load_adds); + +-#if defined(__i386__) +- /* Force non-TLS libraries for glibc 2.0 binaries +- or if a buggy binary references non-TLS errno or h_errno. */ +- if (__builtin_expect (main_map->l_info[DT_NUM + DT_THISPROCNUM +- + DT_VERSIONTAGIDX (DT_VERNEED)] +- == NULL, 0) +- && main_map->l_info[DT_DEBUG]) +- GLRO(dl_osversion) = 0x20205; +- else if ((__builtin_expect (mode, normal) != normal +- || main_map->l_info[ADDRIDX (DT_GNU_LIBLIST)] == NULL) +- /* Only binaries have DT_DEBUG dynamic tags... */ +- && main_map->l_info[DT_DEBUG]) +- { +- /* Workaround for buggy binaries. This doesn't handle buggy +- libraries. */ +- bool buggy = false; +- const ElfW(Sym) *symtab = (const void *) D_PTR (main_map, +- l_info[DT_SYMTAB]); +- const char *strtab = (const void *) D_PTR (main_map, +- l_info[DT_STRTAB]); +- Elf_Symndx symidx; +- for (symidx = main_map->l_buckets[0x6c994f % main_map->l_nbuckets]; +- symidx != STN_UNDEF; +- symidx = main_map->l_chain[symidx]) +- { +- if (__builtin_expect (strcmp (strtab + symtab[symidx].st_name, +- "errno") == 0, 0) +- && ELFW(ST_TYPE) (symtab[symidx].st_info) != STT_TLS) +- buggy = true; +- } +- for (symidx = main_map->l_buckets[0xe5c992f % main_map->l_nbuckets]; +- symidx != STN_UNDEF; +- symidx = main_map->l_chain[symidx]) +- { +- if (__builtin_expect (strcmp (strtab + symtab[symidx].st_name, +- "h_errno") == 0, 0) +- && ELFW(ST_TYPE) (symtab[symidx].st_info) != STT_TLS) +- buggy = true; +- } +- if (__builtin_expect (buggy, false) && GLRO(dl_osversion) > 0x20401) +- { +- GLRO(dl_osversion) = 0x20401; +- _dl_error_printf ("Incorrectly built binary which accesses errno or h_errno directly. Needs to be fixed.\n"); +- } +- } +-#endif +- + /* If LD_USE_LOAD_BIAS env variable has not been seen, default + to not using bias for non-prelinked PIEs and libraries + and using it for executables or prelinked PIEs or libraries. */ + |