aboutsummaryrefslogtreecommitdiff
path: root/sysdeps/generic/dl-cache.c
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>2002-01-31 03:41:25 +0000
committerUlrich Drepper <drepper@redhat.com>2002-01-31 03:41:25 +0000
commitd6b5d570a3255d8dc80e07c3674594574cd98fe7 (patch)
tree36e05b0d065614559820d2a4f43bb1076ea5cfa1 /sysdeps/generic/dl-cache.c
parent1b4575aefaaa43adfed4658f7d66de587f12120e (diff)
downloadglibc-d6b5d570a3255d8dc80e07c3674594574cd98fe7.zip
glibc-d6b5d570a3255d8dc80e07c3674594574cd98fe7.tar.gz
glibc-d6b5d570a3255d8dc80e07c3674594574cd98fe7.tar.bz2
Update.
2002-01-30 Ulrich Drepper <drepper@redhat.com> * Versions.def [ld]: Add GLIBC_2.3. * elf/dl-addr.c: Move global variables for SHARED code in struct _rtld_global. Export this struct, remove all exports for the signal variables. * elf/dl-close.c: Likewise. * elf/dl-conflict.c: Likewise. * elf/dl-debug.c: Likewise. * elf/dl-deps.c: Likewise. * elf/dl-dst.h: Likewise. * elf/dl-error.c: Likewise. * elf/dl-fini.c: Likewise. * elf/dl-init.c: Likewise. * elf/dl-iteratephdr.c: Likewise. * elf/dl-libc.c: Likewise. * elf/dl-load.c: Likewise. * elf/dl-lookup.c: Likewise. * elf/dl-minimal.c: Likewise. * elf/dl-object.c: Likewise. * elf/dl-open.c: Likewise. * elf/dl-profile.c: Likewise. * elf/dl-profstub.c: Likewise. * elf/dl-reloc.c: Likewise. * elf/dl-runtime.c: Likewise. * elf/dl-support.c: Likewise. * elf/dl-sym.c: Likewise. * elf/dl-version.c: Likewise. * elf/do-lookup.h: Likewise. * elf/do-rel.h: Likewise. * elf/dynamic-link.h: Likewise. * elf/rtld.c: Likewise. * sysdeps/generic/dl-cache.c: Likewise. * sysdeps/generic/dl-sysdep.c: Likewise. * sysdeps/generic/ldsodefs.h: Likewise. * sysdeps/generic/libc-start.c: Likewise. * sysdeps/i386/dl-machine.h: Likewise. * sysdeps/ia64/dl-fptr.c: Likewise. * sysdeps/ia64/dl-machine.h: Likewise. * sysdeps/unix/sysv/linux/dl-librecon.h: Likewise. * sysdeps/unix/sysv/linux/dl-origin.c: Likewise. * sysdeps/unix/sysv/linux/dl-osinfo.h: Likewise. * sysdeps/unix/sysv/linux/getclktck.c: Likewise. * sysdeps/unix/sysv/linux/getpagesize.c: Likewise. * sysdeps/unix/sysv/linux/i386/dl-librecon.h: Likewise. * sysdeps/unix/sysv/linux/ia64/dl-static.c: Likewise. * sysdeps/unix/sysv/linux/ia64/getpagesize.c: Likewise. * malloc/thread-m.h: Spinlock definitions for x86/x86_64.
Diffstat (limited to 'sysdeps/generic/dl-cache.c')
-rw-r--r--sysdeps/generic/dl-cache.c17
1 files changed, 9 insertions, 8 deletions
diff --git a/sysdeps/generic/dl-cache.c b/sysdeps/generic/dl-cache.c
index 6ed26a3..7ba00e4 100644
--- a/sysdeps/generic/dl-cache.c
+++ b/sysdeps/generic/dl-cache.c
@@ -1,5 +1,5 @@
/* Support for reading /etc/ld.so.cache files written by Linux ldconfig.
- Copyright (C) 1996,1997,1998,1999,2000,2001 Free Software Foundation, Inc.
+ Copyright (C) 1996,1997,1998,1999,2000,2001,2002 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
@@ -26,8 +26,6 @@
#include <stdio-common/_itoa.h>
-extern const char *_dl_platform;
-
#ifndef _DL_PLATFORMS_COUNT
# define _DL_PLATFORMS_COUNT 0
#endif
@@ -154,7 +152,7 @@ _dl_load_cache_lookup (const char *name)
const char *best;
/* Print a message if the loading of libs is traced. */
- if (__builtin_expect (_dl_debug_mask & DL_DEBUG_LIBS, 0))
+ if (__builtin_expect (GL(dl_debug_mask) & DL_DEBUG_LIBS, 0))
_dl_debug_printf (" search cache=%s\n", LD_SO_CACHE);
if (cache == NULL)
@@ -213,7 +211,9 @@ _dl_load_cache_lookup (const char *name)
/* This file ends in static libraries where we don't have a hwcap. */
unsigned long int *hwcap;
uint64_t platform;
+#ifndef SHARED
weak_extern (_dl_hwcap);
+#endif
/* This is where the strings start. */
cache_data = (const char *) cache_new;
@@ -221,14 +221,15 @@ _dl_load_cache_lookup (const char *name)
/* Now we can compute how large the string table is. */
cache_data_size = (const char *) cache + cachesize - cache_data;
- hwcap = &_dl_hwcap;
- platform = _dl_string_platform (_dl_platform);
+ hwcap = &GL(dl_hwcap);
+ platform = _dl_string_platform (GL(dl_platform));
if (platform != -1)
platform = 1ULL << platform;
/* Only accept hwcap if it's for the right platform. */
#define HWCAP_CHECK \
- if (_dl_osversion && cache_new->libs[middle].osversion > _dl_osversion) \
+ if (GL(dl_osversion) \
+ && cache_new->libs[middle].osversion > GL(dl_osversion)) \
continue; \
if (_DL_PLATFORMS_COUNT && platform != -1 \
&& (lib->hwcap & _DL_HWCAP_PLATFORM) != 0 \
@@ -253,7 +254,7 @@ _dl_load_cache_lookup (const char *name)
}
/* Print our result if wanted. */
- if (__builtin_expect (_dl_debug_mask & DL_DEBUG_LIBS, 0) && best != NULL)
+ if (__builtin_expect (GL(dl_debug_mask) & DL_DEBUG_LIBS, 0) && best != NULL)
_dl_debug_printf (" trying file=%s\n", best);
return best;