[Mplayer-cvslog] CVS: main Makefile,1.194,1.195 codec-cfg.c,1.89,1.90 codec-cfg.h,1.59,1.60 configure,1.520,1.521
Alban Bedel CVS
albeu at mplayerhq.hu
Wed Jul 10 22:56:58 CEST 2002
Update of /cvsroot/mplayer/main
In directory mail:/var/tmp.root/cvs-serv25137
Modified Files:
Makefile codec-cfg.c codec-cfg.h configure
Log Message:
Support for Xvid using their new api. If divx4 compatiblity is disabeled
in xvid it can be used along with divx4.
Index: Makefile
===================================================================
RCS file: /cvsroot/mplayer/main/Makefile,v
retrieving revision 1.194
retrieving revision 1.195
diff -u -r1.194 -r1.195
--- Makefile 29 Jun 2002 00:16:32 -0000 1.194
+++ Makefile 10 Jul 2002 20:56:50 -0000 1.195
@@ -50,7 +50,7 @@
AO_LIBS = -Llibao2 -lao2
A_LIBS = $(ALSA_LIB) $(ARTS_LIB) $(NAS_LIB) $(MAD_LIB) $(VORBIS_LIB) $(FAAD_LIB) $(SGIAUDIO_LIB)
-CODEC_LIBS = -Llibmpcodecs -lmpcodecs -Lmp3lib -lMP3 -Lliba52 -la52 -Llibmpeg2 -lmpeg2 $(AV_LIB) $(FAME_LIB)
+CODEC_LIBS = -Llibmpcodecs -lmpcodecs -Lmp3lib -lMP3 -Lliba52 -la52 -Llibmpeg2 -lmpeg2 $(AV_LIB) $(FAME_LIB) $(XVID_LIB)
COMMON_LIBS = $(CODEC_LIBS) -Llibmpdemux -lmpdemux $(NEW_INPUT_LIB) $(LIB_LOADER) $(A_LIBS) $(CSS_LIB) $(ARCH_LIB) -Lpostproc -lpostproc $(DECORE_LIB) -Llinux -losdep $(TERMCAP_LIB) $(STREAMING_LIB) $(Z_LIB) $(GTK_LIBS) $(PNG_LIB) $(JPEG_LIB) $(GIF_LIB) $(CDPARANOIA_LIB) -lm
ifeq ($(VIDIX),yes)
MISC_LIBS += -Llibdha -ldha -Lvidix -lvidix
Index: codec-cfg.c
===================================================================
RCS file: /cvsroot/mplayer/main/codec-cfg.c,v
retrieving revision 1.89
retrieving revision 1.90
diff -u -r1.89 -r1.90
--- codec-cfg.c 25 Jun 2002 22:26:33 -0000 1.89
+++ codec-cfg.c 10 Jul 2002 20:56:50 -0000 1.90
@@ -263,6 +263,7 @@
"mpegpes",
"realvid",
"svq1",
+ "xvid",
NULL
};
char **drv=audioflag?audiodrv:videodrv;
Index: codec-cfg.h
===================================================================
RCS file: /cvsroot/mplayer/main/codec-cfg.h,v
retrieving revision 1.59
retrieving revision 1.60
diff -u -r1.59 -r1.60
--- codec-cfg.h 25 Jun 2002 22:26:33 -0000 1.59
+++ codec-cfg.h 10 Jul 2002 20:56:50 -0000 1.60
@@ -76,6 +76,7 @@
#define VFM_MPEGPES 25
#define VFM_REAL 26
#define VFM_SVQ1 27
+#define VFM_XVID 28
#ifndef GUID_TYPE
#define GUID_TYPE
Index: configure
===================================================================
RCS file: /cvsroot/mplayer/main/configure,v
retrieving revision 1.520
retrieving revision 1.521
diff -u -r1.520 -r1.521
--- configure 10 Jul 2002 03:02:11 -0000 1.520
+++ configure 10 Jul 2002 20:56:50 -0000 1.521
@@ -3547,37 +3547,67 @@
echores "$_zr"
fi
-
-echocheck "XviD/DivX4linux/DivX5linux/OpenDivX decore"
-# DivX5: DEC_OPT_MEMORY_REQS - DivX4: DEC_OPT_FRAME_311
+echocheck "XviD"
cat > $TMPC << EOF
-#include <decore.h>
-int main(void) { (void) decore(0, 0, 0, 0); return DEC_OPT_FRAME_311; }
+#include <xvid.h>
+int main(void) { xvid_init(0, 0, 0, 0); return 0; }
EOF
-if test "$_xvidcore" && cc_check -lm "$_xvidcore" ; then
+if test "$_xvid" != no && cc_check -lm "$_xvidcore" ; then
_xvid=yes
- _divx4linux=no
- _opendivx=no
- _ld_decore="$_xvidcore"
- _def_decore='#define NEW_DECORE 1'
- _def_divx='#define USE_DIVX'
- _def_divx5='#undef DECORE_DIVX5'
- _def_odivx_postprocess='#undef HAVE_ODIVX_POSTPROCESS'
+ _ld_xvid="$_xvidcore"
+ _def_xvid='#define HAVE_XVID 1'
_codecmodules="xvid $_codecmodules"
- echores "XviD (with $_xvidcore)"
elif test "$_xvid" != no && cc_check -lm -lxvidcore ; then
_xvid=yes
+ _ld_xvid='-lxvidcore'
+ _def_xvid='#define HAVE_XVID 1'
+ _codecmodules="xvid $_codecmodules"
+else
+ _xvid=no
+ _ld_xvid=''
+ _def_xvid='#undef HAVE_XVID'
+ _nocodecmodules="xvid $_nocodecmodules"
+fi
+echores "$_xvid"
+
+_xvidcompat=no
+_def_divx4_h='#undef HAVE_DIVX4_H'
+if test "$_xvid" = yes ; then
+ echocheck "DivX4 compatibility in XviD"
+ cat > $TMPC << EOF
+#include <divx4.h>
+int main(void) { (void) decore(0, 0, 0, 0); return 0; }
+EOF
+ if cc_check -lm "$_ld_xvid" ; then
+ _xvidcompat='yes (using divx4.h)'
+ _def_divx4_h='#define HAVE_DIVX4_H 1'
+ else
+ cat > $TMPC << EOF
+#include <decore.h>
+int main(void) { (void) decore(0, 0, 0, 0); return 0; }
+EOF
+ cc_check -lm "$_ld_xvid" && _xvidcompat='yes (using decore.h)'
+ fi
+ echores "$_xvidcompat"
+fi
+
+if test "$_xvidcompat" != no ; then
_divx4linux=no
_opendivx=no
- _ld_decore='-lxvidcore'
+ _ld_decore=''
_def_decore='#define NEW_DECORE 1'
- _def_divx='#define USE_DIVX'
+ _def_divx='#define USE_DIVX 1'
_def_divx5='#undef DECORE_DIVX5'
_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
+ _nocodecmodules="opendivx divx5linux divx4linux $_nocodecmodules"
+else
+echocheck "DivX4linux/DivX5linux/OpenDivX decore"
+# DivX5: DEC_OPT_MEMORY_REQS - DivX4: DEC_OPT_FRAME_311
+cat > $TMPC << EOF
+#include <decore.h>
+int main(void) { (void) decore(0, 0, 0, 0); return DEC_OPT_FRAME_311; }
+EOF
+if test "$_divx4linux" != no && cc_check -lm -ldivxdecore -lm ; then
_divx4linux=yes
_opendivx=no
_ld_decore='-ldivxdecore'
@@ -3586,7 +3616,6 @@
_def_divx5='#undef DECORE_DIVX5'
_def_odivx_postprocess='#undef HAVE_ODIVX_POSTPROCESS'
_codecmodules="divx4linux $_codecmodules"
- _nocodecmodules="xvid $_nocodecmodules"
echores "DivX4linux (with libdivxdecore.so)"
elif test "$_divx4linux" != no ; then
# DivX5 check
@@ -3597,7 +3626,6 @@
int main(void) { (void) decore(0, 0, 0, 0); return DEC_OPT_MEMORY_REQS; }
EOF
if cc_check -lm -ldivxdecore -lm ; then
- _xvid=no
_divx4linux=yes
_opendivx=no
# _ld_decore='-ldivxdecore opendivx/postprocess.o'
@@ -3611,7 +3639,6 @@
_nocodecmodules="divx4linux $_nocodecmodules"
echores "DivX5linux (with libdivxdecore.so)"
elif test "$_opendivx" != no ; then
- _xvid=no
_divx4linux=no
_opendivx=yes
_ld_decore='-Lopendivx -ldecore'
@@ -3623,7 +3650,6 @@
_nocodecmodules="divx5linux $_nocodecmodules"
echores "OpenDivX"
else
- _xvid=no
_divx4linux=no
_opendivx=no
_ld_decore=''
@@ -3635,7 +3661,7 @@
echores "no"
fi # DivX5 check
fi
-
+fi # XviD divx4 compatiblity check
# mencoder requires (optional) those libs: libmp3lame and divx4linux encore
if test "$_mencoder" != no ; then
@@ -4110,6 +4136,7 @@
ARCH_LIB = $_ld_arch $_ld_iconv
DIVX4LINUX = $_divx4linux
XVID = $_xvid
+XVID_LIB = $_ld_xvid
DECORE_LIB = $_ld_decore
MENCODER = $_mencoder
ENCORE_LIB = $_ld_encore $_ld_mp3lame $_ld_libdv
@@ -4202,6 +4229,12 @@
/* Define if you are using DivX5Linux Decore library */
$_def_divx5
+
+/* Define if you are using XviD library */
+$_def_xvid
+
+/* Define if you have divx4.h in place of decore.h */
+$_def_divx4_h
/* Define to include support for libdv-0.9.5 */
$_def_libdv
More information about the MPlayer-cvslog
mailing list