summaryrefslogtreecommitdiff
path: root/pcr
diff options
context:
space:
mode:
authorNicolás Reynolds <fauno@endefensadelsl.org>2013-09-20 16:18:17 -0300
committerNicolás Reynolds <fauno@endefensadelsl.org>2013-09-20 16:18:17 -0300
commita15e19cb5254a876b22065a3c7ec24124429c51c (patch)
tree0a1f97c83e0f6a65d410c9bc603e1891fca3977c /pcr
parent27a3b01f9a5cd93e2cefb9bafed26a6ce404a0a4 (diff)
parentde974812574e5aca6b197da8b8bb40597e69fe73 (diff)
Merge branch 'master' of vparabola:abslibre
Diffstat (limited to 'pcr')
-rw-r--r--pcr/android-udev/PKGBUILD26
-rw-r--r--pcr/android-udev/android-udev.install12
2 files changed, 38 insertions, 0 deletions
diff --git a/pcr/android-udev/PKGBUILD b/pcr/android-udev/PKGBUILD
new file mode 100644
index 000000000..10fe60934
--- /dev/null
+++ b/pcr/android-udev/PKGBUILD
@@ -0,0 +1,26 @@
+# Maintainer: Luke Shumaker <lukeshu@sbcglobal.net>
+# Maintainer (AUR): M0Rf30
+# Contributor: marlock
+
+pkgname=android-udev
+pkgver=20130911
+_gitver=8dfd1cd0002d7067d24a2ef89360212f164f3856
+url="https://github.com/M0Rf30/android-udev-rules"
+pkgdesc='Udev rules to for Android devices.'
+
+# The author is the maintainer of the AUR package, where it is listed as GPL;
+# this is the best hint to the license that we have.
+license=('GPL')
+
+pkgrel=1
+arch=('any')
+source=("51-android-$pkgver.rules::https://raw.github.com/M0Rf30/android-udev-rules/$_gitver/51-android.rules")
+depends=('systemd' 'libmtp')
+install='android-udev.install'
+
+package() {
+ cd "$srcdir"
+ install -Dm755 "$srcdir"/51-android-$pkgver.rules "$pkgdir"/usr/lib/udev/rules.d/51-android.rules
+}
+
+md5sums=('1b2033fcf52b1b0ffa807ba90b11fd14')
diff --git a/pcr/android-udev/android-udev.install b/pcr/android-udev/android-udev.install
new file mode 100644
index 000000000..dcb1ebc20
--- /dev/null
+++ b/pcr/android-udev/android-udev.install
@@ -0,0 +1,12 @@
+post_install() {
+ post_upgrade
+ echo "NOTE: To use adb as a normal user you have to add yourself to the adbusers group"
+}
+
+post_upgrade() {
+ { getent group adbusers || /usr/sbin/groupadd adbusers; } &>/dev/null
+}
+
+post_remove() {
+ getent group adbusers &>/dev/null && /usr/sbin/groupdel adbusers
+}