Make sure HAVE_PNG gets set no matter how png is detected.

This commit is contained in:
Bill Currie 2010-12-20 21:31:41 +09:00
parent d272775613
commit 0d1d3a9bb2

View file

@ -77,11 +77,11 @@ if test "x$enable_png" != "xno"; then
AC_CHECK_LIB(png, png_set_read_fn, HAVE_PNG=yes, HAVE_PNG=no, [$LIBS])
if test "x$HAVE_PNG" = "xyes"; then
AC_CHECK_HEADER(png.h, HAVE_PNG=yes, HAVE_PNG=no)
if test "x$HAVE_PNG" = "xyes"; then
PNG_LIBS="-lpng"
AC_DEFINE(HAVE_PNG, 1, [Define if you have libpng])
fi
fi
fi
fi
AC_SUBST(PNG_LIBS)
if test "x$HAVE_PNG" = "xyes"; then
PNG_LIBS="-lpng"
AC_DEFINE(HAVE_PNG, 1, [Define if you have libpng])
fi