Hello community,

here is the log from the commit of package upower for openSUSE:Factory checked 
in at 2015-07-16 17:17:29
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/upower (Old)
 and      /work/SRC/openSUSE:Factory/.upower.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "upower"

Changes:
--------
--- /work/SRC/openSUSE:Factory/upower/upower.changes    2014-12-21 
12:00:55.000000000 +0100
+++ /work/SRC/openSUSE:Factory/.upower.new/upower.changes       2015-07-16 
17:17:31.000000000 +0200
@@ -1,0 +2,17 @@
+Fri Jun 19 17:30:56 UTC 2015 - mplus...@suse.com
+
+- Update to version 0.99.3
+  * Bail out when iDevice state is malformed (Bastien Nocera)
+  * Defer getting iDevice info until ready (Bastien Nocera)
+  * Fix crash on uninitialized variant (Vlad Orlov)
+  * Fix libimobiledevice msg in configure (Bastien Nocera)
+  * More memory handling fixes in iDevice (Bastien Nocera)
+  * Properly detect bluetooth mice and keyboards that are HID 
+    devices (Marc Deslauriers)
+  * Support Logitech Unifying in Linux 3.19 (Peter Wu)
+  * Work-around broken battery on the Onda v975w (Bastien Nocera)
+- Add missing rcsymlink
+- Remove old provides/obsoletes
+- Do not recommend obsolete pm-utils
+
+-------------------------------------------------------------------

Old:
----
  upower-0.99.2.tar.xz

New:
----
  upower-0.99.3.tar.xz

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ upower.spec ++++++
--- /var/tmp/diff_new_pack.oqoS9t/_old  2015-07-16 17:17:32.000000000 +0200
+++ /var/tmp/diff_new_pack.oqoS9t/_new  2015-07-16 17:17:32.000000000 +0200
@@ -1,7 +1,7 @@
 #
 # spec file for package upower
 #
-# Copyright (c) 2014 SUSE LINUX Products GmbH, Nuernberg, Germany.
+# Copyright (c) 2015 SUSE LINUX GmbH, Nuernberg, Germany.
 #
 # All modifications and additions to the file contributed by third parties
 # remain the property of their copyright owners, unless otherwise agreed
@@ -23,7 +23,7 @@
 Summary:        Power Device Enumeration Framework
 License:        GPL-2.0+
 Group:          System/Daemons
-Version:        0.99.2
+Version:        0.99.3
 Release:        0
 Url:            http://upower.freedesktop.org/
 Source:         
http://upower.freedesktop.org/releases/%{name}-%{version}.tar.xz
@@ -34,15 +34,12 @@
 BuildRequires:  libgudev-1_0-devel
 BuildRequires:  libimobiledevice-devel
 BuildRequires:  libusb-devel
+BuildRequires:  pkg-config
 BuildRequires:  pkgconfig(systemd)
 BuildRequires:  pkgconfig(udev)
 %{?systemd_requires}
 Recommends:     %{name}-lang
-# bnc#790787 - upower calls /usr/bin/pm-is-supported, so a Recommends should 
be safe
-# for reference see src/linux/up-backend.c
-Recommends:     pm-utils
 BuildRoot:      %{_tmppath}/%{name}-%{version}-build
-Obsoletes:      DeviceKit-power < 0.9.9
 
 %description
 UPower is an abstraction for enumerating power devices, listening to
@@ -107,6 +104,8 @@
 %install
 %makeinstall
 rm -f %{buildroot}%{_libdir}/*.la
+install -d %{buildroot}%{_sbindir}
+ln -s %{_sbindir}/service %{buildroot}%{_sbindir}/rc%{name}
 %find_lang %{name}
 
 %clean
@@ -134,6 +133,7 @@
 %doc AUTHORS COPYING NEWS README
 %config %{_sysconfdir}/UPower/
 %{_bindir}/upower
+%{_sbindir}/rc%{name}
 %dir %{_libexecdir}/upower
 %{_libexecdir}/upower/upowerd
 %{_udevrulesdir}/*.rules

++++++ upower-0.99.2.tar.xz -> upower-0.99.3.tar.xz ++++++
++++ 2961 lines of diff (skipped)
++++    retrying with extended exclude list
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/upower-0.99.2/NEWS new/upower-0.99.3/NEWS
--- old/upower-0.99.2/NEWS      2014-12-18 10:31:28.000000000 +0100
+++ new/upower-0.99.3/NEWS      2015-05-28 11:20:26.000000000 +0200
@@ -1,3 +1,17 @@
+Version 0.99.3
+~~~~~~~~~~~~~~
+Released: 2015-05-28
+
+Bugfixes:
+ - Bail out when iDevice state is malformed (Bastien Nocera)
+ - Defer getting iDevice info until ready (Bastien Nocera)
+ - Fix crash on uninitialized variant (Vlad Orlov)
+ - Fix libimobiledevice msg in configure (Bastien Nocera)
+ - More memory handling fixes in iDevice (Bastien Nocera)
+ - Properly detect bluetooth mice and keyboards that are HID devices (Marc 
Deslauriers)
+ - Support Logitech Unifying in Linux 3.19 (Peter Wu)
+ - Work-around broken battery on the Onda v975w (Bastien Nocera)
+
 Version 0.99.2
 ~~~~~~~~~~~~~~
 Released: 2014-12-18
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/upower-0.99.2/build-aux/compile new/upower-0.99.3/build-aux/compile
--- old/upower-0.99.2/build-aux/compile 2014-12-18 10:29:47.000000000 +0100
+++ new/upower-0.99.3/build-aux/compile 2015-05-28 10:51:56.000000000 +0200
@@ -3,7 +3,7 @@
 
 scriptversion=2012-10-14.11; # UTC
 
-# Copyright (C) 1999-2013 Free Software Foundation, Inc.
+# Copyright (C) 1999-2014 Free Software Foundation, Inc.
 # Written by Tom Tromey <tro...@cygnus.com>.
 #
 # This program is free software; you can redistribute it and/or modify
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/upower-0.99.2/build-aux/missing new/upower-0.99.3/build-aux/missing
--- old/upower-0.99.2/build-aux/missing 2014-12-18 10:29:47.000000000 +0100
+++ new/upower-0.99.3/build-aux/missing 2015-05-28 10:51:56.000000000 +0200
@@ -3,7 +3,7 @@
 
 scriptversion=2013-10-28.13; # UTC
 
-# Copyright (C) 1996-2013 Free Software Foundation, Inc.
+# Copyright (C) 1996-2014 Free Software Foundation, Inc.
 # Originally written by Fran,cois Pinard <pin...@iro.umontreal.ca>, 1996.
 
 # This program is free software; you can redistribute it and/or modify
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/upower-0.99.2/build-aux/test-driver new/upower-0.99.3/build-aux/test-driver
--- old/upower-0.99.2/build-aux/test-driver     2014-12-18 10:29:47.000000000 
+0100
+++ new/upower-0.99.3/build-aux/test-driver     2015-05-28 10:51:56.000000000 
+0200
@@ -3,7 +3,7 @@
 
 scriptversion=2013-07-13.22; # UTC
 
-# Copyright (C) 2011-2013 Free Software Foundation, Inc.
+# Copyright (C) 2011-2014 Free Software Foundation, Inc.
 #
 # This program is free software; you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
@@ -106,11 +106,14 @@
 # Test script is run here.
 "$@" >$log_file 2>&1
 estatus=$?
+
 if test $enable_hard_errors = no && test $estatus -eq 99; then
-  estatus=1
+  tweaked_estatus=1
+else
+  tweaked_estatus=$estatus
 fi
 
-case $estatus:$expect_failure in
+case $tweaked_estatus:$expect_failure in
   0:yes) col=$red res=XPASS recheck=yes gcopy=yes;;
   0:*)   col=$grn res=PASS  recheck=no  gcopy=no;;
   77:*)  col=$blu res=SKIP  recheck=no  gcopy=yes;;
@@ -119,6 +122,12 @@
   *:*)   col=$red res=FAIL  recheck=yes gcopy=yes;;
 esac
 
+# Report the test outcome and exit status in the logs, so that one can
+# know whether the test passed or failed simply by looking at the '.log'
+# file, without the need of also peaking into the corresponding '.trs'
+# file (automake bug#11814).
+echo "$res $test_name (exit status: $estatus)" >>$log_file
+
 # Report outcome to console.
 echo "${col}${res}${std}: $test_name"
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/upower-0.99.2/config.h.in new/upower-0.99.3/config.h.in
--- old/upower-0.99.2/config.h.in       2014-12-18 10:32:04.000000000 +0100
+++ new/upower-0.99.3/config.h.in       2015-05-28 10:51:56.000000000 +0200
@@ -34,7 +34,7 @@
 /* Define if you have the iconv() function and it works. */
 #undef HAVE_ICONV
 
-/* Define to 1 if AFC is going to be built */
+/* Define to 1 if iDevice is going to be built */
 #undef HAVE_IDEVICE
 
 /* Define to 1 if you have the <inttypes.h> header file. */
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/upower-0.99.2/configure.ac new/upower-0.99.3/configure.ac
--- old/upower-0.99.2/configure.ac      2014-12-18 10:31:57.000000000 +0100
+++ new/upower-0.99.3/configure.ac      2015-04-22 11:57:08.000000000 +0200
@@ -2,7 +2,7 @@
 
 m4_define([up_major_version], [0])
 m4_define([up_minor_version], [99])
