aboutsummaryrefslogtreecommitdiff
path: root/sysdeps
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>2000-04-01 17:43:53 +0000
committerUlrich Drepper <drepper@redhat.com>2000-04-01 17:43:53 +0000
commit0adb8e479b6222c81376575bbe2d1b9b4f7e03cd (patch)
treef6c76374eb601eb58e853cc6d1c88d065244ceb0 /sysdeps
parent6674e127c93b0ed04a44c78b98ec9c76c71b49c8 (diff)
downloadglibc-0adb8e479b6222c81376575bbe2d1b9b4f7e03cd.zip
glibc-0adb8e479b6222c81376575bbe2d1b9b4f7e03cd.tar.gz
glibc-0adb8e479b6222c81376575bbe2d1b9b4f7e03cd.tar.bz2
Update.
2000-04-01 Ulrich Drepper <drepper@redhat.com> * sysdeps/unix/sysv/linux/init-first.c (init): Add code from former init-first.h. Initialize __libc_multiple_libcs.
Diffstat (limited to 'sysdeps')
-rw-r--r--sysdeps/unix/sysv/linux/init-first.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/sysdeps/unix/sysv/linux/init-first.c b/sysdeps/unix/sysv/linux/init-first.c
index 94d2749..9f58d9c 100644
--- a/sysdeps/unix/sysv/linux/init-first.c
+++ b/sysdeps/unix/sysv/linux/init-first.c
@@ -58,6 +58,12 @@ static void
init (int argc, char **argv, char **envp)
{
extern void __getopt_clean_environment (char **);
+ /* The next variable is only here to work around a bug in gcc <= 2.7.2.2.
+ If the address would be taken inside the expression the optimizer
+ would try to be too smart and throws it away. Grrr. */
+ int *dummy_addr = &_dl_starting_up;
+
+ __libc_multiple_libcs = dummy_addr && !_dl_starting_up;
/* Make sure we don't initialize twice. */
if (!__libc_multiple_libcs)