Package: iio-sensor-proxy
Version: 3.0-2
Tags: patch
User: ubuntu-de...@lists.ubuntu.com
Usertags: origin-ubuntu kinetic ubuntu-patch
The patch is based on the update in Ubuntu.
You could perhaps also consider moving the package to be team maintained
(pkg-gnome for example)?
Thanks,
diff -Nur iio-sensor-proxy-3.0/debian/changelog iio-sensor-proxy-3.4/debian/changelog
--- iio-sensor-proxy-3.0/debian/changelog 2021-01-29 08:05:45.000000000 +0100
+++ iio-sensor-proxy-3.4/debian/changelog 2022-09-16 19:22:55.209417249 +0200
@@ -1,3 +1,17 @@
+iio-sensor-proxy (3.4-1) UNRELEASED; urgency=medium
+
+ * New upstream version
+ * debian/control:
+ - build-depends on libpolkit-gobject-1-dev
+ - updated libgudev requirement
+ - updated Build-Depends for the new integration tests
+ * debian/patches/proximity-Get-near-level-from-sysfs-if-available.patch,
+ debian/patches/build_older_polkit.patch:
+ - remove patch upstream, add one to allow building with the
+ unstable polkit version
+
+ -- Sebastien Bacher <seb...@ubuntu.com> Fri, 16 Sep 2022 19:09:35 +0200
+
iio-sensor-proxy (3.0-2) unstable; urgency=medium
[ Ritesh Raj Sarraf ]
diff -Nur iio-sensor-proxy-3.0/debian/control iio-sensor-proxy-3.4/debian/control
--- iio-sensor-proxy-3.0/debian/control 2021-01-29 08:05:45.000000000 +0100
+++ iio-sensor-proxy-3.4/debian/control 2022-09-16 19:19:25.452184127 +0200
@@ -4,11 +4,19 @@
Maintainer: Ritesh Raj Sarraf <r...@debian.org>
Build-Depends:
debhelper-compat (= 12),
- libgudev-1.0-dev,
+ libgudev-1.0-dev (>= 1:237),
+ libpolkit-gobject-1-dev,
+ libudev-dev,
udev,
systemd,
gtk-doc-tools (>= 1.0),
- libgtk-3-dev
+ libgtk-3-dev,
+ meson,
+ gir1.2-umockdev-1.0,
+ python3-dbusmock,
+ python3-gi,
+ python3-psutil,
+ umockdev,
Standards-Version: 4.5.1
Rules-Requires-Root: no
Homepage: https://gitlab.freedesktop.org/hadess/iio-sensor-proxy
diff -Nur iio-sensor-proxy-3.0/debian/files iio-sensor-proxy-3.4/debian/files
--- iio-sensor-proxy-3.0/debian/files 1970-01-01 01:00:00.000000000 +0100
+++ iio-sensor-proxy-3.4/debian/files 2022-09-16 19:23:01.329335672 +0200
@@ -0,0 +1 @@
+iio-sensor-proxy_3.4-1_source.buildinfo utils optional
diff -Nur iio-sensor-proxy-3.0/debian/patches/build_older_polkit.patch iio-sensor-proxy-3.4/debian/patches/build_older_polkit.patch
--- iio-sensor-proxy-3.0/debian/patches/build_older_polkit.patch 1970-01-01 01:00:00.000000000 +0100
+++ iio-sensor-proxy-3.4/debian/patches/build_older_polkit.patch 2022-09-16 19:18:08.501181948 +0200
@@ -0,0 +1,29 @@
+Index: iio-sensor-proxy-3.4/src/iio-sensor-proxy.c
+===================================================================
+--- iio-sensor-proxy-3.4.orig/src/iio-sensor-proxy.c
++++ iio-sensor-proxy-3.4/src/iio-sensor-proxy.c
+@@ -33,6 +33,13 @@
+
+ #define NUM_SENSOR_TYPES DRIVER_TYPE_PROXIMITY + 1
+
++/* This uses a weird Auto prefix to avoid conflicts with later added polkit types. */
++typedef PolkitAuthorizationResult AutoPolkitAuthorizationResult;
++typedef PolkitSubject AutoPolkitSubject;
++
++G_DEFINE_AUTOPTR_CLEANUP_FUNC (AutoPolkitAuthorizationResult, g_object_unref)
++G_DEFINE_AUTOPTR_CLEANUP_FUNC (AutoPolkitSubject, g_object_unref)
++
+ typedef struct {
+ GMainLoop *loop;
+ GUdevClient *client;
+@@ -437,8 +444,8 @@ check_claim_permission (SensorData *da
+ GError **error)
+ {
+ g_autoptr(GError) local_error = NULL;
+- g_autoptr(PolkitAuthorizationResult) result = NULL;
+- g_autoptr(PolkitSubject) subject = NULL;
++ g_autoptr(AutoPolkitAuthorizationResult) result = NULL;
++ g_autoptr(AutoPolkitSubject) subject = NULL;
+
+ subject = polkit_system_bus_name_new (sender);
+ result = polkit_authority_check_authorization_sync (data->auth,
diff -Nur iio-sensor-proxy-3.0/debian/patches/proximity-Get-near-level-from-sysfs-if-available.patch iio-sensor-proxy-3.4/debian/patches/proximity-Get-near-level-from-sysfs-if-available.patch
--- iio-sensor-proxy-3.0/debian/patches/proximity-Get-near-level-from-sysfs-if-available.patch 2021-01-28 16:22:11.000000000 +0100
+++ iio-sensor-proxy-3.4/debian/patches/proximity-Get-near-level-from-sysfs-if-available.patch 1970-01-01 01:00:00.000000000 +0100
@@ -1,31 +0,0 @@
-From: Your Name <y...@example.com>
-Date: Wed, 25 Mar 2020 11:59:03 +0100
-Subject: proximity: Get near-level from sysfs if available
-MIME-Version: 1.0
-Content-Type: text/plain; charset="utf-8"
-Content-Transfer-Encoding: 8bit
-
-DT based devices can set the near-level via sysfs. Parse it from
-there too.
-
-Signed-off-by: Guido Günther <a...@sigxcpu.org>
-Closes: #297
-(cherry picked from commit ed427251b703dc832a2051b5e4bdd1b51b99b115)
----
- src/drv-iio-poll-proximity.c | 3 +++
- 1 file changed, 3 insertions(+)
-
-diff --git a/src/drv-iio-poll-proximity.c b/src/drv-iio-poll-proximity.c
-index 98bacb1..432cda5 100644
---- a/src/drv-iio-poll-proximity.c
-+++ b/src/drv-iio-poll-proximity.c
-@@ -100,6 +100,9 @@ get_near_level (GUdevDevice *device)
- gint near_level;
-
- near_level = g_udev_device_get_property_as_int (device, PROXIMITY_NEAR_LEVEL);
-+ if (!near_level)
-+ near_level = g_udev_device_get_sysfs_attr_as_int (device, "in_proximity_nearlevel");
-+
- if (!near_level) {
- g_warning ("Found proximity sensor but no " PROXIMITY_NEAR_LEVEL " udev property");
- g_warning ("See https://gitlab.freedesktop.org/hadess/iio-sensor-proxy/blob/master/README.md");
diff -Nur iio-sensor-proxy-3.0/debian/patches/series iio-sensor-proxy-3.4/debian/patches/series
--- iio-sensor-proxy-3.0/debian/patches/series 2021-01-28 16:22:11.000000000 +0100
+++ iio-sensor-proxy-3.4/debian/patches/series 2022-09-16 19:18:08.501181948 +0200
@@ -1 +1 @@
-proximity-Get-near-level-from-sysfs-if-available.patch
+build_older_polkit.patch