Commit f45e22e5 authored by Gildas Bazin's avatar Gildas Bazin

* configure.ac: update for newer speex + workaround a libxml2 problem on OSX.

* modules/codec/speex.c: update for newer speex.
parent 2b2cba2a
...@@ -450,7 +450,7 @@ AC_CHECK_LIB(m,pow,[ ...@@ -450,7 +450,7 @@ AC_CHECK_LIB(m,pow,[
VLC_ADD_LDFLAGS([ffmpeg ffmpegaltivec stream_out_transrate i420_rgb faad toolame equalizer vlc],[-lm]) VLC_ADD_LDFLAGS([ffmpeg ffmpegaltivec stream_out_transrate i420_rgb faad toolame equalizer vlc],[-lm])
]) ])
AC_CHECK_LIB(m,sqrt,[ AC_CHECK_LIB(m,sqrt,[
VLC_ADD_LDFLAGS([headphone_channel_mixer normvol],[-lm]) VLC_ADD_LDFLAGS([headphone_channel_mixer normvol speex],[-lm])
]) ])
fi # end "${SYS}" != "mingw32" fi # end "${SYS}" != "mingw32"
...@@ -2442,19 +2442,15 @@ AC_ARG_ENABLE(speex, ...@@ -2442,19 +2442,15 @@ AC_ARG_ENABLE(speex,
[ --enable-speex Speex decoder support (default enabled)]) [ --enable-speex Speex decoder support (default enabled)])
if test "${enable_speex}" != "no" if test "${enable_speex}" != "no"
then then
AC_CHECK_HEADERS(speex.h, [ AC_CHECK_HEADERS(speex/speex.h, [
AC_MSG_CHECKING(for libspeex version > 1.1.0) LDFLAGS="${LDFLAGS_save} ${LDFLAGS_toolame}"
AC_EGREP_CPP(yes, AC_CHECK_LIB(speex, speex_decode_int, [
[#include <speex.h> VLC_ADD_PLUGINS([speex])
#ifdef SPEEX_SET_SUBMODE_ENCODING VLC_ADD_LDFLAGS([speex],[-lspeex]) ],
yes
#endif],
[ AC_MSG_RESULT([yes])
VLC_ADD_PLUGINS([speex])
VLC_ADD_LDFLAGS([speex],[-lspeex]) ],
[ AC_MSG_RESULT([no]) [ AC_MSG_RESULT([no])
AC_MSG_WARN([Your libspeex is too old, please get the development AC_MSG_WARN([Your libspeex is too old, please get the development
version.]) ] ) version.]) ],[])
LDFLAGS="${LDFLAGS_save}"
],[]) ],[])
fi fi
...@@ -2875,14 +2871,22 @@ then ...@@ -2875,14 +2871,22 @@ then
VLC_ADD_CPPFLAGS([xml],[`${XML2_CONFIG} --cflags`]) VLC_ADD_CPPFLAGS([xml],[`${XML2_CONFIG} --cflags`])
VLC_ADD_LDFLAGS([xml],[`${XML2_CONFIG} --libs`]) VLC_ADD_LDFLAGS([xml],[`${XML2_CONFIG} --libs`])
dnl depends on the xmlTextReader extension dnl depends on the xmlTextReader extension
CPPFLAGS="${CPPFLAGS_save} ${CPPFLAGS_xml}"
LDFLAGS="${LDFLAGS_save} ${LDFLAGS_xml}" LDFLAGS="${LDFLAGS_save} ${LDFLAGS_xml}"
AC_CHECK_LIB(xml2,xmlTextReaderConstName,[ AC_CHECK_LIB(xml2,xmlTextReaderConstName,[
VLC_ADD_PLUGINS([xml]) ],[ AC_EGREP_HEADER(xmlTextReaderConstName,libxml/xmlreader.h,[
VLC_ADD_PLUGINS([xml]) ],[
AC_MSG_WARN([libxml2 missing the xmlTextReader extension, you should update your version])
if test "${enable_xml2}" = "yes"; then
AC_MSG_ERROR([libxml2 missing the xmlTextReader extension])
fi])
],[
AC_MSG_WARN([libxml2 missing the xmlTextReader extension, you should update your version]) AC_MSG_WARN([libxml2 missing the xmlTextReader extension, you should update your version])
if test "${enable_xml2}" = "yes"; then if test "${enable_xml2}" = "yes"; then
AC_MSG_ERROR([libxml2 missing the xmlTextReader extension]) AC_MSG_ERROR([libxml2 missing the xmlTextReader extension])
fi]) fi])
LDFLAGS="${LDFLAGS_save}" LDFLAGS="${LDFLAGS_save}"
CPPFLAGS="${CPPFLAGS_save}"
else else
if test "${enable_xml2}" = "yes"; then if test "${enable_xml2}" = "yes"; then
AC_MSG_ERROR([Could not find libxml2]) AC_MSG_ERROR([Could not find libxml2])
......
...@@ -29,10 +29,10 @@ ...@@ -29,10 +29,10 @@
#include <vlc/input.h> #include <vlc/input.h>
#include <ogg/ogg.h> #include <ogg/ogg.h>
#include <speex.h> #include <speex/speex.h>
#include "speex_header.h" #include <speex/speex_header.h>
#include "speex_stereo.h" #include <speex/speex_stereo.h>
#include "speex_callbacks.h" #include <speex/speex_callbacks.h>
/***************************************************************************** /*****************************************************************************
* decoder_sys_t : speex decoder descriptor * decoder_sys_t : speex decoder descriptor
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment