updated on Thu Jan 12 04:00:44 UTC 2012
[aur-mirror.git] / rr264x-lts / PKGBUILD
blob31f926141d552e931f8d57ec97d9b8e658f7ba39
1 # Maintainer: Alessandro Sagratini <ale_sagra at hotmail dot com>
2 pkgname=rr264x-lts
3 pkgver=1.3
4 pkgrel=1
5 pkgdesc="Kernel modules for Highpoint RocketRAID 2640X1 SAS Card. Patched for use with kernel26 >=2.6.37 and kernel >= 3 (a.k.a. linux)"
6 arch=('i686' 'x86_64')
7 url="http://www.highpoint-tech.com/USA_new/series_rr2600.htm"
8 license=('custom')
9 groups=()
11 depends=('kernel26-lts')
12 makedepends=('kernel26-lts-headers')
14 provides=()
15 conflicts=()
16 replaces=()
17 backup=()
18 options=()
19 install=$pkgname.install
20 source=(http://www.highpoint-tech.cn/BIOS_Driver/rr26xx/2640X1-2640X4-2642/Linux/rr264x-linux-src-v$pkgver-legacy_single-101203-0910.tar.gz scsi_lck.patch kernel3.patch)
21 noextract=()
22 md5sums=('14856755232b273113f9e4f882a1a500' 'b96f51f73edf509564f02f96c3ee62be' 'd68544c85cf03f443e66a8878a031d03')
24 _extramodules=extramodules-2.6.32-lts
25 _kernver=`cat /lib/modules/${_extramodules}/version`
27 build() {
28     mkdir -p $startdir/pkg/lib/modules/${_extramodules}/
30     cd $startdir/src/rr2640-linux-src-v$pkgver-legacy_single/
31     # Apply the scsi lock patch to make the driver work with kernel26 > 2.6.37
32     patch -p0 -i $startdir/scsi_lck.patch
33     patch -p0 -i $startdir/kernel3.patch
34     cd product/rr2640/linuxls/
35     make KERNELDIR=/usr/src/linux-$_kernver || return 1
37     # Install the kernel module
38     install -m 644 -D rr26xx.ko "${pkgdir}/lib/modules/${_extramodules}/"
39     gzip "${pkgdir}/lib/modules/${_extramodules}/rr26xx.ko"
41     mkdir -p $pkgdir/usr/share/licenses/$pkgname
42     cp $srcdir/rr2640-linux-src-v$pkgver-legacy_single/README $pkgdir/usr/share/licenses/$pkgname/