# Contributor: Stefan Reimer # Maintainer: Stefan Reimer pkgname=aws-neuron-driver pkgver=0.1.0 pkgrel=0 pkgdesc="Linux Kernel module for AWS Neuron INF instances" url="https://github.com/aws/aws-neuron-driver" arch="x86_64" license="GPL-2.0" makedepends="bash linux-headers linux-virt-dev" options="!check" # No Tags nor releases ;-( # cad466aa978944bc8ef51f2228c2ca80618d3103" source="$pkgname-$pkgver.zip::https://github.com/aws/$pkgname/archive/refs/heads/master.zip missing-io.patch " builddir="$srcdir/aws-neuron-driver-master" build() { # Hack running the build inside a container other uname -r returns host kernel KERNEL_VERSION=$(basename $(ls -d /lib/modules/*-virt)) make KERNEL_SRC_DIR=/lib/modules/$KERNEL_VERSION/build } package() { KERNEL_VERSION=$(basename $(ls -d /lib/modules/*-virt)) mkdir -p "$pkgdir"/lib/modules/$KERNEL_VERSION "$pkgdir"/lib/udev/rules.d cp neuron.ko "$pkgdir"/lib/modules/$KERNEL_VERSION echo 'KERNEL=="neuron*", MODE="0666"' > "$pkgdir"/lib/udev/rules.d/90-neuron-udev.rules } sha512sums=" 521c65cbdf4f5c05d20a2dbee2c3c597b075189cb729fa3213691e10486706f10776316da7c16dc8d869489c979878d4040f73eddfed1c29f9fec83ef19faf27 aws-neuron-driver-0.1.0.zip 6658805f1cc830020544b3fe42c4e0a28791f84d0c6d9594961c11761b9228b9591841f740ac78bf9411655c3138af3286da5fa9eb9cb3f03a1cd6bf0d58a8f3 missing-io.patch "