-m4_define([up_micro_version], [2])
+m4_define([up_micro_version], [3])
 m4_define([up_version],
           [up_major_version.up_minor_version.up_micro_version])
 
@@ -208,7 +208,7 @@
              [PKG_CHECK_MODULES(IDEVICE, libimobiledevice-1.0 >= 0.9.7 
libplist >= 0.12, have_idevice=yes, have_idevice=no)],
              [have_idevice=no])
        AS_IF([test "x$have_idevice" = "xyes"],
-             [AC_DEFINE(HAVE_IDEVICE, 1, [Define to 1 if AFC is going to be 
built])])
+             [AC_DEFINE(HAVE_IDEVICE, 1, [Define to 1 if iDevice is going to 
be built])])
 fi
 
 AM_CONDITIONAL(HAVE_IDEVICE, [test x$have_idevice = xyes])
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/upower-0.99.2/doc/html/index.html new/upower-0.99.3/doc/html/index.html
--- old/upower-0.99.2/doc/html/index.html       2014-12-18 10:32:42.000000000 
+0100
+++ new/upower-0.99.3/doc/html/index.html       2015-05-28 11:21:06.000000000 
+0200
@@ -22,7 +22,7 @@
             <code class="email">&lt;<a class="email" 
href="mailto:rich...@hughsie.com";>rich...@hughsie.com</a>&gt;</code><br>
           </p></div></div>
 </div></div></div>
