diff options
author | Warren Dukes <warren.dukes@gmail.com> | 2005-02-01 04:15:41 +0000 |
---|---|---|
committer | Warren Dukes <warren.dukes@gmail.com> | 2005-02-01 04:15:41 +0000 |
commit | 92ad6c47fb57f73586d1df86dcd11cd38f80366b (patch) | |
tree | 18cdb2c9eaa2fde1ba9cd913a4275982b7292aac | |
parent | e02659f6c0a7ad77fb8e765b0c555342cf3b1752 (diff) | |
download | mpd-92ad6c47fb57f73586d1df86dcd11cd38f80366b.tar.gz mpd-92ad6c47fb57f73586d1df86dcd11cd38f80366b.tar.xz mpd-92ad6c47fb57f73586d1df86dcd11cd38f80366b.zip |
configure now checks for libmusepack
git-svn-id: https://svn.musicpd.org/mpd/trunk@2920 09075e82-0dd4-0310-85a5-a0d7c8717e4f
-rw-r--r-- | configure.ac | 46 |
1 files changed, 46 insertions, 0 deletions
diff --git a/configure.ac b/configure.ac index d49bd0d00..8df774124 100644 --- a/configure.ac +++ b/configure.ac @@ -43,6 +43,7 @@ AC_ARG_ENABLE(mp3,[ --disable-mp3 disable mp3 support],,enable_mp3=yes) AC_ARG_ENABLE(aac,[ --disable-aac disable AAC support],,enable_aac=yes) AC_ARG_ENABLE(audiofile,[ --disable-audiofile disable audiofile support, disables wave support],,enable_audiofile=yes) AC_ARG_ENABLE(mod,[ --enable-mod enable MOD support],enable_mod=yes,) +AC_ARG_ENABLE(mpc,[ --disable-mpc disable MPC support],,enable_mpc=yes) AC_ARG_ENABLE(id3,[ --disable-id3 disable id3 support],,enable_id3=yes) AC_ARG_ENABLE(mpd_mad,[ --enable-mpd-mad use mpd libmad],use_mpd_mad=yes,) AC_ARG_ENABLE(mpd_id3tag,[ --enable-mpd-id3tag use mpd libid3tag],use_mpd_id3tag=yes,) @@ -259,6 +260,45 @@ if test x$enable_mp3 = xyes; then AC_DEFINE(HAVE_MAD,1,[Define to use libmad]) fi +if test x$enable_mpc = xyes; then + if test "x$musepack_libraries" != "x" ; then + MUSEPACK_LIBS="-L$musepack_libraries" + elif test "x$musepack_prefix" != "x" ; then + MUSEPACK_LIBS="-L$faad_prefix/lib" + elif test "x$prefix" != "xNONE"; then + MUSEPACK_LIBS="-L$libdir" + fi + + MUSEPACK_LIBS="$MUSEPACK_LIBS -lmusepack" + + if test "x$musepack_includes" != "x" ; then + MUSEPACK_CFLAGS="-I$musepack_includes" + elif test "x$musepack_prefix" != "x" ; then + MUSEPACK_CFLAGS="-I$musepack_prefix/include" + elif test "x$prefix" != "xNONE"; then + MUSEPACK_CFLAGS="-I$includedir" + fi + + oldcflags=$CFLAGS + oldlibs=$LIBS + oldcppflags=$CPPFLAGS + CFLAGS="$CFLAGS $MPD_CFLAGS $MUSEPACK_CFLAGS -I." + LIBS="$LIBS $MPD_LIBS $MUSEPACK_LIBS" + CPPFLAGS=$CFLAGS + AC_CHECK_HEADER(musepack/musepack.h,,enable_mpc=no) + if test x$enable_mpc = xyes; then + AC_CHECK_LIB(musepack,main,[MPD_LIBS="$MPD_LIBS $MUSEPACK_LIBS";MPD_CFLAGS="$MPD_CFLAGS $MUSEPACK_CFLAGS";],enable_mpc=no) + fi + if test x$enable_mpc = xyes; then + AC_DEFINE(HAVE_MUSEPACK,1,[Define to use libmusepack for MPC decoding]) + else + AC_MSG_WARN([musepack lib needed for MPC support -- disabling MPC support]) + fi + CFLAGS=$oldcflags + LIBS=$oldlibs + CPPFLAGS=$oldcppflags +fi + MP4FF_SUBDIR="" if test x$enable_aac = xyes; then @@ -578,6 +618,12 @@ else echo "MP4/AAC support ...............disabled" fi +if test x$enable_mpc = xyes; then + echo "MPC support ...................enabled" +else + echo "MPC support ...................disabled" +fi + if test x$enable_mod = xyes; then echo "MOD support ...................enabled" else |