Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230

 

 

 

[SOLVED] nvidia driver "kernel does not support PIC mode"

Graphical Environments, Managers, Multimedia & Desktop questions.
Post Reply
Message
Author
warthog
Posts: 8
Joined: 2016-04-27 02:35

[SOLVED] nvidia driver "kernel does not support PIC mode"

#1 Post by warthog »

After updating my Debian (testing) system via apt-get a few days ago, I was unable to compile/install Nvidia's proprietary driver from nvidia.com. The relevant error message seemed to be "kernel does not support PIC mode".

After much fumbling about, I finally got it to compile via the following:

Code: Select all

$ export KCPPFLAGS="-fno-pie -Wno-pointer-sign -fno-stack-protector -mfentry"
$ export CPPFLAGS="$KCPPFLAGS"                                                     
$ sh NVIDIA-Linux-x86_64-367.57.run
NOTE 1: I'm not sure if the export CPPFLAGS="$KCPPFLAGS" line is necessary or not.
NOTE 2: Without the "-mfentry" option, the module seems to compile, but trying to actually use it results in a fatal error regarding "mcount".

Hopefully this post will save someone the time/frustration that it took me to get it sorted.

User avatar
fabrixx
Posts: 170
Joined: 2009-12-14 23:00

Re: [SOLVED] nvidia driver "kernel does not support PIC mode

#2 Post by fabrixx »

Work for me on Debian testing
Thank you.

AndyMender
Posts: 5
Joined: 2016-11-16 14:29

Re: [SOLVED] nvidia driver "kernel does not support PIC mode

#3 Post by AndyMender »

Is there any reason why you didn't install the nVidia drivers metapackage from the Testing/Stretch repositories (nvidia-driver)?
If you check https://packages.debian.org/stretch/nvidia-driver, you'll see it's the exact same version as you tried installing manually.

Post Reply