[MPlayer-cvslog] r27417 - in trunk: cfg-mplayer.h configure libmpcodecs/vd.c libmpdemux/demux_gif.c libmpdemux/demuxer.c libvo/video_out.c libvo/vo_gif89a.c

diego subversion at mplayerhq.hu
Tue Aug 5 10:47:52 CEST 2008


Author: diego
Date: Tue Aug  5 10:47:51 2008
New Revision: 27417

Log:
Rename preprocessor directives related to image libraries.
Change a HAVE_ prefix to a CONFIG_ prefix.


Modified:
   trunk/cfg-mplayer.h
   trunk/configure
   trunk/libmpcodecs/vd.c
   trunk/libmpdemux/demux_gif.c
   trunk/libmpdemux/demuxer.c
   trunk/libvo/video_out.c
   trunk/libvo/vo_gif89a.c

Modified: trunk/cfg-mplayer.h
==============================================================================
--- trunk/cfg-mplayer.h	(original)
+++ trunk/cfg-mplayer.h	Tue Aug  5 10:47:51 2008
@@ -128,11 +128,11 @@ const m_option_t mplayer_opts[]={
 #endif
 
 	// -vo png only:
-#ifdef HAVE_PNG
+#ifdef CONFIG_PNG
 	{"z", "-z has been removed. Use -vo png:z=<0-9> instead.\n", CONF_TYPE_PRINT, 0, 0, 0, NULL},
 #endif
 	// -vo jpeg only:
-#ifdef HAVE_JPEG
+#ifdef CONFIG_JPEG
 	{"jpeg", "-jpeg has been removed. Use -vo jpeg:<options> instead.\n",
 	    CONF_TYPE_PRINT, 0, 0, 0, NULL},
 #endif

Modified: trunk/configure
==============================================================================
--- trunk/configure	(original)
+++ trunk/configure	Tue Aug  5 10:47:51 2008
@@ -4635,12 +4635,12 @@ EOF
 fi
 echores "$_png"
 if test "$_png" = yes ; then
-  _def_png='#define HAVE_PNG 1'
+  _def_png='#define CONFIG_PNG 1'
   _ld_extra="$_ld_extra -lpng -lz"
   _vosrc="$_vosrc vo_png.c"
   _vomodules="png $_vomodules"
 else
-  _def_png='#undef HAVE_PNG'
+  _def_png='#undef CONFIG_PNG'
   _novomodules="png $_novomodules"
 fi
 
@@ -4664,12 +4664,12 @@ fi
 echores "$_jpeg"
 
 if test "$_jpeg" = yes ; then
-  _def_jpeg='#define HAVE_JPEG 1'
+  _def_jpeg='#define CONFIG_JPEG 1'
   _vosrc="$_vosrc vo_jpeg.c"
   _vomodules="jpeg $_vomodules"
   _ld_extra="$_ld_extra -ljpeg"
 else
-  _def_jpeg='#undef HAVE_JPEG'
+  _def_jpeg='#undef CONFIG_JPEG'
   _novomodules="jpeg $_novomodules"
 fi
 
@@ -4677,11 +4677,11 @@ fi
 
 echocheck "PNM support"
 if test "$_pnm" = yes; then
-  _def_pnm="#define HAVE_PNM"
+  _def_pnm="#define CONFIG_PNM"
   _vosrc="$_vosrc vo_pnm.c"
   _vomodules="pnm $_vomodules"
 else
-  _def_pnm="#undef HAVE_PNM"
+  _def_pnm="#undef CONFIG_PNM"
   _novomodules="pnm $_novomodules"
 fi
 echores "$_pnm"
@@ -4723,12 +4723,12 @@ if test "$_force_gif" = yes && test "$_g
 fi
 
 if test "$_gif" = yes ; then
-  _def_gif='#define HAVE_GIF 1'
+  _def_gif='#define CONFIG_GIF 1'
   _vosrc="$_vosrc vo_gif89a.c"
   _codecmodules="gif $_codecmodules"
   _vomodules="gif89a $_vomodules"
   _res_comment="old version, some encoding functions disabled"
-  _def_gif_4='#undef HAVE_GIF_4'
+  _def_gif_4='#undef CONFIG_GIF_4'
   _ld_extra="$_ld_extra $_ld_gif"
 
   cat > $TMPC << EOF
@@ -4743,12 +4743,12 @@ int main(void) {
 }
 EOF
   if cc_check "$_ld_gif" && tmp_run ; then
-    _def_gif_4='#define HAVE_GIF_4 1'
+    _def_gif_4='#define CONFIG_GIF_4 1'
     _res_comment=""
   fi
 else
-  _def_gif='#undef HAVE_GIF'
-  _def_gif_4='#undef HAVE_GIF_4'
+  _def_gif='#undef CONFIG_GIF'
+  _def_gif_4='#undef CONFIG_GIF_4'
   _novomodules="gif89a $_novomodules"
   _nocodecmodules="gif $_nocodecmodules"
 fi
@@ -4757,7 +4757,7 @@ echores "$_gif"
 
 case "$_gif" in yes*)
   echocheck "broken giflib workaround"
-  _def_gif_tvt_hack='#define HAVE_GIF_TVT_HACK 1'
+  _def_gif_tvt_hack='#define CONFIG_GIF_TVT_HACK 1'
 
   cat > $TMPC << EOF
 #include <gif_lib.h>
@@ -4768,7 +4768,7 @@ int main(void) {
 }
 EOF
   if cc_check "$_ld_gif" && tmp_run ; then
