about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog12
-rw-r--r--aclocal.m43
-rw-r--r--elf/dl-support.c19
-rw-r--r--sysdeps/generic/libc-tls.c20
4 files changed, 34 insertions, 20 deletions
diff --git a/ChangeLog b/ChangeLog
index 3cc5ca5154..4eb39a2e8d 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,15 @@
+2002-10-17  Roland McGrath  <roland@redhat.com>
+
+	* aclocal.m4 (GLIBC_PROVIDES): Add AC_PROVIDE([_AS_ECHO_N_PREPARE]).
+	Remove AC_LANG(C) call, instead just define([_AC_LANG], [C]).
+
+	* elf/dl-support.c: Move _dl_tls_* variables to ...
+	* sysdeps/generic/libc-tls.c: ... here.
+
+	* elf/dl-close.c (remove_slotinfo): Take new argument.  If false,
+	allow IDX to be one past the current last slotinfo entry.
+	(_dl_close): Pass IMAP->l_init_called for that parameter.
+
 2002-10-07  Andreas Schwab  <schwab@suse.de>
 
 	* aclocal.m4: Fix for autoconf 2.53.
diff --git a/aclocal.m4 b/aclocal.m4
index 4bcd3bf472..2325c73cd8 100644
--- a/aclocal.m4
+++ b/aclocal.m4
@@ -4,6 +4,7 @@ dnl Each sysdep configure.in does GLIBC_PROVIDES first, to avoid any
 dnl AC_REQUIREs or AC_BEFOREs duplicating their code.
 dnl
 define([GLIBC_PROVIDES], [dnl
+AC_PROVIDE([_AS_ECHO_N_PREPARE])dnl
 AC_PROVIDE([AC_PROG_INSTALL])dnl
 AC_PROVIDE([AC_PROG_RANLIB])dnl
 AC_PROVIDE([AC_PROG_CC])dnl
@@ -13,7 +14,7 @@ define([AS_MESSAGE_FD],6)dnl
 AS_INIT()dnl
 m4_divert_text([HEADER-COMMENT],
 [@%:@ This file is generated from configure.in by Autoconf.  DO NOT EDIT!])
-AC_LANG(C)dnl
+define([_AC_LANG], [C])dnl
 ])dnl
 dnl
 dnl Check for a symbol
diff --git a/elf/dl-support.c b/elf/dl-support.c
index 70ab30aedc..b4b185fd97 100644
--- a/elf/dl-support.c
+++ b/elf/dl-support.c
@@ -140,25 +140,6 @@ size_t _dl_phnum;
    At this time it is not anymore a problem to modify the tables.  */
 __libc_lock_define_initialized_recursive (, _dl_load_lock)
 
-#ifdef USE_TLS
-
-/* Highest dtv index currently needed.  */
-size_t _dl_tls_max_dtv_idx;
-/* Flag signalling whether there are gaps in the module ID allocation.  */
-bool _dl_tls_dtv_gaps;
-/* Information about the dtv slots.  */
-struct dtv_slotinfo_list *_dl_tls_dtv_slotinfo_list;
-/* Number of modules in the static TLS block.  */
-size_t _dl_tls_static_nelem;
-/* Size of the static TLS block.  */
-size_t _dl_tls_static_size;
-/* Alignment requirement of the static TLS block.  */
-size_t _dl_tls_static_align;
-
-/* Generation counter for the dtv.  */
-size_t _dl_tls_generation;
-#endif
-
 
 #ifdef HAVE_AUX_VECTOR
 int _dl_clktck;
diff --git a/sysdeps/generic/libc-tls.c b/sysdeps/generic/libc-tls.c
index 3fc89c15b4..df8dc2cbdc 100644
--- a/sysdeps/generic/libc-tls.c
+++ b/sysdeps/generic/libc-tls.c
@@ -22,6 +22,9 @@
 #include <tls.h>
 #include <unistd.h>
 
+#ifdef SHARED
+ #error makefile bug, this file is for static only
+#endif
 
 #ifdef USE_TLS
 extern ElfW(Phdr) *_dl_phdr;
@@ -47,6 +50,23 @@ static struct
 static struct link_map static_map;
 
 
+/* Highest dtv index currently needed.  */
+size_t _dl_tls_max_dtv_idx;
+/* Flag signalling whether there are gaps in the module ID allocation.  */
+bool _dl_tls_dtv_gaps;
+/* Information about the dtv slots.  */
+struct dtv_slotinfo_list *_dl_tls_dtv_slotinfo_list;
+/* Number of modules in the static TLS block.  */
+size_t _dl_tls_static_nelem;
+/* Size of the static TLS block.  */
+size_t _dl_tls_static_size;
+/* Alignment requirement of the static TLS block.  */
+size_t _dl_tls_static_align;
+
+/* Generation counter for the dtv.  */
+size_t _dl_tls_generation;
+
+
 /* Additional definitions needed by TLS initialization.  */
 #ifdef TLS_INIT_HELPER
 TLS_INIT_HELPER