-<div><p class="releaseinfo">Version 0.99.2
+<div><p class="releaseinfo">Version 0.99.3
 </p></div>
 <div><p class="copyright">Copyright © 2010 The UPower Authors</p></div>
 <div><div class="legalnotice">
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/upower-0.99.2/doc/version.xml new/upower-0.99.3/doc/version.xml
--- old/upower-0.99.2/doc/version.xml   2014-12-18 10:32:04.000000000 +0100
+++ new/upower-0.99.3/doc/version.xml   2015-05-28 10:51:58.000000000 +0200
@@ -1 +1 @@
-0.99.2
+0.99.3
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/upower-0.99.2/libupower-glib/up-client-glue.c 
new/upower-0.99.3/libupower-glib/up-client-glue.c
--- old/upower-0.99.2/libupower-glib/up-client-glue.c   2014-12-18 
10:30:06.000000000 +0100
+++ new/upower-0.99.3/libupower-glib/up-client-glue.c   2015-05-28 
10:52:12.000000000 +0200
@@ -1,5 +1,5 @@
 /*
- * Generated by gdbus-codegen 2.42.1. DO NOT EDIT.
+ * Generated by gdbus-codegen 2.44.0. DO NOT EDIT.
  *
  * The license of this code is the same as for the source it was derived from.
  */
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/upower-0.99.2/libupower-glib/up-client-glue.h 
new/upower-0.99.3/libupower-glib/up-client-glue.h
--- old/upower-0.99.2/libupower-glib/up-client-glue.h   2014-12-18 
10:30:06.000000000 +0100
+++ new/upower-0.99.3/libupower-glib/up-client-glue.h   2015-05-28 
10:52:12.000000000 +0200
@@ -1,5 +1,5 @@
 /*
- * Generated by gdbus-codegen 2.42.1. DO NOT EDIT.
+ * Generated by gdbus-codegen 2.44.0. DO NOT EDIT.
  *
  * The license of this code is the same as for the source it was derived from.
  */
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/upower-0.99.2/libupower-glib/up-device-glue.c 
new/upower-0.99.3/libupower-glib/up-device-glue.c
--- old/upower-0.99.2/libupower-glib/up-device-glue.c   2014-12-18 
10:30:06.000000000 +0100
+++ new/upower-0.99.3/libupower-glib/up-device-glue.c   2015-05-28 
10:52:12.000000000 +0200
@@ -1,5 +1,5 @@
 /*
- * Generated by gdbus-codegen 2.42.1. DO NOT EDIT.
+ * Generated by gdbus-codegen 2.44.0. DO NOT EDIT.
  *
  * The license of this code is the same as for the source it was derived from.
  */
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/upower-0.99.2/libupower-glib/up-device-glue.h 
new/upower-0.99.3/libupower-glib/up-device-glue.h
--- old/upower-0.99.2/libupower-glib/up-device-glue.h   2014-12-18 
10:30:06.000000000 +0100
+++ new/upower-0.99.3/libupower-glib/up-device-glue.h   2015-05-28 
10:52:12.000000000 +0200
@@ -1,5 +1,5 @@
 /*
- * Generated by gdbus-codegen 2.42.1. DO NOT EDIT.
+ * Generated by gdbus-codegen 2.44.0. DO NOT EDIT.
  *
  * The license of this code is the same as for the source it was derived from.
  */
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/upower-0.99.2/libupower-glib/up-device.c 
new/upower-0.99.3/libupower-glib/up-device.c
--- old/upower-0.99.2/libupower-glib/up-device.c        2014-05-20 
14:24:12.000000000 +0200
+++ new/upower-0.99.3/libupower-glib/up-device.c        2015-04-22 
11:57:08.000000000 +0200
@@ -422,7 +422,7 @@
 up_device_get_history_sync (UpDevice *device, const gchar *type, guint 
timespec, guint resolution, GCancellable *cancellable, GError **error)
 {
        GError *error_local = NULL;
-       GVariant *gva;
+       GVariant *gva = NULL;
        guint i;
        GPtrArray *array = NULL;
        gboolean ret;
@@ -502,7 +502,7 @@
 up_device_get_statistics_sync (UpDevice *device, const gchar *type, 
GCancellable *cancellable, GError **error)
 {
        GError *error_local = NULL;
-       GVariant *gva;
+       GVariant *gva = NULL;
        guint i;
        GPtrArray *array = NULL;
        gboolean ret;
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/upower-0.99.2/libupower-glib/up-version.h 
new/upower-0.99.3/libupower-glib/up-version.h
--- old/upower-0.99.2/libupower-glib/up-version.h       2014-12-18 
10:32:04.000000000 +0100
+++ new/upower-0.99.3/libupower-glib/up-version.h       2015-05-28 
10:51:58.000000000 +0200
@@ -55,7 +55,7 @@
  *
  * The compile-time micro version
  */
-#define UP_MICRO_VERSION                               (2)
+#define UP_MICRO_VERSION                               (3)
 
 /* check whether a UPower version equal to or greater than
  * major.minor.micro.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/upower-0.99.2/libupower-glib/up-wakeups-glue.c 
new/upower-0.99.3/libupower-glib/up-wakeups-glue.c
--- old/upower-0.99.2/libupower-glib/up-wakeups-glue.c  2014-12-18 
10:30:06.000000000 +0100
+++ new/upower-0.99.3/libupower-glib/up-wakeups-glue.c  2015-05-28 
10:52:12.000000000 +0200
@@ -1,5 +1,5 @@
 /*
- * Generated by gdbus-codegen 2.42.1. DO NOT EDIT.
+ * Generated by gdbus-codegen 2.44.0. DO NOT EDIT.
  *
  * The license of this code is the same as for the source it was derived from.
  */
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/upower-0.99.2/libupower-glib/up-wakeups-glue.h 
new/upower-0.99.3/libupower-glib/up-wakeups-glue.h
--- old/upower-0.99.2/libupower-glib/up-wakeups-glue.h  2014-12-18 
10:30:06.000000000 +0100
+++ new/upower-0.99.3/libupower-glib/up-wakeups-glue.h  2015-05-28 
10:52:12.000000000 +0200
@@ -1,5 +1,5 @@
 /*
- * Generated by gdbus-codegen 2.42.1. DO NOT EDIT.
+ * Generated by gdbus-codegen 2.44.0. DO NOT EDIT.
  *
  * The license of this code is the same as for the source it was derived from.
  */
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/upower-0.99.2/m4/intltool.m4 new/upower-0.99.3/m4/intltool.m4
--- old/upower-0.99.2/m4/intltool.m4    2014-12-18 10:29:40.000000000 +0100
+++ new/upower-0.99.3/m4/intltool.m4    2015-05-28 10:51:47.000000000 +0200
@@ -155,31 +155,6 @@
 # Substitute ALL_LINGUAS so we can use it in po/Makefile
 AC_SUBST(ALL_LINGUAS)
 
-# Set DATADIRNAME correctly if it is not set yet
-# (copied from glib-gettext.m4)
-if test -z "$DATADIRNAME"; then
-  AC_LINK_IFELSE(
-    [AC_LANG_PROGRAM([[]],
-                     [[extern int _nl_msg_cat_cntr;
-                       return _nl_msg_cat_cntr]])],
-    [DATADIRNAME=share],
-    [case $host in
-    *-*-solaris*)
-    dnl On Solaris, if bind_textdomain_codeset is in libc,
-    dnl GNU format message catalog is always supported,
-    dnl since both are added to the libc all together.
-    dnl Hence, we'd like to go with DATADIRNAME=share
-    dnl in this case.
-    AC_CHECK_FUNC(bind_textdomain_codeset,
-      [DATADIRNAME=share], [DATADIRNAME=lib])
-    ;;
-    *)
-    [DATADIRNAME=lib]
-    ;;
-    esac])
-fi
-AC_SUBST(DATADIRNAME)
-
 IT_PO_SUBDIR([po])
 
 ])
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/upower-0.99.2/po/Makefile.in.in new/upower-0.99.3/po/Makefile.in.in
--- old/upower-0.99.2/po/Makefile.in.in 2014-12-18 10:29:40.000000000 +0100
+++ new/upower-0.99.3/po/Makefile.in.in 2015-05-28 10:51:47.000000000 +0200
@@ -33,8 +33,7 @@
 datadir = @datadir@
 datarootdir = @datarootdir@
 libdir = @libdir@
