summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSamuli Suominen <ssuominen@gentoo.org>2014-05-31 19:02:31 +0000
committerSamuli Suominen <ssuominen@gentoo.org>2014-05-31 19:02:31 +0000
commita6a38a4a243cf6ae02236a20d161f1e106dcfd2b (patch)
tree8a0aef7b8232a5b172576053abd6884d7eee3379 /xfce-extra/xfce4-weather-plugin
parentLooks to work with both upower versions (diff)
downloadgentoo-2-a6a38a4a243cf6ae02236a20d161f1e106dcfd2b.tar.gz
gentoo-2-a6a38a4a243cf6ae02236a20d161f1e106dcfd2b.tar.bz2
gentoo-2-a6a38a4a243cf6ae02236a20d161f1e106dcfd2b.zip
Restrict -r0 to old UPower and add -r1 for compability with UPower >= 0.99
(Portage version: 2.2.10/cvs/Linux x86_64, signed Manifest commit with key 4868F14D)
Diffstat (limited to 'xfce-extra/xfce4-weather-plugin')
-rw-r--r--xfce-extra/xfce4-weather-plugin/ChangeLog9
-rw-r--r--xfce-extra/xfce4-weather-plugin/files/xfce4-weather-plugin-0.8.3-upower-0.99.patch64
-rw-r--r--xfce-extra/xfce4-weather-plugin/xfce4-weather-plugin-0.8.3-r1.ebuild40
-rw-r--r--xfce-extra/xfce4-weather-plugin/xfce4-weather-plugin-0.8.3.ebuild4
4 files changed, 114 insertions, 3 deletions
diff --git a/xfce-extra/xfce4-weather-plugin/ChangeLog b/xfce-extra/xfce4-weather-plugin/ChangeLog
index b4ffa00c2a8d..c46ecfc4a997 100644
--- a/xfce-extra/xfce4-weather-plugin/ChangeLog
+++ b/xfce-extra/xfce4-weather-plugin/ChangeLog
@@ -1,6 +1,13 @@
# ChangeLog for xfce-extra/xfce4-weather-plugin
# Copyright 1999-2014 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/xfce-extra/xfce4-weather-plugin/ChangeLog,v 1.34 2014/05/26 19:49:28 ssuominen Exp $
+# $Header: /var/cvsroot/gentoo-x86/xfce-extra/xfce4-weather-plugin/ChangeLog,v 1.35 2014/05/31 19:02:31 ssuominen Exp $
+
+*xfce4-weather-plugin-0.8.3-r1 (31 May 2014)
+
+ 31 May 2014; Samuli Suominen <ssuominen@gentoo.org>
+ +files/xfce4-weather-plugin-0.8.3-upower-0.99.patch,
+ +xfce4-weather-plugin-0.8.3-r1.ebuild, xfce4-weather-plugin-0.8.3.ebuild:
+ Restrict -r0 to old UPower and add -r1 for compability with UPower >= 0.99
26 May 2014; Samuli Suominen <ssuominen@gentoo.org>
xfce4-weather-plugin-0.8.3.ebuild:
diff --git a/xfce-extra/xfce4-weather-plugin/files/xfce4-weather-plugin-0.8.3-upower-0.99.patch b/xfce-extra/xfce4-weather-plugin/files/xfce4-weather-plugin-0.8.3-upower-0.99.patch
new file mode 100644
index 000000000000..0e3d6e8cc4bb
--- /dev/null
+++ b/xfce-extra/xfce4-weather-plugin/files/xfce4-weather-plugin-0.8.3-upower-0.99.patch
@@ -0,0 +1,64 @@
+http://bug-attachment.xfce.org/attachment.cgi?id=5500
+
+From 79887843c58ef21233a0de571474ac656f977d7c Mon Sep 17 00:00:00 2001
+From: Eric Koegel <eric.koegel@gmail.com>
+Date: Fri, 30 May 2014 19:01:08 +0300
+Subject: [PATCH] Update for Upower 0.99
+
+Upower changed a singal handler.
+---
+ panel-plugin/weather.c | 22 +++++++++++++++++-----
+ 1 file changed, 17 insertions(+), 5 deletions(-)
+
+diff --git a/panel-plugin/weather.c b/panel-plugin/weather.c
+index efa8559..30eddb3 100644
+--- a/panel-plugin/weather.c
++++ b/panel-plugin/weather.c
+@@ -1553,8 +1553,14 @@ proxy_auth(SoupSession *session,
+
+ #ifdef HAVE_UPOWER_GLIB
+ static void
++#if UP_CHECK_VERSION(0, 99, 0)
+ upower_changed_cb(UpClient *client,
++ GParamSpec *pspec,
+ plugin_data *data)
++#else /* UP_CHECK_VERSION < 0.99 */
++upower_changed_cb(UpClient *client,
++ plugin_data *data)
++#endif /* UP_CHECK_VERSION */
+ {
+ gboolean on_battery;
+
+@@ -1576,7 +1582,7 @@ upower_changed_cb(UpClient *client,
+ schedule_next_wakeup(data);
+ }
+ }
+-#endif
++#endif /* HAVE_UPOWER_GLIB */
+
+
+ static void
+@@ -2171,10 +2177,16 @@ weather_construct(XfcePanelPlugin *plugin)
+ G_CALLBACK(xfceweather_show_about), data);
+
+ #ifdef HAVE_UPOWER_GLIB
+- if (data->upower)
+- g_signal_connect(data->upower, "changed",
+- G_CALLBACK(upower_changed_cb), data);
+-#endif
++ if (data->upower) {
++#if UP_CHECK_VERSION(0, 99, 0)
++ g_signal_connect (data->upower, "notify",
++ G_CALLBACK(upower_changed_cb), data);
++#else /* UP_CHECK_VERSION < 0.99 */
++ g_signal_connect (data->upower, "changed",
++ G_CALLBACK(upower_changed_cb), data);
++#endif /* UP_CHECK_VERSION */
++ }
++#endif /* HAVE_UPOWER_GLIB */
+
+ weather_dump(weather_dump_plugindata, data);
+ }
+--
+1.9.3
+
diff --git a/xfce-extra/xfce4-weather-plugin/xfce4-weather-plugin-0.8.3-r1.ebuild b/xfce-extra/xfce4-weather-plugin/xfce4-weather-plugin-0.8.3-r1.ebuild
new file mode 100644
index 000000000000..08b85bc5d19f
--- /dev/null
+++ b/xfce-extra/xfce4-weather-plugin/xfce4-weather-plugin-0.8.3-r1.ebuild
@@ -0,0 +1,40 @@
+# Copyright 1999-2014 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/xfce-extra/xfce4-weather-plugin/xfce4-weather-plugin-0.8.3-r1.ebuild,v 1.1 2014/05/31 19:02:31 ssuominen Exp $
+
+EAPI=5
+inherit xfconf
+
+DESCRIPTION="A weather plug-in for the Xfce desktop environment"
+HOMEPAGE="http://goodies.xfce.org/projects/panel-plugins/xfce4-weather-plugin"
+SRC_URI="mirror://xfce/src/panel-plugins/${PN}/${PV%.*}/${P}.tar.bz2"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~arm ~ppc ~ppc64 ~x86"
+IUSE="debug udev"
+
+RDEPEND=">=dev-libs/glib-2.20
+ dev-libs/libxml2
+ >=net-libs/libsoup-2.26
+ >=x11-libs/gtk+-2.14:2
+ >=xfce-base/libxfce4ui-4.10
+ >=xfce-base/libxfce4util-4.10
+ >=xfce-base/xfce4-panel-4.10
+ udev? ( || ( >=sys-power/upower-0.9.23 sys-power/upower-pm-utils ) )"
+DEPEND="${RDEPEND}
+ dev-util/intltool
+ virtual/pkgconfig"
+
+pkg_setup() {
+ PATCHES=( "${FILESDIR}"/${P}-upower-0.99.patch )
+
+ # For GEONAMES_USERNAME, read README file and ask ssuominen@!
+ XFCONF=(
+ $(use_enable udev upower)
+ $(xfconf_use_debug)
+ GEONAMES_USERNAME=Gentoo
+ )
+
+ DOCS=( AUTHORS ChangeLog NEWS README TODO )
+}
diff --git a/xfce-extra/xfce4-weather-plugin/xfce4-weather-plugin-0.8.3.ebuild b/xfce-extra/xfce4-weather-plugin/xfce4-weather-plugin-0.8.3.ebuild
index cf1d44a921fb..0b29a84b5764 100644
--- a/xfce-extra/xfce4-weather-plugin/xfce4-weather-plugin-0.8.3.ebuild
+++ b/xfce-extra/xfce4-weather-plugin/xfce4-weather-plugin-0.8.3.ebuild
@@ -1,6 +1,6 @@
# Copyright 1999-2014 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/xfce-extra/xfce4-weather-plugin/xfce4-weather-plugin-0.8.3.ebuild,v 1.4 2014/05/26 19:49:28 ssuominen Exp $
+# $Header: /var/cvsroot/gentoo-x86/xfce-extra/xfce4-weather-plugin/xfce4-weather-plugin-0.8.3.ebuild,v 1.5 2014/05/31 19:02:31 ssuominen Exp $
EAPI=5
inherit xfconf
@@ -21,7 +21,7 @@ RDEPEND=">=dev-libs/glib-2.20
>=xfce-base/libxfce4ui-4.10
>=xfce-base/libxfce4util-4.10
>=xfce-base/xfce4-panel-4.10
- udev? ( || ( >=sys-power/upower-0.9.19 sys-power/upower-pm-utils ) )"
+ udev? ( || ( <sys-power/upower-0.99 sys-power/upower-pm-utils ) )"
DEPEND="${RDEPEND}
dev-util/intltool
virtual/pkgconfig"