mirror of
https://github.com/cookiengineer/audacity
synced 2025-06-24 08:10:05 +02:00
You may now do: mkdir build cd build ../configure ./audacity And all but one directory will remain unmolested...no more object files in "src". And if you look carefully, you'll see that the newly built "audacity" is copied to the top of the build tree...no more having to use "src/audacity" to run. You can of course still do the configure from the top and get all of the objects strewn about the tree. I still haven't figured out how to keep the locale directory from getting soiled. I'm not really sure there's a way around it really.
67 lines
2.4 KiB
Plaintext
67 lines
2.4 KiB
Plaintext
dnl Add audacity / libmad license?
|
|
dnl Please increment the serial number below whenever you alter this macro
|
|
dnl for the benefit of automatic macro update systems
|
|
# audacity_checklib_libmad.m4 serial 2
|
|
|
|
AC_DEFUN([AUDACITY_CHECKLIB_LIBMAD], [
|
|
AC_ARG_WITH(libmad,
|
|
[AS_HELP_STRING([--with-libmad],
|
|
[use libmad for mp2/3 decoding support])],
|
|
LIBMAD_ARGUMENT=$withval,
|
|
LIBMAD_ARGUMENT="unspecified")
|
|
|
|
dnl see if libmad is installed in the system >= 0.14.2b
|
|
|
|
PKG_CHECK_MODULES(LIBMAD, mad >= 0.14.2b,
|
|
LIBMAD_SYSTEM_AVAILABLE="yes",
|
|
LIBMAD_SYSTEM_AVAILABLE="no")
|
|
|
|
dnl if we don't have the version we want, do we have any at all?
|
|
|
|
AC_CHECK_LIB(mad, mad_decoder_init,
|
|
libmad_found="yes",
|
|
libmad_found="no")
|
|
|
|
if test "$LIBMAD_SYSTEM_AVAILABLE" = "yes" -a "$libmad_found" = "no"; then
|
|
AC_MSG_WARN([system installation of libmad found, but it is too old. Upgrade to at least 0.14.2b to use with Audacity])
|
|
fi
|
|
|
|
if test "$LIBMAD_SYSTEM_AVAILABLE" = "yes"; then
|
|
AC_MSG_NOTICE([libmad libraries are available as system libraries])
|
|
else
|
|
AC_MSG_NOTICE([libmad libraries are NOT available as system libraries])
|
|
fi
|
|
|
|
dnl see if libmad is available in the local tree
|
|
|
|
AC_CHECK_FILE(${srcdir}/lib-src/libmad/frame.h,
|
|
LIBMAD_LOCAL_AVAILABLE="yes",
|
|
LIBMAD_LOCAL_AVAILABLE="no")
|
|
|
|
if test "$LIBMAD_LOCAL_AVAILABLE" = "yes"; then
|
|
AC_MSG_NOTICE([libmad libraries are available in the local tree])
|
|
else
|
|
AC_MSG_NOTICE([libmad libraries are NOT available in the local tree])
|
|
fi
|
|
LIBMAD_MIMETYPES="audio/mpeg;"
|
|
])
|
|
|
|
AC_DEFUN([AUDACITY_CONFIG_LIBMAD], [
|
|
if test "$LIBMAD_USE_LOCAL" = yes; then
|
|
LIBMAD_CFLAGS='-I$(top_srcdir)/lib-src/libmad -I../lib-src/libmad'
|
|
LIBMAD_LIBS='$(top_builddir)/lib-src/libmad/libmad.la'
|
|
AC_CONFIG_SUBDIRS([lib-src/libmad])
|
|
fi
|
|
|
|
AC_SUBST([LIBMAD_CFLAGS])
|
|
AC_SUBST([LIBMAD_LIBS])
|
|
|
|
AM_CONDITIONAL([USE_LIBMAD], [test "$LIBMAD_USE_LOCAL" = yes -o "$LIBMAD_USE_SYSTEM" = yes])
|
|
AM_CONDITIONAL([USE_LOCAL_LIBMAD], [test "$LIBMAD_USE_LOCAL" = yes])
|
|
|
|
if test "$LIBMAD_USE_LOCAL" = yes -o "$LIBMAD_USE_SYSTEM" = yes; then
|
|
AC_DEFINE(USE_LIBMAD, 1,
|
|
[Define if mp3 support is implemented with the libmad library])
|
|
fi
|
|
])
|