updated on Thu Jan 19 12:17:07 UTC 2012
[aur-mirror.git] / ndiswrapper-lts / PKGBUILD
blob6f2b33c84ddae84c5268088ab7f73899b01ff687
1 # Maintainer: Tobias Powalowski <tpowa@archlinux.org>
3 pkgname=ndiswrapper-lts
4 _kernver=2.6.32-lts
5 pkgver=1.56
6 pkgrel=5
7 pkgdesc="Module for NDIS (Windows Network Drivers) drivers supplied by vendors. For LTS 2.6 kernel."
8 license=('GPL')
9 arch=(i686 x86_64)
10 url="http://ndiswrapper.sourceforge.net"
11 install="ndiswrapper.install"
12 depends=("ndiswrapper-utils=$pkgver" 'kernel26-lts>=2.6.32' 'kernel26-lts<2.6.33')
13 makedepends=('kernel26-lts-headers>=2.6.32' 'kernel26-lts-headers<2.6.33')
14 source=(http://downloads.sourceforge.net/sourceforge/ndiswrapper/ndiswrapper-$pkgver.tar.gz)
15 options=(!strip)
16 md5sums=('1431f7ed5f8e92e752d330bbb3aed333')
18 build()
20   cd $srcdir/ndiswrapper-$pkgver/driver
21   make KVERS=$_kernver
24 package() {
25   cd $srcdir/ndiswrapper-$pkgver/driver
26   make DESTDIR=$pkgdir KVERS=$_kernver install
27   rm $pkgdir/lib/modules/$_kernver/modules.* #wtf?
29   sed -i -e "s/KERNEL_VERSION='.*'/KERNEL_VERSION='${_kernver}'/" $startdir/*.install
30   # move it to correct kernel directory
31   mkdir -p $pkgdir/lib/modules/$_kernver/kernel/drivers/net/wireless/ndiswrapper
32   mv $pkgdir/lib/modules/$_kernver/misc/* $pkgdir/lib/modules/$_kernver/kernel/drivers/net/wireless/ndiswrapper/
33   rm -r $pkgdir/lib/modules/$_kernver/misc/
34   # gzip -9 modules
35   find "$pkgdir" -name '*.ko' -exec gzip -9 {} \;