diff --git a/polymer/eduke32/build/include/mutex.h b/polymer/eduke32/build/include/mutex.h index 4582eef91..987a141bd 100644 --- a/polymer/eduke32/build/include/mutex.h +++ b/polymer/eduke32/build/include/mutex.h @@ -3,11 +3,9 @@ /* Mutual exclusion mechanism wrappers for the different platforms */ -#if defined(_WIN32) +#ifdef RENDERTYPEWIN # include # include -#elif !defined GEKKO -# include #else # include "sdl_inc.h" #endif @@ -16,10 +14,8 @@ extern "C" { #endif -#if defined(_WIN32) +#ifdef RENDERTYPEWIN typedef HANDLE mutex_t; -#elif !defined GEKKO -typedef pthread_mutex_t mutex_t; #else /* PK: I don't like pointer typedefs, but SDL_CreateMutex() _returns_ one, * so we're out of luck with our interface. */ diff --git a/polymer/eduke32/build/src/mutex.c b/polymer/eduke32/build/src/mutex.c index 6be0e323b..9d6e4ed6f 100644 --- a/polymer/eduke32/build/src/mutex.c +++ b/polymer/eduke32/build/src/mutex.c @@ -3,11 +3,9 @@ int32_t mutex_init(mutex_t *mutex) { -#ifdef _WIN32 +#ifdef RENDERTYPEWIN *mutex = CreateMutex(0, FALSE, 0); return (*mutex == 0); -#elif !defined GEKKO - return pthread_mutex_init(mutex, NULL); #else if (mutex) { @@ -21,10 +19,8 @@ int32_t mutex_init(mutex_t *mutex) int32_t mutex_lock(mutex_t *mutex) { -#ifdef _WIN32 +#ifdef RENDERTYPEWIN return (WaitForSingleObject(*mutex, INFINITE) == WAIT_FAILED); -#elif !defined GEKKO - return pthread_mutex_lock(mutex); #else return SDL_LockMutex(*mutex); #endif @@ -32,10 +28,8 @@ int32_t mutex_lock(mutex_t *mutex) int32_t mutex_unlock(mutex_t *mutex) { -#ifdef _WIN32 +#ifdef RENDERTYPEWIN return (ReleaseMutex(*mutex) == 0); -#elif !defined GEKKO - return pthread_mutex_unlock(mutex); #else return SDL_UnlockMutex(*mutex); #endif