Skip to content

Commit

Permalink
Mike Frysinger 2009-10-04 22:28:31 PDT
Browse files Browse the repository at this point in the history
this patch should convert SDL_image's png lookup to pkg-config
  • Loading branch information
slouken committed Oct 5, 2009
1 parent f71d64e commit 516a07f
Showing 1 changed file with 9 additions and 3 deletions.
12 changes: 9 additions & 3 deletions configure.in
Expand Up @@ -172,9 +172,15 @@ if test x$enable_jpg = xyes || test x$enable_tif = xyes; then
fi
fi

if test x$enable_png = xyes; then
AC_CHECK_HEADER([png.h], [have_png_hdr=yes])
AC_CHECK_LIB([png], [png_create_read_struct], [have_png_lib=yes], [], [-lz])
if test "x$enable_png" = xyes; then
PKG_CHECK_MODULES([LIBPNG], [libpng], [dnl
have_png_hdr=yes
CFLAGS="$LIBPNG_CFLAGS $CFLAGS"
have_png_lib=yes
], [dnl
AC_CHECK_HEADER([png.h], [have_png_hdr=yes])
AC_CHECK_LIB([png], [png_create_read_struct], [have_png_lib=yes], [], [-lz])
])
if test x$have_png_hdr = xyes -a x$have_png_lib = xyes; then
AC_DEFINE([LOAD_PNG])

Expand Down

0 comments on commit 516a07f

Please sign in to comment.