In this example a would like show you how to build nvidia non-free driver manually with a stock kernel.
We will mix branches too,
we want unstable nvidia drivers on testing environment.Set architecture and kernel versions on environment variables:
Quote:
export KVERS=$(uname -r)
export KSRC=/usr/src/linux-headers-$KVERS
export KPKG_DEST_DIR=/usr/src
Install nvidia unstable drivers on testing:
Quote:
aptitude install nvidia-kernel-source/unstable nvidia-kernel-common/unstable
This will give you source on /usr/src/nvidia-kernel.tar.bz2, unpack it with
Quote:
cd /usr/src
tar -jxf nvidia-kernel.tar.bz2
Install headers files:
Quote:
aptitude install linux-headers-$KVERS
It's important to check that installed kernel image and kernel header packages have the same version:
Quote:
apt-cache policy linux-image-$KVERS linux-headers-$KVERS
Example
Quote:
linux-image-2.6.32-trunk-686:
Instalados: 2.6.32-5 Candidato: 2.6.32-5
Tabla de versión:
*** 2.6.32-5 0
650
http://ftp.es.debian.org testing/main Packages
100 /var/lib/dpkg/status
linux-headers-2.6.32-trunk-686:
Instalados: 2.6.32-5 Candidato: 2.6.32-5
Tabla de versión:
*** 2.6.32-5 0
650
http://ftp.es.debian.org testing/main Packages
100 /var/lib/dpkg/status
Building the kernel module package:
Quote:
cd /usr/src/modules/nvidia-kernel
debian/rules binary_modules
And here you are:
Quote:
ls -l /usr/src/nvidia-kernel-2.6.32-trunk-686_190.53-1_i386.deb
-rw-r--r-- 1 root src 3045154 mar 7 01:53 /usr/src/nvidia-kernel-2.6.32-trunk-686_190.53-1_i386.deb
Interesting Lectures:
- http://wiki.debian.org/NvidiaGraphicsDrivers
- http://tinyplanet.ca/~lsorense/debian/debian-nvidia-dri-howto.html
BerMeJo