summarylogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.SRCINFO4
-rw-r--r--PKGBUILD16
-rw-r--r--dc4dc54c5ebac7e4b455d8df35076fc044a581a7.patch29
3 files changed, 41 insertions, 8 deletions
diff --git a/.SRCINFO b/.SRCINFO
index f1158f8f7561..e9b9aed7f9fd 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,7 +1,7 @@
pkgbase = ckb-next
pkgdesc = Corsair Keyboard and Mouse Input Driver, release version
pkgver = 0.4.4
- pkgrel = 1
+ pkgrel = 2
url = https://github.com/ckb-next/ckb-next
install = ckb-next.install
arch = i686
@@ -23,7 +23,9 @@ pkgbase = ckb-next
conflicts = ckb-git-latest
conflicts = ckb-next-git
source = https://github.com/ckb-next/ckb-next/archive/v0.4.4.tar.gz
+ source = dc4dc54c5ebac7e4b455d8df35076fc044a581a7.patch
sha256sums = 6946bd035cdbbbd2f139e543d2ca84ba422176c62c3a3665b544118dc6d618d0
+ sha256sums = ca662407404a0b22c3f2706f729717ab73575101247689ce80b7528fea0de87e
pkgname = ckb-next
diff --git a/PKGBUILD b/PKGBUILD
index 30c46ca2ba7e..4e1b2823b9fe 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -2,7 +2,7 @@
# Contributor: Light2Yellow <oleksii.vilchanskyi@gmail.com>
pkgname=ckb-next
pkgver=0.4.4
-pkgrel=1
+pkgrel=2
pkgdesc="Corsair Keyboard and Mouse Input Driver, release version"
arch=('i686' 'x86_64')
url="https://github.com/ckb-next/ckb-next"
@@ -13,8 +13,10 @@ optdepends=('libpulse')
conflicts=('ckb-git' 'ckb-git-latest' 'ckb-next-git')
provides=('ckb-next')
install=ckb-next.install
-source=("https://github.com/ckb-next/$pkgname/archive/v$pkgver.tar.gz")
-sha256sums=('6946bd035cdbbbd2f139e543d2ca84ba422176c62c3a3665b544118dc6d618d0')
+source=("https://github.com/ckb-next/$pkgname/archive/v$pkgver.tar.gz"
+ 'dc4dc54c5ebac7e4b455d8df35076fc044a581a7.patch')
+sha256sums=('6946bd035cdbbbd2f139e543d2ca84ba422176c62c3a3665b544118dc6d618d0'
+ 'ca662407404a0b22c3f2706f729717ab73575101247689ce80b7528fea0de87e')
build() {
cd "$srcdir/${pkgname}-${pkgver}"
@@ -30,10 +32,10 @@ build() {
cmake --build build --target all
}
-#prepare() {
-# cd "$srcdir/${pkgname}-${pkgver}"
-# patch -p1 -i "$srcdir/a9f41cd8b8f5b04c0c66c6d94f96a9725943831e.patch"
-#}
+prepare() {
+ cd "$srcdir/${pkgname}-${pkgver}"
+ patch -p1 -i "$srcdir/dc4dc54c5ebac7e4b455d8df35076fc044a581a7.patch"
+}
package() {
cd "$srcdir/${pkgname}-${pkgver}"
diff --git a/dc4dc54c5ebac7e4b455d8df35076fc044a581a7.patch b/dc4dc54c5ebac7e4b455d8df35076fc044a581a7.patch
new file mode 100644
index 000000000000..211d5e4ea01e
--- /dev/null
+++ b/dc4dc54c5ebac7e4b455d8df35076fc044a581a7.patch
@@ -0,0 +1,29 @@
+From dc4dc54c5ebac7e4b455d8df35076fc044a581a7 Mon Sep 17 00:00:00 2001
+From: Tasos Sahanidis <tasos@tasossah.com>
+Date: Mon, 20 Sep 2021 14:48:18 +0300
+Subject: [PATCH] Don't enable unneeded axes in mouse device
+
+Specifically, we used to enable HI_RES wheel events without ever
+sending any. This breaks scrolling in latest libinput as it expects
+us to actually send HI_RES events.
+---
+ src/daemon/input_linux.c | 6 ++++--
+ 1 file changed, 4 insertions(+), 2 deletions(-)
+
+diff --git a/src/daemon/input_linux.c b/src/daemon/input_linux.c
+index 68cc0ebb..a9ac8c8e 100644
+--- a/src/daemon/input_linux.c
++++ b/src/daemon/input_linux.c
+@@ -25,8 +25,10 @@ int uinputopen(struct uinput_user_dev* indev, int mouse){
+ ioctl(fd, UI_SET_KEYBIT, i);
+ // Enable mouse axes
+ ioctl(fd, UI_SET_EVBIT, EV_REL);
+- for(int i = 0; i < REL_CNT; i++)
+- ioctl(fd, UI_SET_RELBIT, i);
++ ioctl(fd, UI_SET_RELBIT, REL_X);
++ ioctl(fd, UI_SET_RELBIT, REL_Y);
++ ioctl(fd, UI_SET_RELBIT, REL_WHEEL);
++ ioctl(fd, UI_SET_RELBIT, REL_HWHEEL);
+ } else {
+ // Enable common keyboard keys
+ for(int i = KEY_ESC; i <= KEY_MEDIA; i++)