Blame SOURCES/glibc-fedora-elf-init-hidden_undef.patch

29e444
* Fri May 29 2003 Jakub Jelinek <jakub@redhat.com> 2.3.2-44
29e444
- make __init_array_start etc. symbols in elf-init.oS hidden undefined
29e444
12745e
diff -Nru glibc-2.17-c758a686/csu/elf-init.c glibc-2.17-c758a686/csu/elf-init.c
12745e
--- glibc-2.17-c758a686/csu/elf-init.c	2012-06-05 07:42:49.000000000 -0600
12745e
+++ glibc-2.17-c758a686/csu/elf-init.c	2012-06-07 12:15:21.570319597 -0600
29e444
@@ -63,6 +63,23 @@ extern void (*__init_array_end []) (int,
29e444
 extern void (*__fini_array_start []) (void) attribute_hidden;
29e444
 extern void (*__fini_array_end []) (void) attribute_hidden;
29e444
 
29e444
+#if defined HAVE_VISIBILITY_ATTRIBUTE \
29e444
+    && (defined SHARED || defined LIBC_NONSHARED)
29e444
+# define hidden_undef_2(x) #x
29e444
+# define hidden_undef_1(x) hidden_undef_2 (x)
29e444
+# define hidden_undef(x) \
29e444
+  __asm (hidden_undef_1 (ASM_GLOBAL_DIRECTIVE) " " #x); \
29e444
+  __asm (".hidden " #x);
29e444
+#else
29e444
+# define hidden_undef(x)
29e444
+#endif
29e444
+
29e444
+hidden_undef (__preinit_array_start)
29e444
+hidden_undef (__preinit_array_end)
29e444
+hidden_undef (__init_array_start)
29e444
+hidden_undef (__init_array_end)
29e444
+hidden_undef (__fini_array_start)
29e444
+hidden_undef (__fini_array_end)
29e444
 
29e444
 /* These function symbols are provided for the .init/.fini section entry
29e444
    points automagically by the linker.  */