Fixed build for giflib version >= 5.0; fixed issue #90

This commit is contained in:
Bert Münnich 2013-04-21 13:55:08 +02:00
parent 593da23cf3
commit b1a24cb018
2 changed files with 5 additions and 1 deletions

View File

@ -1,4 +1,4 @@
VERSION = git-20130414 VERSION = git-20130421
PREFIX = /usr/local PREFIX = /usr/local
MANPREFIX = $(PREFIX)/share/man MANPREFIX = $(PREFIX)/share/man

View File

@ -125,7 +125,11 @@ bool img_load_gif(img_t *img, const fileinfo_t *file)
img->multi.cnt = 0; img->multi.cnt = 0;
img->multi.sel = 0; img->multi.sel = 0;
#if defined(GIFLIB_MAJOR) && GIFLIB_MAJOR >= 5
gif = DGifOpenFileName(file->path, NULL);
#else
gif = DGifOpenFileName(file->path); gif = DGifOpenFileName(file->path);
#endif
if (gif == NULL) { if (gif == NULL) {
warn("could not open gif file: %s", file->name); warn("could not open gif file: %s", file->name);
return false; return false;