summarylogtreecommitdiffstats
path: root/PKGBUILD
diff options
context:
space:
mode:
authorEgor Vorontsov2022-01-31 18:24:33 +0300
committerEgor Vorontsov2022-01-31 18:24:33 +0300
commit2643641f5a4e316a525b462d172b0c8c21fe3d4c (patch)
tree9679d6746ab628387e41a4d1f09a9f7eba1e1f0e /PKGBUILD
downloadaur-huawei-wmi-dkms-kbdlight-git.tar.gz
Initial commit
Diffstat (limited to 'PKGBUILD')
-rw-r--r--PKGBUILD27
1 files changed, 27 insertions, 0 deletions
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..4b57e47ec40e
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,27 @@
+# Maintainer: Egor Vorontsov <sdoregor@sdore.me>
+# Based on: huawei-wmi-dkms by ylxdzsw
+
+_pkgbase="huawei-wmi"
+pkgname="${_pkgbase}-dkms-kbdlight-git"
+pkgver=3.3.r12.gc142bce
+pkgrel=1
+pkgdesc="Huawei WMI laptop extras driver (feat/kbdlight branch)"
+url="https://github.com/sermart1234/Huawei-WMI"
+arch=('x86_64')
+license=('GPLv2')
+depends=('dkms')
+source=("${_pkgbase}::git+https://github.com/aymanbagabas/Huawei-WMI#branch=feat/kbdlight")
+sha256sums=('SKIP')
+
+pkgver() {
+ cd "${_pkgbase}"
+ # cutting off 'v' prefix that presents in the git tag
+ git describe --long | sed 's/^v//;s/\([^-]*-g\)/r\1/;s/-/./g'
+}
+
+package() {
+ cd "${_pkgbase}/dkms"
+ dir="$(ls | tail -1)"
+ cd "$dir"
+ install -Dm644 'dkms.conf' 'Makefile' '../../huawei-wmi.c' -t "${pkgdir}/usr/src/${dir}"
+}