mirror of
https://github.com/cookiengineer/audacity
synced 2025-06-18 00:50:05 +02:00
Rob's 3resamplers.patch
This commit is contained in:
parent
0adda738dc
commit
17d33203c9
32
configure.in
32
configure.in
@ -339,14 +339,16 @@ dnl-------------------------------------------------------------
|
|||||||
dnl Optional library support. Lots of things we could use, but
|
dnl Optional library support. Lots of things we could use, but
|
||||||
dnl can do without if they aren't available.
|
dnl can do without if they aren't available.
|
||||||
dnl-------------------------------------------------------------
|
dnl-------------------------------------------------------------
|
||||||
dnl LIBRARIES="LIBVORBIS LIBMAD LIBSNDFILE LIBFLAC LIBID3TAG LIBSOXR LIBSBSMS LIBSOUNDTOUCH LIBNYQUIST LIBVAMP LIBEXPAT LIBTWOLAME FFMPEG LIBLRDF SLV2 REDLAND PORTSMF TAGLIB"
|
dnl LIBRARIES="LIBVORBIS LIBMAD LIBSNDFILE LIBFLAC LIBID3TAG LIBSOXR LIBRESAMPLE LIBSAMPLERATE LIBSBSMS LIBSOUNDTOUCH LIBNYQUIST LIBVAMP LIBEXPAT LIBTWOLAME FFMPEG LIBLRDF SLV2 REDLAND PORTSMF TAGLIB"
|
||||||
dnl disable plugin categorisation and LV2 libs for 1.3.7 release
|
dnl disable plugin categorisation and LV2 libs for 1.3.7 release
|
||||||
LIBRARIES="LIBVORBIS LIBMAD LIBSNDFILE LIBFLAC LIBID3TAG LIBSOXR LIBSBSMS LIBSOUNDTOUCH LIBNYQUIST LIBVAMP LIBEXPAT LIBTWOLAME FFMPEG PORTSMF PORTAUDIO LAME"
|
LIBRARIES="LIBVORBIS LIBMAD LIBSNDFILE LIBFLAC LIBID3TAG LIBSOXR LIBRESAMPLE LIBSAMPLERATE LIBSBSMS LIBSOUNDTOUCH LIBNYQUIST LIBVAMP LIBEXPAT LIBTWOLAME FFMPEG PORTSMF PORTAUDIO LAME"
|
||||||
|
|
||||||
AC_MSG_NOTICE([Determining what libraries are available in this tree and on the system])
|
AC_MSG_NOTICE([Determining what libraries are available in this tree and on the system])
|
||||||
|
|
||||||
AUDACITY_CHECKLIB_LIBSNDFILE
|
AUDACITY_CHECKLIB_LIBSNDFILE
|
||||||
AUDACITY_CHECKLIB_LIBSOXR
|
AUDACITY_CHECKLIB_LIBSOXR
|
||||||
|
AUDACITY_CHECKLIB_LIBRESAMPLE
|
||||||
|
AUDACITY_CHECKLIB_LIBSAMPLERATE
|
||||||
AUDACITY_CHECKLIB_LIBEXPAT
|
AUDACITY_CHECKLIB_LIBEXPAT
|
||||||
AUDACITY_CHECKLIB_LIBVORBIS
|
AUDACITY_CHECKLIB_LIBVORBIS
|
||||||
AUDACITY_CHECKLIB_LIBMAD
|
AUDACITY_CHECKLIB_LIBMAD
|
||||||
@ -438,6 +440,32 @@ if test "$PORTAUDIO_USE_LOCAL" != "yes" && test "$PORTAUDIO_USE_SYSTEM" != "yes"
|
|||||||
AC_MSG_ERROR([Audacity requires portaudio to be enabled])
|
AC_MSG_ERROR([Audacity requires portaudio to be enabled])
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
dnl we can only have one variable-rate resampling library used.
|
||||||
|
dnl by now we will have both enabled if they are present, regardless of whether
|
||||||
|
dnl they were requested, unless one was specifically disabled.
|
||||||
|
dnl we would like to honour requests at this stage, so need to know about
|
||||||
|
dnl the original options, not just which LIB_USE variables have been set.
|
||||||
|
if ( test "$LIBRESAMPLE_USE_LOCAL" = "yes" || test "$LIBRESAMPLE_USE_SYSTEM" = "yes") && ( test "$LIBSAMPLERATE_USE_LOCAL" = "yes" || test "$LIBSAMPLERATE_USE_SYSTEM" = "yes"); then
|
||||||
|
dnl if we get here, both libraries are available to us.
|
||||||
|
AC_MSG_NOTICE([Both libresample and libsamplerate are available])
|
||||||
|
AC_MSG_NOTICE([deciding which to use based on arguments ...])
|
||||||
|
if test x"$LIBSAMPLERATE_ARGUMENT" = x"unspecified" ; then
|
||||||
|
dnl they didn't ask for libsamplerate, they don't get it
|
||||||
|
LIBSAMPLERATE_USE_LOCAL="no"
|
||||||
|
LIBSAMPLERATE_USE_SYSTEM="no"
|
||||||
|
dnl done - we are using libresample
|
||||||
|
AC_MSG_NOTICE([Libsamplerate not explicity requested, using libresample])
|
||||||
|
else
|
||||||
|
dnl if we get here, then libsample rate has been explicity specified.
|
||||||
|
dnl could that be disabling it? No, because it wouldn't then have been
|
||||||
|
dnl enabled above.
|
||||||
|
LIBRESAMPLE_USE_LOCAL="no"
|
||||||
|
LIBRESAMPLE_USE_SYSTEM="no"
|
||||||
|
dnl done - we are using libsamplerate
|
||||||
|
AC_MSG_NOTICE([Using libsamplerate as requested])
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
dnl if ( test "$SLV2_USE_LOCAL" != "yes" && test "$LIBLRDF_USE_LOCAL" != "yes") && test "$REDLAND_USE_LOCAL" = "yes" ; then
|
dnl if ( test "$SLV2_USE_LOCAL" != "yes" && test "$LIBLRDF_USE_LOCAL" != "yes") && test "$REDLAND_USE_LOCAL" = "yes" ; then
|
||||||
dnl AC_MSG_NOTICE([Not building local Redland library since we don't use the local SLV2 or liblrdf libraries])
|
dnl AC_MSG_NOTICE([Not building local Redland library since we don't use the local SLV2 or liblrdf libraries])
|
||||||
dnl REDLAND_USE_LOCAL=no
|
dnl REDLAND_USE_LOCAL=no
|
||||||
|
@ -105,8 +105,12 @@ libsoxr-recursive:
|
|||||||
$(MAKE) -C libsoxr
|
$(MAKE) -C libsoxr
|
||||||
libsoxr.a: libsoxr-recursive
|
libsoxr.a: libsoxr-recursive
|
||||||
ln -sf libsoxr/src/libsoxr.a
|
ln -sf libsoxr/src/libsoxr.a
|
||||||
libsoxr-lsr.a: libsoxr-recursive
|
|
||||||
ln -sf libsoxr/src/libsoxr-lsr.a
|
# libresample
|
||||||
|
libresample-recursive:
|
||||||
|
$(MAKE) -C libresample libresample.a
|
||||||
|
libresample.a: libresample-recursive
|
||||||
|
ln -sf libresample/libresample.a libresample.a
|
||||||
|
|
||||||
# libsndfile
|
# libsndfile
|
||||||
libsndfile-recursive:
|
libsndfile-recursive:
|
||||||
|
@ -7,7 +7,7 @@ AC_DEFUN([AUDACITY_CHECKLIB_LIBRESAMPLE], [
|
|||||||
|
|
||||||
AC_ARG_WITH(libresample,
|
AC_ARG_WITH(libresample,
|
||||||
[AS_HELP_STRING([--with-libresample],
|
[AS_HELP_STRING([--with-libresample],
|
||||||
[use libresample for sample rate conversion: [yes,no]])],
|
[use libresample for variable-rate resampling: [yes,no]])],
|
||||||
LIBRESAMPLE_ARGUMENT=$withval,
|
LIBRESAMPLE_ARGUMENT=$withval,
|
||||||
LIBRESAMPLE_ARGUMENT="unspecified")
|
LIBRESAMPLE_ARGUMENT="unspecified")
|
||||||
|
|
||||||
|
@ -7,7 +7,7 @@ AC_DEFUN([AUDACITY_CHECKLIB_LIBSAMPLERATE], [
|
|||||||
|
|
||||||
AC_ARG_WITH(libsamplerate,
|
AC_ARG_WITH(libsamplerate,
|
||||||
[AS_HELP_STRING([--with-libsamplerate],
|
[AS_HELP_STRING([--with-libsamplerate],
|
||||||
[use libsamplerate instead of libresample for sample rate conversion. Do not use in conjunction with VST plug-in support!])],
|
[use libsamplerate instead of libresample for variable-rate resampling. Do not use in conjunction with VST plug-in support!])],
|
||||||
LIBSAMPLERATE_ARGUMENT=$withval,
|
LIBSAMPLERATE_ARGUMENT=$withval,
|
||||||
LIBSAMPLERATE_ARGUMENT="unspecified")
|
LIBSAMPLERATE_ARGUMENT="unspecified")
|
||||||
|
|
||||||
|
@ -7,7 +7,7 @@ AC_DEFUN([AUDACITY_CHECKLIB_LIBSOXR], [
|
|||||||
|
|
||||||
AC_ARG_WITH(libsoxr,
|
AC_ARG_WITH(libsoxr,
|
||||||
[AS_HELP_STRING([--with-libsoxr],
|
[AS_HELP_STRING([--with-libsoxr],
|
||||||
[use libsoxr for sample rate conversion: [yes,no]])],
|
[use libsoxr for constant-rate resampling: [yes,no]])],
|
||||||
LIBSOXR_ARGUMENT=$withval,
|
LIBSOXR_ARGUMENT=$withval,
|
||||||
LIBSOXR_ARGUMENT="unspecified")
|
LIBSOXR_ARGUMENT="unspecified")
|
||||||
|
|
||||||
@ -18,9 +18,25 @@ AC_DEFUN([AUDACITY_CHECKLIB_LIBSOXR], [
|
|||||||
|
|
||||||
dnl see if libsoxr is installed on the system
|
dnl see if libsoxr is installed on the system
|
||||||
|
|
||||||
dnl ... but libsoxr isn't yet generally installed as a system library...
|
AC_CHECK_LIB(soxr, soxr_create,
|
||||||
|
libsoxr_found="yes",
|
||||||
|
libsoxr_found="no")
|
||||||
|
|
||||||
|
soxr_h_found="no"
|
||||||
|
|
||||||
|
AC_CHECK_HEADER(soxr.h,
|
||||||
|
soxr_h_found="yes",
|
||||||
|
soxr_h_found="no")
|
||||||
|
|
||||||
|
if test "x$libsoxr_found" = "xyes" && test "x$soxr_h_found" = "xyes" ; then
|
||||||
|
LIBSOXR_SYSTEM_AVAILABLE="yes"
|
||||||
|
LIBSOXR_SYSTEM_LIBS="-lsoxr"
|
||||||
|
LIBSOXR_SYSTEM_CPPSYMBOLS="USE_SYSTEM_SOXR"
|
||||||
|
AC_MSG_NOTICE([Soxr libraries are available as system libraries])
|
||||||
|
else
|
||||||
LIBSOXR_SYSTEM_AVAILABLE="no"
|
LIBSOXR_SYSTEM_AVAILABLE="no"
|
||||||
|
AC_MSG_NOTICE([Soxr libraries are NOT available as system libraries])
|
||||||
|
fi
|
||||||
|
|
||||||
dnl see if libsoxr is available locally
|
dnl see if libsoxr is available locally
|
||||||
|
|
||||||
@ -30,7 +46,7 @@ AC_DEFUN([AUDACITY_CHECKLIB_LIBSOXR], [
|
|||||||
|
|
||||||
if test "x$soxr_h_found" = "xyes" ; then
|
if test "x$soxr_h_found" = "xyes" ; then
|
||||||
LIBSOXR_LOCAL_AVAILABLE="yes"
|
LIBSOXR_LOCAL_AVAILABLE="yes"
|
||||||
LIBSOXR_LOCAL_LIBS="libsoxr-lsr.a libsoxr.a"
|
LIBSOXR_LOCAL_LIBS="libsoxr.a"
|
||||||
LIBSOXR_LOCAL_CXXFLAGS='-I$(top_srcdir)/lib-src/libsoxr/src'
|
LIBSOXR_LOCAL_CXXFLAGS='-I$(top_srcdir)/lib-src/libsoxr/src'
|
||||||
LIBSOXR_LOCAL_CPPSYMBOLS="USE_LIBSOXR"
|
LIBSOXR_LOCAL_CPPSYMBOLS="USE_LIBSOXR"
|
||||||
|
|
||||||
|
@ -102,11 +102,14 @@
|
|||||||
/* Define if mp3 support is implemented with the libmad library */
|
/* Define if mp3 support is implemented with the libmad library */
|
||||||
#undef USE_LIBMAD
|
#undef USE_LIBMAD
|
||||||
|
|
||||||
|
/* Define if libsoxr support should be enabled */
|
||||||
|
#undef USE_LIBSOXR
|
||||||
|
|
||||||
/* Define if libresample support should be enabled */
|
/* Define if libresample support should be enabled */
|
||||||
#undef USE_LIBRESAMPLE
|
#undef USE_LIBRESAMPLE
|
||||||
|
|
||||||
/* Define if libsoxr support should be enabled */
|
/* Define if libsamplerate support should be enabled */
|
||||||
#undef USE_LIBSOXR
|
#undef USE_LIBSAMPLERATE
|
||||||
|
|
||||||
/* Define if libtwolame (MP2 export) support should be enabled */
|
/* Define if libtwolame (MP2 export) support should be enabled */
|
||||||
#undef USE_LIBTWOLAME
|
#undef USE_LIBTWOLAME
|
||||||
|
Loading…
x
Reference in New Issue
Block a user