[packages/mplayer] - added giflib patch (fixes build with giflib 5.1+)

qboosh qboosh at pld-linux.org
Tue Sep 16 18:40:29 CEST 2014


commit 426fca519b7bd023331730ea8d993704ca04ef51
Author: Jakub Bogusz <qboosh at pld-linux.org>
Date:   Tue Sep 16 18:40:22 2014 +0200

    - added giflib patch (fixes build with giflib 5.1+)

 mplayer-giflib.patch | 26 ++++++++++++++++++++++++++
 mplayer.spec         |  2 ++
 2 files changed, 28 insertions(+)
---
diff --git a/mplayer.spec b/mplayer.spec
index fab2eab..b5bc399 100644
--- a/mplayer.spec
+++ b/mplayer.spec
@@ -141,6 +141,7 @@ Source8:	%{name}.desktop
 # http://www.on2.com/gpl/mplayer/
 Source9:	http://support.on2.com/gpl/mplayer/2009-10-08-mencoder-on2flixenglinux.tar.bz2
 # Source9-md5:	07774a2663a8fda07c308df0c6569b56
+Patch0:		%{name}-giflib.patch
 
 # build (configure / Makefile) related:
 Patch10:	%{name}-ldflags.patch
@@ -394,6 +395,7 @@ MEncoder to koder filmów dla Linuksa będący częścią pakietu MPlayer.
 %prep
 %setup -q -n %{name}-export-%{snap} -a1 -a3 -a6 -a9
 cp -f etc/codecs.conf etc/codecs.win32.conf
+%patch0 -p1
 
 # build (configure / Makefile) related:
 %patch10 -p1
diff --git a/mplayer-giflib.patch b/mplayer-giflib.patch
new file mode 100644
index 0000000..2812969
--- /dev/null
+++ b/mplayer-giflib.patch
@@ -0,0 +1,26 @@
+--- mplayer-export-2014-09-12/libvo/vo_gif89a.c.orig	2014-01-18 22:39:07.000000000 +0100
++++ mplayer-export-2014-09-12/libvo/vo_gif89a.c	2014-09-16 17:01:13.843265608 +0200
+@@ -367,7 +367,11 @@
+ 			MPLAYER_VERSION, VO_GIF_REVISION,
+ 			"joey at nicewarrior.org");
+ 		EGifPutComment(new_gif, temp);
++#if (GIFLIB_MAJOR > 5) || ((GIFLIB_MAJOR == 5) && (GIFLIB_MINOR >= 1))
++		EGifCloseFile(new_gif, NULL); // also frees gif storage space.
++#else
+ 		EGifCloseFile(new_gif); // also frees gif storage space.
++#endif
+ 	}
+ 
+ 	// free our allocated ram
+--- mplayer-export-2014-09-12/libmpdemux/demux_gif.c.orig	2014-02-23 19:14:44.000000000 +0100
++++ mplayer-export-2014-09-12/libmpdemux/demux_gif.c	2014-09-16 18:00:40.546449439 +0200
+@@ -51,6 +51,9 @@
+ #define GifError() (gif ? gif->Error : 0)
+ #define GifErrorString() GifErrorString(gif->Error)
+ #endif
++#if defined GIFLIB_MAJOR && ((GIFLIB_MAJOR > 5) || ((GIFLIB_MAJOR == 5) && (GIFLIB_MINOR >= 1)))
++#define DGifCloseFile(a) DGifCloseFile(a, NULL)
++#endif
+ 
+ /* >= 4.2 prior GIFLIB did not have MAJOR/MINOR defines */
+ #if defined GIFLIB_MAJOR && GIFLIB_MAJOR >= 4
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/mplayer.git/commitdiff/426fca519b7bd023331730ea8d993704ca04ef51



More information about the pld-cvs-commit mailing list