summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorwillemw122015-06-08 12:12:58 +0200
committerwillemw122015-06-08 12:12:58 +0200
commit59a73efb8398b257664e653824384bd9953c4f13 (patch)
tree1b7140b2e11a01986655da8c44ee95c3752a1445
downloadaur-59a73efb8398b257664e653824384bd9953c4f13.tar.gz
Initial commit
-rw-r--r--.SRCINFO24
-rw-r--r--PKGBUILD36
-rw-r--r--indicator-sensors.install31
3 files changed, 91 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 000000000000..beecf25f868d
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,24 @@
+pkgbase = indicator-sensors
+ pkgdesc = Small application to provide hardware sensor readings using the AppIndicator framework
+ pkgver = 0.8
+ pkgrel = 2
+ url = https://github.com/alexmurray/indicator-sensors
+ install = indicator-sensors.install
+ arch = i686
+ arch = x86_64
+ license = GPL3
+ makedepends = gnome-common
+ makedepends = intltool
+ depends = dconf
+ depends = libappindicator-gtk3
+ depends = libatasmart
+ depends = libnotify
+ depends = libpeas
+ depends = lm_sensors
+ depends = udisks2
+ optdepends = libxnvctrl: NVIDIA GPU support
+ source = https://github.com/alexmurray/indicator-sensors/archive/0.8.tar.gz
+ md5sums = 2975c3b04778e18b549356383a3740d8
+
+pkgname = indicator-sensors
+
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..2079eec687dd
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,36 @@
+# Maintainer: willemw <willemw12@gmail.com>
+
+pkgname=indicator-sensors
+pkgver=0.8
+pkgrel=2
+pkgdesc="Small application to provide hardware sensor readings using the AppIndicator framework"
+arch=('i686' 'x86_64')
+url="https://github.com/alexmurray/indicator-sensors"
+license=('GPL3')
+depends=('dconf' 'libappindicator-gtk3' 'libatasmart' 'libnotify' 'libpeas' 'lm_sensors' 'udisks2')
+optdepends=('libxnvctrl: NVIDIA GPU support')
+makedepends=('gnome-common' 'intltool')
+install=$pkgname.install
+source=(https://github.com/alexmurray/$pkgname/archive/$pkgver.tar.gz)
+md5sums=('2975c3b04778e18b549356383a3740d8')
+
+prepare() {
+ cd $pkgname-$pkgver
+
+ # Fix autogen with latest gnome-common
+ # Side-by-side use of IT_PROG_INTLTOOL and AM_GNU_GETTEXT is not supported.
+ #sed -i "s|\(^AM_GNU_GETTEXT\)|#\1|" configure.ac
+}
+
+build() {
+ cd $pkgname-$pkgver
+ sh ./autogen.sh
+ ./configure --disable-schemas-compile --prefix=/usr
+ make
+}
+
+package() {
+ cd $pkgname-$pkgver
+ make DESTDIR="$pkgdir" install
+}
+
diff --git a/indicator-sensors.install b/indicator-sensors.install
new file mode 100644
index 000000000000..74d0cfbc1bff
--- /dev/null
+++ b/indicator-sensors.install
@@ -0,0 +1,31 @@
+post_install() {
+ post_remove $1
+
+ cat << EOF
+==> One way to solve Policykit/UDisks2 related errors ("Error:org.freedesktop.UDisks2.Error.NotAuthorized: Not authorized to perform operation") is to define the following rules in file /etc/polkit-1/rules.d/50-udisks.rules:
+
+ polkit.addRule(function(action, subject) {
+ var YES = polkit.Result.YES;
+ var permission = {
+ // only required for udisks2:
+ "org.freedesktop.udisks2.ata-check-power": YES,
+ "org.freedesktop.udisks2.ata-smart-update": YES,
+ };
+ if (subject.isInGroup("users")) {
+ return permission[action.id];
+ }
+ });
+
+ Then restart the polkit service.
+EOF
+}
+
+post_upgrade() {
+ post_remove $1
+}
+
+post_remove() {
+ glib-compile-schemas usr/share/glib-2.0/schemas
+ gtk-update-icon-cache -q -t -f usr/share/icons/hicolor
+}
+