changeset 32892:b5f21d533644

Fix compilation for systems where vorbis encode is split out into libvorbisenc. Note that vorbis support will be completely disabled for systems that use the split libraries but do not have libvorbisenc installed. That should be ok since there shouldn't be a real need to use libvorbis for decoding.
author reimar
date Sun, 27 Feb 2011 15:25:20 +0000
parents 744741d2607a
children c873777e957d
files configure
diffstat 1 files changed, 4 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/configure	Sun Feb 27 15:14:23 2011 +0000
+++ b/configure	Sun Feb 27 15:25:20 2011 +0000
@@ -6295,7 +6295,9 @@
 fi
 if test "$_libvorbis" = auto; then
   _libvorbis=no
-  statement_check vorbis/codec.h 'vorbis_packet_blocksize(0, 0)' -lvorbis -logg $_ld_lm && _libvorbis=yes
+  for vorbislibs in '-lvorbis -logg' '-lvorbis -lvorbisenc -logg' ; do
+    statement_check vorbis/vorbisenc.h 'vorbis_encode_ctl(0, 0, 0)' $vorbislibs $_ld_lm && _libvorbis=yes && break
+  done
 fi
 if test "$_tremor_internal" = yes ; then
   _vorbis=yes
@@ -6319,7 +6321,7 @@
   def_vorbis='#define CONFIG_OGGVORBIS 1'
   codecmodules="libvorbis $codecmodules"
   res_comment="libvorbis"
-  extra_ldflags="$extra_ldflags -lvorbis -logg"
+  extra_ldflags="$extra_ldflags $vorbislibs"
   libavencoders="$libavencoders LIBVORBIS_ENCODER"
 else
   _vorbis=no