summaryrefslogtreecommitdiffstatshomepage
path: root/src
diff options
context:
space:
mode:
author R. Belmont <rb6502@users.noreply.github.com>2011-07-28 01:51:24 +0000
committer R. Belmont <rb6502@users.noreply.github.com>2011-07-28 01:51:24 +0000
commit0c0093842af04738f3046a5a2bc8e8538727ca78 (patch)
tree4a9cf853917d8c12d57e13345d29bb6d97815649 /src
parentb7f7a187b74d3f205ed6689b2305c1475d433923 (diff)
cothreads: fixed to run on PowerPC Mac OS X [R. Belmont]
Diffstat (limited to 'src')
-rw-r--r--src/lib/cothread/ppc.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/lib/cothread/ppc.c b/src/lib/cothread/ppc.c
index 637ad426ada..5640ad8d2cb 100644
--- a/src/lib/cothread/ppc.c
+++ b/src/lib/cothread/ppc.c
@@ -13,7 +13,7 @@ floating-point and AltiVec save/restore */
#include <stdint.h>
#include <string.h>
-#define LIBCO_MPROTECT defined(__unix__) && !defined(LIBCO_PPC_ASM)
+#define LIBCO_MPROTECT (defined(__unix__) && !defined(LIBCO_PPC_ASM)) || defined(SDLMAME_MACOSX)
#if LIBCO_MPROTECT
#include <unistd.h>
@@ -46,10 +46,14 @@ static thread_local cothread_t co_active_handle = 0;
/* Whether function calls are indirect through a descriptor,
or are directly to function */
#ifndef LIBCO_PPCDESC
+#ifdef SDLMAME_MACOSX
+ #define LIBCO_PPCDESC 0
+#else
#if !defined(_CALL_SYSV) && (defined(_CALL_AIX) || defined(_CALL_AIXDESC) || defined(LIBCO_PPC64))
#define LIBCO_PPCDESC 1
#endif
#endif
+#endif
#ifdef LIBCO_PPC_ASM