-DATADIRNAME = @DATADIRNAME@
-itlocaledir = $(prefix)/$(DATADIRNAME)/locale
+localedir = @localedir@
 subdir = po
 install_sh = @install_sh@
 # Automake >= 1.8 provides @mkdir_p@.
@@ -80,7 +79,7 @@
 
 .po.pox:
        $(MAKE) $(GETTEXT_PACKAGE).pot
-       $(MSGMERGE) $< $(GETTEXT_PACKAGE).pot -o $*.pox
+       $(MSGMERGE) $* $(GETTEXT_PACKAGE).pot -o $*.pox
 
 .po.mo:
        $(INTLTOOL_V_MSGFMT)$(MSGFMT) -o $@ $<
@@ -108,7 +107,7 @@
 install-data-yes: all
        linguas="$(USE_LINGUAS)"; \
        for lang in $$linguas; do \
-         dir=$(DESTDIR)$(itlocaledir)/$$lang/LC_MESSAGES; \
+         dir=$(DESTDIR)$(localedir)/$$lang/LC_MESSAGES; \
          $(mkdir_p) $$dir; \
          if test -r $$lang.gmo; then \
            $(INSTALL_DATA) $$lang.gmo $$dir/$(GETTEXT_PACKAGE).mo; \
@@ -142,8 +141,8 @@
 uninstall:
        linguas="$(USE_LINGUAS)"; \
        for lang in $$linguas; do \
-         rm -f 
$(DESTDIR)$(itlocaledir)/$$lang/LC_MESSAGES/$(GETTEXT_PACKAGE).mo; \
-         rm -f 
$(DESTDIR)$(itlocaledir)/$$lang/LC_MESSAGES/$(GETTEXT_PACKAGE).mo.m; \
+         rm -f 
$(DESTDIR)$(localedir)/$$lang/LC_MESSAGES/$(GETTEXT_PACKAGE).mo; \
+         rm -f 
$(DESTDIR)$(localedir)/$$lang/LC_MESSAGES/$(GETTEXT_PACKAGE).mo.m; \
        done
 
 check: all $(GETTEXT_PACKAGE).pot
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/upower-0.99.2/rules/95-upower-csr.rules 
new/upower-0.99.3/rules/95-upower-csr.rules
--- old/upower-0.99.2/rules/95-upower-csr.rules 2013-03-22 20:44:58.000000000 
+0100
+++ new/upower-0.99.3/rules/95-upower-csr.rules 2015-04-22 11:57:08.000000000 
+0200
@@ -25,5 +25,8 @@
 ATTRS{idVendor}=="046d", ENV{UPOWER_VENDOR}="Logitech, Inc."
 ATTRS{idVendor}=="046d", ATTRS{idProduct}=="c52b", 
DRIVER=="logitech-djdevice", ENV{UPOWER_BATTERY_TYPE}="unifying"
 ATTRS{idVendor}=="046d", ATTRS{idProduct}=="c532", 
DRIVER=="logitech-djdevice", ENV{UPOWER_BATTERY_TYPE}="unifying"
+# These devices bind to the hid-logitech-hidpp module since Linux 3.19
+ATTRS{idVendor}=="046d", ATTRS{idProduct}=="c52b", 
DRIVER=="logitech-hidpp-device", ENV{UPOWER_BATTERY_TYPE}="unifying"
+ATTRS{idVendor}=="046d", ATTRS{idProduct}=="c532", 
DRIVER=="logitech-hidpp-device", ENV{UPOWER_BATTERY_TYPE}="unifying"
 ATTRS{idVendor}=="046d", ATTRS{idProduct}=="c52f", 
ENV{UPOWER_BATTERY_TYPE}="lg-wireless"
 LABEL="up_unifying_end"
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/upower-0.99.2/src/linux/integration-test 
new/upower-0.99.3/src/linux/integration-test
--- old/upower-0.99.2/src/linux/integration-test        2014-09-03 
09:36:11.000000000 +0200
+++ new/upower-0.99.3/src/linux/integration-test        2015-05-21 
11:22:08.000000000 +0200
@@ -761,6 +761,47 @@
         self.assertEqual(self.get_dbus_dev_property(mb1_up, 'Percentage'), 30)
         self.assertEqual(self.get_dbus_dev_property(mb1_up, 'PowerSupply'), 
False)
 
