Hello community,
here is the log from the commit of package hp-drive-guard for openSUSE:Factory
checked in at Fri Jul 29 16:38:01 CEST 2011.
--------
--- hp-drive-guard/hp-drive-guard.changes 2011-06-28 13:13:33.000000000 +0200
+++ /mounts/work_src_done/STABLE/hp-drive-guard/hp-drive-guard.changes 2011-07-29 15:32:32.000000000 +0200
@@ -1,0 +2,6 @@
+Fri Jul 29 12:43:05 CEST 2011 - tiwai@suse.de
+
+- Convert to new polkit-1 (bnc#708992)
+- Use gtk3 for FACTORY
+
+-------------------------------------------------------------------
calling whatdependson for head-i586
New:
----
use-gtk3.diff
use-new-polkit.diff
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ hp-drive-guard.spec ++++++
--- /var/tmp/diff_new_pack.NvzP3x/_old 2011-07-29 16:37:14.000000000 +0200
+++ /var/tmp/diff_new_pack.NvzP3x/_new 2011-07-29 16:37:14.000000000 +0200
@@ -17,12 +17,32 @@
# norootforbuild
+%define new_polkit (%suse_version >= 1140)
+%define use_upower (%suse_version > 1120)
+%define use_gtk3 (%suse_version > 1140)
+
+%if %{new_polkit}
+%define polkitdir %{_datadir}/polkit-1/actions
+%else
+%define polkitdir %{_datadir}/PolicyKit/policy
+%endif
Name: hp-drive-guard
BuildRequires: fdupes gnome-common intltool
-BuildRequires: gtk2-devel libnotify-devel
+%if %{use_gtk3}
+BuildRequires: gtk3-devel
+%else
+BuildRequires: gtk2-devel
+%endif
+BuildRequires: libnotify-devel
+BuildRequires: dbus-1-glib-devel
+BuildRequires: libxslt
+%if %{new_polkit}
+BuildRequires: polkit-devel
+%else
BuildRequires: PolicyKit-gnome-devel
-%if %suse_version > 1120
+%endif
+%if %{use_upower}
BuildRequires: libupower-glib-devel
%else
BuildRequires: hal-devel
@@ -32,11 +52,13 @@
License: GPLv2+
Group: Hardware/Mobile
Version: 0.3.12
-Release: 6
+Release: 8
Summary: HP DriveGuard for SuSE
Source: hp-drive-guard-%{version}.tar.bz2
Patch1: 0001-Fix-misc-compile-warnings.patch
Patch2: 0002-Fix-build-with-the-new-libnotify.patch
+Patch3: use-new-polkit.diff
+Patch4: use-gtk3.diff
Url: http://www.gnome.org
BuildRoot: %{_tmppath}/%{name}-%{version}-build
@@ -55,12 +77,19 @@
%setup -q
%patch1 -p1
%patch2 -p1
+%if %{new_polkit}
+%patch3 -p1
+%endif
+%if %{use_gtk3}
+%patch4 -p1
+%endif
-%if %suse_version > 1120
+%if %use_upower
%define pm_method upower
%else
%define pm_method hal
%endif
+
%if %suse_version >= 1120
%define user_setup --enable-user-setup
%else
@@ -100,6 +129,6 @@
%{_sysconfdir}/xdg/autostart/hp-drive-guard-client.desktop
%{_sysconfdir}/dbus-1/system.d/hp-drive-guard-dbus.conf
%{_sysconfdir}/init.d/hp-drive-guard
-%{_datadir}/PolicyKit/policy/*
+%{polkitdir}/*
%changelog
++++++ use-gtk3.diff ++++++
---
configure.ac | 2 +-
src/client.c | 6 +++---
src/setup.c | 2 +-
3 files changed, 5 insertions(+), 5 deletions(-)
--- a/configure.ac
+++ b/configure.ac
@@ -37,7 +37,7 @@
AM_GNU_GETTEXT_VERSION([0.17])
PKG_CHECK_MODULES(GLIB, glib-2.0)
-PKG_CHECK_MODULES(GTK, gtk+-2.0 >= $GTK_REQUIRED)
+PKG_CHECK_MODULES(GTK, gtk+-3.0)
PKG_CHECK_MODULES(DBUS, dbus-glib-1)
PKG_CHECK_MODULES(LIBNOTIFY, libnotify)
PKG_CHECK_MODULES(POLKIT, polkit-gobject-1)
--- a/src/client.c
+++ b/src/client.c
@@ -245,7 +245,7 @@
if (drive_guard->current_tooltip != drive_guard->current_state)
{
drive_guard->current_tooltip = drive_guard->current_state;
- gtk_status_icon_set_tooltip (drive_guard->status_icon,
+ gtk_status_icon_set_tooltip_text (drive_guard->status_icon,
gettext (tooltip_msgs [drive_guard->current_tooltip]));
}
@@ -581,7 +581,7 @@
}
drive_guard->status_icon = gtk_status_icon_new_from_pixbuf (drive_guard->state_pixbuf [DRIVE_GUARD_DRIVE_STATE_NONE]);
- gtk_status_icon_set_tooltip (drive_guard->status_icon,
+ gtk_status_icon_set_tooltip_text (drive_guard->status_icon,
_("Looking for HP DriveGuard service"));
init_state_change_notification (drive_guard);
queue_state_change_notification (drive_guard);
@@ -635,7 +635,7 @@
return 1;
textdomain (PACKAGE);
- gtk_set_locale ();
+ setlocale (LC_ALL, "");
notify_init ("DriveGuard");
--- a/src/setup.c
+++ b/src/setup.c
@@ -171,7 +171,7 @@
vbox1 = gtk_vbox_new (FALSE, 0);
gtk_widget_show (vbox1);
- gtk_box_pack_start (GTK_BOX (GTK_DIALOG (dialog)->vbox), vbox1, FALSE, FALSE, 0);
+ gtk_box_pack_start (GTK_BOX (gtk_dialog_get_content_area (GTK_DIALOG (dialog))), vbox1, FALSE, FALSE, 0);
device_enable = gtk_check_button_new_with_label (_("Enable HP DriveGuard"));
gtk_widget_show (device_enable);
++++++ use-new-polkit.diff ++++++
---
configure.ac | 3 --
src/Makefile.am | 8 +++----
src/client.c | 38 ++++++++-------------------------
src/daemon.c | 64 ++++++++++++++++++++++----------------------------------
4 files changed, 41 insertions(+), 72 deletions(-)
--- a/configure.ac
+++ b/configure.ac
@@ -40,8 +40,7 @@
PKG_CHECK_MODULES(GTK, gtk+-2.0 >= $GTK_REQUIRED)
PKG_CHECK_MODULES(DBUS, dbus-glib-1)
PKG_CHECK_MODULES(LIBNOTIFY, libnotify)
-PKG_CHECK_MODULES(POLKITDBUS, polkit-dbus)
-PKG_CHECK_MODULES(POLKITGNOME, polkit-gnome)
+PKG_CHECK_MODULES(POLKIT, polkit-gobject-1)
AC_ARG_WITH(pm,
AS_HELP_STRING([--with-pm=hal|upower],
[Power-management backend, either hal or upower]),
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -1,6 +1,6 @@
hp_drive_guarddatadir = $(datadir)/hp-drive-guard
dbusservicedir=$(DBUS_SYS_DIR)
-polkit_policydir = $(datadir)/PolicyKit/policy
+polkitdir = $(datadir)/polkit-1/actions
hpgcdir = @HELPER_EXEC_DIR@
@@ -11,8 +11,8 @@
hp_drive_guard_client_SOURCES = \
client.c common.h setup.c serverconfig.c serverconfig.h
-LDADD = @POLKITGNOME_LIBS@ @LIBNOTIFY_LIBS@
-AM_CFLAGS = @POLKITGNOME_CFLAGS@ @LIBNOTIFY_CFLAGS@
+LDADD = @POLKIT_LIBS@ @LIBNOTIFY_LIBS@
+AM_CFLAGS = @POLKIT_CFLAGS@ @LIBNOTIFY_CFLAGS@
if PM_BACKEND_HAL
LDADD += @HAL_LIBS@
AM_CFLAGS += @HAL_CFLAGS@
@@ -45,7 +45,7 @@
dbusservice_DATA = hp-drive-guard-dbus.conf
autostart_DATA = hp-drive-guard-client.desktop
-dist_polkit_policy_DATA = com.hp.driveguard.policy
+dist_polkit_DATA = com.hp.driveguard.policy
EXTRA_DIST = \
hp-drive-guard-dbus.conf \
--- a/src/client.c
+++ b/src/client.c
@@ -44,8 +44,6 @@
#include