updated on Sun Jan 22 12:09:12 UTC 2012
[aur-mirror.git] / nvidia-pae / PKGBUILD
blob5a8b28e18ac211fefb9e306f1dd546502e041256
1 # $Id: PKGBUILD 134241 2011-08-02 17:12:50Z ibiru $
2 # Maintainer : Thomas Baechler <thomas@archlinux.org>
4 pkgname=nvidia-pae
5 pkgver=290.10
6 _extramodules=extramodules-3.1-pae
7 _kernver="$(cat /lib/modules/${_extramodules}/version)"
8 pkgrel=1
9 pkgdesc="NVIDIA drivers for linux."
10 arch=('i686' 'x86_64')
11 url="http://www.nvidia.com/"
12 depends=('linux-pae>=3.1' 'linux-pae<3.2' "nvidia-utils=${pkgver}")
13 makedepends=('linux-pae-headers>=3.1' 'linux-pae-headers<3.2')
14 conflicts=('nvidia-96xx' 'nvidia-173xx')
15 license=('custom')
16 install=nvidia.install
17 options=(!strip)
19 if [ "$CARCH" = "i686" ]; then
20     _arch='x86'
21     _pkg="NVIDIA-Linux-${_arch}-${pkgver}"
22     source=("ftp://download.nvidia.com/XFree86/Linux-${_arch}/${pkgver}/${_pkg}.run")
23     md5sums=('50319a4b3818c12c9c7243525e0e6316')
24 elif [ "$CARCH" = "x86_64" ]; then
25     _arch='x86_64'
26     _pkg="NVIDIA-Linux-${_arch}-${pkgver}-no-compat32"
27     source=("ftp://download.nvidia.com/XFree86/Linux-${_arch}/${pkgver}/${_pkg}.run")
28     md5sums=('cebfba9a7e91716a06c66bb5b38d9661')
31 build() {
32     cd "${srcdir}"
33     sh "${_pkg}.run" --extract-only
34     cd "${_pkg}/kernel"
35     make SYSSRC=/lib/modules/"${_kernver}/build" module
38 package() {
39     install -D -m644 "${srcdir}/${_pkg}/kernel/nvidia.ko" \
40         "${pkgdir}/lib/modules/${_extramodules}/nvidia.ko"
41     install -d -m755 "${pkgdir}/etc/modprobe.d"
42     echo "blacklist nouveau" >> "${pkgdir}/etc/modprobe.d/nouveau_blacklist-pae.conf"
43     sed -i -e "s/EXTRAMODULES='.*'/EXTRAMODULES='${_extramodules}'/" "${startdir}/nvidia.install"
44     gzip "${pkgdir}/lib/modules/${_extramodules}/nvidia.ko"