36 lines
1.3 KiB
Plaintext
36 lines
1.3 KiB
Plaintext
$OpenBSD: patch-configure_ac,v 1.1 2014/11/04 08:35:57 armani Exp $
|
|
--- configure.ac.orig Sun Jul 31 13:33:50 2011
|
|
+++ configure.ac Thu Nov 15 21:38:44 2012
|
|
@@ -93,6 +93,10 @@ if test "x$enable_sound" = "xyes"; then
|
|
AC_ARG_ENABLE(sound_esound,
|
|
[ --enable-sound-esound compile with EsounD sound support @<:@default=yes@:>@],,
|
|
enable_sound_esound=yes)
|
|
+ AC_ARG_ENABLE(sound_sndio,
|
|
+ [ --enable-sound-sndio compile with sndio sound support @<:@default=yes@:>@],,
|
|
+ enable_sound_sndio=yes)
|
|
+
|
|
fi
|
|
enable_sound=no
|
|
|
|
@@ -124,6 +128,20 @@ if test "x$enable_sound_esound" = "xyes"; then
|
|
enable_sound=esound
|
|
fi
|
|
AM_CONDITIONAL(USE_LIBESD, test "x$enable_sound_esound" = "xyes")
|
|
+
|
|
+if test "x$enable_sound_sndio" = "xyes"; then
|
|
+ AC_CHECK_HEADERS(sndio.h,, enable_sound_sndio=no)
|
|
+ AC_CHECK_LIB(sndio, sio_open, SNDIO_LIBS="-lsndio", enable_sound_sndio=no)
|
|
+ AC_SUBST(SNDIO_LIBS)
|
|
+fi
|
|
+if test "x$enable_sound_sndio" = "xyes"; then
|
|
+ AC_DEFINE(HAVE_SOUND, 1, [Sound support])
|
|
+ AC_DEFINE(HAVE_SOUND_SNDIO, 1, [Sndio sound support])
|
|
+ AC_DEFINE(USE_SOUND_LOADER_AUDIOFILE, 1, [Use audiofile sound loader])
|
|
+ PKG_CHECK_MODULES(AUDIOFILE, audiofile,,)
|
|
+ enable_sound=sndio
|
|
+fi
|
|
+AM_CONDITIONAL(USE_LIBSNDIO, test "x$enable_sound_sndio" = "xyes")
|
|
|
|
# Save CPPFLAGS/LDFLAGS and add X_... to each
|
|
SAVE_CPPFLAGS="$CPPFLAGS"
|