diff --git a/configure.ac b/configure.ac index dda267bd..9843224d 100644 --- a/configure.ac +++ b/configure.ac @@ -1188,7 +1188,6 @@ if test x"$with_libspng" != x"no"; then [AC_DEFINE(HAVE_SPNG,1,[define if you have libspng installed.]) with_libspng=yes PACKAGES_USED="$PACKAGES_USED spng" - with_png=no ], [ ] diff --git a/libvips/foreign/pngload.c b/libvips/foreign/pngload.c index 1c4d34b0..8092078e 100644 --- a/libvips/foreign/pngload.c +++ b/libvips/foreign/pngload.c @@ -50,7 +50,7 @@ #include "pforeign.h" -#ifdef HAVE_PNG +#if defined(HAVE_PNG) && !defined(HAVE_SPNG) typedef struct _VipsForeignLoadPng { VipsForeignLoad parent_object; @@ -387,7 +387,7 @@ vips_foreign_load_png_buffer_init( VipsForeignLoadPngBuffer *buffer ) { } -#endif /*HAVE_PNG*/ +#endif /*defined(HAVE_PNG) && !defined(HAVE_SPNG)*/ /** * vips_pngload: