about summary refs log tree commit diff
path: root/elf/libc_early_init.c
diff options
context:
space:
mode:
Diffstat (limited to 'elf/libc_early_init.c')
-rw-r--r--elf/libc_early_init.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/elf/libc_early_init.c b/elf/libc_early_init.c
index 725ab2f811..28c6adca10 100644
--- a/elf/libc_early_init.c
+++ b/elf/libc_early_init.c
@@ -18,8 +18,13 @@
 
 #include <ctype.h>
 #include <libc-early-init.h>
+#include <libc-internal.h>
 #include <sys/single_threaded.h>
 
+#ifdef SHARED
+_Bool __libc_initial;
+#endif
+
 void
 __libc_early_init (_Bool initial)
 {
@@ -28,4 +33,8 @@ __libc_early_init (_Bool initial)
 
   /* Only the outer namespace is marked as single-threaded.  */
   __libc_single_threaded = initial;
+
+#ifdef SHARED
+  __libc_initial = initial;
+#endif
 }