1dnl SDL/SDL-GL checks
2AC_ARG_ENABLE(sdl,
3[  --disable-sdl           disable checking for SDL],
4)
5
6if test "x$enable_sdl" != xno; then
7	if test "x$PKG_CONFIG" != "x"; then
8		PKG_CHECK_MODULES([SDL], [sdl >= 1.2.0], HAVE_SDL=yes, HAVE_SDL=no)
9	else
10		AM_PATH_SDL(1.2.0, HAVE_SDL=yes, HAVE_SDL=no)
11	fi
12	if test "x$HAVE_SDL" = "xyes"; then
13		case "$host_os" in
14			mingw*)
15				case "$build_os" in
16					cygwin*)
17						SDL_LIBS=`echo $SDL_LIBS | sed -e 's/-mwindows//'`
18						;;
19				esac
20			;;
21		esac
22	fi
23fi
24
25dnl SDL-AUDIO checks
26AC_ARG_ENABLE(sdl-audio,
27[  --disable-sdl-audio     disable checking for SDL-AUDIO],
28)
29
30if test "x$enable_sdl_audio" != xno; then
31	if test "x$HAVE_SDL" = "xyes"; then
32		HAVE_SDL_AUDIO=yes
33	fi
34fi
35
36dnl SDL-CD checks
37AC_ARG_ENABLE(sdl-cd,
38[  --disable-sdl-cd        disable checking for SDL-CD],
39)
40if test "x$enable_sdl_cd" != xno; then
41	if test "x$HAVE_SDL" = "xyes"; then
42		HAVE_SDL_CD=yes
43	fi
44fi
45