summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'dev-libs/pwlib/files/pwlib-1.9.3-sdl-configure.patch')
-rw-r--r--dev-libs/pwlib/files/pwlib-1.9.3-sdl-configure.patch48
1 files changed, 48 insertions, 0 deletions
diff --git a/dev-libs/pwlib/files/pwlib-1.9.3-sdl-configure.patch b/dev-libs/pwlib/files/pwlib-1.9.3-sdl-configure.patch
new file mode 100644
index 0000000..bf8f402
--- /dev/null
+++ b/dev-libs/pwlib/files/pwlib-1.9.3-sdl-configure.patch
@@ -0,0 +1,48 @@
+--- pwlib-1.9.3/configure.ac.orig 2006-01-31 10:23:43.000000000 +0100
++++ pwlib-1.9.3/configure.ac 2006-02-16 00:42:27.000000000 +0100
+@@ -1476,6 +1476,7 @@
+ AC_ARG_ENABLE(sdl,
+ [ --disable-sdl disable SDL support])
+
++
+ if test "${enable_sdl}z" = "z" ; then
+ enable_sdl=$default_sdl
+ fi
+@@ -1485,6 +1486,9 @@
+ AC_MSG_NOTICE(SDL disabled)
+ AC_DEFINE(P_SDL, 0)
+ else
++ dnl check for sdl-config
++ AC_PATH_PROG([SDL_CONFIG], [sdl-config],, [$PATH:/usr/local/bin])
++
+ dnl SDL checks
+ if test "${SDLLIB:-unset}" = "unset" ; then
+ SDLLIB=SDL
+@@ -1496,7 +1500,13 @@
+ if test "${X11LIBDIR:-unset}" == "unset" ; then
+ X11LIBDIR=/usr/X11R6/lib
+ fi
+- AC_CHECK_LIB(SDL, SDL_CreateYUVOverlay, HAS_SDL=1, HAS_SDL=, -L${X11LIBDIR} -lpthread -lX11 -lXext)
++ if test "x${SDL_CONFIG}" = "x" ; then
++ SDL_LIBS="-L${X11LIBDIR} -lpthread -lX11 -lXext -laa"
++ else
++ SDL_LIBS="`${SDL_CONFIG} --libs`"
++ fi
++
++ AC_CHECK_LIB([SDL], [SDL_CreateYUVOverlay], [HAS_SDL=1], [HAS_SDL=], [$SDL_LIBS])
+ fi
+
+ dnl freeBSD SDL check
+@@ -1516,7 +1526,11 @@
+ if test ${SDLLIBDIR:-unset} != "unset" ; then
+ LDFLAGS="$LDFLAGS -L${SDLLIBDIR}"
+ fi
+- ENDLDLIBS="$ENDLDLIBS -l${SDLLIB}"
++ if test "x${SDL_CONFIG}" = "x" ; then
++ ENDLDLIBS="$ENDLDLIBS -l${SDLLIB}"
++ else
++ ENDLDLIBS="$ENDLDLIBS `${SDL_CONFIG} --libs`"
++ fi
+ fi
+ fi
+ AC_SUBST(HAS_SDL)