+    def test_bluetooth_hid_mouse(self):
+        '''bluetooth HID mouse battery'''
+
+        self.testbed.add_device('hid',
+                                'usb1/bluetooth/hci0/hci0:01',
+                                None,
+                                [], [])
+
+        self.testbed.add_device(
+            'input',
+            'usb1/bluetooth/hci0/hci0:01/input/input2/mouse3',
+            None,
+            [], ['DEVNAME', 'input/mouse3', 'ID_INPUT_MOUSE', '1'])
+
+        self.testbed.add_device(
+            'power_supply',
+            
'usb1/bluetooth/hci0/hci0:01/1/power_supply/hid-00:11:22:33:44:55-battery',
+            None,
+            ['type', 'Battery',
+             'scope', 'Device',
+             'present', '1',
+             'online', '1',
+             'status', 'Discharging',
+             'capacity', '30',
+             'model_name', 'Fancy BT mouse'],
+            [])
+
+        self.start_daemon()
+        devs = self.proxy.EnumerateDevices()
+        self.assertEqual(len(devs), 1)
+        mousebat0_up = devs[0]
+
+        self.assertEqual(self.get_dbus_dev_property(mousebat0_up, 'Model'), 
'Fancy BT mouse')
+        self.assertEqual(self.get_dbus_dev_property(mousebat0_up, 
'Percentage'), 30)
+        self.assertEqual(self.get_dbus_dev_property(mousebat0_up, 
'PowerSupply'), False)
+        # 5 == mouse
+        self.assertEqual(self.get_dbus_dev_property(mousebat0_up, 'Type'), 5)
+        self.assertEqual(self.get_dbus_property('OnBattery'), False)
+        self.assertEqual(self.get_dbus_display_property('WarningLevel'), 
UP_DEVICE_LEVEL_NONE)
+        self.stop_daemon()
+
     def test_bluetooth_keyboard(self):
         '''bluetooth keyboard battery'''
 
@@ -802,6 +843,33 @@
         self.assertEqual(self.get_dbus_display_property('WarningLevel'), 
UP_DEVICE_LEVEL_NONE)
         self.stop_daemon()
 
+    def test_broken_onda_battery(self):
+        '''Onda v975w battery: 
https://bugzilla.kernel.org/show_bug.cgi?id=83941'''
+
+        batc = self.testbed.add_device('power_supply', 'BATC', None,
+                                       ['type', 'Battery',
+                                        'capacity', '0',
+                                        'capacity_level', 'Normal',
+                                        'present', '1',
+                                        'energy_full', '0',
+                                        'energy_full_design', '0',
+                                        'energy_now', '5549000',
+                                        'power_now', '97000',
+                                        'voltage_now', '3970000'], [])
+
+        self.start_daemon()
+        devs = self.proxy.EnumerateDevices()
+        self.assertEqual(len(devs), 1)
+        batc_up = devs[0]
+
+        self.assertEqual(self.get_dbus_dev_property(batc_up, 'Percentage'), 
100.0)
+
+        self.testbed.set_attribute(batc, 'energy_now', '2774500')
+        time.sleep(5)
+        self.assertEqual(int(self.get_dbus_dev_property(batc_up, 
'Percentage')), 50)
+
+        self.stop_daemon()
+
     #
     # libupower-glib tests (through introspection)
     #
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/upower-0.99.2/src/linux/up-device-idevice.c 
new/upower-0.99.3/src/linux/up-device-idevice.c
--- old/upower-0.99.2/src/linux/up-device-idevice.c     2014-10-08 
20:36:03.000000000 +0200
+++ new/upower-0.99.3/src/linux/up-device-idevice.c     2015-04-22 
11:57:08.000000000 +0200
@@ -43,6 +43,7 @@
 
 struct UpDeviceIdevicePrivate
 {
+       guint                    start_id;
        idevice_t                dev;
        lockdownd_client_t       client;
 };
@@ -67,6 +68,53 @@
        return TRUE;
 }
 
+static gboolean
+start_poll_cb (UpDeviceIdevice *idevice)
+{
+       UpDevice *device = UP_DEVICE (idevice);
+       idevice_t dev = NULL;
+       lockdownd_client_t client = NULL;
+       char *uuid;
+
+       g_object_get (G_OBJECT (idevice), "serial", &uuid, NULL);
+       g_assert (uuid);
+
+       /* Connect to the device */
+       if (idevice_new (&dev, uuid) != IDEVICE_E_SUCCESS)
+               goto out;
+
+       g_free (uuid);
+
+       if (LOCKDOWN_E_SUCCESS != lockdownd_client_new_with_handshake (dev, 
&client, "upower"))
+               goto out;
+
+       /* coldplug */
+       idevice->priv->client = client;
+       if (up_device_idevice_refresh (device) == FALSE) {
+               idevice->priv->client = NULL;
+               goto out;
+       }
+       idevice->priv->dev = dev;
+
+       /* _refresh will reopen a new lockdownd client */
+       idevice->priv->client = NULL;
+       g_clear_pointer (&client, lockdownd_client_free);
+
+       g_object_set (G_OBJECT (idevice), "is-present", TRUE, NULL);
+
+       /* set up a poll */
+       up_daemon_start_poll (G_OBJECT (idevice), (GSourceFunc) 
up_device_idevice_poll_cb);
+
+       idevice->priv->start_id = 0;
+       return G_SOURCE_REMOVE;
+
+out:
+       g_clear_pointer (&client, lockdownd_client_free);
+       g_clear_pointer (&dev, idevice_free);
+       g_free (uuid);
+       return G_SOURCE_CONTINUE;
+}
+
 /**
  * up_device_idevice_coldplug:
  *
@@ -79,30 +127,17 @@
        GUdevDevice *native;
        const gchar *uuid;
        const gchar *model;
-       idevice_t dev = NULL;
-       lockdownd_client_t client = NULL;
        UpDeviceKind kind;
 
        /* Is it an iDevice? */
        native = G_UDEV_DEVICE (up_device_get_native (device));
        if (g_udev_device_get_property_as_boolean (native, "USBMUX_SUPPORTED") 
== FALSE)
-               goto out;
+               return FALSE;
 
        /* Get the UUID */
        uuid = g_udev_device_get_property (native, "ID_SERIAL_SHORT");
        if (uuid == NULL)
