Commit a76460f4 authored by Michael Natterer's avatar Michael Natterer 😴

configure, plug-ins: make libpng a hard dependency

parent 4573a12b
...@@ -1282,27 +1282,10 @@ AC_SUBST(GS_LIBS) ...@@ -1282,27 +1282,10 @@ AC_SUBST(GS_LIBS)
# Check for libpng # Check for libpng
################## ##################
AC_ARG_WITH(libpng, [ --without-libpng build without PNG support]) PKG_CHECK_MODULES(PNG, libpng >= libpng_required_version)
have_libpng=no MIME_TYPES="$MIME_TYPES;image/png;image/x-icon"
if test "x$with_libpng" != xno; then PNG_CFLAGS="$PNG_CFLAGS -DPNG_PEDANTIC_WARNINGS"
have_libpng=yes
PKG_CHECK_MODULES(PNG, libpng >= libpng_required_version,
FILE_PNG='file-png$(EXEEXT)',
[have_libpng="no (libpng not found)"
AC_MSG_ERROR([
*** Checks for PNG library failed. You can build without it by passing
*** --without-libpng to configure but you won't be able to use PNGs then.])])
fi
if test "x$have_libpng" = xyes; then
MIME_TYPES="$MIME_TYPES;image/png;image/x-icon"
PNG_CFLAGS="$PNG_CFLAGS -DPNG_PEDANTIC_WARNINGS"
fi
AC_SUBST(FILE_PNG)
AM_CONDITIONAL(HAVE_PNG, test "x$have_libpng" = xyes)
################## ##################
...@@ -2370,7 +2353,6 @@ Optional Plug-Ins: ...@@ -2370,7 +2353,6 @@ Optional Plug-Ins:
OpenEXR: $have_openexr OpenEXR: $have_openexr
PDF (import): $have_poppler PDF (import): $have_poppler
PDF (export): $have_cairo_pdf PDF (export): $have_cairo_pdf
PNG: $have_libpng
Print: $enable_print Print: $enable_print
PSP: $have_zlib PSP: $have_zlib
Python: $enable_python Python: $enable_python
......
...@@ -37,10 +37,6 @@ endif ...@@ -37,10 +37,6 @@ endif
endif endif
endif endif
if HAVE_PNG
file_ico = file-ico
endif
if OS_WIN32 if OS_WIN32
twain = twain twain = twain
win_snap = win-snap win_snap = win-snap
...@@ -61,7 +57,7 @@ SUBDIRS = \ ...@@ -61,7 +57,7 @@ SUBDIRS = \
file-faxg3 \ file-faxg3 \
file-fits \ file-fits \
file-fli \ file-fli \
$(file_ico) \ file-ico \
$(file_jpeg) \ $(file_jpeg) \
$(file_psd) \ $(file_psd) \
file-sgi \ file-sgi \
......
...@@ -103,7 +103,7 @@ libexec_PROGRAMS = \ ...@@ -103,7 +103,7 @@ libexec_PROGRAMS = \
$(FILE_PDF_LOAD) \ $(FILE_PDF_LOAD) \
$(FILE_PDF_SAVE) \ $(FILE_PDF_SAVE) \
file-pix \ file-pix \
$(FILE_PNG) \ file-png \
file-pnm \ file-pnm \
$(FILE_PS) \ $(FILE_PS) \
$(FILE_PSP) \ $(FILE_PSP) \
...@@ -175,7 +175,6 @@ EXTRA_PROGRAMS = \ ...@@ -175,7 +175,6 @@ EXTRA_PROGRAMS = \
file-mng \ file-mng \
file-pdf-load \ file-pdf-load \
file-pdf-save \ file-pdf-save \
file-png \
file-ps \ file-ps \
file-psp \ file-psp \
file-svg \ file-svg \
......
...@@ -56,7 +56,7 @@ ...@@ -56,7 +56,7 @@
'file-pat' => { ui => 1, gegl => 1 }, 'file-pat' => { ui => 1, gegl => 1 },
'file-pcx' => { ui => 1, gegl => 1 }, 'file-pcx' => { ui => 1, gegl => 1 },
'file-pix' => { ui => 1, gegl => 1 }, 'file-pix' => { ui => 1, gegl => 1 },
'file-png' => { ui => 1, gegl => 1, optional => 1, libs => 'PNG_LIBS', cflags => 'PNG_CFLAGS' }, 'file-png' => { ui => 1, gegl => 1, libs => 'PNG_LIBS', cflags => 'PNG_CFLAGS' },
'file-pnm' => { ui => 1, gegl => 1 }, 'file-pnm' => { ui => 1, gegl => 1 },
'file-pdf-load' => { ui => 1, optional => 1, libs => 'POPPLER_LIBS', cflags => 'POPPLER_CFLAGS' }, 'file-pdf-load' => { ui => 1, optional => 1, libs => 'POPPLER_LIBS', cflags => 'POPPLER_CFLAGS' },
'file-pdf-save' => { ui => 1, gegl => 1, optional => 1, libs => 'CAIRO_PDF_LIBS', cflags => 'CAIRO_PDF_CFLAGS' }, 'file-pdf-save' => { ui => 1, gegl => 1, optional => 1, libs => 'CAIRO_PDF_LIBS', cflags => 'CAIRO_PDF_CFLAGS' },
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment