archrelease: copy trunk to community-x86_64
[ArchLinux/community.git] / vhba-module / trunk / PKGBUILD
blobbbfa13a6336a80ede63e6e79fbc72b549a49aee1
1 # Maintainer: Jan Alexander Steffens (heftig) <heftig@archlinux.org>
2 # Contributor: Ray Rashif <schiv@archlinux.org>
3 # Contributor: Mateusz Herych <heniekk@gmail.com>
4 # Contributor: Charles Lindsay <charles@chaoslizard.org>
6 pkgbase=vhba-module
7 pkgname=(vhba-module vhba-module-dkms)
8 pkgver=20211218
9 pkgrel=121
10 pkgdesc="Kernel module that emulates SCSI devices"
11 url="https://cdemu.sourceforge.io/"
12 arch=(x86_64)
13 license=(GPL)
14 makedepends=('linux-headers')
15 source=("https://downloads.sourceforge.net/cdemu/$pkgbase-$pkgver.tar.xz"
16         dkms.conf)
17 sha256sums=('72c5a8c1c452805e4cef8cafefcecc2d25ce197ae4c67383082802e5adcd77b6'
18             '8cab0ebb4fee72069d63616b0983f105b98d1261e72e9bef5509a6e60bc382a7')
20 prepare() {
21   cd $pkgbase-$pkgver
24 build() {
25   cd $pkgbase-$pkgver
26   make KERNELRELEASE="$(</usr/src/linux/version)"
29 package_vhba-module() {
30   depends=(linux)
31   provides=(VHBA-MODULE)
33   local extradir="/usr/lib/modules/$(</usr/src/linux/version)/extramodules"
34   install -Dt "$pkgdir$extradir" -m644 $pkgbase-$pkgver/*.ko
36   find "$pkgdir" -name '*.ko' -exec strip --strip-debug {} +
37   find "$pkgdir" -name '*.ko' -exec xz {} +
40 package_vhba-module-dkms() {
41   depends=(dkms)
42   provides=(VHBA-MODULE)
43   conflicts=(vhba-module)
45   install -Dt "$pkgdir/usr/src/$pkgbase-$pkgver" -m644 \
46     dkms.conf $pkgbase-$pkgver/{Makefile,vhba.c}
49 # vim:set ts=2 sw=2 et: