<p>Alexander Traud has uploaded this change for <strong>review</strong>.</p><p><a href="https://gerrit.asterisk.org/8437">View Change</a></p><pre style="font-family: monospace,monospace; white-space: pre-wrap;">BuildSystem: Enable PortAudio in NetBSD.<br><br>ASTERISK-27721<br><br>Change-Id: I4175500126909ad1b181fff8e11bb4a3a6ae4fa9<br>---<br>M configure<br>M configure.ac<br>M include/asterisk/autoconfig.h.in<br>3 files changed, 98 insertions(+), 1 deletion(-)<br><br></pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;">git pull ssh://gerrit.asterisk.org:29418/asterisk refs/changes/37/8437/1</pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;">diff --git a/configure b/configure<br>index 3442d57..460b97a 100755<br>--- a/configure<br>+++ b/configure<br>@@ -657,6 +657,8 @@<br> GMIME_CFLAGS<br> PBX_SSL_OP_NO_TLSV1_2<br> PBX_SSL_OP_NO_TLSV1_1<br>+PORTAUDIO_LIBS<br>+PORTAUDIO_CFLAGS<br> PYTHONDEV_LIBS<br> PYTHONDEV_CFLAGS<br> PYTHONDEV_INCLUDE<br>@@ -1449,6 +1451,8 @@<br> PJPROJECT_LIBS<br> PYTHONDEV_CFLAGS<br> PYTHONDEV_LIBS<br>+PORTAUDIO_CFLAGS<br>+PORTAUDIO_LIBS<br> GMIME_CFLAGS<br> GMIME_LIBS<br> GTK2_CFLAGS<br>@@ -2204,6 +2208,10 @@<br> C compiler flags for PYTHONDEV, overriding pkg-config<br> PYTHONDEV_LIBS<br> linker flags for PYTHONDEV, overriding pkg-config<br>+ PORTAUDIO_CFLAGS<br>+ C compiler flags for PORTAUDIO, overriding pkg-config<br>+ PORTAUDIO_LIBS<br>+ linker flags for PORTAUDIO, overriding pkg-config<br> GMIME_CFLAGS<br> C compiler flags for GMIME, overriding pkg-config<br> GMIME_LIBS linker flags for GMIME, overriding pkg-config<br>@@ -25800,6 +25808,94 @@<br> <br> <br> <br>+ if test "x${PBX_PORTAUDIO}" != "x1" -a "${USE_PORTAUDIO}" != "no"; then<br>+<br>+pkg_failed=no<br>+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for PORTAUDIO" >&5<br>+$as_echo_n "checking for PORTAUDIO... " >&6; }<br>+<br>+if test -n "$PORTAUDIO_CFLAGS"; then<br>+ pkg_cv_PORTAUDIO_CFLAGS="$PORTAUDIO_CFLAGS"<br>+ elif test -n "$PKG_CONFIG"; then<br>+ if test -n "$PKG_CONFIG" && \<br>+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"portaudio-2.0\""; } >&5<br>+ ($PKG_CONFIG --exists --print-errors "portaudio-2.0") 2>&5<br>+ ac_status=$?<br>+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5<br>+ test $ac_status = 0; }; then<br>+ pkg_cv_PORTAUDIO_CFLAGS=`$PKG_CONFIG --cflags "portaudio-2.0" 2>/dev/null`<br>+ test "x$?" != "x0" && pkg_failed=yes<br>+else<br>+ pkg_failed=yes<br>+fi<br>+ else<br>+ pkg_failed=untried<br>+fi<br>+if test -n "$PORTAUDIO_LIBS"; then<br>+ pkg_cv_PORTAUDIO_LIBS="$PORTAUDIO_LIBS"<br>+ elif test -n "$PKG_CONFIG"; then<br>+ if test -n "$PKG_CONFIG" && \<br>+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"portaudio-2.0\""; } >&5<br>+ ($PKG_CONFIG --exists --print-errors "portaudio-2.0") 2>&5<br>+ ac_status=$?<br>+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5<br>+ test $ac_status = 0; }; then<br>+ pkg_cv_PORTAUDIO_LIBS=`$PKG_CONFIG --libs "portaudio-2.0" 2>/dev/null`<br>+ test "x$?" != "x0" && pkg_failed=yes<br>+else<br>+ pkg_failed=yes<br>+fi<br>+ else<br>+ pkg_failed=untried<br>+fi<br>+<br>+<br>+<br>+if test $pkg_failed = yes; then<br>+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5<br>+$as_echo "no" >&6; }<br>+<br>+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then<br>+ _pkg_short_errors_supported=yes<br>+else<br>+ _pkg_short_errors_supported=no<br>+fi<br>+ if test $_pkg_short_errors_supported = yes; then<br>+ PORTAUDIO_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "portaudio-2.0" 2>&1`<br>+ else<br>+ PORTAUDIO_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "portaudio-2.0" 2>&1`<br>+ fi<br>+ # Put the nasty error message in config.log where it belongs<br>+ echo "$PORTAUDIO_PKG_ERRORS" >&5<br>+<br>+<br>+ PBX_PORTAUDIO=0<br>+<br>+<br>+elif test $pkg_failed = untried; then<br>+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5<br>+$as_echo "no" >&6; }<br>+<br>+ PBX_PORTAUDIO=0<br>+<br>+<br>+else<br>+ PORTAUDIO_CFLAGS=$pkg_cv_PORTAUDIO_CFLAGS<br>+ PORTAUDIO_LIBS=$pkg_cv_PORTAUDIO_LIBS<br>+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5<br>+$as_echo "yes" >&6; }<br>+<br>+ PBX_PORTAUDIO=1<br>+ PORTAUDIO_INCLUDE="$PORTAUDIO_CFLAGS"<br>+ PORTAUDIO_LIB="$PORTAUDIO_LIBS"<br>+<br>+$as_echo "#define HAVE_PORTAUDIO 1" >>confdefs.h<br>+<br>+<br>+fi<br>+ fi<br>+<br>+<br> if test "x${PBX_PORTAUDIO}" != "x1" -a "${USE_PORTAUDIO}" != "no"; then<br> pbxlibdir=""<br> # if --with-PORTAUDIO=DIR has been specified, use it.<br>diff --git a/configure.ac b/configure.ac<br>index d9148c0..39a9372 100644<br>--- a/configure.ac<br>+++ b/configure.ac<br>@@ -2252,6 +2252,7 @@<br> <br> AST_EXT_LIB_CHECK([POPT], [popt], [poptStrerror], [popt.h])<br> <br>+AST_PKG_CONFIG_CHECK([PORTAUDIO], [portaudio-2.0])<br> AST_EXT_LIB_CHECK([PORTAUDIO], [portaudio], [Pa_GetDeviceCount], [portaudio.h])<br> <br> AST_EXT_LIB_CHECK([PRI], [pri], [pri_connected_line_update], [libpri.h])<br>diff --git a/include/asterisk/autoconfig.h.in b/include/asterisk/autoconfig.h.in<br>index 0615ea7..5c3bb67 100644<br>--- a/include/asterisk/autoconfig.h.in<br>+++ b/include/asterisk/autoconfig.h.in<br>@@ -639,7 +639,7 @@<br> /* Define to 1 if you have the popt library. */<br> #undef HAVE_POPT<br> <br>-/* Define to 1 if you have the PortAudio library. */<br>+/* Define if your system has the PORTAUDIO libraries. */<br> #undef HAVE_PORTAUDIO<br> <br> /* Define to 1 if you have the `pow' function. */<br></pre><p>To view, visit <a href="https://gerrit.asterisk.org/8437">change 8437</a>. To unsubscribe, visit <a href="https://gerrit.asterisk.org/settings">settings</a>.</p><div itemscope itemtype="http://schema.org/EmailMessage"><div itemscope itemprop="action" itemtype="http://schema.org/ViewAction"><link itemprop="url" href="https://gerrit.asterisk.org/8437"/><meta itemprop="name" content="View Change"/></div></div>
<div style="display:none"> Gerrit-Project: asterisk </div>
<div style="display:none"> Gerrit-Branch: 13 </div>
<div style="display:none"> Gerrit-MessageType: newchange </div>
<div style="display:none"> Gerrit-Change-Id: I4175500126909ad1b181fff8e11bb4a3a6ae4fa9 </div>
<div style="display:none"> Gerrit-Change-Number: 8437 </div>
<div style="display:none"> Gerrit-PatchSet: 1 </div>
<div style="display:none"> Gerrit-Owner: Alexander Traud <pabstraud@compuserve.com> </div>