configure: check for a symbol contained in libpng

rather than 'main'. this fixes mis-detection when cross compiling.

Change-Id: I9560ca4805ef9eea5bd7370aeef2dcf6ed293478
This commit is contained in:
James Zern 2011-10-07 19:44:03 -07:00
parent 408b8918c1
commit 767afea250

View File

@ -46,7 +46,7 @@ CPPFLAGS="$PNG_INCLUDES $CPPFLAGS"
LIBS="$PNG_LIBS $LIBS"
AC_CHECK_HEADER(png.h,
AC_CHECK_LIB(png, main,
AC_CHECK_LIB(png, png_get_libpng_ver,
[PNG_LIBS="$PNG_LIBS -lpng"
PNG_INCLUDES="$PNG_INCLUDES -DWEBP_HAVE_PNG"
AC_DEFINE(WEBP_HAVE_PNG, [1], [Set to 1 if PNG library is installed])