summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authoreNV252021-12-11 13:53:07 +0530
committereNV252021-12-11 13:53:07 +0530
commitc319e43060400f77d3ea38e92208dfc1664b7955 (patch)
treee6c361eedf5ba07ca526ee203fbb0a9e6e59b3fc
downloadaur-c319e43060400f77d3ea38e92208dfc1664b7955.tar.gz
Initial upload: anbox-modules-dkms-git r38.8148a16-1
-rw-r--r--.SRCINFO15
-rw-r--r--PKGBUILD38
2 files changed, 53 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 000000000000..7063fea0ab0b
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,15 @@
+pkgbase = anbox-modules-dkms-git
+ pkgdesc = Kernel modules for Anbox or Waydroid (DKMS)
+ pkgver = r38.8148a16
+ pkgrel = 1
+ url = https://github.com/choff/anbox-modules
+ arch = x86_64
+ license = GPL
+ makedepends = git
+ depends = dkms
+ provides = anbox-modules-dkms
+ conflicts = anbox-modules-dkms
+ source = anbox-modules::git+https://github.com/choff/anbox-modules#branch=master
+ sha256sums = SKIP
+
+pkgname = anbox-modules-dkms-git
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..c31f580402ac
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,38 @@
+# Maintainer: eNV25 <env252525@gmail.com>
+
+pkgname=anbox-modules-dkms-git
+_pkgname=anbox-modules
+pkgver=r38.8148a16
+pkgrel=1
+pkgdesc="Kernel modules for Anbox or Waydroid (DKMS)"
+arch=(x86_64)
+url="https://github.com/choff/anbox-modules"
+license=('GPL')
+depends=('dkms')
+makedepends=('git')
+provides=("${pkgname%-git}")
+conflicts=("${pkgname%-git}")
+source=("$_pkgname::git+$url#branch=master")
+sha256sums=('SKIP')
+
+pkgver() {
+ cd "$srcdir/$_pkgname/"
+ printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
+}
+
+prepare() {
+ cd "$srcdir/$_pkgname/"
+ sed -i "s/^PACKAGE_VERSION=\".*\"$/PACKAGE_VERSION=\"$pkgver\"/g" **/dkms.conf
+ # this should work with all Arch Linux kernels (including linux-lts)
+ # https://github.com/choff/anbox-modules/pull/1#issuecomment-974865917
+ sed -i 's/^#if (LINUX_VERSION_CODE >= KERNEL_VERSION(5,15,2))$/#if 1/g' binder/binder.c
+}
+
+package() {
+ cd "$srcdir/$_pkgname/"
+ install -Dm644 anbox.conf -t "$pkgdir/usr/lib/modules-load.d/"
+ install -Dm644 99-anbox.rules -t "$pkgdir/usr/lib/udev/rules.d/"
+ install -dm644 "$pkgdir/usr/src/"
+ cp -rT ashmem "$pkgdir/usr/src/anbox-ashmem-$pkgver"
+ cp -rT binder "$pkgdir/usr/src/anbox-binder-$pkgver"
+}