1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-10-11 00:53:46 +02:00

3rd attempt to Add the ability to build without trashing the source tree

Hopefully this take care of all situations.
This commit is contained in:
lllucius@gmail.com
2014-10-28 06:27:57 +00:00
parent 49ce8fd212
commit 7f8270a5c8
10 changed files with 48 additions and 44 deletions

View File

@@ -48,7 +48,7 @@ AC_DEFUN([AUDACITY_CHECKLIB_LIBMAD], [
AC_DEFUN([AUDACITY_CONFIG_LIBMAD], [
if test "$LIBMAD_USE_LOCAL" = yes; then
LIBMAD_CFLAGS='-I$(top_srcdir)/lib-src/libmad -I$(top_builddir)/lib-src/libmad'
LIBMAD_CFLAGS='-I$(top_builddir)/lib-src/libmad -I$(top_srcdir)/lib-src/libmad'
LIBMAD_LIBS='$(top_builddir)/lib-src/libmad/libmad.la'
AC_CONFIG_SUBDIRS([lib-src/libmad])
fi

View File

@@ -46,7 +46,7 @@ AC_DEFUN([AUDACITY_CHECKLIB_LIBSNDFILE], [
AC_DEFUN([AUDACITY_CONFIG_LIBSNDFILE], [
if test "$LIBSNDFILE_USE_LOCAL" = yes; then
SNDFILE_CFLAGS='-I$(top_srcdir)/lib-src/libsndfile/src'
SNDFILE_CFLAGS='-I$(top_builddir)/lib-src/libsndfile/src -I$(top_srcdir)/lib-src/libsndfile/src'
SNDFILE_LIBS='$(top_builddir)/lib-src/libsndfile/src/.libs/libsndfile.a'
AC_CONFIG_SUBDIRS([lib-src/libsndfile])
fi

View File

@@ -54,7 +54,7 @@ AC_DEFUN([AUDACITY_CHECKLIB_LIBSOUNDTOUCH], [
AC_DEFUN([AUDACITY_CONFIG_LIBSOUNDTOUCH], [
if test "$LIBSOUNDTOUCH_USE_LOCAL" = yes; then
SOUNDTOUCH_CFLAGS='-I$(top_srcdir)/lib-src/soundtouch/include -I$(top_builddir)/lib-src/soundtouch/include'
SOUNDTOUCH_CFLAGS='-I$(top_builddir)/lib-src/soundtouch/include -I$(top_srcdir)/lib-src/soundtouch/include'
SOUNDTOUCH_LIBS='$(top_builddir)/lib-src/soundtouch/source/SoundTouch/.libs/libSoundTouch.a'
AC_CONFIG_SUBDIRS([lib-src/soundtouch])
fi

View File

@@ -43,12 +43,13 @@ AC_DEFUN([AUDACITY_CHECKLIB_LIBVORBIS], [
dnl We need to override the pkg-config check for libogg by passing
dnl OGG_CFLAGS and OGG_LIBS to the configure script of libvorbis.
libogg_dir="$(pwd)/lib-src/libogg"
LIBVORBIS_LOCAL_CONFIGURE_ARGS="--disable-oggtest OGG_CFLAGS=-I${libogg_dir}/include OGG_LIBS=${libogg_dir}/src/libogg.la"
ogg_srcdir="$(pwd)/${srcdir}/lib-src/libogg"
ogg_blddir="$(pwd)/lib-src/libogg"
LIBVORBIS_LOCAL_CONFIGURE_ARGS="--disable-oggtest OGG_CFLAGS='-I${ogg_blddir}/include -I${ogg_srcdir}/include' OGG_LIBS=${ogg_blddir}/src/libogg.la"
dnl libflac needs libogg too. So we need to pass these flags to the
dnl configure script of libflac, because it does not use pkg-config.
LIBVORBIS_LOCAL_CONFIGURE_ARGS="$LIBVORBIS_LOCAL_CONFIGURE_ARGS --with-ogg-includes=${libogg_dir}/include --with-ogg-libraries=${libogg_dir}/src/.libs"
LIBVORBIS_LOCAL_CONFIGURE_ARGS="$LIBVORBIS_LOCAL_CONFIGURE_ARGS --with-ogg-includes='${ogg_blddir}/include -I${ogg_srcdir}/include' --with-ogg-libraries=${ogg_blddir}/src/.libs"
AC_MSG_NOTICE([Vorbis libraries are available in this source tree])
else
@@ -59,7 +60,7 @@ AC_DEFUN([AUDACITY_CHECKLIB_LIBVORBIS], [
AC_DEFUN([AUDACITY_CONFIG_LIBVORBIS], [
if test "$LIBVORBIS_USE_LOCAL" = yes; then
LIBVORBIS_CFLAGS='-I$(top_srcdir)/lib-src/libogg/include -I$(top_srcdir)/lib-src/libvorbis/include'
LIBVORBIS_CFLAGS='-I$(top_builddir)/lib-src/libogg/include -I$(top_srcdir)/lib-src/libogg/include -I$(top_srcdir)/lib-src/libvorbis/include'
LIBVORBIS_LIBS='$(top_builddir)/lib-src/libvorbis/lib/libvorbisenc.la $(top_builddir)/lib-src/libvorbis/lib/libvorbisfile.la'
AC_CONFIG_SUBDIRS([lib-src/libogg lib-src/libvorbis])
fi

View File

@@ -38,8 +38,8 @@ AC_DEFUN([AUDACITY_CHECKLIB_PORTAUDIO], [
if test "$PORTAUDIO_LOCAL_AVAILABLE" = "yes"; then
dnl We need to override the pkg-config check for portmixer by passing
dnl PORTAUDIO_CFLAGS and PORTAUDIO_LIBS to the configure script of portmixer.
portaudio_dir="$(pwd)/lib-src/portaudio-v19"
PORTAUDIO_LOCAL_CONFIGURE_ARGS="PORTAUDIO_CFLAGS=-I${portaudio_dir}/include PORTAUDIO_LIBS=${portaudio_dir}/lib/libportaudio.la"
pa_dir="$(pwd)/${srcdir}/lib-src/portaudio-v19"
PORTAUDIO_LOCAL_CONFIGURE_ARGS="PORTAUDIO_CFLAGS=-I${pa_dir}/include PORTAUDIO_LIBS=${pa_dir}/lib/libportaudio.la"
AC_MSG_NOTICE([portaudio19 library is available in the local tree])
else
AC_MSG_NOTICE([portaudio19 library is NOT available in the local tree])