Mercurial > dwindows
changeset 2747:c83d6261ce3e
GTK4: Change configure tests, and try to support webkit.
Try gtk4-x11 first then just gtk4 (wayland)... so if the X11 version is
available we can use Xlib functions if on the X11 backend.
If requesting GTK4 use webkitgtk-5.0 the package reported for GTK4.
I was unable to build webkit for GTK4 due to dependency nightmares.
Will try to build it on Fedora and see if I can actuall test this.
author | bsmith@81767d24-ef19-dc11-ae90-00e081727c95 |
---|---|
date | Mon, 27 Dec 2021 14:03:33 +0000 |
parents | 0ce46809e95d |
children | d8db838d5616 |
files | configure configure.in |
diffstat | 2 files changed, 22 insertions(+), 4 deletions(-) [+] |
line wrap: on
line diff
--- a/configure Wed Dec 22 09:54:41 2021 +0000 +++ b/configure Mon Dec 27 14:03:33 2021 +0000 @@ -5485,12 +5485,21 @@ GTK_PACKAGES="gtk+-2.0 gthread-2.0" GTK_LIBS=`$PKG_CFG --silence-errors --libs $GTK_PACKAGES` fi + # Default WebKitGTK test is 4.0 for GTK3 + WEBKIT_PKG="webkit2gtk-4.0" if test $with_gtk4 = "yes"; then DW_DIR=gtk4 - GTK_PACKAGES="gtk4" + # First try the X11 version so we can call Xlib directly + # to fill in the holes not available with Wayland + GTK_PACKAGES="gtk4-x11" GTK_LIBS=`$PKG_CFG --silence-errors --libs $GTK_PACKAGES` + if test x"$GTK_LIBS" = x; then + GTK_PACKAGES="gtk4" + GTK_LIBS=`$PKG_CFG --silence-errors --libs $GTK_PACKAGES` + fi + # WebKitGTK built for GTK4 becomes 5.0 + WEBKIT_PKG="webkitgtk-5.0" fi - WEBKIT_PKG="webkit2gtk-4.0" if test x"$GTK_LIBS" = x; then GTK_PACKAGES="gtk+-3.0" GTK_LIBS=`$PKG_CFG --silence-errors --libs $GTK_PACKAGES`
--- a/configure.in Wed Dec 22 09:54:41 2021 +0000 +++ b/configure.in Mon Dec 27 14:03:33 2021 +0000 @@ -219,12 +219,21 @@ GTK_PACKAGES="gtk+-2.0 gthread-2.0" GTK_LIBS=`$PKG_CFG --silence-errors --libs $GTK_PACKAGES` fi + # Default WebKitGTK test is 4.0 for GTK3 + WEBKIT_PKG="webkit2gtk-4.0" if test $with_gtk4 = "yes"; then DW_DIR=gtk4 - GTK_PACKAGES="gtk4" + # First try the X11 version so we can call Xlib directly + # to fill in the holes not available with Wayland + GTK_PACKAGES="gtk4-x11" GTK_LIBS=`$PKG_CFG --silence-errors --libs $GTK_PACKAGES` + if test x"$GTK_LIBS" = x; then + GTK_PACKAGES="gtk4" + GTK_LIBS=`$PKG_CFG --silence-errors --libs $GTK_PACKAGES` + fi + # WebKitGTK built for GTK4 becomes 5.0 + WEBKIT_PKG="webkitgtk-5.0" fi - WEBKIT_PKG="webkit2gtk-4.0" if test x"$GTK_LIBS" = x; then GTK_PACKAGES="gtk+-3.0" GTK_LIBS=`$PKG_CFG --silence-errors --libs $GTK_PACKAGES`