mirror of
https://github.com/mpv-player/mpv
synced 2024-10-22 08:51:57 +02:00
Support for XviD library detection:
- preferences are: xvid static > xvid dyn. > divx4 dyn. > opendivx static > nothing - --enable/disable-xvid (default = autoenabled if libxvidcore.so found) - --with-xvidcore=... (to use a static linking: path to xvid's libcore.a) Notes: - opendivx postprocess filters are not enabled for xvid as Michael's are better - add weird path for include/dyn lib to the --with-extra* git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@4679 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
parent
ad68b36313
commit
af63c0eb10
117
configure
vendored
117
configure
vendored
@ -124,7 +124,8 @@ Optional features:
|
|||||||
--disable-win32 disable Win32 DLL support [autodetect]
|
--disable-win32 disable Win32 DLL support [autodetect]
|
||||||
--disable-dshow disable DirectShow support [autodetect]
|
--disable-dshow disable DirectShow support [autodetect]
|
||||||
--disable-xanim disable XAnim DLL support [autodetect]
|
--disable-xanim disable XAnim DLL support [autodetect]
|
||||||
--disable-divx4linux disable Divx4Linux codec [enable]
|
--disable-xvid disable XviD codec [autodetect]
|
||||||
|
--disable-divx4linux disable DivX4linux codec [autodetect]
|
||||||
--disable-opendivx disable OpenDivx codec [enable]
|
--disable-opendivx disable OpenDivx codec [enable]
|
||||||
--enable-vorbis build with OggVorbis support [autodetect]
|
--enable-vorbis build with OggVorbis support [autodetect]
|
||||||
--disable-iconv do not use iconv(3) function [autodetect]
|
--disable-iconv do not use iconv(3) function [autodetect]
|
||||||
@ -201,6 +202,7 @@ Use these options if autodetection fails:
|
|||||||
--with-mlibdir=DIR libmlib (MLIB support) in DIR (Solaris only)
|
--with-mlibdir=DIR libmlib (MLIB support) in DIR (Solaris only)
|
||||||
--with-win32libdir=DIR W*ndows DLL files in DIR
|
--with-win32libdir=DIR W*ndows DLL files in DIR
|
||||||
--with-xanimlibdir=DIR XAnim DLL files in DIR
|
--with-xanimlibdir=DIR XAnim DLL files in DIR
|
||||||
|
--with-xvidcore=PATH path to XviD libcore.a (e.g: /opt/lib/libcore.a)
|
||||||
--with-sdl-config=PATH path to sdl*-config (e.g.: /opt/bin/sdl-config)
|
--with-sdl-config=PATH path to sdl*-config (e.g.: /opt/bin/sdl-config)
|
||||||
--with-gtk-config=PATH path to gtk*-config (e.g.: /opt/bin/gtk-config)
|
--with-gtk-config=PATH path to gtk*-config (e.g.: /opt/bin/gtk-config)
|
||||||
--with-glib-config=PATH path to glib*-config (e.g.: /opt/bin/glib-config)
|
--with-glib-config=PATH path to glib*-config (e.g.: /opt/bin/glib-config)
|
||||||
@ -762,6 +764,7 @@ _streaming=yes
|
|||||||
_vidix=yes
|
_vidix=yes
|
||||||
_new_input=no
|
_new_input=no
|
||||||
_joystick=no
|
_joystick=no
|
||||||
|
_xvid=auto
|
||||||
_divx4linux=auto
|
_divx4linux=auto
|
||||||
_opendivx=yes
|
_opendivx=yes
|
||||||
_lirc=auto
|
_lirc=auto
|
||||||
@ -870,6 +873,8 @@ for ac_option do
|
|||||||
--disable-new-input) _new_input=no ;;
|
--disable-new-input) _new_input=no ;;
|
||||||
--enable-joystick) _joystick=yes ;;
|
--enable-joystick) _joystick=yes ;;
|
||||||
--disable-joystick) _joystick=no ;;
|
--disable-joystick) _joystick=no ;;
|
||||||
|
--enable-xvid) _xvid=yes ;;
|
||||||
|
--disable-xvid) _xvid=no ;;
|
||||||
--enable-divx4linux) _divx4linux=yes ;;
|
--enable-divx4linux) _divx4linux=yes ;;
|
||||||
--disable-divx4linux) _divx4linux=no ;;
|
--disable-divx4linux) _divx4linux=no ;;
|
||||||
--enable-opendivx) _opendivx=yes ;;
|
--enable-opendivx) _opendivx=yes ;;
|
||||||
@ -964,6 +969,9 @@ for ac_option do
|
|||||||
--with-x11libdir=*)
|
--with-x11libdir=*)
|
||||||
_ld_x11=-L`echo $ac_option | cut -d '=' -f 2 | sed 's,:, -L,g'`
|
_ld_x11=-L`echo $ac_option | cut -d '=' -f 2 | sed 's,:, -L,g'`
|
||||||
;;
|
;;
|
||||||
|
--with-xvidcore=*)
|
||||||
|
_xvidcore=`echo $ac_option | cut -d '=' -f 2`
|
||||||
|
;;
|
||||||
--with-sdl-config=*)
|
--with-sdl-config=*)
|
||||||
_sdlconfig=`echo $ac_option | cut -d '=' -f 2`
|
_sdlconfig=`echo $ac_option | cut -d '=' -f 2`
|
||||||
;;
|
;;
|
||||||
@ -1607,7 +1615,6 @@ int main(void) {
|
|||||||
EOF
|
EOF
|
||||||
cc_check $_inc_x11 $_ld_x11 && _xdpms4=yes
|
cc_check $_inc_x11 $_ld_x11 && _xdpms4=yes
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if test "$_xdpms4" = yes ; then
|
if test "$_xdpms4" = yes ; then
|
||||||
_def_xdpms='#define HAVE_XDPMS 1'
|
_def_xdpms='#define HAVE_XDPMS 1'
|
||||||
echores "yes (using Xdpms 4)"
|
echores "yes (using Xdpms 4)"
|
||||||
@ -2558,6 +2565,7 @@ elif test "$_libavcodecso" = yes ; then
|
|||||||
_codecmodules="libavcodec.so $_codecmodules"
|
_codecmodules="libavcodec.so $_codecmodules"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
echocheck "zr"
|
echocheck "zr"
|
||||||
if test "$_zr" = yes ; then
|
if test "$_zr" = yes ; then
|
||||||
if test "$_libavcodec" = yes ; then
|
if test "$_libavcodec" = yes ; then
|
||||||
@ -2574,45 +2582,64 @@ else
|
|||||||
echores "$_zr"
|
echores "$_zr"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# FIXME : variables don't have a "standard" name so check this one day
|
|
||||||
if test "$_divx4linux" = auto ; then
|
echocheck "XviD/DivX4linux/OpenDivX decore"
|
||||||
_divx4linux=no
|
cat > $TMPC << EOF
|
||||||
echocheck "Divx4linux decore"
|
|
||||||
cat > $TMPC << EOF
|
|
||||||
#include <decore.h>
|
#include <decore.h>
|
||||||
int main(void) { (void) decore(0, 0, 0, 0); return DEC_OPT_FRAME_311; }
|
int main(void) { (void) decore(0, 0, 0, 0); return DEC_OPT_FRAME_311; }
|
||||||
EOF
|
EOF
|
||||||
_divx4linux_decore=no
|
if test "$_xvidcore" && cc_check -lm "$_xvidcore" ; then
|
||||||
if cc_check -ldivxdecore -lm ; then
|
_xvid=yes
|
||||||
_divx4linux_decore=yes
|
_divx4linux=no
|
||||||
else
|
_opendivx=no
|
||||||
_divx4linux_decore='not found'
|
_ld_decore="$_xvidcore"
|
||||||
fi
|
|
||||||
echores "$_divx4linux_decore"
|
|
||||||
test "$_divx4linux_decore" = yes && _divx4linux=yes
|
|
||||||
fi
|
|
||||||
if test "$_divx4linux_decore" = yes ; then
|
|
||||||
_opendivx='no'
|
|
||||||
_def_decore='#define NEW_DECORE 1'
|
_def_decore='#define NEW_DECORE 1'
|
||||||
|
_def_divx='#define USE_DIVX'
|
||||||
|
_def_odivx_postprocess='#undef HAVE_ODIVX_POSTPROCESS'
|
||||||
|
_codecmodules="xvid $_codecmodules"
|
||||||
|
echores "XviD (with $_xvidcore)"
|
||||||
|
elif test "$_xvid" != no && cc_check -lm -lxvidcore ; then
|
||||||
|
_xvid=yes
|
||||||
|
_divx4linux=no
|
||||||
|
_opendivx=no
|
||||||
|
_ld_decore='-lxvidcore'
|
||||||
|
_def_decore='#define NEW_DECORE 1'
|
||||||
|
_def_divx='#define USE_DIVX'
|
||||||
|
_def_odivx_postprocess='#undef HAVE_ODIVX_POSTPROCESS'
|
||||||
|
_codecmodules="xvid $_codecmodules"
|
||||||
|
echores "XviD (with libxvidcore.so)"
|
||||||
|
elif test "$_divx4linux" != no && cc_check -lm -ldivxdecore -lm ; then
|
||||||
|
_xvid=no
|
||||||
|
_divx4linux=yes
|
||||||
|
_opendivx=no
|
||||||
_ld_decore='-ldivxdecore opendivx/postprocess.o'
|
_ld_decore='-ldivxdecore opendivx/postprocess.o'
|
||||||
|
_def_decore='#define NEW_DECORE 1'
|
||||||
_def_divx='#define USE_DIVX'
|
_def_divx='#define USE_DIVX'
|
||||||
_def_odivx_postprocess='#define HAVE_ODIVX_POSTPROCESS 1'
|
_def_odivx_postprocess='#define HAVE_ODIVX_POSTPROCESS 1'
|
||||||
_codecmodules="divx4linux $_codecmodules"
|
_codecmodules="divx4linux $_codecmodules"
|
||||||
|
echores "Divx4linux (with libdivxdecore.so)"
|
||||||
|
elif test "$_opendivx" != no ; then
|
||||||
|
_xvid=no
|
||||||
|
_divx4linux=no
|
||||||
|
_opendivx=yes
|
||||||
|
_ld_decore='-Lopendivx -ldecore'
|
||||||
|
_def_decore='#undef NEW_DECORE'
|
||||||
|
_def_divx='#define USE_DIVX'
|
||||||
|
_def_odivx_postprocess='#define HAVE_ODIVX_POSTPROCESS 1'
|
||||||
|
_codecmodules="opendivx $_codecmodules"
|
||||||
|
echores "OpenDivX"
|
||||||
else
|
else
|
||||||
if test "$_opendivx" = yes ; then
|
_xvid=no
|
||||||
_ld_decore='-Lopendivx -ldecore'
|
_divx4linux=no
|
||||||
_def_decore='#undef NEW_DECORE'
|
_opendivx=no
|
||||||
_def_divx='#define USE_DIVX'
|
_ld_decore=''
|
||||||
_def_odivx_postprocess='#define HAVE_ODIVX_POSTPROCESS 1'
|
_def_decore='#undef NEW_DECORE'
|
||||||
_codecmodules="opendivx $_codecmodules"
|
_def_divx='#undef USE_DIVX'
|
||||||
else
|
_def_odivx_postprocess='#undef HAVE_ODIVX_POSTPROCESS'
|
||||||
_ld_decore=''
|
echores "no"
|
||||||
_def_decore='#undef NEW_DECORE'
|
|
||||||
_def_divx='#undef USE_DIVX'
|
|
||||||
_def_odivx_postprocess='#undef HAVE_ODIVX_POSTPROCESS'
|
|
||||||
fi
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
# mencoder requires (optional) those libs: libmp3lame and divx4linux encore
|
# mencoder requires (optional) those libs: libmp3lame and divx4linux encore
|
||||||
if test "$_mencoder" != no ; then
|
if test "$_mencoder" != no ; then
|
||||||
|
|
||||||
@ -2632,21 +2659,28 @@ EOF
|
|||||||
fi
|
fi
|
||||||
echores "$_mp3lame"
|
echores "$_mp3lame"
|
||||||
|
|
||||||
echocheck "Divx4linux encore (for mencoder)"
|
|
||||||
_divx4linux_encore=no
|
echocheck "XviD/DivX4linux encore (for mencoder)"
|
||||||
cat > $TMPC <<EOF
|
cat > $TMPC << EOF
|
||||||
#include <encore2.h>
|
#include <encore2.h>
|
||||||
int main(void) { (void) encore(0, 0, 0, 0); return 0; }
|
int main(void) { (void) encore(0, 0, 0, 0); return 0; }
|
||||||
EOF
|
EOF
|
||||||
if cc_check -ldivxencore -lm ; then
|
if test "$_xvid" != no && test "$_xvidcore" && cc_check -lm "$_xvidcore" ; then
|
||||||
_divx4linux_encore=yes
|
|
||||||
_def_encore='#define HAVE_DIVX4ENCORE 1'
|
_def_encore='#define HAVE_DIVX4ENCORE 1'
|
||||||
_ld_encore='-ldivxencore'
|
_ld_encore="lm $_xvidcore"
|
||||||
|
echores "XviD (with $_xvidcore)"
|
||||||
|
elif test "$_xvid" != no && cc_check -lm -lxvidcore ; then
|
||||||
|
_def_encore='#define HAVE_DIVX4ENCORE 1'
|
||||||
|
_ld_encore='lm -lxvidcore'
|
||||||
|
echores "XviD (with libxvidcore.so)"
|
||||||
|
elif test "$_divx4linux" != no && cc_check -lm -ldivxencore ; then
|
||||||
|
_def_encore='#define HAVE_DIVX4ENCORE 1'
|
||||||
|
_ld_encore='-lm -ldivxencore'
|
||||||
|
echores "DivX4linux (with libdivxencore.so)"
|
||||||
else
|
else
|
||||||
_def_encore='#undef HAVE_DIVX4ENCORE'
|
_def_encore='#undef HAVE_DIVX4ENCORE'
|
||||||
|
echores "no"
|
||||||
fi
|
fi
|
||||||
echores "$_divx4linux_encore"
|
|
||||||
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
echocheck "mencoder"
|
echocheck "mencoder"
|
||||||
@ -2993,6 +3027,7 @@ MP1E_DEP = $_dep_mp1e
|
|||||||
MP1E_LIB = $_ld_mp1e
|
MP1E_LIB = $_ld_mp1e
|
||||||
ARCH_LIB = $_ld_arch $_ld_iconv
|
ARCH_LIB = $_ld_arch $_ld_iconv
|
||||||
DIVX4LINUX = $_divx4linux
|
DIVX4LINUX = $_divx4linux
|
||||||
|
XVID = $_xvid
|
||||||
DECORE_LIB = $_ld_decore
|
DECORE_LIB = $_ld_decore
|
||||||
MENCODER = $_mencoder
|
MENCODER = $_mencoder
|
||||||
ENCORE_LIB = $_ld_encore $_ld_mp3lame
|
ENCORE_LIB = $_ld_encore $_ld_mp3lame
|
||||||
@ -3048,17 +3083,17 @@ $_def_dvdread
|
|||||||
-cache <kilobytes> */
|
-cache <kilobytes> */
|
||||||
#define USE_STREAM_CACHE 1
|
#define USE_STREAM_CACHE 1
|
||||||
|
|
||||||
/* Define to include support for OpenDivx/Divx4Linux */
|
/* Define to include support for XviD/Divx4Linux/OpenDivx */
|
||||||
$_def_divx
|
$_def_divx
|
||||||
|
|
||||||
/* Define for using new DivX4Linux library, instead of open-source OpenDivX */
|
/* Define for using new XviD/DivX4Linux library, instead of open-source OpenDivX */
|
||||||
/* You have to change DECORE_LIBS in config.mak too! */
|
/* You have to change DECORE_LIBS in config.mak too! */
|
||||||
$_def_decore
|
$_def_decore
|
||||||
|
|
||||||
/* If build mencoder */
|
/* If build mencoder */
|
||||||
$_mencoder_flag
|
$_mencoder_flag
|
||||||
|
|
||||||
/* Indicates if Divx4linux encore is available
|
/* Indicates if XviD/Divx4linux encore is available
|
||||||
Note: for mencoder */
|
Note: for mencoder */
|
||||||
$_def_encore
|
$_def_encore
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user