You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Reported in version: 1.2.15 Reported for operating system, platform: Mac OS X (All), x86_64
Comments on the original bug report:
On 2013-09-03 21:47:32 +0000, Adrian Petrescu wrote:
Created attachment 1320
patch to build on OS X 10.9 Mavericks
The CGDirectPaletteRef struct no longer exists in 10.9 (it had been previously deprecated) which prevents SDL 1.2.15 from building with the following error:
In file included from ./src/video/quartz/SDL_QuartzEvents.m:24:
./src/video/quartz/SDL_QuartzVideo.h:94:5: error: unknown type name 'CGDirectPaletteRef'
CGDirectPaletteRef palette; /* palette of an 8-bit display */
^
I was able to make everything compile just by removing that item from the struct, nothing else in libsdl seems to depend on it, but I have no idea if this is a valid fix, knowing next to nothing about SDL.
I've attached the patch. Hopefully it's fine.
Cheers,
Adrian Petrescu
On 2013-09-03 22:51:32 +0000, Adrian Petrescu wrote:
I can confirm, anecdotally, that this patch works fine on Mavericks with several SDL-dependent projects such as Gource.
This patch seems wrong: SDL_QuartzVideo.m still plays with the palette member
when compiled for 10.6 and older. I think the following would be a better fix
(also attaching in case it gets mangled) :
--- SDL-1.2/src/video/quartz/SDL_QuartzVideo.h~
+++ SDL-1.2/src/video/quartz/SDL_QuartzVideo.h
@@ -91,6 +91,9 @@
CGDirectDisplayID display; /* 0 == main display (only support single display) */
const void mode; / current mode of the display */
const void save_mode; / original mode of the display */
+#if (MAC_OS_X_VERSION_MIN_REQUIRED < 1070)
CGDirectPaletteRef palette; /* palette of an 8-bit display */
+#endif
NSOpenGLContext gl_context; / OpenGL rendering context */
NSGraphicsContext nsgfx_context; / Cocoa graphics context /
Uint32 width, height, bpp; / frequently used data about the display */
On 2013-09-07 04:58:45 +0000, Ozkan Sezer wrote:
Created attachment 1324
better fix for compiling for 10.6 and older
This bug report was migrated from our old Bugzilla tracker.
These attachments are available in the static archive:
Reported in version: 1.2.15
Reported for operating system, platform: Mac OS X (All), x86_64
Comments on the original bug report:
On 2013-09-03 21:47:32 +0000, Adrian Petrescu wrote:
On 2013-09-03 22:51:32 +0000, Adrian Petrescu wrote:
On 2013-09-05 13:40:21 +0000, Sam Lantinga wrote:
On 2013-09-07 04:57:27 +0000, Ozkan Sezer wrote:
On 2013-09-07 04:58:45 +0000, Ozkan Sezer wrote:
On 2013-09-07 06:38:23 +0000, Sam Lantinga wrote:
The text was updated successfully, but these errors were encountered: