core/vhba-module/PKGBUILD
2018-01-29 23:32:12 +01:00

39 lines
1003 B
Bash

# Source global configuration
source ../linux.conf
pkgname=vhba-module
pkgver=20170610
pkgrel=5
pkgdesc="Kernel module that emulates SCSI devices"
arch=('x86_64')
url="http://cdemu.sourceforge.net/"
license=('GPL')
depends=("linux=${_kernelver}")
makedepends=("linux-headers=${_kernelver}")
install=vhba-module.install
source=("http://downloads.sourceforge.net/cdemu/$pkgname-$pkgver.tar.bz2"
60-vhba.rules)
md5sums=('f9478a5f5528fc672c204b6b4bd02213'
'4dc37dc348b5a2c83585829bde790dcc')
prepare() {
cd $pkgname-$pkgver
}
build() {
cd $pkgname-$pkgver
make KERNELRELEASE="$(cat /usr/lib/modules/$_extramodules/version)"
}
package() {
depends=("linux=${_kernelver}")
install=vhba-module.install
cd $pkgname-$pkgver
install -Dt "$pkgdir/usr/lib/modules/$_extramodules" -m644 vhba.ko
install -Dt "$pkgdir/usr/lib/udev/rules.d" -m644 ../60-vhba.rules
sed -i -e "s/EXTRAMODULES='.*'/EXTRAMODULES='${_extramodules}'/" \
"${startdir}/vhba-module.install"
}