Commit 0b111637 authored by alice's avatar alice 🌗
Browse files

community/iio-sensor-proxy: upgrade to 3.4

parent 13d2eb01
It only needs systemd to determine the unit dir, so delete the dep for now.
From a1c5436d11e3e0dabc3cd236bf8175b13ac929cb Mon Sep 17 00:00:00 2001
From: Andrea Brancaleoni <abc@pompel.me>
Date: Fri, 23 Dec 2016 12:43:36 +0100
Subject: [PATCH] Revert "build: Check for .pc files before using them"
This reverts commit 78b4656fc24a1b21c948d8e68252f42df2a91735.
---
configure.ac | 2 --
1 file changed, 2 deletions(-)
diff --git a/configure.ac b/configure.ac
index f8ded66..1d54698 100644
--- a/configure.ac
+++ b/configure.ac
@@ -25,14 +25,12 @@ AX_COMPILER_FLAGS([WARN_CFLAGS],[WARN_LDFLAGS])
GTK_DOC_CHECK([1.11],[--flavour no-tmpl])
-PKG_CHECK_EXISTS(udev, [], [AC_MSG_ERROR(udev development libraries are required)])
AC_ARG_WITH([udevrulesdir],
AS_HELP_STRING([--with-udevrulesdir=DIR], [Directory for udev rules]),
[],
[with_udevrulesdir=$($PKG_CONFIG --variable=udevdir udev)"/rules.d"])
AC_SUBST([udevrulesdir], [$with_udevrulesdir])
-PKG_CHECK_EXISTS(systemd, [], [AC_MSG_ERROR(systemd development libraries are required)])
AC_ARG_WITH([systemdsystemunitdir],
AS_HELP_STRING([--with-systemdsystemunitdir=DIR], [Directory for systemd service files]),
[],
--
2.11.0
From ed427251b703dc832a2051b5e4bdd1b51b99b115 Mon Sep 17 00:00:00 2001
From: Guido Günther <agx@sigxcpu.org>
Date: Wed, 25 Mar 2020 11:59:03 +0100
Subject: [PATCH] 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 <agx@sigxcpu.org>
Closes: #297
---
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");
--
2.30.0
# Contributor: Rasmus Thomsen <oss@cogitri.dev>
# Maintainer: Rasmus Thomsen <oss@cogitri.dev>
pkgname=iio-sensor-proxy
pkgver=3.0
pkgrel=5
pkgver=3.4
pkgrel=0
pkgdesc="IIO sensors to D-Bus proxy"
url="https://gitlab.freedesktop.org/hadess/iio-sensor-proxy"
arch="all"
license="GPL-2.0-or-later"
depends="dbus"
makedepends="eudev-dev libgudev-dev glib-dev autoconf automake libtool
gtk+3.0-dev gtk-doc
makedepends="
eudev-dev
glib-dev
libgudev-dev
meson
polkit-dev
"
subpackages="$pkgname-doc $pkgname-openrc"
source="https://gitlab.freedesktop.org/hadess/iio-sensor-proxy/uploads/de965bcb444552d328255639b241ce73/iio-sensor-proxy-$pkgver.tar.xz
subpackages="$pkgname-openrc"
source="https://gitlab.freedesktop.org/hadess/iio-sensor-proxy/uploads/9125f3f44e12924e2168bab91a511509/iio-sensor-proxy-3.4.tar.xz
iio-sensor-proxy.initd
0001-Revert-build-Check-for-.pc-files-before-using-them.patch
0002-proximity-Get-near-level-from-sysfs-if-available.patch
"
prepare() {
default_prepare
# Fix location of dbus configuration
sed -e 's|^dbusconfdir = $(sysconfdir)|dbusconfdir = $(datadir)|' \
-i data/Makefile.am
autoreconf -if
}
build() {
./configure \
--build=$CBUILD \
--host=$CHOST \
--prefix=/usr \
--sysconfdir=/etc \
--mandir=/usr/share/man \
--localstatedir=/var \
--with-geoclue-user=geoclue
make
abuild-meson \
-Db_lto=true \
-Dsystemdsystemunitdir=/no \
. output
meson compile -C output
}
check() {
make check
meson test --no-rebuild --print-errorlogs -C output
}
package() {
make DESTDIR="$pkgdir" install
DESTDIR="$pkgdir" meson install --no-rebuild -C output
rm -r "$pkgdir"/no
install -Dm755 "$srcdir"/$pkgname.initd "$pkgdir"/etc/init.d/$pkgname
}
sha512sums="
50e84a5df006c34db07532bdb583142723ad610ade7dc495d0c1b076c7ef84564a60202a8be378173a429bd04dee10e8b33e5b7acc4b3dd810755cb831ebf2ea iio-sensor-proxy-3.0.tar.xz
a34cb2e76b5d634f2e8def5e14c718c7b4ab9abbebf961bf9f420e64882241307d437f58a72dd70b5c7e4093d2e75da1fc166d6f4accc396fb9ca5d30e2b5e5f iio-sensor-proxy.initd
5480763f85cb22fd7b1b791609baa3a4b251fc30a025b40aee2de584fa114686bf181a87a249ba4b0cb9080881ff55498baa7e496513bc39fa1af7c43253c465 0001-Revert-build-Check-for-.pc-files-before-using-them.patch
ceda9e69c78a84e0f8dfd242e401ad4d84e58ef54ea46de284890896b7adf75ab4b66a1a58305e2f554861005ba941912558749d00963008f14642a66b311cf9 0002-proximity-Get-near-level-from-sysfs-if-available.patch
e8662d3fc520069076422c72bbf58a627162934f115b362b360181c04d09bfd6335e2092d5d80e9be59acdd5c7a9adb1309f46b38f706f612a374e0282c26148 iio-sensor-proxy-3.4.tar.xz
b25df94e249ca46fe96926e5a866c20dc913fa52a2d9259fb7a3594861c6b2f246fc7fef8a21f5b021f3a71401f734ae27210137b0b1917a7daaffb5e3221f2e iio-sensor-proxy.initd
"
#!/sbin/openrc-run
supervisor=supervise-daemon
command="/usr/sbin/iio-sensor-proxy"
command="/usr/libexec/iio-sensor-proxy"
depend() {
need dbus
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment