diff --git a/src/SDL_loadso.c b/src/SDL_loadso.c index 8996bfe4c..b38120743 100644 --- a/src/SDL_loadso.c +++ b/src/SDL_loadso.c @@ -37,6 +37,7 @@ static char rcsid = # include #elif defined(macintosh) # include +#define OLDP2C 1 # include # include # include diff --git a/src/audio/macrom/SDL_romaudio.c b/src/audio/macrom/SDL_romaudio.c index 2026d933a..8dc8a8f43 100644 --- a/src/audio/macrom/SDL_romaudio.c +++ b/src/audio/macrom/SDL_romaudio.c @@ -42,6 +42,9 @@ static char rcsid = #if !defined(NewSndCallBackProc) /* avoid circular redefinition... */ #define NewSndCallBackUPP NewSndCallBackProc #endif +#if !defined(NewSndCallBackUPP) +#define NewSndCallBackUPP NewSndCallBackProc +#endif #endif #include "SDL_endian.h" diff --git a/src/joystick/win32/SDL_mmjoystick.c b/src/joystick/win32/SDL_mmjoystick.c index 791105ed2..a5cafad52 100644 --- a/src/joystick/win32/SDL_mmjoystick.c +++ b/src/joystick/win32/SDL_mmjoystick.c @@ -87,7 +87,7 @@ static char *GetJoystickName(int index, const char *szRegKey) unsigned char regvalue[256]; unsigned char regname[256]; - sprintf(regkey, "%s\\%s\\%s", + sprintf((char *) regkey, "%s\\%s\\%s", REGSTR_PATH_JOYCONFIG, szRegKey, REGSTR_KEY_JOYCURR); @@ -100,20 +100,20 @@ static char *GetJoystickName(int index, const char *szRegKey) joystick's properties */ regsize = sizeof(regname); - sprintf(regvalue, + sprintf((char *) regvalue, "Joystick%d%s", index+1, REGSTR_VAL_JOYOEMNAME); regresult = RegQueryValueExA(hKey, - regvalue, 0, 0, (LPBYTE) ®name, + (char *) regvalue, 0, 0, (LPBYTE) ®name, (LPDWORD) ®size); RegCloseKey(hKey); if (regresult == ERROR_SUCCESS) { /* open that registry key */ - sprintf(regkey, "%s\\%s", + sprintf((char *) regkey, "%s\\%s", REGSTR_PATH_JOYOEM, regname); regresult = RegOpenKeyExA(HKEY_LOCAL_MACHINE, - regkey, 0, KEY_READ, &hKey); + (char *) regkey, 0, KEY_READ, &hKey); if (regresult == ERROR_SUCCESS) { /* find the size for the OEM name text */ diff --git a/src/video/macdsp/SDL_dspvideo.c b/src/video/macdsp/SDL_dspvideo.c index c31cca104..bb5a6750d 100644 --- a/src/video/macdsp/SDL_dspvideo.c +++ b/src/video/macdsp/SDL_dspvideo.c @@ -520,9 +520,11 @@ static int DSp_GetMainDevice (_THIS, GDHandle *device) static int DSp_VideoInit(_THIS, SDL_PixelFormat *vformat) { - NumVersion dsp_version; + NumVersion dsp_version = { 0x01, 0x00, 0x00, 0x00 }; +#if UNIVERSAL_INTERFACES_VERSION > 0x0320 dsp_version = DSpGetVersion (); +#endif if ( (dsp_version.majorRev == 1 && dsp_version.minorAndBugRev < 0x73) || (dsp_version.majorRev < 1) ) { @@ -801,7 +803,7 @@ rebuild: attrib.colorNeeds = kDSpColorNeeds_Require; attrib.colorTable = 0; attrib.pageCount = page_count; - #if TARGET_API_MAC_OSX + #if TARGET_API_MAC_OSX || UNIVERSAL_INTERFACES_VERSION == 0x0320 if ( DSpFindBestContext (&attrib, &dsp_context) != noErr ) { SDL_SetError ("DrawSprocket couldn't find a context");