bug-glibc
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

unresolved external atexit (possible solution)


From: Marco Mattle
Subject: unresolved external atexit (possible solution)
Date: Mon, 27 Aug 2001 15:47:56 +0200

Hello

I came across some problems regarding 'unresolved external atexit or
atexit@@GLIBC_2.0. Searching on the net was not so refreshing. U. Drepper
responded in a mailing list that it is not a glibc fault. Still there is
this misery.

Actually I tried to compile gdbm-1.8 from sources which was successfully,
but using gdbm in an application results in the error mentioned above. My
workaround was to create an atexit.c file with the contents below

extern int atexit (void (*__func) (void));

void atexit0 ( void ) {
}

int dummy0 ( void ) {
        atexit( atexit0 );
        return 0;
}

and have this file included in the makefile SRCS OBJS etc...
now the linker won't complain about the missing symbol anymore, because it
is used in gdbm... gdbm itself never calls atexit, also other apps I found
out, programs who happened to have this problem don't use atexit thus maybe
results in this mysterious unresolved external problem.

A reply is appreciated, because I don't really know if I did not break
something with this additional steps, until now everything works fine.

Sincerely

Marco Mattle

System: compiled from scratch (no distro)
Kernel 2.4.5 glibc 2.2.3 gcc 2.59.3 on a PII 450





reply via email to

[Prev in Thread] Current Thread [Next in Thread]