summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorJohn-Gee2023-07-07 06:04:21 -0700
committerJohn-Gee2023-07-07 06:04:21 -0700
commitde7ad94f2a33b83aa3e171417064b1a8f7ce8a60 (patch)
tree01edc39094ac36fad751edcd1d3c5270e2aad748
downloadaur-de7ad94f2a33b83aa3e171417064b1a8f7ce8a60.tar.gz
First commit
-rw-r--r--.SRCINFO15
-rw-r--r--PKGBUILD35
-rw-r--r--hidapi.patch11
-rwxr-xr-xrangoli.sh3
4 files changed, 64 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 000000000000..06529ae5ceaf
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,15 @@
+pkgbase = rangoli
+ pkgdesc = Free, Open Source, Lightweight, Cross-platform Software for Royal Kludge Keyboards
+ pkgver = 2.0
+ pkgrel = 1
+ url = https://github.com/rnayabed/rangoli
+ arch = x86_64
+ license = GPL3
+ makedepends = cmake
+ makedepends = ninja
+ depends = qt6-base
+ depends = gcc-libs
+ source = https://github.com/rnayabed/rangoli/archive/refs/tags/2.0.tar.gz
+ sha256sums = 83b19220d2a3ccf667f6deb8e560f816676fe426f5ecc40507c9e5f62dc9cdeb
+
+pkgname = rangoli
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..c61fe34e6095
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,35 @@
+# Maintainer: gee
+pkgname='rangoli'
+pkgver=2.0
+pkgrel=1
+pkgdesc='Free, Open Source, Lightweight, Cross-platform Software for Royal Kludge Keyboards'
+arch=('x86_64')
+url='https://github.com/rnayabed/rangoli'
+license=('GPL3')
+depends=('qt6-base' 'gcc-libs')
+makedepends=('cmake' 'ninja')
+source=("${url}/archive/refs/tags/${pkgver}.tar.gz"
+ "hidapi.patch"
+ "rangoli.sh")
+sha256sums=('83b19220d2a3ccf667f6deb8e560f816676fe426f5ecc40507c9e5f62dc9cdeb'
+ '1d09c0cb39d84d6be319775791c51e84ad1999469b881627c3615e3544423f09'
+ '8fead456a8b711d372e12bc058e7f6680ebc4851b854f5d908a0a24e7ed1d1c4')
+
+build() {
+ cd ${srcdir}/${pkgname}-${pkgver}
+
+ patch -p1 -i ../hidapi.patch
+ cmake -B build -G Ninja -S . -DCMAKE_BUILD_TYPE=Release
+ cmake --build build --parallel
+}
+
+package() {
+ install -Dm 755 rangoli.sh "${pkgdir}/usr/bin/rangoli"
+
+ cd ${srcdir}/${pkgname}-${pkgver}/build/src
+ install -dm 755 "${pkgdir}/usr/share/${pkgname}"
+ install -Dm 755 rangoli "${pkgdir}/usr/share/${pkgname}/"
+ install -dm 755 "${pkgdir}/usr/share/${pkgname}/keyboards"
+ install -Dm 755 keyboards/*.* "${pkgdir}/usr/share/${pkgname}/keyboards/"
+ install -Dm 755 udev-rule-writer.sh "${pkgdir}/usr/share/${pkgname}/"
+}
diff --git a/hidapi.patch b/hidapi.patch
new file mode 100644
index 000000000000..a3ce1d8367f9
--- /dev/null
+++ b/hidapi.patch
@@ -0,0 +1,11 @@
+--- rangoli-2.0/CMakeLists.txt 2023-03-24 23:40:11.000000000 -0700
++++ rangoli-2.0/CMakeLists.txt 2023-07-07 05:03:20.581971999 -0700
+@@ -58,5 +58,7 @@
+ set(HIDAPI_WITH_LIBUSB FALSE)
+ set(BUILD_SHARED_LIBS FALSE)
+
+-add_subdirectory(hidapi)
++find_package(HIDAPI REQUIRED)
++include_directories(${HIDAPI_INCLUDE_DIRS})
+ add_subdirectory(src)
++target_link_libraries(rangoli ${HIDAPI_LIBRARIES})
diff --git a/rangoli.sh b/rangoli.sh
new file mode 100755
index 000000000000..4fe69929ad6a
--- /dev/null
+++ b/rangoli.sh
@@ -0,0 +1,3 @@
+#!/usr/bin/sh
+
+/usr/share/rangoli/rangoli @?