[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-devel
Subject:    gcc's atexit problem (Re: Problems with qt-copy in CVS)
From:       Matthias Posseldt <matthi () gmx ! li>
Date:       2001-06-16 18:15:02
[Download RAW message or body]

On Saturday 16 June 2001 13:14, Thorsten Schnebeck wrote:

> Am Samstag, 16. Juni 2001 12:56 schrieb Nils Holland:
> [...]
>
> > /usr/X11R6/lib/libX11.so.6: undefined reference to `atexit'
> > collect2: ld returned 1 exit status
> > make[4]: *** [aclock] Error 1
>
> Hmm, this seems to be the problem mentioned in
>
> http://lists.kde.org/?l=kde-devel&m=99264135212831&w=2
>
> For some unknown reasons I don't have these problems here (so far:) using
> gcc-2.95.3 and glib-2.2.2 too.

After some investigation I found the problem that occurs with the following 
versions:

gcc 2.95.3
glibc 2.2.3

Due to a bug in the compiler/linker/I don't know the linker sometimes doesn't 
link against libc.so.6 which is a text file with the content "GROUP 
(/lib/libc-2.2.3.so /lib/libc_unshared.a)", but directly to 
/lib/libc-2.2.3.so. But only in the nonshared file there is a function 
'atexit' (also fstat, etc.). So sometimes if you link a program to a library 
linked incorrectly the "Undefined reference to 'atexit'" occurs.

On the gcc mailing list there is a patch, I attached it for convenience 
(searched some time for it myself).

After patching and rebuilding your gcc 2.95.3, you have to recompile your 
XFree86 (if you have the error described), then you can compile qt-2.3.1 and 
no more "Undefined references to 'atexit'".

Ciao, Matthias
-- 

Go Open Source and build software that doesn't crash even when it's hit
       by an U.S. Navy submarine piloted by rich civilians.

["01-gcc-2.95.3.patch.gz" (application/x-gzip)]
>> Visit http://master.kde.org/mailman/listinfo/kde-devel#unsub to unsubscribe <<


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic