public inbox for libc-hacker@sourceware.org
 help / color / mirror / Atom feed
From: Andreas Jaeger <aj@suse.de>
To: GNU libc hacker <libc-hacker@sources.redhat.com>
Subject: Fix _exit for Linux
Date: Sun, 15 Sep 2002 20:40:00 -0000	[thread overview]
Message-ID: <u8lm62bo1p.fsf@gromit.moeb> (raw)


Building glibc with GCC 3.3 CVS I get these errors:

/opt/gcc/3.3-devel/bin/gcc -nostdlib -nostartfiles -o /builds/glibc/gcc-3.3/iconv/iconvconfig  -Wl,-dynamic-linker=/usr/src/test/glibc-2.3/lib/ld-linux.so.2   -Wl,-z,combreloc /builds/glibc/gcc-3.3/csu/crt1.o /builds/glibc/gcc-3.3/csu/crti.o `/opt/gcc/3.3-devel/bin/gcc --print-file-name=crtbegin.o` /builds/glibc/gcc-3.3/iconv/iconvconfig.o /builds/glibc/gcc-3.3/iconv/strtab.o /builds/glibc/gcc-3.3/iconv/xmalloc.o  -Wl,-rpath-link=/builds/glibc/gcc-3.3:/builds/glibc/gcc-3.3/math:/builds/glibc/gcc-3.3/elf:/builds/glibc/gcc-3.3/dlfcn:/builds/glibc/gcc-3.3/nss:/builds/glibc/gcc-3.3/nis:/builds/glibc/gcc-3.3/rt:/builds/glibc/gcc-3.3/resolv:/builds/glibc/gcc-3.3/crypt:/builds/glibc/gcc-3.3/linuxthreads /builds/glibc/gcc-3.3/libc.so.6 /builds/glibc/gcc-3.3/libc_nonshared.a -lgcc `/opt/gcc/3.3-devel/bin/gcc --print-file-name=crtend.o` /builds/glibc/gcc-3.3/csu/crtn.o
/builds/glibc/gcc-3.3/libc.so.6(.data+0xb2c): multiple definition of `__ctype_toupper@GLIBC_2.0'
/builds/glibc/gcc-3.3/libc.so.6(*IND*+0x0): multiple definition of `__ctype32_toupper@GLIBC_2.2'
/builds/glibc/gcc-3.3/libc.so.6(.data+0xb34): first defined here
/builds/glibc/gcc-3.3/libc.so.6(.data+0xb30): multiple definition of `__ctype32_tolower@GLIBC_2.2'
/builds/glibc/gcc-3.3/libc.so.6(.data+0xb20): multiple definition of `__ctype_b@GLIBC_2.0'
/builds/glibc/gcc-3.3/libc.so.6(*IND*+0x0): multiple definition of `__ctype_tolower@GLIBC_2.0'
/builds/glibc/gcc-3.3/libc.so.6(.data+0xb28): first defined here
/builds/glibc/gcc-3.3/libc.so.6(.data+0xb24): multiple definition of `__ctype32_b@GLIBC_2.0'
/builds/glibc/gcc-3.3/libc.so.6: undefined reference to `__GI__exit'
collect2: ld returned 1 exit status
make[2]: *** [/builds/glibc/gcc-3.3/iconv/iconvconfig] Error 1
make[2]: Leaving directory `/usr/src/cvs/libc/iconv'

__GI__exit comes from sysdeps/unix/sysv/linux/i386/clone.S:
	call	HIDDEN_JUMPTARGET (_exit)

The new _exit code needs the right aliases.  I've changed i386/_exit.S
also to use the macros.

Ok to commit the appended patch?

Andreas

2002-09-16  Andreas Jaeger  <aj@suse.de>

	* sysdeps/unix/sysv/linux/_exit.c: Add hidden alias and weak_alias
	to _Exit.
	* sysdeps/unix/sysv/linux/i386/_exit.S: Likewise.

============================================================
Index: sysdeps/unix/sysv/linux/i386/_exit.S
--- sysdeps/unix/sysv/linux/i386/_exit.S	15 Sep 2002 02:28:28 -0000	1.1
+++ sysdeps/unix/sysv/linux/i386/_exit.S	16 Sep 2002 03:39:31 -0000
@@ -38,6 +38,5 @@ _exit:
 	hlt
 	.size	_exit,.-_exit
 
-	.globl	_Exit
-	.weak	_Exit
-_Exit	= _exit
+libc_hidden_def (_exit)
+weak_alias (_exit, _Exit)
============================================================
Index: sysdeps/unix/sysv/linux/_exit.c
--- sysdeps/unix/sysv/linux/_exit.c	15 Sep 2002 02:27:40 -0000	1.1
+++ sysdeps/unix/sysv/linux/_exit.c	16 Sep 2002 03:39:31 -0000
@@ -36,3 +36,5 @@ _exit (status)
       ABORT_INSTRUCTION;
     }
 }
+libc_hidden_def (_exit)
+weak_alias (_exit, _Exit)

-- 
 Andreas Jaeger
  SuSE Labs aj@suse.de
   private aj@arthur.inka.de
    http://www.suse.de/~aj

             reply	other threads:[~2002-09-16  3:40 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-09-15 20:40 Andreas Jaeger [this message]
2002-09-15 22:11 ` Ulrich Drepper
2002-09-15 23:56 ` Roland McGrath
2002-09-16  0:10   ` Ulrich Drepper
2002-09-16  0:36     ` Roland McGrath
2002-09-16  0:45       ` Ulrich Drepper
2002-09-16  9:46 ` Alexandre Oliva
2002-09-16  9:37   ` Andreas Jaeger
2002-09-16  9:52     ` Alexandre Oliva
2002-09-16  9:54     ` Jakub Jelinek
2002-09-16 10:14       ` Ulrich Drepper
2002-09-24 20:24         ` Alexandre Oliva
2002-09-24 20:28           ` Roland McGrath
2002-09-24 20:35             ` Ulrich Drepper
2002-09-24 21:08               ` Roland McGrath
2002-09-24 21:53                 ` Ulrich Drepper
2002-09-24 22:02                   ` Roland McGrath
2002-09-24 21:55                 ` Alexandre Oliva
2002-09-24 22:01                   ` Roland McGrath
2002-09-25 10:27               ` Andreas Jaeger

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=u8lm62bo1p.fsf@gromit.moeb \
    --to=aj@suse.de \
    --cc=libc-hacker@sources.redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).