[ILUG] glibc problem

Dave Neary dave.neary at palamon.ie
Thu Sep 20 18:26:19 IST 2001


Hi all,

Has anyone else had issues with a RedHat glibc (2.2.2-10)? Mine doesn't
seem to define atexit(3), or doesn't define it properly... I'm just
wondering whether I've messed something up, or this is something I
should tell redhat about - I haven't found anything in their errata.

The following program shows it up, if the problem's there - this came
about from upgrading my glibc from an older (2.1) glibc, so there may be
confusion as to what's defining what.
--- test_atexit.c ---
#include <stdlib.h>
#include <stdio.h>

void my_exit(void)
{
	printf("Exitting now.\n");
}
int main(void)
{
	atexit(my_exit);
	return 0;
}
--- EOF ---

nm /lib/i686/libc.so.6 | grep atexit  
gives
00030420 T __cxa_atexit
00030514 t __dyn_atexit
00129b8c ? __elf_set___libc_atexit_element__cleanup__
00129b8c a __start___libc_atexit
00129b90 a __stop___libc_atexit
0012c160 b added_atexit_handler.0
00030514 T atexit at GLIBC_2.0
           ^^^^^^^^^^^^^^^^^
I think the last line's the important one. Somehow it hasn't defined
atexit, but only atexit at GLIBC_2.0 - I don't know what this all means -
any of you have any idea? If there's something wrong here, there could
be something wrong elsewhere that I haven't spotted, so I'd kind of like
to figure it out :)

Thanks for the help,
Dave.

-- 
David Neary,               E-Mail dave.neary at palamon.ie
Palamon Technologies Ltd.  Phone +353-1-634-5059




More information about the ILUG mailing list