summaryrefslogtreecommitdiff
path: root/pcr/python-steamcontroller-git/PKGBUILD
diff options
context:
space:
mode:
Diffstat (limited to 'pcr/python-steamcontroller-git/PKGBUILD')
-rw-r--r--pcr/python-steamcontroller-git/PKGBUILD44
1 files changed, 44 insertions, 0 deletions
diff --git a/pcr/python-steamcontroller-git/PKGBUILD b/pcr/python-steamcontroller-git/PKGBUILD
new file mode 100644
index 000000000..1c9a4c409
--- /dev/null
+++ b/pcr/python-steamcontroller-git/PKGBUILD
@@ -0,0 +1,44 @@
+# Maintainer: André Silva <emulatorman@parabola.nu>
+# Contributor (Arch): vorpalblade77@gmail.com
+pkgname=python-steamcontroller-git
+_pkgname=steamcontroller
+pkgver=r92.71cb09c
+_gitver=71cb09c9dd4e0d6dfd61a109562f24e5aea58517
+pkgrel=1
+pkgdesc="Standalone userland driver for the Steam controller"
+arch=('i686' 'x86_64')
+url="https://github.com/ynsta/${_pkgname}"
+license=('MIT')
+makedepends=('git' 'python-distutils-extra' 'python-setuptools')
+depends=('python-libusb1')
+optdepends=('python-pyside: Required for sc-gyro-plot.py'
+ 'python-pyqtgraph: Required for sc-gyro-plot.py')
+provides=('steamcontroller')
+conflicts=("${_pkgname}")
+changelog='changelog.txt'
+source=("${_pkgname}-${pkgver}::git+https://github.com/ynsta/${_pkgname}.git/#commit=$_gitver"
+ '80-steam-controller-permission.rules')
+sha256sums=('SKIP'
+ 'ab6efa7c0aaf408f51eee8e1d83ec07004730848bdef3ab9e091847fb915f240')
+install='steamcontroller.install'
+
+pkgver() {
+ cd "${_pkgname}-${pkgver}"
+ printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
+}
+
+build() {
+ cd "${_pkgname}-${pkgver}"
+ python setup.py build
+}
+
+package() {
+ cd "${_pkgname}-${pkgver}"
+ install -m755 -d "${pkgdir}/usr/lib/udev/rules.d"
+ install -Dm 644 "${srcdir}/80-steam-controller-permission.rules" \
+ "${pkgdir}/usr/lib/udev/rules.d/80-steam-controller-permission.rules"
+ python setup.py install --root="${pkgdir}" \
+ --prefix="/usr" \
+ --compile -O1
+ install -D LICENSE "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
+}