ports/audio/portaudio-svn/patches/patch-configure_in

47 lines
1.6 KiB
Text

Index: configure.in
--- configure.in.orig
+++ configure.in
@@ -33,6 +33,10 @@ AC_ARG_WITH(alsa,
AS_HELP_STRING([--with-alsa], [Enable support for ALSA @<:@autodetect@:>@]),
[with_alsa=$withval])
+AC_ARG_WITH(sndio,
+ AS_HELP_STRING([--with-sndio], [Enable support for sndio @<:@autodetect@:>@]),
+ [with_sndio=$withval])
+
AC_ARG_WITH(jack,
AS_HELP_STRING([--with-jack], [Enable support for JACK @<:@autodetect@:>@]),
[with_jack=$withval])
@@ -129,6 +133,10 @@ have_alsa=no
if test "x$with_alsa" != "xno"; then
AC_CHECK_LIB(asound, snd_pcm_open, have_alsa=yes, have_alsa=no)
fi
+have_sndio=no
+if test "x$with_sndio" != "xno"; then
+ AC_CHECK_LIB(sndio, sio_open, have_sndio=yes, have_sndio=no)
+fi
have_asihpi=no
if test "x$with_asihpi" != "xno"; then
AC_CHECK_LIB(hpi, HPI_SubSysCreate, have_asihpi=yes, have_asihpi=no, -lm)
@@ -401,6 +409,13 @@ case "${host_os}" in
AC_DEFINE(PA_USE_ALSA,1)
fi
+ if [[ "$have_sndio" = "yes" -a "$with_sndio" != "no" ]] ; then
+ DLL_LIBS="$DLL_LIBS -lsndio"
+ LIBS="$LIBS -lsndio"
+ OTHER_OBJS="$OTHER_OBJS src/hostapi/sndio/pa_sndio.o"
+ AC_DEFINE(PA_USE_SNDIO,1)
+ fi
+
if [[ "$have_jack" = "yes" ] && [ "$with_jack" != "no" ]] ; then
DLL_LIBS="$DLL_LIBS $JACK_LIBS"
CFLAGS="$CFLAGS $JACK_CFLAGS"
@@ -504,6 +519,7 @@ case "$target_os" in
;;
*)
AC_MSG_RESULT([
+ Sndio ....................... $have_sndio
OSS ......................... $have_oss
JACK ........................ $have_jack
])