-               goto out;
-
-       /* Connect to the device */
-       if (idevice_new (&dev, uuid) != IDEVICE_E_SUCCESS)
-               goto out;
-
-       if (LOCKDOWN_E_SUCCESS != lockdownd_client_new_with_handshake (dev, 
&client, "upower"))
-               goto out;
-
-       /* Set up struct */
-       idevice->priv->dev = dev;
-       idevice->priv->client = client;
+               return FALSE;
 
        /* find the kind of device */
        model = g_udev_device_get_property (native, "ID_MODEL");
@@ -120,33 +155,14 @@
                      "vendor", g_udev_device_get_property (native, 
"ID_VENDOR"),
                      "model", g_udev_device_get_property (native, "ID_MODEL"),
                      "power-supply", FALSE,
-                     "is-present", TRUE,
+                     "is-present", FALSE,
                      "is-rechargeable", TRUE,
                      "has-history", TRUE,
                      NULL);
 
-       /* coldplug */
-       if (up_device_idevice_refresh (device) == FALSE)
-               goto out;
-
-       /* disconnect */
-       lockdownd_client_free (idevice->priv->client);
-       idevice->priv->client = NULL;
+       idevice->priv->start_id = g_timeout_add_seconds (1, (GSourceFunc) 
start_poll_cb, idevice);
 
-       /* set up a poll */
-       up_daemon_start_poll (G_OBJECT (idevice), (GSourceFunc) 
up_device_idevice_poll_cb);
        return TRUE;
-
-out:
-       if (client != NULL) {
-               lockdownd_client_free (client);
-               idevice->priv->client = NULL;
-       }
-       if (dev != NULL) {
-               idevice_free (dev);
-               idevice->priv->dev = NULL;
-       }
-       return FALSE;
 }
 
 /**
@@ -178,6 +194,10 @@
 
        /* get battery status */
        node = plist_dict_get_item (dict, "BatteryCurrentCapacity");
+       if (!node) {
+               plist_free (dict);
+               goto out;
+       }
        plist_get_uint_val (node, &percentage);
 
        g_object_set (device, "percentage", (double) percentage, NULL);
@@ -239,6 +259,11 @@
        idevice = UP_DEVICE_IDEVICE (object);
        g_return_if_fail (idevice->priv != NULL);
 
+       if (idevice->priv->start_id > 0) {
+               g_source_remove (idevice->priv->start_id);
+               idevice->priv->start_id = 0;
+       }
+
        up_daemon_stop_poll (object);
        if (idevice->priv->client != NULL)
                lockdownd_client_free (idevice->priv->client);
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/upower-0.99.2/src/linux/up-device-supply.c 
new/upower-0.99.3/src/linux/up-device-supply.c
--- old/upower-0.99.2/src/linux/up-device-supply.c      2014-11-26 
12:56:15.000000000 +0100
+++ new/upower-0.99.3/src/linux/up-device-supply.c      2015-05-21 
11:22:08.000000000 +0200
@@ -584,6 +584,16 @@
                        supply->priv->coldplug_units = 
UP_DEVICE_SUPPLY_COLDPLUG_UNITS_CHARGE;
                }
 
