]> git.eshelyaron.com Git - emacs.git/commitdiff
* src/image.c: Fix building with giflib on MS-Windows.
authorStefan Kangas <stefan@marxist.se>
Fri, 29 Oct 2021 18:20:46 +0000 (20:20 +0200)
committerStefan Kangas <stefan@marxist.se>
Fri, 29 Oct 2021 18:25:42 +0000 (20:25 +0200)
src/image.c

index 376a53e9672552134dfa57dd1fa310881b1f4c25..6ab9670e4b0501152c8e9b9e178e97db23d5bc7a 100644 (file)
@@ -8277,6 +8277,8 @@ DEF_DLL_FN (GifFileType *, DGifOpenFileName, (const char *));
 #  else
 DEF_DLL_FN (GifFileType *, DGifOpen, (void *, InputFunc, int *));
 DEF_DLL_FN (GifFileType *, DGifOpenFileName, (const char *, int *));
+DEF_DLL_FN (int, DGifSavedExtensionToGCB, (GifFileType *, int,
+                                          GraphicsControlBlock *));
 #  endif
 #  if HAVE_GIFERRORSTRING
 DEF_DLL_FN (char const *, GifErrorString, (int));
@@ -8294,6 +8296,9 @@ init_gif_functions (void)
   LOAD_DLL_FN (library, DGifSlurp);
   LOAD_DLL_FN (library, DGifOpen);
   LOAD_DLL_FN (library, DGifOpenFileName);
+#  if GIFLIB_MAJOR >= 5
+  LOAD_DLL_FN (library, DGifSavedExtensionToGCB);
+#  endif
 #  if HAVE_GIFERRORSTRING
   LOAD_DLL_FN (library, GifErrorString);
 #  endif
@@ -8304,12 +8309,14 @@ init_gif_functions (void)
 #  undef DGifOpen
 #  undef DGifOpenFileName
 #  undef DGifSlurp
+#  undef DGifSavedExtensionToGCB
 #  undef GifErrorString
 
 #  define DGifCloseFile fn_DGifCloseFile
 #  define DGifOpen fn_DGifOpen
 #  define DGifOpenFileName fn_DGifOpenFileName
 #  define DGifSlurp fn_DGifSlurp
+#  define DGifSavedExtensionToGCB fn_DGifSavedExtensionToGCB
 #  define GifErrorString fn_GifErrorString
 
 # endif /* WINDOWSNT */