Skip to content

Instantly share code, notes, and snippets.

@StuntsPT

StuntsPT/PKGBUILD

Created Jan 3, 2017
Embed
What would you like to do?
PKGBUILD with uhid access for "roccat" group users.
# Maintainer: Aaron Fischer <mail@aaron-fischer.net>
# Contributor: Nuno Araujo <nuno.araujo@russo79.com>
# Contributor: Xpander <xpander0@gmail.com>
# Contributor: Stefan Achatz <erazor_de@users.soruceforge.net>
# Contributor: Zachary Lund <admin@computerquip.com>
# Contributor: Jesus Gonzalez <jesusmgh@gmail.com>
# Contributor: Francisco Pina-Martins <f.pinamartins@gmail.com>
pkgname=('roccat-tools-common'
'roccat-tools-arvo'
'roccat-tools-kiro'
'roccat-tools-isku'
'roccat-tools-iskufx'
'roccat-tools-kone'
'roccat-tools-koneplus'
'roccat-tools-konepure'
'roccat-tools-konepuremilitary'
'roccat-tools-konepureoptical'
'roccat-tools-konextd'
'roccat-tools-konextdoptical'
'roccat-tools-kovaplus'
'roccat-tools-kova2016'
'roccat-tools-lua'
'roccat-tools-pyra'
'roccat-tools-ryosmk'
'roccat-tools-ryosmkfx'
'roccat-tools-ryostkl'
'roccat-tools-savu'
'roccat-tools-sova'
'roccat-tools-suora'
'roccat-tools-tyon'
'roccat-tools-nyth')
pkgbase=roccat-tools
pkgver=5.5.0
pkgrel=2
pkgdesc='Userland applications to configure and make extended use of ROCCAT devices'
arch=('i686' 'x86_64')
url='http://roccat.sourceforge.net'
license=('GPL2')
depends=('libgaminggear>=0.15.0' 'libcanberra' 'gtk2' 'libnotify>=0.7.0' 'dbus-glib' 'udev' 'hicolor-icon-theme' 'libgudev' 'lua>=5.3')
makedepends=('cmake')
optdepends=('kmod-roccat: Adds support for the old kone device.')
source=("http://downloads.sourceforge.net/project/roccat/roccat-tools/roccat-tools-$pkgver.tar.bz2")
md5sums=('1cd328de42261c736ee275b33c8ecbb8')
build() {
cd "$srcdir/$pkgbase-$pkgver"
cmake \
-DCMAKE_INSTALL_PREFIX=/usr \
-DUDEVDIR=/usr/lib/udev/rules.d \
-DWITHOUT_PYTHON=TRUE \
-DLIBDIR="/usr/lib" \
-DWITH_LUA="5.3"
make
}
package_roccat-tools-common() {
pkgdesc='ROCCAT tools common files'
install=roccat-tools.install
for i in icons sounds libroccat libroccathelper libroccatwidget roccateventhandler; do
cd $srcdir/$pkgbase-$pkgver/$i
make DESTDIR="$pkgdir/" install
done
# Make sure we load the uhid module
echo "uhid" > $pkgdir/etc/modules-load.d/uhid.conf
# Add the correct udev rule to allow "roccat" group to access /dev/uhid
echo 'KERNEL=="uinput", GROUP="roccat", MODE="0660"' > $pkgdir/etc/udev/rules.d/90-uinput.rules
echo 'KERNEL=="uhid", GROUP="uinput-users", MODE="0660"' >> $pkgdir/etc/udev/rules.d/90-uinput.rules
}
package_roccat-tools-arvo() {
pkgdesc='Userland applications to configure and make extended use of ROCCAT Arvo devices'
depends=('roccat-tools-common')
cd "$srcdir/$pkgbase-$pkgver/arvo"
make DESTDIR="$pkgdir/" install
cd "$srcdir/$pkgbase-$pkgver"
install -Dm644 udev/90-roccat-arvo.rules $pkgdir/usr/lib/udev/rules.d/90-roccat-arvo.rules
}
package_roccat-tools-kiro() {
pkgdesc='Userland applications to configure and make extended use of ROCCAT Kiro devices'
depends=('roccat-tools-common')
cd "$srcdir/$pkgbase-$pkgver/kiro"
make DESTDIR="$pkgdir/" install
cd "$srcdir/$pkgbase-$pkgver"
install -Dm644 udev/90-roccat-kiro.rules $pkgdir/usr/lib/udev/rules.d/90-roccat-kiro.rules
}
package_roccat-tools-isku() {
pkgdesc='Userland applications to configure and make extended use of ROCCAT Isku devices'
depends=('roccat-tools-common')
cd "$srcdir/$pkgbase-$pkgver/isku"
make DESTDIR="$pkgdir/" install
cd "$srcdir/$pkgbase-$pkgver"
install -Dm644 udev/90-roccat-isku.rules $pkgdir/usr/lib/udev/rules.d/90-roccat-isku.rules
}
package_roccat-tools-iskufx() {
pkgdesc='Userland applications to configure and make extended use of ROCCAT Isku FX devices'
depends=('roccat-tools-common' 'roccat-tools-isku')
cd "$srcdir/$pkgbase-$pkgver/iskufx"
make DESTDIR="$pkgdir/" install
cd "$srcdir/$pkgbase-$pkgver"
install -Dm644 udev/90-roccat-iskufx.rules $pkgdir/usr/lib/udev/rules.d/90-roccat-iskufx.rules
}
package_roccat-tools-kone() {
pkgdesc='Userland applications to configure and make extended use of ROCCAT Kone devices'
depends=('roccat-tools-common')
cd "$srcdir/$pkgbase-$pkgver/kone"
make DESTDIR="$pkgdir/" install
cd "$srcdir/$pkgbase-$pkgver"
install -Dm644 udev/90-roccat-kone.rules $pkgdir/usr/lib/udev/rules.d/90-roccat-kone.rules
}
package_roccat-tools-koneplus() {
pkgdesc='Userland applications to configure and make extended use of ROCCAT Kone[+] devices'
depends=('roccat-tools-common')
cd "$srcdir/$pkgbase-$pkgver/koneplus"
make DESTDIR="$pkgdir/" install
cd "$srcdir/$pkgbase-$pkgver"
install -Dm644 udev/90-roccat-koneplus.rules $pkgdir/usr/lib/udev/rules.d/90-roccat-koneplus.rules
}
package_roccat-tools-konepure() {
pkgdesc='Userland applications to configure and make extended use of ROCCAT Kone Pure devices'
depends=('roccat-tools-common' 'roccat-tools-konextd')
cd "$srcdir/$pkgbase-$pkgver/konepure"
make DESTDIR="$pkgdir/" install
cd "$srcdir/$pkgbase-$pkgver"
install -Dm644 udev/90-roccat-konepure.rules $pkgdir/usr/lib/udev/rules.d/90-roccat-konepure.rules
}
package_roccat-tools-konepureoptical() {
pkgdesc='Userland applications to configure and make extended use of ROCCAT Kone Pure optical devices'
depends=('roccat-tools-common' 'roccat-tools-konepure')
cd "$srcdir/$pkgbase-$pkgver/konepureoptical"
make DESTDIR="$pkgdir/" install
cd "$srcdir/$pkgbase-$pkgver"
install -Dm644 udev/90-roccat-konepureoptical.rules $pkgdir/usr/lib/udev/rules.d/90-roccat-konepureoptical.rules
}
package_roccat-tools-konepuremilitary() {
pkgdesc='Userland applications to configure and make extended use of ROCCAT Kone Pure Military devices'
depends=('roccat-tools-common' 'roccat-tools-konepure')
cd "$srcdir/$pkgbase-$pkgver/konepuremilitary"
make DESTDIR="$pkgdir/" install
cd "$srcdir/$pkgbase-$pkgver"
install -Dm644 udev/90-roccat-konepuremilitary.rules $pkgdir/usr/lib/udev/rules.d/90-roccat-konepuremilitary.rules
}
package_roccat-tools-konextd() {
pkgdesc='Userland applications to configure and make extended use of ROCCAT Kone XTD devices'
depends=('roccat-tools-common' 'roccat-tools-koneplus')
cd "$srcdir/$pkgbase-$pkgver/konextd"
make DESTDIR="$pkgdir/" install
cd "$srcdir/$pkgbase-$pkgver"
install -Dm644 udev/90-roccat-konextd.rules $pkgdir/usr/lib/udev/rules.d/90-roccat-konextd.rules
}
package_roccat-tools-konextdoptical() {
pkgdesc='Userland applications to configure and make extended use of ROCCAT Kone XTD Optical devices'
depends=('roccat-tools-common' 'roccat-tools-konepuremilitary')
cd "$srcdir/$pkgbase-$pkgver/konextdoptical"
make DESTDIR="$pkgdir/" install
cd "$srcdir/$pkgbase-$pkgver"
install -Dm644 udev/90-roccat-konextdoptical.rules $pkgdir/usr/lib/udev/rules.d/90-roccat-konextdoptical.rules
}
package_roccat-tools-kovaplus() {
pkgdesc='Userland applications to configure and make extended use of ROCCAT Kova[+] devices'
depends=('roccat-tools-common')
cd "$srcdir/$pkgbase-$pkgver/kovaplus"
make DESTDIR="$pkgdir/" install
cd "$srcdir/$pkgbase-$pkgver"
install -Dm644 udev/90-roccat-kovaplus.rules $pkgdir/usr/lib/udev/rules.d/90-roccat-kovaplus.rules
}
package_roccat-tools-kova2016() {
pkgdesc='Userland applications to configure and make extended use of ROCCAT Kova2016 devices'
depends=('roccat-tools-common')
cd "$srcdir/$pkgbase-$pkgver/kova2016"
make DESTDIR="$pkgdir/" install
cd "$srcdir/$pkgbase-$pkgver"
install -Dm644 udev/90-roccat-kova2016.rules $pkgdir/usr/lib/udev/rules.d/90-roccat-kova2016.rules
}
package_roccat-tools-lua() {
pkgdesc='Userland applications to configure and make extended use of ROCCAT Lua devices'
depends=('roccat-tools-common')
cd "$srcdir/$pkgbase-$pkgver/lua"
make DESTDIR="$pkgdir/" install
cd "$srcdir/$pkgbase-$pkgver"
install -Dm644 udev/90-roccat-lua.rules $pkgdir/usr/lib/udev/rules.d/90-roccat-lua.rules
}
package_roccat-tools-pyra() {
pkgdesc='Userland applications to configure and make extended use of ROCCAT Pyra devices'
depends=('roccat-tools-common')
cd "$srcdir/$pkgbase-$pkgver/pyra"
make DESTDIR="$pkgdir/" install
cd "$srcdir/$pkgbase-$pkgver"
install -Dm644 udev/90-roccat-pyra.rules $pkgdir/usr/lib/udev/rules.d/90-roccat-pyra.rules
}
package_roccat-tools-ryosmk() {
pkgdesc='Userland applications to configure and make extended use of ROCCAT RyosMK devices'
depends=('roccat-tools-common')
cd "$srcdir/$pkgbase-$pkgver/ryosmk"
make DESTDIR="$pkgdir/" install
cd "$srcdir/$pkgbase-$pkgver"
install -Dm644 udev/90-roccat-ryosmk.rules $pkgdir/usr/lib/udev/rules.d/90-roccat-ryosmk.rules
}
package_roccat-tools-ryosmkfx() {
pkgdesc='Userland applications to configure and make extended use of ROCCAT RyosMK FX devices'
depends=('roccat-tools-common')
cd "$srcdir/$pkgbase-$pkgver/ryosmkfx"
make DESTDIR="$pkgdir/" install
cd "$srcdir/$pkgbase-$pkgver"
install -Dm644 udev/90-roccat-ryosmkfx.rules $pkgdir/usr/lib/udev/rules.d/90-roccat-ryosmkfx.rules
}
package_roccat-tools-ryostkl() {
pkgdesc='Userland applications to configure and make extended use of ROCCAT RyosTKL devices'
depends=('roccat-tools-common' 'roccat-tools-ryosmk')
cd "$srcdir/$pkgbase-$pkgver/ryostkl"
make DESTDIR="$pkgdir/" install
cd "$srcdir/$pkgbase-$pkgver"
install -Dm644 udev/90-roccat-ryostkl.rules $pkgdir/usr/lib/udev/rules.d/90-roccat-ryostkl.rules
}
package_roccat-tools-savu() {
pkgdesc='Userland applications to configure and make extended use of ROCCAT Savu devices'
depends=('roccat-tools-common')
cd "$srcdir/$pkgbase-$pkgver/savu"
make DESTDIR="$pkgdir/" install
cd "$srcdir/$pkgbase-$pkgver"
install -Dm644 udev/90-roccat-savu.rules $pkgdir/usr/lib/udev/rules.d/90-roccat-savu.rules
}
package_roccat-tools-tyon() {
pkgdesc='Userland applications to configure and make extended use of ROCCAT Tyon devices'
depends=('roccat-tools-common')
cd "$srcdir/$pkgbase-$pkgver/tyon"
make DESTDIR="$pkgdir/" install
cd "$srcdir/$pkgbase-$pkgver"
install -Dm644 udev/90-roccat-tyon.rules $pkgdir/usr/lib/udev/rules.d/90-roccat-tyon.rules
}
package_roccat-tools-suora() {
pkgdesc='Userland applications to configure and make extended use of ROCCAT Suora devices'
depends=('roccat-tools-common')
cd "$srcdir/$pkgbase-$pkgver/suora"
make DESTDIR="$pkgdir/" install
cd "$srcdir/$pkgbase-$pkgver"
install -Dm644 udev/90-roccat-suora.rules $pkgdir/usr/lib/udev/rules.d/90-roccat-suora.rules
}
package_roccat-tools-sova() {
pkgdesc='Userland applications to configure and make extended use of ROCCAT Sova devices'
depends=('roccat-tools-common')
cd "$srcdir/$pkgbase-$pkgver/sova"
make DESTDIR="$pkgdir/" install
cd "$srcdir/$pkgbase-$pkgver"
install -Dm644 udev/90-roccat-sova.rules $pkgdir/usr/lib/udev/rules.d/90-roccat-sova.rules
}
package_roccat-tools-nyth() {
pkgdesc='Userland applications to configure and make extended use of ROCCAT Nyth devices'
depends=('roccat-tools-common')
cd "$srcdir/$pkgbase-$pkgver/nyth"
make DESTDIR="$pkgdir/" install
cd "$srcdir/$pkgbase-$pkgver"
install -Dm644 udev/90-roccat-nyth.rules $pkgdir/usr/lib/udev/rules.d/90-roccat-nyth.rules
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment