From da829e02ff9a192fe7dbbc0c98d97e0990b53303 Mon Sep 17 00:00:00 2001 From: Mamoru TASAKA Date: Mar 31 2017 06:34:43 +0000 Subject: F-26+: switch to WebKit2 (on Fedora: webkitgtk4) --- diff --git a/gphotoframe-2.0.2-WebKit2.patch b/gphotoframe-2.0.2-WebKit2.patch new file mode 100644 index 0000000..ac943ad --- /dev/null +++ b/gphotoframe-2.0.2-WebKit2.patch @@ -0,0 +1,20 @@ +--- gphotoframe-2.0.2-hg2084299dffb6/lib/plugins/facebook/authdialog.py.wk 2015-03-27 10:40:55.000000000 +0900 ++++ gphotoframe-2.0.2-hg2084299dffb6/lib/plugins/facebook/authdialog.py 2017-03-31 15:17:43.243296343 +0900 +@@ -9,7 +9,7 @@ + import re + # from gettext import gettext as _ + +-from gi.repository import GObject, Gtk, Gdk, WebKit ++from gi.repository import GObject, Gtk, Gdk, WebKit2 + + from ..flickr.authdialog import PluginFlickrDialog + from ...utils.urlgetautoproxy import urlget_with_autoproxy +--- gphotoframe-2.0.2-hg2084299dffb6/lib/utils/authwebkit.py.wk 2015-03-27 10:40:55.000000000 +0900 ++++ gphotoframe-2.0.2-hg2084299dffb6/lib/utils/authwebkit.py 2017-03-31 15:17:39.507286152 +0900 +@@ -1,5 +1,5 @@ + import re +-from gi.repository import Gtk, GObject, WebKit ++from gi.repository import Gtk, GObject, WebKit2 + + class AuthWebKitScrolledWindow(Gtk.ScrolledWindow): + diff --git a/gphotoframe.spec b/gphotoframe.spec index 4696692..cc628bc 100644 --- a/gphotoframe.spec +++ b/gphotoframe.spec @@ -14,14 +14,19 @@ %global mainver 2.0.2 #%%define minorver -b1 -%global mainrel 2 +%global mainrel 3 %global rpmminorver %(echo "%minorver" | sed -e 's|^-||' | sed -e 's|\\\.||') %global fedorarel %{?minorver:0.}%{mainrel}%{?minorver:.%rpmminorver}%{?hghash:.hg%hghash} +%global usewebkit2 0 +%if 0%{?fedora} >= 26 +%global usewebkit2 1 +%endif + Name: gphotoframe Version: %{mainver} -Release: %{fedorarel}%{?dist}.3 +Release: %{fedorarel}%{?dist} Summary: Photo Frame Gadget for the GNOME Desktop Group: Amusements/Graphics @@ -50,6 +55,8 @@ Patch4: gphotoframe-2.0.1-gdk-pixbuf2-2_31_2_API.patch # https://bugzilla.redhat.com/show_bug.cgi?id=1296817 # disable libproxy support for now Patch5: gphotoframe-2.0.2-disable-libproxy.patch +# F-26+: Switch to WebKit2 (on Fedora: it is webkitgtk4) +Patch6: gphotoframe-2.0.2-WebKit2.patch BuildRequires: GConf2 BuildRequires: desktop-file-utils @@ -72,7 +79,11 @@ Requires: python-oauth # girepository Requires: gtk3 +%if 0%{?usewebkit2} +Requires: webkitgtk4 +%else Requires: webkitgtk3 +%endif # Optional # see bug 1296817 %if 0%{?fedora} < 23 @@ -111,6 +122,9 @@ for gnome-screensaver compatibility. %if 0%{?fedora} >= 23 %patch5 -p1 -b .libproxy_disable %endif +%if 0%{?usewebkit2} +%patch6 -p1 -b .wk2 +%endif # Remove unneeded shebangs grep -rl '^#![ \t]*%{_bindir}' lib/ | \ @@ -246,6 +260,9 @@ exit 0 %{_datadir}/applications/screensavers/%{name}-screensaver.desktop %changelog +* Fri Mar 31 2017 Mamoru TASAKA - 2.0.2-3.hg2084299dffb6 +- F-26+: switch to WebKit2 (on Fedora: webkitgtk4) + * Fri Feb 10 2017 Fedora Release Engineering - 2.0.2-2.hg2084299dffb6.3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild