summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorraveit65 <[email protected]>2023-05-04 16:15:06 +0200
committerraveit65 <[email protected]>2023-05-15 19:10:04 +0200
commitec957cf18919166ca8b8335475ef06f9fd5f2e67 (patch)
treea8151e793e9c6994584b86524a03da0c37ea8b46
parent727e8167fcc40a37dc91883575b98619e6b1c2b5 (diff)
downloadatril-ec957cf18919166ca8b8335475ef06f9fd5f2e67.tar.bz2
atril-ec957cf18919166ca8b8335475ef06f9fd5f2e67.tar.xz
support webkit2 4.0 and 4.1
Co-authored-by: Colomban Wendling <[email protected]>
-rw-r--r--configure.ac8
1 files changed, 7 insertions, 1 deletions
diff --git a/configure.ac b/configure.ac
index f5496aea..e25de054 100644
--- a/configure.ac
+++ b/configure.ac
@@ -622,7 +622,13 @@ AC_ARG_ENABLE(epub,
have_webkit="no"
if test "x$enable_epub" = "xyes"; then
- PKG_CHECK_MODULES(EPUB, webkit2gtk-4.1 >= $WEBKIT_REQUIRED \
+ dnl select the available WebKit2Gtk4 version, with a preference towards 4.1
+ webkit_pkg=webkit2gtk-4.1
+ PKG_CHECK_EXISTS([$webkit_pkg >= $WEBKIT_REQUIRED], [],
+ [PKG_CHECK_EXISTS([webkit2gtk-4.0 >= $WEBKIT_REQUIRED],
+ [webkit_pkg=webkit2gtk-4.0])])
+
+ PKG_CHECK_MODULES(EPUB, $webkit_pkg >= $WEBKIT_REQUIRED \
libxml-2.0 >= $LIBXML_REQUIRED zlib,have_webkit=yes,have_webkit=no)
if test "x$have_webkit" = "xyes"; then