applied current haiku sdl-1.2.13 patch to sdl-svn-r4114 1.2 branch

This commit is contained in:
Scott McCreary
2008-10-21 23:39:42 +00:00
parent 4740db5be1
commit c3f634de97

View File

@@ -0,0 +1,85 @@
Index: test/configure.in
===================================================================
--- test/configure.in (revision 4114)
+++ test/configure.in (working copy)
@@ -20,7 +20,7 @@
MATHLIB=""
SYS_GL_LIBS="-lopengl32"
;;
- *-*-beos*)
+ *-*-beos* | *-*-haiku*)
EXE=""
MATHLIB=""
SYS_GL_LIBS="-lGL"
Index: test/testplatform.c
===================================================================
--- test/testplatform.c (revision 4114)
+++ test/testplatform.c (working copy)
@@ -154,7 +154,11 @@
printf("This system is running %s\n",
#if __AIX__
"AIX"
-#elif __BEOS__
+#elif __HAIKU__
+ "Haiku"
+ /* Haiku must appear here before BeOS,
+ since it also defines __BEOS__ */
+#elif __BEOS__
"BeOS"
#elif __BSDI__
"BSDI"
Index: include/begin_code.h
===================================================================
--- include/begin_code.h (revision 4114)
+++ include/begin_code.h (working copy)
@@ -33,7 +33,7 @@
/* Some compilers use a special export keyword */
#ifndef DECLSPEC
-# if defined(__BEOS__)
+# if defined(__BEOS__) || defined(__HAIKU__)
# if defined(__GNUC__)
# define DECLSPEC __declspec(dllexport)
# else
Index: include/SDL_platform.h
===================================================================
--- include/SDL_platform.h (revision 4114)
+++ include/SDL_platform.h (working copy)
@@ -29,10 +29,14 @@
#undef __AIX__
#define __AIX__ 1
#endif
-#if defined(__BEOS__)
+#if defined(__BEOS__) && !defined(__HAIKU__)
#undef __BEOS__
#define __BEOS__ 1
#endif
+#if defined(__HAIKU__)
+#undef __HAIKU__
+#define __HAIKU__ 1
+#endif
#if defined(bsdi) || defined(__bsdi) || defined(__bsdi__)
#undef __BSDI__
#define __BSDI__ 1
Index: configure.in
===================================================================
--- configure.in (revision 4114)
+++ configure.in (working copy)
@@ -40,7 +40,7 @@
AC_SUBST(LT_AGE)
dnl Detect the canonical build and host environments
-AC_CONFIG_AUX_DIRS($srcdir/build-scripts)
+AC_CONFIG_AUX_DIR([build-scripts])
AC_CANONICAL_HOST
AC_C_BIGENDIAN
if test x$ac_cv_c_bigendian = xyes; then
@@ -2493,7 +2493,7 @@
SDL_CFLAGS="$SDL_CFLAGS -Dmain=SDL_main -D_WIN32_WCE=0x420"
SDL_LIBS="-lSDLmain $SDL_LIBS"
;;
- *-*-beos*)
+ *-*-beos* | *-*-haiku*)
ARCH=beos
ac_default_prefix=/boot/develop/tools/gnupro
CheckDummyVideo