summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2009-04-01 22:03:37 +0200
committerMax Kellermann <max@duempel.org>2009-04-01 22:03:37 +0200
commit9509bd460fb0abd7100fc1ebb6c508110ff2dcb0 (patch)
tree5354d2fb4ac6370f7bbb1bd4e91a934b52c98b33
parent1d0b2c56798f18791be9d6e61f0adc0417f9e990 (diff)
configure.ac: don't check for encoders when shout/httpd disabled
Use the new $need_encoder variable to determine whether encoder plugins would actually be used if they were available.
-rw-r--r--configure.ac23
1 files changed, 19 insertions, 4 deletions
diff --git a/configure.ac b/configure.ac
index 585f63b8a..e7f3f5865 100644
--- a/configure.ac
+++ b/configure.ac
@@ -939,6 +939,20 @@ dnl
dnl Encoder API and shout/httpd output plugin
dnl
+if test x$enable_shout = xyes || test x$enable_httpd_output = xyes; then
+ # at least one output using encoders is explicitly enabled
+ need_encoder=yes
+elif test x$enable_shout = xauto || test x$enable_httpd_output = xauto; then
+ need_encoder=auto
+else
+ # all outputs using encoders are disabled
+ need_encoder=no
+
+ # don't bother to check for encoder plugins
+ enable_oggvorbis_encoder=no
+ enable_lame=no
+fi
+
if test x$enable_oggvorbis_encoder = xyes; then
if test x$enable_oggvorbis = xno; then
AC_MSG_WARN([disabling ogg shout streaming support because vorbis is not enabled])
@@ -967,8 +981,13 @@ if test x$enable_oggvorbis_encoder != xno || test x$enable_lame != xno; then
else
# no encoder plugin is enabled: disable the whole encoder API
enable_encoder=no
+
+ if test x$need_encoder = xyes; then
+ AC_MSG_ERROR([No encoder plugin found])
+ fi
fi
+
if test x$enable_shout = xauto; then
# handle shout auto-detection: disable if no encoder is
# available
@@ -1242,10 +1261,6 @@ if
echo " Ogg Vorbis encoder ............disabled"
fi
echo ""
-
- if test x$enable_encoder = xno; then
- AC_MSG_ERROR([Cannot enable a streaming output without an encoder.])
- fi
fi
echo " File Format Support:"