From f6fbe8df16022da03e1b483818a687a4729b7971 Mon Sep 17 00:00:00 2001 From: Jeff Teunissen Date: Sat, 9 Dec 2000 20:46:05 +0000 Subject: [PATCH] SDL sound support. --- configure.in | 13 ++++++++++++- source/Makefile.am | 3 +++ 2 files changed, 15 insertions(+), 1 deletion(-) diff --git a/configure.in b/configure.in index baf50d8..cae13e1 100644 --- a/configure.in +++ b/configure.in @@ -580,6 +580,10 @@ AC_ARG_ENABLE(alsa, [ --disable-alsa disable alsa support], ) +AC_ARG_ENABLE(sdlsound, +[ --enable-sdlsound use SDL for sound output] +) + SNDTYPE="" SOUND_LIBS="" SOUND_CFLAGS="" @@ -613,6 +617,12 @@ QF_maGiC_VALUE fi fi +dnl Must put SDL tests before other sound tests... +if test -z "$SNDTYPE" -a "x$HAVE_SDL" = "xyes" -a "x$enable_sdlsound" = "xyes"; then + SNDTYPE="SDL" + SOUND_LIBS="$SDL_LIBS" +fi + dnl MME if test -z "$SNDTYPE" -a "x$ac_cv_header_mme_mmsystem_h" = "xyes" -a "x$HAVE_LIBMME" = "xyes"; then AC_EGREP_CPP([QF_maGiC_VALUE], @@ -702,10 +712,11 @@ AM_CONDITIONAL(SNDTYPE_ALSA_0_5, test "$SNDTYPE" = "ALSA_0_5") AM_CONDITIONAL(SNDTYPE_ALSA_0_6, test "$SNDTYPE" = "ALSA_0_6") AM_CONDITIONAL(SNDTYPE_MME, test "$SNDTYPE" = "MME") AM_CONDITIONAL(SNDTYPE_OSS, test "$SNDTYPE" = "OSS") +AM_CONDITIONAL(SNDTYPE_SDL, test "$SNDTYPE" = "SDL") AM_CONDITIONAL(SNDTYPE_SGI, test "$SNDTYPE" = "SGI") AM_CONDITIONAL(SNDTYPE_SUN, test "$SNDTYPE" = "SUN") AM_CONDITIONAL(SNDTYPE_WIN32, test "$SNDTYPE" = "WIN32") -AM_CONDITIONAL(SNDTYPE_NULL, test "$SNDTYPE" != "ALSA_0_5" -a "$SNDTYPE" != "ALSA_0_6" -a "$SNDTYPE" != "MME" -a "$SNDTYPE" != "OSS" -a "$SNDTYPE" != "SGI" -a "$SNDTYPE" != "SUN" -a "$SNDTYPE" != "WIN32") +AM_CONDITIONAL(SNDTYPE_NULL, test "$SNDTYPE" != "ALSA_0_5" -a "$SNDTYPE" != "ALSA_0_6" -a "$SNDTYPE" != "MME" -a "$SNDTYPE" != "OSS" -a "$SNDTYPE" != "SDL" -a "$SNDTYPE" != "SGI" -a "$SNDTYPE" != "SUN" -a "$SNDTYPE" != "WIN32") dnl Tests for joystick support AC_MSG_CHECKING(for joystick support) diff --git a/source/Makefile.am b/source/Makefile.am index 671ef04..13ac427 100644 --- a/source/Makefile.am +++ b/source/Makefile.am @@ -103,6 +103,9 @@ endif if SNDTYPE_OSS libqfsnd_a_SOURCES= snd_dma.c snd_mem.c snd_mix.c snd_oss.c endif +if SNDTYPE_SDL +libqfsnd_a_SOURCES= snd_dma.c snd_mem.c snd_mix.c snd_sdl.c +endif if SNDTYPE_SGI libqfsnd_a_SOURCES= snd_dma.c snd_mem.c snd_mix.c snd_sgi.c endif