Disable SDLmain.m for SDL2.
authordivverent <divverent@d7cf8633-e32d-0410-b094-e92efae38249>
Thu, 28 Aug 2014 12:47:58 +0000 (12:47 +0000)
committerdivverent <divverent@d7cf8633-e32d-0410-b094-e92efae38249>
Thu, 28 Aug 2014 12:47:58 +0000 (12:47 +0000)
git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12093 d7cf8633-e32d-0410-b094-e92efae38249

SDLMain.m
makefile.inc

index 2434f81..6eadb9e 100644 (file)
--- a/SDLMain.m
+++ b/SDLMain.m
@@ -5,7 +5,10 @@
     Feel free to customize this file to suit your needs
 */
 
-#include "SDL.h"
+#include <SDL.h>
+
+#if SDL_MAJOR_VERSION == 1
+
 #include "SDLMain.h"
 #include <sys/param.h> /* for MAXPATHLEN */
 #include <unistd.h>
@@ -379,3 +382,4 @@ int main (int argc, char **argv)
     return 0;
 }
 
+#endif
index 3dfd1c5..c7e98d2 100644 (file)
@@ -241,7 +241,7 @@ OBJ_MACOSXCD=$(OBJ_NOCD)
 # Link
 LDFLAGS_MACOSXCL=$(LDFLAGS_UNIXCOMMON) -ldl -framework IOKit -framework Carbon $(LIB_SOUND)
 LDFLAGS_MACOSXSV=$(LDFLAGS_UNIXCOMMON) -ldl
-LDFLAGS_MACOSXSDL=$(LDFLAGS_UNIXCOMMON) -ldl -framework IOKit $(SDLCONFIG_STATICLIBS)
+LDFLAGS_MACOSXSDL=$(LDFLAGS_UNIXCOMMON) -ldl -framework IOKit $(SDLCONFIG_STATICLIBS) ../../../SDLMain.m
 
 OBJ_AGL= builddate.c sys_linux.o vid_agl.o thread_null.o $(OBJ_MENU) $(OBJ_SOUND) $(OBJ_CD) $(OBJ_VIDEO_CAPTURE) $(OBJ_COMMON)