summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMagnus Holmgren <magnushol@gmail.com>2010-08-26 15:44:32 +0000
committerMagnus Holmgren <magnushol@gmail.com>2010-08-26 15:44:32 +0000
commit1bf5777af2558ee2767616c29622e15625bde09b (patch)
treef3aeb92aa8420c96ed59c6141b051e93acf2515f
parent41bac24abbbc39b3a78ee54eda53509a7539d4d8 (diff)
downloadrockbox-1bf5777af2558ee2767616c29622e15625bde09b.tar.gz
rockbox-1bf5777af2558ee2767616c29622e15625bde09b.zip
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
-rw-r--r--apps/plugins/lib/pluginlib_exit.h8
1 files changed, 6 insertions, 2 deletions
diff --git a/apps/plugins/lib/pluginlib_exit.h b/apps/plugins/lib/pluginlib_exit.h
index 411d0751d1..8170cf71e9 100644
--- a/apps/plugins/lib/pluginlib_exit.h
+++ b/apps/plugins/lib/pluginlib_exit.h
@@ -27,8 +27,12 @@
27#include <stdlib.h> 27#include <stdlib.h>
28#include "gcc_extensions.h" 28#include "gcc_extensions.h"
29 29
30/* these are actually implemented in plugin_crt0.c which all plugins link */ 30/* these are actually implemented in plugin_crt0.c which all plugins link
31extern int atexit(void (*func)(void)); 31 *
32 * the cygwin/mingw shared library stub also defines atexit, so give our
33 * implementation a prefix */
34#define atexit rb_atexit
35extern int rb_atexit(void (*func)(void));
32extern void exit(int status) NORETURN_ATTR; 36extern void exit(int status) NORETURN_ATTR;
33/* these don't call the exit handlers */ 37/* these don't call the exit handlers */
34extern void _exit(int status) NORETURN_ATTR; 38extern void _exit(int status) NORETURN_ATTR;