aboutsummaryrefslogtreecommitdiff
path: root/libc-symbols.h
diff options
context:
space:
mode:
authorRoland McGrath <roland@gnu.org>1995-04-12 01:03:38 +0000
committerRoland McGrath <roland@gnu.org>1995-04-12 01:03:38 +0000
commit53afa8d96790cce8fd0d0ce71307bc7ae31c15fb (patch)
treeca8c58bb02b0d0fccc45e63708a775836c1cbe7e /libc-symbols.h
parent217d85b9c89bc7d6e2c2db7fa93238a6b6f12d73 (diff)
downloadglibc-53afa8d96790cce8fd0d0ce71307bc7ae31c15fb.zip
glibc-53afa8d96790cce8fd0d0ce71307bc7ae31c15fb.tar.gz
glibc-53afa8d96790cce8fd0d0ce71307bc7ae31c15fb.tar.bz2
Tue Apr 11 20:38:55 1995 Roland McGrath <roland@churchy.gnu.ai.mit.edu>cvs/libc-950411
* sysdeps/i386/add_n.S [PIC]: Use self-call to avoid generating reloc. * sysdeps/i386/sub_n.S [PIC]: Likewise. * libc-symbols.h (_elf_set_element) [PIC]: Don't make the element word `const'. * Makeconfig (CPPFLAGS, CFLAGS): Fix swapped references to $(foo-$(suffix $@)). * manual/Makefile (chapters-incl): Filter out summary.texi.
Diffstat (limited to 'libc-symbols.h')
-rw-r--r--libc-symbols.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/libc-symbols.h b/libc-symbols.h
index 83773bf..be88e76 100644
--- a/libc-symbols.h
+++ b/libc-symbols.h
@@ -153,9 +153,17 @@ Cambridge, MA 02139, USA. */
/* These are all done the same way in ELF.
There is a new section created for each set. */
+#ifdef PIC
+/* When building a shared library, make the set section writable,
+ because it will need to be relocated at run time anyway. */
+#define _elf_set_element(set, symbol) \
+ static const void *__elf_set_##set##_element_##symbol##__ \
+ __attribute__ ((section (#set))) = &(symbol)
+#else
#define _elf_set_element(set, symbol) \
static const void *const __elf_set_##set##_element_##symbol##__ \
__attribute__ ((section (#set))) = &(symbol)
+#endif
/* Define SET as a symbol set. This may be required (it is in a.out) to
be able to use the set's contents. */