Compile Nvidia driver 331.17 against kernel 3.11

Author: | Posted in howto No comments

Nvidia released a new beta driver 331.17 as a minor update to the previous beta driver 331.13. I wanted to do the update on my Fedora 19 machine running kernel 3.11 (I was still using the older 325.15 driver provided by the RPMFusion repository) and — not exactly unexpected — the driver didn’t compile, it was the dkms kernel module build that failed. Luckily I found a fix that should work on all Linux systems running kernel 3.11.

Here’s what you need to do to compile the Nvidia driver 331.17 against kernel 3.11:

 

  • download the Nvidia installer

mkdir -p ~/Downloads/NVIDIA
cd ~/Downloads/NVIDIA
wget http://us.download.nvidia.com/XFree86/Linux-x86_64/331.17/NVIDIA-Linux-x86_64-331.17.run

 

  • download the 3.11 patch

wget http://pastebin.com/download.php?i=gxKDqu9N -O nvidia-3.11.patch

 

  • extract the installation files

sh NVIDIA-Linux-x86_64-331.17.run --extract-only

 

  • apply the patch

cp nvidia-3.11.patch NVIDIA-Linux-x86_64-331.17
cd NVIDIA-Linux-x86_64-331.17
patch -p1 < nvidia-3.11.patch

 

  • run the Nvidia installer

sudo ./nvidia-installer

The patched installer should run without hiccups on all Linux flavors and the kernel module should build successfully and register with dkms.

 

UPDATE:

Nvidia has released official patches to add compatibility for kernel 3.11 and newer so use those patches instead. Read more on my other post. Thanks!

via devtalk.nvidia.com

Add Your Comment