portaudio-svn: sync sndio backend with what was committed upstream

from Brad.
This commit is contained in:
sthen
2024-02-28 14:50:01 +00:00
parent aad26c1963
commit be322ddcd4
6 changed files with 658 additions and 634 deletions
+1 -1
View File
@@ -2,7 +2,7 @@ COMMENT= portable cross-platform audio API
DISTNAME = pa_stable_v190700_20210406
PKGNAME = portaudio-svn-1970
REVISION = 0
REVISION = 1
CATEGORIES= audio
SITES = http://files.portaudio.com/archives/
EXTRACT_SUFX = .tgz
File diff suppressed because it is too large Load Diff
@@ -1,3 +1,6 @@
Add support for sndio (#878)
45c12e8d18ae4434000ed1521e49d9b5ef91dedf
Index: Makefile.in
--- Makefile.in.orig
+++ Makefile.in
+10 -7
View File
@@ -1,3 +1,6 @@
Add support for sndio (#878)
45c12e8d18ae4434000ed1521e49d9b5ef91dedf
Index: configure.in
--- configure.in.orig
+++ configure.in
@@ -18,7 +21,7 @@ Index: configure.in
fi
+have_sndio=no
+if test "x$with_sndio" != "xno"; then
+ AC_CHECK_LIB(sndio, sio_open, have_sndio=yes, have_sndio=no)
+ PKG_CHECK_MODULES(SNDIO, sndio, have_sndio=yes, have_sndio=no)
+fi
have_asihpi=no
if test "x$with_asihpi" != "xno"; then
@@ -28,8 +31,8 @@ Index: configure.in
fi
+ if [[ "$have_sndio" = "yes" -a "$with_sndio" != "no" ]] ; then
+ DLL_LIBS="$DLL_LIBS -lsndio"
+ LIBS="$LIBS -lsndio"
+ DLL_LIBS="$DLL_LIBS $SNDIO_LIBS"
+ CFLAGS="$CFLAGS $SNDIO_CFLAGS"
+ OTHER_OBJS="$OTHER_OBJS src/hostapi/sndio/pa_sndio.o"
+ AC_DEFINE(PA_USE_SNDIO,1)
+ fi
@@ -37,11 +40,11 @@ Index: configure.in
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
;;
*)
@@ -506,6 +521,7 @@ case "$target_os" in
AC_MSG_RESULT([
+ Sndio ....................... $have_sndio
OSS ......................... $have_oss
JACK ........................ $have_jack
+ Sndio ....................... $have_sndio
])
;;
esac
@@ -1,3 +1,6 @@
Add support for sndio (#878)
45c12e8d18ae4434000ed1521e49d9b5ef91dedf
Index: include/portaudio.h
--- include/portaudio.h.orig
+++ include/portaudio.h
@@ -1,3 +1,6 @@
Add support for sndio (#878)
45c12e8d18ae4434000ed1521e49d9b5ef91dedf
Index: src/os/unix/pa_unix_hostapis.c
--- src/os/unix/pa_unix_hostapis.c.orig
+++ src/os/unix/pa_unix_hostapis.c
@@ -9,14 +12,23 @@ Index: src/os/unix/pa_unix_hostapis.c
PaError PaOSS_Initialize( PaUtilHostApiRepresentation **hostApi, PaHostApiIndex index );
/* Added for IRIX, Pieter, oct 2, 2003: */
PaError PaSGI_Initialize( PaUtilHostApiRepresentation **hostApi, PaHostApiIndex index );
@@ -78,6 +79,10 @@ PaUtilHostApiInitializer *paHostApiInitializers[] =
@@ -63,11 +64,19 @@ PaUtilHostApiInitializer *paHostApiInitializers[] =
PaAlsa_Initialize,
#endif
#endif /* __linux__ */
+#ifdef PA_USE_SNDIO
+ PaSndio_Initialize,
+#endif
+
#if PA_USE_OSS
PaOSS_Initialize,
#endif
#else /* __linux__ */
+
+#ifdef PA_USE_SNDIO
+ PaSndio_Initialize,
+ PaSndio_Initialize,
+#endif
#if PA_USE_JACK
PaJack_Initialize,
#if PA_USE_OSS
PaOSS_Initialize,