diff configure.in @ 1573:1d4de024f7cb

(cautious version of) fix for configure.in for libpng 1.4 (reported by xentalion)
author corvid <corvid@lavabit.com>
date Fri, 19 Feb 2010 21:31:12 +0000
parents 26fc17b38ef2
children d70c73254772
line wrap: on
line diff
--- a/configure.in	Wed Feb 17 23:10:05 2010 +0000
+++ b/configure.in	Fri Feb 19 21:31:12 2010 +0000
@@ -213,7 +213,10 @@
 
 dnl Check if the user hasn't set the variable $PNG_CONFIG
   if test -z "$PNG_CONFIG"; then
-    PNG_CONFIG=`which libpng12-config`
+    PNG_CONFIG=`which libpng14-config`
+    if test -z "$PNG_CONFIG"; then
+      PNG_CONFIG=`which libpng12-config`
+    fi
     if test -z "$PNG_CONFIG"; then
       PNG_CONFIG=`which libpng-config`
     fi
@@ -236,6 +239,7 @@
     AC_MSG_CHECKING([for libpng version])
     png_version=`$PNG_CONFIG --version`
     case $png_version in
+      1.4.*) AC_MSG_RESULT([$png_version (newer version)]) ;;
       1.2.*) AC_MSG_RESULT([$png_version (newer version)]) ;;
       1.0.*) AC_MSG_RESULT([$png_version (older version)]) ;;
           *) AC_MSG_RESULT([ERROR]) ;;
@@ -253,7 +257,7 @@
 
     if test "x$png_ok" = "xyes"; then
       old_libs="$LIBS"
-      AC_CHECK_LIB(png, png_check_sig, png_ok=yes, png_ok=no, $LIBZ_LIBS -lm)
+      AC_CHECK_LIB(png, png_sig_cmp, png_ok=yes, png_ok=no, $LIBZ_LIBS -lm)
       LIBS="$old_libs"
 
       if test "x$png_ok" = "xyes"; then