aboutsummaryrefslogtreecommitdiffstats
path: root/configure.ac
diff options
context:
space:
mode:
authorAvuton Olrich <avuton@gmail.com>2010-04-23 06:48:12 -0700
committerAvuton Olrich <avuton@gmail.com>2010-04-23 06:53:26 -0700
commitb8b2ef3de139735e6f2e4eb815113267719d0ed4 (patch)
tree4301dcad9da6d2c0a514c91a3b99ff40c66772f0 /configure.ac
parent681128def43127d700a2b0adda473ed892f2f22f (diff)
downloadmpd-b8b2ef3de139735e6f2e4eb815113267719d0ed4.tar.gz
mpd-b8b2ef3de139735e6f2e4eb815113267719d0ed4.tar.xz
mpd-b8b2ef3de139735e6f2e4eb815113267719d0ed4.zip
configure.ac: Add libogg section
Add libogg section rather than checking for it every time it's necessary.
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac23
1 files changed, 17 insertions, 6 deletions
diff --git a/configure.ac b/configure.ac
index 172e4decb..c42d2f907 100644
--- a/configure.ac
+++ b/configure.ac
@@ -628,6 +628,9 @@ if test x$enable_lastfm = xyes; then
fi
AM_CONDITIONAL(ENABLE_LASTFM, test x$enable_lastfm = xyes)
+dnl ---------------------------------- libogg ---------------------------------
+PKG_CHECK_MODULES(OGG, [ogg], enable_ogg=yes, enable_ogg=no)
+
dnl ---------------------------------- libmms ---------------------------------
MPD_AUTO_PKG(mms, MMS, [libmms >= 0.4],
[libmms mms:// protocol support], [libmms not found])
@@ -768,9 +771,12 @@ if test x$enable_flac = xyes; then
LIBS="$oldlibs"
if test x$enable_oggflac = xflac; then
- PKG_CHECK_MODULES(OGG, [ogg], FLAC_LIBS="${FLAC_LIBS} -logg",
- enable_oggflac=yes;
- AC_MSG_WARN("FLAC has the ogg API built in, but couldn't find ogg. Disabling oggflac."))
+ if test x$enable_ogg = xyes; then
+ FLAC_LIBS="${FLAC_LIBS} -logg",
+ else
+ enable_oggflac=yes
+ AC_MSG_WARN("FLAC has the ogg API built in, but couldn't find ogg. Disabling oggflac.")
+ fi
fi
fi
@@ -970,9 +976,14 @@ AM_CONDITIONAL(HAVE_OGGFLAC, test x$enable_oggflac = xyes)
dnl -------------------------------- Ogg Vorbis -------------------------------
if test x$enable_tremor != xno && test x$enable_vorbis = xyes; then
- PKG_CHECK_MODULES(VORBIS, [ogg vorbis vorbisfile],
- AC_DEFINE(ENABLE_VORBIS_DECODER, 1, [Define for Ogg Vorbis support]),
- enable_vorbis=no)
+ if test x$enable_ogg = xyes; then
+ PKG_CHECK_MODULES(VORBIS, [vorbis vorbisfile],
+ AC_DEFINE(ENABLE_VORBIS_DECODER, 1, [Define for Ogg Vorbis support]),
+ enable_vorbis=no)
+ else
+ AC_MSG_WARN("Ogg not detected, could not enable Vorbis.")
+ enable_vorbis=no
+ fi
fi
AM_CONDITIONAL(ENABLE_VORBIS_DECODER, test x$enable_vorbis = xyes)