]> git.pld-linux.org Git - packages/fbv.git/commitdiff
- added giflib5 patch (adjust Open/Close API for giflib 5+); release 8 master auto/th/fbv-1.0b-8
authorJakub Bogusz <qboosh@pld-linux.org>
Wed, 12 Apr 2023 19:21:43 +0000 (21:21 +0200)
committerJakub Bogusz <qboosh@pld-linux.org>
Wed, 12 Apr 2023 19:21:43 +0000 (21:21 +0200)
fbv-giflib5.patch [new file with mode: 0644]
fbv.spec

diff --git a/fbv-giflib5.patch b/fbv-giflib5.patch
new file mode 100644 (file)
index 0000000..4da9049
--- /dev/null
@@ -0,0 +1,61 @@
+--- fbv-1.0b/gif.c.orig        2003-08-24 22:23:02.000000000 +0200
++++ fbv-1.0b/gif.c     2023-04-12 21:15:20.080578085 +0200
+@@ -31,10 +31,10 @@
+ #include <string.h>
+ #define min(a,b) ((a) < (b) ? (a) : (b))
+ #define gflush return(FH_ERROR_FILE);
+-#define grflush { DGifCloseFile(gft); return(FH_ERROR_FORMAT); }
+-#define mgrflush { free(lb); free(slb); DGifCloseFile(gft); return(FH_ERROR_FORMAT); }
++#define grflush { DGifCloseFile(gft, NULL); return(FH_ERROR_FORMAT); }
++#define mgrflush { free(lb); free(slb); DGifCloseFile(gft, NULL); return(FH_ERROR_FORMAT); }
+ #define agflush return(FH_ERROR_FORMAT);
+-#define agrflush { DGifCloseFile(gft); return(FH_ERROR_FORMAT); }
++#define agrflush { DGifCloseFile(gft, NULL); return(FH_ERROR_FORMAT); }
+ int fh_gif_id(char *name)
+@@ -81,7 +81,7 @@ int fh_gif_load(char *name,unsigned char
+     ColorMapObject *cmap;
+     int cmaps;
+-    gft=DGifOpenFileName(name);
++    gft=DGifOpenFileName(name, NULL);
+     if(gft==NULL){printf("err5\n"); gflush;} //////////
+     do
+     {
+@@ -170,7 +170,7 @@ int fh_gif_load(char *name,unsigned char
+       }
+     }
+     while( rt!= TERMINATE_RECORD_TYPE );
+-    DGifCloseFile(gft);
++    DGifCloseFile(gft, NULL);
+     return(FH_ERROR_OK);
+ }
+@@ -184,7 +184,7 @@ int fh_gif_getsize(char *name,int *x,int
+     int extcode;
+     GifRecordType rt;
+-    gft=DGifOpenFileName(name);
++    gft=DGifOpenFileName(name, NULL);
+     if(gft==NULL) gflush;
+     do
+     {
+@@ -197,7 +197,7 @@ int fh_gif_getsize(char *name,int *x,int
+               px=gft->Image.Width;
+               py=gft->Image.Height;
+               *x=px; *y=py;
+-              DGifCloseFile(gft);
++              DGifCloseFile(gft, NULL);
+               return(FH_ERROR_OK);
+               break;
+           case EXTENSION_RECORD_TYPE:
+@@ -210,7 +210,7 @@ int fh_gif_getsize(char *name,int *x,int
+       }  
+     }
+     while( rt!= TERMINATE_RECORD_TYPE );
+-    DGifCloseFile(gft);
++    DGifCloseFile(gft, NULL);
+     return(FH_ERROR_FORMAT);
+ }
+ #endif
index 68060b6613f629b70a5cceb5660b34af178fecd4..07ac9acd5e36eb4d504696b55e93fe7518071054 100644 (file)
--- a/fbv.spec
+++ b/fbv.spec
@@ -2,15 +2,16 @@ Summary:      FrameBuffer Viewer
 Summary(pl.UTF-8):     Przeglądarka obrazków dla framebuffera
 Name:          fbv
 Version:       1.0b
-Release:       7
-License:       GPL
+Release:       8
+License:       GPL v2+
 Group:         Applications/Graphics
 Source0:       http://s-tech.elsat.net.pl/fbv/%{name}-%{version}.tar.gz
 # Source0-md5: 3e466375b930ec22be44f1041e77b55d
 Patch0:                %{name}-nocenter.patch
 Patch1:                %{name}-libpng15.patch
+Patch2:                %{name}-giflib5.patch
 URL:           http://s-tech.elsat.net.pl/
-BuildRequires: giflib-devel
+BuildRequires: giflib-devel >= 5
 BuildRequires: libjpeg-devel
 BuildRequires: libpng-devel
 BuildRequires: util-linux
@@ -28,6 +29,7 @@ Obsługuje pliki PNG, JPEG, GIF i BMP.
 %setup -q
 %patch0 -p1
 %patch1 -p1
+%patch2 -p1
 
 %build
 # it's not autoconf script
@@ -37,7 +39,9 @@ Obsługuje pliki PNG, JPEG, GIF i BMP.
        --mandir=%{_mandir}
 
 %{__make} \
-       CC="%{__cc} %{rpmcflags}"
+       CC="%{__cc}" \
+       CFLAGS="%{rpmcflags} %{rpmcppflags} -Wall -D_GNU_SOURCE" \
+       LDFLAGS="%{rpmldflags} %{rpmcflags}"
 
 %install
 rm -rf $RPM_BUILD_ROOT
@@ -52,5 +56,5 @@ rm -rf $RPM_BUILD_ROOT
 %files
 %defattr(644,root,root,755)
 %doc ChangeLog README TODO
-%attr(755,root,root) %{_bindir}/*
-%{_mandir}/man1/*
+%attr(755,root,root) %{_bindir}/fbv
+%{_mandir}/man1/fbv.1*
This page took 0.14402 seconds and 4 git commands to generate.