diff options
author | Antoine Brodin <antoine@FreeBSD.org> | 2015-11-13 00:07:45 +0800 |
---|---|---|
committer | Antoine Brodin <antoine@FreeBSD.org> | 2015-11-13 00:07:45 +0800 |
commit | d1b67d955db2307b124f146c9d410d9c5bd0bd18 (patch) | |
tree | 6acd1d7844057ef5dc2cd881889c4a3b129ae0b9 /emulators/vice/files | |
parent | 7fe3462d55d652f6dd6aea6f0b5dd22af0e6853a (diff) | |
download | freebsd-ports-gnome-d1b67d955db2307b124f146c9d410d9c5bd0bd18.tar.gz freebsd-ports-gnome-d1b67d955db2307b124f146c9d410d9c5bd0bd18.tar.zst freebsd-ports-gnome-d1b67d955db2307b124f146c9d410d9c5bd0bd18.zip |
Allow building with giflib 5.1
PR: 204492
Diffstat (limited to 'emulators/vice/files')
-rw-r--r-- | emulators/vice/files/patch-src_gfxoutputdrv_gifdrv.c | 50 |
1 files changed, 50 insertions, 0 deletions
diff --git a/emulators/vice/files/patch-src_gfxoutputdrv_gifdrv.c b/emulators/vice/files/patch-src_gfxoutputdrv_gifdrv.c new file mode 100644 index 000000000000..f10b21538cc5 --- /dev/null +++ b/emulators/vice/files/patch-src_gfxoutputdrv_gifdrv.c @@ -0,0 +1,50 @@ +--- src/gfxoutputdrv/gifdrv.c.orig 2012-07-25 23:46:05 UTC ++++ src/gfxoutputdrv/gifdrv.c +@@ -114,7 +114,11 @@ static int gifdrv_open(screenshot_t *scr + if (EGifPutScreenDesc(sdata->fd, screenshot->width, screenshot->height, 8, 0, gif_colors) == GIF_ERROR || + EGifPutImageDesc(sdata->fd, 0, 0, screenshot->width, screenshot->height, 0, NULL) == GIF_ERROR) + { ++#if GIFLIB_MAJOR == 5 && GIFLIB_MINOR >= 1 || GIFLIB_MAJOR > 5 ++ EGifCloseFile(sdata->fd, NULL); ++#else + EGifCloseFile(sdata->fd); ++#endif + VICE_FreeMapObject(gif_colors); + lib_free(sdata->data); + lib_free(sdata->ext_filename); +@@ -145,7 +149,11 @@ static int gifdrv_close(screenshot_t *sc + + sdata = screenshot->gfxoutputdrv_data; + ++#if GIFLIB_MAJOR == 5 && GIFLIB_MINOR >= 1 || GIFLIB_MAJOR > 5 ++ EGifCloseFile(sdata->fd, NULL); ++#else + EGifCloseFile(sdata->fd); ++#endif + VICE_FreeMapObject(gif_colors); + + /* for some reason giflib will create a file with unexpected +@@ -184,7 +192,11 @@ static char *gifdrv_memmap_ext_filename; + + static int gifdrv_close_memmap(void) + { ++#if GIFLIB_MAJOR == 5 && GIFLIB_MINOR >= 1 || GIFLIB_MAJOR > 5 ++ EGifCloseFile(gifdrv_memmap_fd, NULL); ++#else + EGifCloseFile(gifdrv_memmap_fd); ++#endif + VICE_FreeMapObject(gif_colors); + lib_free(gifdrv_memmap_ext_filename); + +@@ -231,7 +243,11 @@ static int gifdrv_open_memmap(const char + if (EGifPutScreenDesc(gifdrv_memmap_fd, x_size, y_size, 8, 0, gif_colors) == GIF_ERROR || + EGifPutImageDesc(gifdrv_memmap_fd, 0, 0, x_size, y_size, 0, NULL) == GIF_ERROR) + { ++#if GIFLIB_MAJOR == 5 && GIFLIB_MINOR >= 1 || GIFLIB_MAJOR > 5 ++ EGifCloseFile(gifdrv_memmap_fd); ++#else + EGifCloseFile(gifdrv_memmap_fd); ++#endif + VICE_FreeMapObject(gif_colors); + lib_free(gifdrv_memmap_ext_filename); + return -1; |