SHA256
1
0
forked from pool/glibc
glibc/glibc-2.3.90-noversion.diff
Andreas Schwab d2f37bcdab Accepting request 249235 from home:Andreas_Schwab:glibc
- Update to glibc 2.20 release.
  * Reverted change of ABI data structures for s390 and s390x
  * Support for file description locks is added to systems running the
    Linux kernel
  * Optimized strchr implementation for AArch64
  * The minimum Linux kernel version that this version of the GNU C Library
    can be used with is 2.6.32
  * Running the testsuite no longer terminates as soon as a test fails
  * The am33 port, which had not worked for several years, has been removed
    from ports.
  * The _BSD_SOURCE and _SVID_SOURCE feature test macros are no longer
    supported; they now act the same as _DEFAULT_SOURCE (but generate a
    warning)
  * Optimized strcmp implementation for ARMv7
  * Added support for TX lock elision of pthread mutexes on s390 and s390x
  * All supported architectures now use the main glibc sysdeps directory
    instead of some being in a separate "ports" directory
  * The NPTL implementation of POSIX pthreads is no longer an "add-on"
  * Locale names, including those obtained from environment variables (LANG
    and the LC_* variables), are more tightly checked for proper syntax
  * On x86-64, the dynamic linker's lazy-binding support is now compatible
    with application code using Intel MPX instructions
- Patches from upstream removed
  * nss-dns-memleak.patch
  * sin-sign.patch
  * pldd-wait-ptrace-stop.patch
  * nscd-track-startup-failures.patch
  * powerpc-opt-power8.patch
  * check-pf-alloca.patch
  * getaddrinfo-uninit-result.patch

OBS-URL: https://build.opensuse.org/request/show/249235
OBS-URL: https://build.opensuse.org/package/show/Base:System/glibc?expand=0&rev=387
2014-09-15 10:37:45 +00:00

58 lines
1.7 KiB
Diff

Index: glibc-2.19.90/elf/rtld.c
===================================================================
--- glibc-2.19.90.orig/elf/rtld.c
+++ glibc-2.19.90/elf/rtld.c
@@ -1740,6 +1740,52 @@ ERROR: ld.so: object '%s' cannot be load
}
}
+#if defined(__i386__)
+ /*
+ * Modifications by Red Hat Software
+ *
+ * Deal with the broken binaries from the non-versioned ages of glibc.
+ * If a binary does not have version information enabled, we assume that
+ * it is a glibc 2.0 binary and we load a compatibility library to try to
+ * overcome binary incompatibilities.
+ * Blame: gafton@redhat.com
+ */
+#define LIB_NOVERSION "/lib/obsolete/noversion/libNoVersion.so.1"
+
+ if (__glibc_unlikely (main_map->l_info[DT_NUM + DT_THISPROCNUM
+ + DT_VERSIONTAGIDX (DT_VERNEED)]
+ == NULL)
+ && (main_map->l_info[DT_DEBUG] != 0
+ || !(GLRO(dl_debug_mask) & DL_DEBUG_PRELINK)))
+ {
+ struct stat test_st;
+ int test_fd;
+ bool can_load;
+
+ HP_TIMING_NOW (start);
+
+ can_load = true;
+ test_fd = __open (LIB_NOVERSION, O_RDONLY);
+ if (test_fd < 0)
+ can_load = false;
+ else
+ {
+ if (__fxstat (_STAT_VER, test_fd, &test_st) < 0
+ || test_st.st_size == 0)
+ can_load = false;
+ __close(test_fd);
+ }
+
+ if (can_load)
+ npreloads += do_preload (LIB_NOVERSION, main_map,
+ "nonversioned binary");
+
+ HP_TIMING_NOW (stop);
+ HP_TIMING_DIFF (diff, start, stop);
+ HP_TIMING_ACCUM_NT (load_time, diff);
+ }
+#endif
+
if (__glibc_unlikely (*first_preload != NULL))
{
/* Set up PRELOADS with a vector of the preloaded libraries. */