mirror of
https://github.com/cookiengineer/audacity
synced 2025-10-10 16:43:33 +02:00
Applying 2 of Benjamin's patches to add an autogen script and to
enable support for using the system portaudio library. The latter also corrects a long standing bug that prevented using config.status to regenerate src/Makefile. As a result of the above, I've taken Benjamin's *_LOCAL_CONFIGURE_ARGS idea and propagated its usage to the other place where ac_configure_args was being set directly. Removed old stuff from lib-src/Makefile.in and made the library locations for portaudio and portmixer like the rest (a symlink in lib-src). Reworked portmixer's configure.ac to properly detect host apis.
This commit is contained in:
602
lib-src/portmixer/configure
vendored
602
lib-src/portmixer/configure
vendored
File diff suppressed because it is too large
Load Diff
@@ -43,7 +43,7 @@ AC_ARG_WITH([pa-include],
|
||||
#
|
||||
#
|
||||
#
|
||||
if [[ with_portaudio != "" ]] ; then
|
||||
if test -n "$with_portaudio"; then
|
||||
CPPFLAGS="$CPPFLAGS -I$withval"
|
||||
AC_SUBST(cflags, ["$cflags -I$withval"] )
|
||||
fi
|
||||
@@ -54,54 +54,65 @@ fi
|
||||
|
||||
have_oss=no
|
||||
AC_CHECK_HEADERS([sys/soundcard.h linux/soundcard.h machine/soundcard.h], have_oss=yes)
|
||||
if [[ $have_oss = "yes" ]] ; then
|
||||
AC_CHECK_HEADER(pa_unix_oss.h, ,have_oss=no, [#include "portaudio.h"])
|
||||
if [[ $have_oss = "yes" ]] ; then
|
||||
AC_EGREP_HEADER([PaOSS_GetStreamInputDevice], [pa_unix_oss.h], , [have_oss=no])
|
||||
if [[ $have_oss = "no" ]] ; then
|
||||
AC_MSG_WARN([Missing PaOSS_GetStreamInputDevice support in pa_unix_oss.h]);
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
|
||||
AC_CHECK_HEADER(alsa/asoundlib.h, have_alsa=yes, have_alsa=no)
|
||||
AC_CHECK_HEADER(CoreAudio/CoreAudio.h, have_coreaudio=yes, have_coreaudio=no)
|
||||
AC_CHECK_HEADER(windows.h, have_windows=yes, have_windows=no)
|
||||
|
||||
#
|
||||
# Make sure the support is there
|
||||
#
|
||||
have_support=yes
|
||||
|
||||
if [[ $have_alsa = "yes" ]] ; then
|
||||
AC_EGREP_HEADER([PaAlsa_GetStreamInputCard], [pa_linux_alsa.h], , [have_support=no])
|
||||
if [[ $have_support = "no" ]] ; then
|
||||
AC_MSG_WARN([Missing support in pa_linux_alsa.h]);
|
||||
fi
|
||||
AC_CHECK_HEADER(pa_linux_alsa.h, ,have_alsa=no)
|
||||
if [[ $have_alsa = "yes" ]] ; then
|
||||
AC_EGREP_HEADER([PaAlsa_GetStreamInputCard], [pa_linux_alsa.h], , [have_alsa=no])
|
||||
if [[ $have_alsa = "no" ]] ; then
|
||||
AC_MSG_WARN([Missing PaAlsa_GetStreamInputCard support in pa_linux_alsa.h]);
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
|
||||
AC_CHECK_HEADER(CoreAudio/CoreAudio.h, have_coreaudio=yes, have_coreaudio=no)
|
||||
if [[ $have_coreaudio = "yes" ]] ; then
|
||||
AC_EGREP_HEADER([PaMacCore_GetStreamInputDevice], [pa_mac_core.h], , [have_support=no])
|
||||
if [[ $have_support = "no" ]] ; then
|
||||
AC_MSG_WARN([Missing support in pa_mac_core.h]);
|
||||
fi
|
||||
fi
|
||||
|
||||
if [[ $have_oss = "yes" ]] ; then
|
||||
AC_EGREP_HEADER([PaOSS_GetStreamInputDevice], [pa_unix_oss.h], , [have_support=no])
|
||||
if [[ $have_support = "no" ]] ; then
|
||||
AC_MSG_WARN([Missing support in pa_unix_oss.h]);
|
||||
fi
|
||||
AC_CHECK_HEADER(pa_mac_core.h, ,have_coreaudio=no, [#include "portaudio.h"])
|
||||
if [[ $have_alsa = "yes" ]] ; then
|
||||
AC_EGREP_HEADER([PaMacCore_GetStreamInputDevice], [pa_mac_core.h], , [have_support=no])
|
||||
if [[ $have_support = "no" ]] ; then
|
||||
AC_MSG_WARN([Missing support in pa_mac_core.h]);
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
|
||||
have_wmme=no
|
||||
have_ds=no
|
||||
AC_CHECK_HEADER(windows.h, have_windows=yes, have_windows=no)
|
||||
if [[ $have_windows = "yes" ]] ; then
|
||||
AC_EGREP_HEADER([PaWinDS_GetStreamInputGUID], [pa_win_ds.h], , [have_support=no])
|
||||
if [[ $have_support = "no" ]] ; then
|
||||
AC_MSG_WARN([Missing support in pa_win_ds.h]);
|
||||
fi
|
||||
AC_EGREP_HEADER([PaWinMME_GetStreamInputHandle], [pa_win_wmme.h], , [have_support=no])
|
||||
if [[ $have_support = "no" ]] ; then
|
||||
AC_MSG_WARN([Missing support in pa_win_wmme.h]);
|
||||
fi
|
||||
AC_CHECK_HEADER(pa_win_wmme.h, have_wmme=yes)
|
||||
if [[ $have_wmme = "yes" ]] ; then
|
||||
AC_EGREP_HEADER([PaWinMME_GetStreamInputHandle], [pa_win_wmme.h], , [have_wmme=no])
|
||||
if [[ $have_wmme = "no" ]] ; then
|
||||
AC_MSG_WARN([Missing PaWinMME_GetStreamInputHandle support in pa_win_wmme.h]);
|
||||
fi
|
||||
fi
|
||||
|
||||
AC_CHECK_HEADER(pa_win_ds.h, have_ds=yes)
|
||||
if [[ $have_ds = "yes" ]] ; then
|
||||
AC_EGREP_HEADER([PaWinDS_GetStreamInputGUID], [pa_win_ds.h], , [have_ds=no])
|
||||
if [[ $have_support = "no" ]] ; then
|
||||
AC_MSG_WARN([Missing PaWinDS_GetStreamInputGUID support in pa_win_ds.h]);
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
|
||||
AC_EGREP_HEADER([Pa_GetStreamHostApiType], [portaudio.h], , [have_support=no])
|
||||
if [[ $have_support = "no" ]] ; then
|
||||
AC_MSG_WARN([Missing support in portaudio.h]);
|
||||
fi
|
||||
if [[ $have_support = "no" ]] ; then
|
||||
AC_MSG_ERROR([Your version of portaudio does not include required functions.]);
|
||||
AC_CHECK_HEADER(portaudio.h, have_portaudio=yes, have_portaudio=no)
|
||||
if [[ $have_portaudio = "yes" ]] ; then
|
||||
AC_EGREP_HEADER([Pa_GetStreamHostApiType], [portaudio.h], , [have_portaudio=no])
|
||||
if [[ $have_portaudio = "no" ]] ; then
|
||||
AC_MSG_ERROR([Your version of portaudio does not include required Pa_GetStreamHostApiType function]);
|
||||
fi
|
||||
fi
|
||||
|
||||
#
|
||||
@@ -113,25 +124,33 @@ AC_SUBST( objects, [px_mixer.o] )
|
||||
#
|
||||
# Set up to use the identified ones
|
||||
#
|
||||
AC_MSG_NOTICE(---------------------------------------);
|
||||
have_support=no
|
||||
AC_MSG_NOTICE([---------------------------------------])
|
||||
if [[ $have_oss = "yes" ]] ; then
|
||||
AC_MSG_NOTICE(Including support for OSS);
|
||||
AC_MSG_NOTICE([Including support for OSS]);
|
||||
AC_DEFINE(PX_USE_UNIX_OSS)
|
||||
objects="$objects px_unix_oss.o"
|
||||
have_support=yes
|
||||
fi
|
||||
|
||||
if [[ $have_alsa = "yes" ]] ; then
|
||||
AC_MSG_NOTICE(Including support for ALSA);
|
||||
AC_MSG_NOTICE([Including support for ALSA])
|
||||
AC_DEFINE(PX_USE_LINUX_ALSA)
|
||||
objects="$objects px_linux_alsa.o"
|
||||
have_support=yes
|
||||
fi
|
||||
|
||||
if [[ $have_coreaudio = "yes" ]] ; then
|
||||
AC_MSG_NOTICE(Including support for Coreaudio);
|
||||
AC_MSG_NOTICE([Including support for Coreaudio])
|
||||
AC_DEFINE(PX_USE_MAC_COREAUDIO)
|
||||
objects="$objects px_mac_coreaudio.o"
|
||||
have_support=yes
|
||||
fi
|
||||
AC_MSG_NOTICE(---------------------------------------);
|
||||
|
||||
if [[ $have_support = "no" ]] ; then
|
||||
AC_MSG_ERROR([No supported mixer interfaces detected])
|
||||
fi
|
||||
AC_MSG_NOTICE([---------------------------------------])
|
||||
|
||||
#
|
||||
# Write it all out
|
||||
|
Reference in New Issue
Block a user