1 # Contributor: JokerBoy <jokerboy at punctweb dot ro>
2 # Contributor: fsckd <fsckdaemon at gmail dot com>
3 # Contributor: Thomas Baechler <thomas@archlinux.org>
7 _extramodules=extramodules-3.2-bfs
8 _kernver="$(cat /lib/modules/${_extramodules}/version)"
10 pkgdesc="NVIDIA drivers for linux-bfs."
11 arch=('i686' 'x86_64')
12 url="http://www.nvidia.com/"
13 depends=('linux-bfs>=3.2' 'linux-bfs<3.3' "nvidia-utils=${pkgver}")
14 makedepends=('linux-bfs-headers>=3.2' 'linux-bfs-headers<3.3')
15 conflicts=('nvidia-bfs-96xx' 'nvidia-bfs-173xx')
16 provides=("nvidia=${pkgver}")
18 install=nvidia.install
20 [ "$CARCH" = "i686" ] && _arch='x86' && _pkg="NVIDIA-Linux-${_arch}-${pkgver}" && md5sums=('50319a4b3818c12c9c7243525e0e6316')
21 [ "$CARCH" = "x86_64" ] && _arch='x86_64' && _pkg="NVIDIA-Linux-${_arch}-${pkgver}-no-compat32" && md5sums=('cebfba9a7e91716a06c66bb5b38d9661')
22 source=("ftp://download.nvidia.com/XFree86/Linux-${_arch}/${pkgver}/${_pkg}.run")
26 sh "${_pkg}.run" --extract-only
28 make SYSSRC="/lib/modules/${_kernver}/build" module
32 install -D -m644 "${srcdir}/${_pkg}/kernel/nvidia.ko" \
33 "${pkgdir}/lib/modules/${_extramodules}/nvidia.ko"
34 install -d -m755 "${pkgdir}/etc/modprobe.d"
35 echo "blacklist nouveau" >> "${pkgdir}/etc/modprobe.d/nouveau_bfs_blacklist.conf"
36 sed -i -e "s/EXTRAMODULES='.*'/EXTRAMODULES='${_extramodules}'/" "${startdir}/nvidia.install"
37 gzip "${pkgdir}/lib/modules/${_extramodules}/nvidia.ko"