Merge pull request #436 from felixbuenemann/fix-giflib4-detection
Fix configure check for giflib4
This commit is contained in:
commit
bd79a10453
16
acinclude.m4
16
acinclude.m4
@ -631,14 +631,26 @@ if test "$GIFLIB_LIBS" = ""; then
|
||||
INCLUDES="$GIFLIB_INCLUDES $INCLUDES"
|
||||
|
||||
# Try the standard search path first
|
||||
AC_TRY_LINK([#include <gif_lib.h>],[EGifSetGifVersion(0,0)], [
|
||||
AC_TRY_LINK([#include <gif_lib.h>],[
|
||||
#if defined(GIFLIB_MAJOR) && GIFLIB_MAJOR > 4
|
||||
EGifSetGifVersion(0,0);
|
||||
#else
|
||||
GifLastError();
|
||||
#endif
|
||||
], [
|
||||
GIFLIB_LIBS="-lgif"
|
||||
], [
|
||||
# giflib is not in the standard search path, try $prefix
|
||||
|
||||
LIBS="-L${prefix}/lib $LIBS"
|
||||
|
||||
AC_TRY_LINK([#include <gif_lib.h>],[EGifSetGifVersion(0,0)], [
|
||||
AC_TRY_LINK([#include <gif_lib.h>],[
|
||||
#if defined(GIFLIB_MAJOR) && GIFLIB_MAJOR > 4
|
||||
EGifSetGifVersion(0,0);
|
||||
#else
|
||||
GifLastError();
|
||||
#endif
|
||||
], [
|
||||
GIFLIB_LIBS="-L${prefix}/lib -lgif"
|
||||
], [
|
||||
GIFLIB_LIBS=no
|
||||
|
Loading…
Reference in New Issue
Block a user