[gimp] configure: improve libheif detection and output.
- From: Jehan <jehanp src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gimp] configure: improve libheif detection and output.
- Date: Tue, 12 Nov 2019 14:26:39 +0000 (UTC)
commit 41285813a599e1902cd2e75cc69a0550c21b8b3f
Author: Jehan <jehan girinstud io>
Date: Tue Nov 12 14:48:26 2019 +0100
configure: improve libheif detection and output.
Replace the "Heif >= 1.4.0" line in the summary output by a comment in
the "Heif" line explaining this is about profile support.
Also add a >= 1.6.0 test and output a warning for Windows and macOS (cf.
bug #4185).
configure.ac | 37 +++++++++++++++++++++++++++----------
1 file changed, 27 insertions(+), 10 deletions(-)
---
diff --git a/configure.ac b/configure.ac
index 532c7ebfbf..7c70eafad8 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1789,27 +1789,45 @@ AM_CONDITIONAL(HAVE_WEBP, test "x$have_webp" = xyes)
AC_ARG_WITH(libheif, [ --without-libheif build without libheif support])
have_libheif=no
+have_libheif_1_4_0=no
+have_libheif_1_6_0=no
if test "x$with_libheif" != xno; then
have_libheif_1_4_0=yes
+ have_libheif_1_6_0=yes
have_libheif=yes
- PKG_CHECK_MODULES(LIBHEIF, libheif >= 1.4.0,,
- [have_libheif_1_4_0="no (libheif >= 1.4.0 not found)"])
- PKG_CHECK_MODULES(LIBHEIF, libheif >= libheif_required_version,
- FILE_HEIF='file-heif$(EXEEXT)',
- [have_libheif="no (libheif not found)"])
+ PKG_CHECK_MODULES(LIBHEIF, libheif >= 1.6.0,,
+ [
+ have_libheif_1_6_0="no (libheif >= 1.6.0 not found)"
+ PKG_CHECK_MODULES(LIBHEIF, libheif >= 1.4.0,,
+ [
+ have_libheif_1_4_0="no (libheif >= 1.4.0 not found)"
+ PKG_CHECK_MODULES(LIBHEIF, libheif >= libheif_required_version,
+ FILE_HEIF='file-heif$(EXEEXT)',
+ [have_libheif="no (libheif not found)"])
+ ])
+ ])
fi
+AC_SUBST(FILE_HEIF)
+AM_CONDITIONAL(HAVE_LIBHEIF, test "x$have_libheif" = xyes)
+
if test "x$have_libheif" = xyes; then
MIME_TYPES="$MIME_TYPES;image/heif;image/heic"
+ have_libheif="yes [[profile support: $have_libheif_1_4_0]]"
fi
-AC_SUBST(FILE_HEIF)
-AM_CONDITIONAL(HAVE_LIBHEIF, test "x$have_libheif" = xyes)
-
if test "x$have_libheif_1_4_0" = xyes; then
AC_DEFINE(HAVE_LIBHEIF_1_4_0, 1,
[Define to 1 if libheif >= 1.4.0 is available])
fi
+if test "x$have_libheif_1_6_0" = xyes; then
+ AC_DEFINE(HAVE_LIBHEIF_1_6_0, 1,
+ [Define to 1 if libheif >= 1.6.0 is available])
+elif test "x$platform_win32" = xyes || test "x$platform_osx" = xyes; then
+ warning_libheif="
+WARNING: libheif lower than version 1.6.0 are known to crash when
+ exporting on Windows and macOS (bug #4185). Please update."
+fi
########################
@@ -3134,7 +3152,6 @@ Optional Plug-Ins:
OpenEXR: $have_openexr
WebP: $have_webp
Heif: $have_libheif
- Heif >= 1.4.0: $have_libheif_1_4_0
PDF (export): $have_cairo_pdf
Print: $enable_print
Python 3 plug-ins: $with_python
@@ -3158,7 +3175,7 @@ Tests:
Test desktop file $have_desktop_file_validate
Bug report URL: $with_bug_report_url
-$override_bug_report_url$warning_vector_icons_windows$warning_glib_networking$warning_gcc$warning_python$warning_javascript$warning_lua"
+$override_bug_report_url$warning_vector_icons_windows$warning_glib_networking$warning_gcc$warning_python$warning_javascript$warning_lua$warning_libheif"
if test "x$required_deps" = "x"; then
AC_OUTPUT
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]