View Single Post
Old 02-11-03, 12:21 PM   #6
bwkaz
Registered User
 
Join Date: Sep 2002
Posts: 2,262
Default Re: gcc-3.2.2 & nv drivers problem solved

Quote:
Originally posted by maynon
It was as you said. i deleted asm, asm-generic, and linux in /usr/include and symlinked to kernel in /usr/src/linux
Uh... that's not what a lot of things are expecting, though. Most stuff that needs the "kernel headers" in /usr/include is not really looking for the headers of the currently-running kernel. Most packages that look in /usr/include/asm require the headers that glibc was compiled against. See the part of the LFS book that comes right before the part where the headers get copied over.

What you need to do is make actual directories, /usr/include/asm and /usr/include/linux, that have the kernel headers that were there when glibc was compiled. Then, make sure that NOTHING in /usr/include points at your kernel source. Then, make sure that /lib/modules/<kernel version>/build DOES point at your current kernel source. Once that's set up, recompile the nVidia drivers (with a make clean, then a make), and they should find the right directory.

What you did will work, but only for the moment. It will fail as soon as you change kernels, then compile something else (i.e. NOT the nVidia drivers) that needs to know what the kernel looked like when glibc was compiled. And to make things even worse, that other thing probably will compile correctly, but will segfault (or worse) when it's run.
__________________
Registered Linux User #219692
bwkaz is offline   Reply With Quote