summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorChristoph Haag2016-04-16 13:33:54 +0200
committerChristoph Haag2016-04-16 13:33:54 +0200
commit96a2cc5126ffaf19da722837278083c15f5f37de (patch)
tree853134e0e8aa11bffaff55b9803360cc75155189
downloadaur-96a2cc5126ffaf19da722837278083c15f5f37de.tar.gz
initial
-rw-r--r--.SRCINFO22
-rw-r--r--PKGBUILD42
-rw-r--r--clevo-wmi-dkms.install20
-rw-r--r--dkms.conf.in7
4 files changed, 91 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 00000000000..4c35a0b40fd
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,22 @@
+pkgbase = clevo-wmi-dkms-git
+ pkgdesc = A reverse engineering driver for the Clevo P15SM/P17SM/W230ST/W350STQ/W370ST/W650SR/W670SR/W740SU backlight keyboard, by Christoph Jaeger (DKMS version)
+ pkgver = 0.9.6
+ pkgrel = 4
+ url = http://www.linux-onlineshop.de/forum/index.php?page=Thread&threadID=26&s=82130b57e71bd5b6ea569abc1424025c6f8d412d
+ install = clevo-wmi-dkms.install
+ arch = any
+ license = GPL
+ depends = dkms
+ depends = linux-headers
+ provides = clevo-wmi
+ conflicts = clevo_wmi-git
+ conflicts = clevo-wmi
+ conflicts = tuxedo-wmi
+ conflicts = tuxedo-wmi-dkms
+ source = git+https://github.com/ChristophHaag/clevo-wmi.git
+ source = dkms.conf.in
+ md5sums = SKIP
+ md5sums = 885768a16582199937509d456b3475af
+
+pkgname = clevo-wmi-dkms-git
+
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 00000000000..5843c616a32
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,42 @@
+# Author: Christoph Jaeger <christophjaeger@linux.com>
+# Maintainer: Marc Rozanc <marc@rozanc.fr>
+
+pkgname="clevo-wmi-dkms-git"
+_modname="clevo-wmi"
+pkgver="0.9.6"
+pkgrel=4
+pkgdesc='A reverse engineering driver for the Clevo P15SM/P17SM/W230ST/W350STQ/W370ST/W650SR/W670SR/W740SU backlight keyboard, by Christoph Jaeger (DKMS version)'
+arch=('any')
+license=('GPL')
+url='http://www.linux-onlineshop.de/forum/index.php?page=Thread&threadID=26&s=82130b57e71bd5b6ea569abc1424025c6f8d412d'
+depends=('dkms' 'linux-headers')
+provides=("clevo-wmi")
+conflicts=("clevo_wmi-git" "clevo-wmi" "tuxedo-wmi" "tuxedo-wmi-dkms")
+source=("git+https://github.com/ChristophHaag/clevo-wmi.git"
+ "dkms.conf.in")
+md5sums=('SKIP'
+ '885768a16582199937509d456b3475af')
+install='clevo-wmi-dkms.install'
+
+_driverdir=clevo-wmi/code-dump/clevo-wmi-code-b5d8a0d3f9cb4f20b39018d25ba9f313ad1b10ba
+
+#_driverdir=clevo-wmi/src #this one doesn't actually controlling the leds
+#_driverdir=clevo-wmi/code-dump/clevo-wmi-0.9.6/src
+#_driverdir=clevo-wmi/code-dump/clevo-wmi #clevo_wmi: Invalid function: 0x56 - and doesn't do anything
+#_driverdir=clevo-wmi/code-dump/clevo_laptop_1.1.1 #doesn't build
+
+build() {
+ cd "${srcdir}/$_driverdir"
+ make
+}
+
+package() {
+ cd "${srcdir}/$_driverdir"
+
+ install -dm755 "${pkgdir}/usr/src/${_modname}-${pkgver}/"
+ for i in "${srcdir}/$_driverdir/"{Makefile,clevo-wmi.c}; do
+ install -D -m644 "${i}" "${pkgdir}/usr/src/${_modname}-${pkgver}/"
+ done
+ sed "s/#MODULE_VERSION#/${pkgver}/" "${srcdir}/dkms.conf.in" > "${pkgdir}/usr/src/${_modname}-${pkgver}/dkms.conf"
+}
+
diff --git a/clevo-wmi-dkms.install b/clevo-wmi-dkms.install
new file mode 100644
index 00000000000..9614b8fb7e8
--- /dev/null
+++ b/clevo-wmi-dkms.install
@@ -0,0 +1,20 @@
+post_install() {
+ dkms install -m clevo-wmi -v ${1%%-*}
+}
+
+pre_upgrade() {
+ local curver=${2%%-*}
+ # $2 is unset due to a bug. See, https://bugs.archlinux.org/task/32278
+ # Query current version using pacman as fallback
+ [ -n "$curver" ] || curver=$(pacman -Q clevo-wmi-dkms | cut -d' ' -f2)
+ pre_remove $curver
+}
+
+post_upgrade() {
+ post_install ${1%%-*}
+}
+
+pre_remove() {
+ dkms remove -m clevo-wmi -v ${1%%-*} --all
+}
+
diff --git a/dkms.conf.in b/dkms.conf.in
new file mode 100644
index 00000000000..29603f743f8
--- /dev/null
+++ b/dkms.conf.in
@@ -0,0 +1,7 @@
+PACKAGE_NAME="clevo-wmi"
+PACKAGE_VERSION="#MODULE_VERSION#"
+MAKE[0]="make KVERSION=$kernelver"
+CLEAN="make clean"
+BUILT_MODULE_NAME[0]="clevo-wmi"
+DEST_MODULE_LOCATION[0]="/kernel/drivers/input/keyboard"
+AUTOINSTALL="yes"