-    _def_gif_tvt_hack='#undef HAVE_GIF_TVT_HACK'
+    _def_gif_tvt_hack='#undef CONFIG_GIF_TVT_HACK'
     echores "disabled"
   else
     echores "enabled"

Modified: trunk/libmpcodecs/vd.c
==============================================================================
--- trunk/libmpcodecs/vd.c	(original)
+++ trunk/libmpcodecs/vd.c	Tue Aug  5 10:47:51 2008
@@ -74,10 +74,10 @@ vd_functions_t* mpcodecs_vd_drivers[] = 
 #ifdef CONFIG_XANIM
         &mpcodecs_vd_xanim,
 #endif
-#ifdef HAVE_PNG
+#ifdef CONFIG_PNG
         &mpcodecs_vd_mpng,
 #endif
-#ifdef HAVE_JPEG
+#ifdef CONFIG_JPEG
 	&mpcodecs_vd_ijpg,
 #endif
 	&mpcodecs_vd_mtga,

Modified: trunk/libmpdemux/demux_gif.c
==============================================================================
--- trunk/libmpdemux/demux_gif.c	(original)
+++ trunk/libmpdemux/demux_gif.c	Tue Aug  5 10:47:51 2008
@@ -29,7 +29,7 @@ typedef struct {
 
 #define GIF_SIGNATURE (('G' << 16) | ('I' << 8) | 'F')
 
-#ifndef HAVE_GIF_TVT_HACK
+#ifndef CONFIG_GIF_TVT_HACK
 // not supported by certain versions of the library
 int my_read_gif(GifFileType *gif, uint8_t *buf, int len) {
   return stream_read(gif->UserData, buf, len);
@@ -230,7 +230,7 @@ static demuxer_t* demux_open_gif(demuxer
   // go back to the beginning
   stream_seek(demuxer->stream,demuxer->stream->start_pos);
 
-#ifdef HAVE_GIF_TVT_HACK
+#ifdef CONFIG_GIF_TVT_HACK
   // without the TVT functionality of libungif, a hard seek must be
   // done to the beginning of the file.  this is because libgif is
   // unable to use mplayer's cache, and without this lseek libgif will

Modified: trunk/libmpdemux/demuxer.c
==============================================================================
--- trunk/libmpdemux/demuxer.c	(original)
+++ trunk/libmpdemux/demuxer.c	Tue Aug  5 10:47:51 2008
@@ -110,7 +110,7 @@ const demuxer_desc_t *const demuxer_list
     &demuxer_desc_fli,
     &demuxer_desc_film,
     &demuxer_desc_roq,
-#ifdef HAVE_GIF
+#ifdef CONFIG_GIF
     &demuxer_desc_gif,
 #endif
 #ifdef CONFIG_OGGVORBIS

Modified: trunk/libvo/video_out.c
==============================================================================
--- trunk/libvo/video_out.c	(original)
+++ trunk/libvo/video_out.c	Tue Aug  5 10:47:51 2008
@@ -228,19 +228,19 @@ const vo_functions_t* const video_out_dr
 #ifdef CONFIG_YUV4MPEG
 	&video_out_yuv4mpeg,
 #endif
-#ifdef HAVE_PNG
+#ifdef CONFIG_PNG
 	&video_out_png,
 #endif	
-#ifdef HAVE_JPEG
+#ifdef CONFIG_JPEG
 	&video_out_jpeg,
 #endif
-#ifdef HAVE_GIF
+#ifdef CONFIG_GIF
 	&video_out_gif89a,
 #endif
 #ifdef CONFIG_TGA
         &video_out_tga,
 #endif
-#ifdef HAVE_PNM
+#ifdef CONFIG_PNM
     &video_out_pnm,
 #endif
 #ifdef CONFIG_MD5SUM

Modified: trunk/libvo/vo_gif89a.c
==============================================================================
--- trunk/libvo/vo_gif89a.c	(original)
+++ trunk/libvo/vo_gif89a.c	Tue Aug  5 10:47:51 2008
@@ -157,7 +157,7 @@ static int config(uint32_t s_width, uint
 		uint32_t d_height, uint32_t flags, char *title,
 		uint32_t format)
 {
-#ifdef HAVE_GIF_4
+#ifdef CONFIG_GIF_4
 	// these are control blocks for the gif looping extension.
 	char LB1[] = "NETSCAPE2.0";
 	char LB2[] = { 1, 0, 0 };
@@ -190,7 +190,7 @@ static int config(uint32_t s_width, uint
 	// earlier versions of libungif.  i don't know exactly which,
 	// but certainly in all those before v4.  if you have problems,
 	// you need to upgrade your gif library.
-#ifdef HAVE_GIF_4
+#ifdef CONFIG_GIF_4
 	EGifSetGifVersion("89a");
 #else
 	mp_msg(MSGT_VO, MSGL_ERR, "GIF89a: Your version of libungif needs to be upgraded.\n");
@@ -232,7 +232,7 @@ static int config(uint32_t s_width, uint
 
 	// set the initial width and height info.
 	EGifPutScreenDesc(new_gif, s_width, s_height, 256, 0, reduce_cmap);
-#ifdef HAVE_GIF_4
+#ifdef CONFIG_GIF_4
 	// version 3 of libungif does not support multiple control blocks.
 	// looping requires multiple control blocks.
 	// therefore, looping is only enabled for v4 and up.



More information about the MPlayer-cvslog mailing list