+               /* Fix broken batteries without energy-full information */
+               if (energy_full < 0.01 && energy_full_design < 0.01) {
+                       gdouble old_energy_full_design;
+
+                       g_object_get (device, "energy-full-design", 
&old_energy_full_design, NULL);
+                       energy_full_design = MAX(old_energy_full_design, 
energy);
+                       /* Make following warning quiet */
+                       energy_full = energy_full_design;
+               }
+
                /* the last full should not be bigger than the design */
                if (energy_full > energy_full_design)
                        g_warning ("energy_full (%f) is greater than 
energy_full_design (%f)",
@@ -678,19 +688,18 @@
        /* get a precise percentage */
         if (sysfs_file_exists (native_path, "capacity")) {
                percentage = sysfs_get_double (native_path, "capacity");
-               if (percentage < 0.0f)
-                       percentage = 0.0f;
-               if (percentage > 100.0f)
-                       percentage = 100.0f;
-                /* for devices which provide capacity, but not 
{energy,charge}_now */
-                if (energy < 0.1f && energy_full > 0.0f)
-                    energy = energy_full * percentage / 100;
+               percentage = CLAMP(percentage, 0.0f, 100.0f);
+               /* for devices which provide capacity, but not 
{energy,charge}_now */
+               if (energy < 0.1f && energy_full > 0.0f) {
+                       energy = energy_full * percentage / 100;
+               } else if (energy > 0.0f && percentage < 0.01) {
+                       /* capacity isn't set but present */
+                       percentage = 100.0 * energy / energy_full;
+                       percentage = CLAMP(percentage, 0.0f, 100.0f);
+               }
         } else if (energy_full > 0.0f) {
                percentage = 100.0 * energy / energy_full;
-               if (percentage < 0.0f)
-                       percentage = 0.0f;
-               if (percentage > 100.0f)
-                       percentage = 100.0f;
+               percentage = CLAMP(percentage, 0.0f, 100.0f);
        }
 
        /* the battery isn't charging or discharging, it's just
@@ -923,9 +932,12 @@
        const gchar *scope;
        gchar *device_type = NULL;
        gchar *input_path = NULL;
+       gchar *subdir = NULL;
        GDir *dir = NULL;
        GError *error = NULL;
        UpDeviceKind type = UP_DEVICE_KIND_UNKNOWN;
+       guint i;
+       const char *class[] = { "hid", "bluetooth" };
 
        up_device_supply_reset_values (supply);
 
@@ -961,28 +973,39 @@
                if (g_ascii_strcasecmp (device_type, "mains") == 0) {
                        type = UP_DEVICE_KIND_LINE_POWER;
                } else if (g_ascii_strcasecmp (device_type, "battery") == 0) {
+                       for (i = 0; i < G_N_ELEMENTS(class) && type == 
UP_DEVICE_KIND_UNKNOWN; i++) {
+                               /* Detect if the battery comes from bluetooth 
keyboard or mouse. */
+                               bluetooth = 
g_udev_device_get_parent_with_subsystem (native, class[i], NULL);
+                               if (bluetooth != NULL) {
+                                       device_path = 
g_udev_device_get_sysfs_path (bluetooth);
+
+                                       /* There may be an extra subdirectory 
here */
+                                       subdir = g_build_filename (device_path, 
"input", NULL);
+                                       if (!g_file_test (subdir, 
G_FILE_TEST_IS_DIR)) {
+                                               g_free(subdir);
+                                               subdir = g_strdup (device_path);
+                                       }
 
-                       /* Detect if the battery comes from bluetooth keyboard 
or mouse. */
-                       bluetooth = g_udev_device_get_parent_with_subsystem 
(native, "bluetooth", NULL);
-                       if (bluetooth != NULL) {
-                               device_path = g_udev_device_get_sysfs_path 
(bluetooth);
-                               if ((dir = g_dir_open (device_path, 0, 
&error))) {
-                                       while ((file = g_dir_read_name (dir))) {
-                                               /* Check if it is an input 
device. */
-                                               if (g_str_has_prefix (file, 
"input")) {
-                                                       input_path = 
g_build_filename (device_path, file, NULL);
-                                                       break;
+                                       if ((dir = g_dir_open (subdir, 0, 
&error))) {
+                                               while ((file = g_dir_read_name 
(dir))) {
+                                                       /* Check if it is an 
input device. */
+                                                       if (g_str_has_prefix 
(file, "input")) {
+                                                               input_path = 
g_build_filename (subdir, file, NULL);
+                                                               break;
+                                                       }
                                                }
+                                               g_dir_close (dir);
+                                       } else {
+                                               g_warning ("Can not open folder 
%s: %s", device_path, error->message);
+                                               g_error_free (error);
                                        }
-                                       g_dir_close (dir);
-                               } else {
-                                       g_warning ("Can not open folder %s: 
%s", device_path, error->message);
-                                       g_error_free (error);
+                                       g_free (subdir);
+                                       g_object_unref (bluetooth);
                                }
-                               g_object_unref (bluetooth);
-                       }
 
-                       if (input_path != NULL) {
+                               if (input_path == NULL)
+                                       continue;
+
                                if ((dir = g_dir_open (input_path, 0, &error))) 
{
                                        while ((file = g_dir_read_name (dir))) {
                                                /* Check if it is a mouse 
device. */


Reply via email to