etrunko pushed a commit to branch evas-1.7.

commit 391002c9a45da748b239c81b49629318696746e6
Author: Doug Newgard <[email protected]>
Date:   Thu Aug 1 12:35:46 2013 -0300

    evas: Fix evas gif image loader for libgif version 5
    
    Backport of 23ed511
---
 ChangeLog                                     |  4 ++++
 src/modules/loaders/gif/evas_image_load_gif.c | 16 ++++++++++++++++
 2 files changed, 20 insertions(+)

diff --git a/ChangeLog b/ChangeLog
index c46d1f5..ed8256d 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1328,3 +1328,7 @@
 2013-07-01  Tom Hacohen
 
         * Evas textblock: Fixed issue when parsing formats with quotes.
+
+2013-08-01  Doug Newgard
+
+        * Fix build with giflib 5
diff --git a/src/modules/loaders/gif/evas_image_load_gif.c 
b/src/modules/loaders/gif/evas_image_load_gif.c
index 18a6e23..6b6ef3d 100644
--- a/src/modules/loaders/gif/evas_image_load_gif.c
+++ b/src/modules/loaders/gif/evas_image_load_gif.c
@@ -700,7 +700,11 @@ evas_image_load_file_head_gif(Image_Entry *ie, const char 
*file, const char *key
         return EINA_FALSE;
      }
 
+#if GIFLIB_MAJOR >= 5
+   gif = DGifOpenFileHandle(fd, NULL);
+#else
    gif = DGifOpenFileHandle(fd);
+#endif
    if (!gif)
      {
         if (fd) close(fd);
@@ -838,7 +842,11 @@ evas_image_load_specific_frame(Image_Entry *ie, const char 
*file, int frame_inde
         return EINA_FALSE;
      }
 
+#if GIFLIB_MAJOR >= 5
+   gif = DGifOpenFileHandle(fd, NULL);
+#else
    gif = DGifOpenFileHandle(fd);
+#endif
    if (!gif)
      {
         if (fd) close(fd);
@@ -927,7 +935,11 @@ evas_image_load_file_data_gif(Image_Entry *ie, const char 
*file, const char *key
                   return EINA_FALSE;
                }
 
+#if GIFLIB_MAJOR >= 5
+             gif = DGifOpenFileHandle(fd, NULL);
+#else
              gif = DGifOpenFileHandle(fd);
+#endif
              if (!gif)
                {
                   if (fd) close(fd);
@@ -1000,7 +1012,11 @@ evas_image_load_frame_duration_gif(Image_Entry *ie, 
const char *file, const int
 #endif
    if (fd < 0) return -1;
 
+#if GIFLIB_MAJOR >=5
+   gif = DGifOpenFileHandle(fd, NULL);
+#else
    gif = DGifOpenFileHandle(fd);
+#endif
    if (!gif)
      {
         if (fd) close(fd);

-- 

------------------------------------------------------------------------------
Get your SQL database under version control now!
Version control is standard for application code, but databases havent 
caught up. So what steps can you take to put your SQL databases under 
version control? Why should you start doing it? Read more to find out.
http://pubads.g.doubleclick.net/gampad/clk?id=49501711&iu=/4140/ostg.clktrk

Reply via email to