Fix building simulator plugins on Cygwin. A DLL stub containing atexit is linked to the plugins, so give our version a prefix.

git-svn-id: svn://svn.rockbox.org/rockbox/trunk@27893 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
Magnus Holmgren 2010-08-26 15:44:32 +00:00
parent 41bac24abb
commit 1bf5777af2

View file

@ -27,8 +27,12 @@
#include <stdlib.h>
#include "gcc_extensions.h"
/* these are actually implemented in plugin_crt0.c which all plugins link */
extern int atexit(void (*func)(void));
/* these are actually implemented in plugin_crt0.c which all plugins link
*
* the cygwin/mingw shared library stub also defines atexit, so give our
* implementation a prefix */
#define atexit rb_atexit
extern int rb_atexit(void (*func)(void));
extern void exit(int status) NORETURN_ATTR;
/* these don't call the exit handlers */
extern void _exit(int status) NORETURN_ATTR;