Rebuilding kernel-source for NVIDIA drivers help!

Andrew Farris fedora at andrewfarris.com
Sat May 1 23:27:26 UTC 2004


Here is a quick response that may get you going.

On Sun, 2004-05-02 at 00:20 +0200, fedora wrote:
> I'm trying to get NVIDIA drivers to work with FC2T3's kernel-2.6.5-1.327 
> -- no luck. Maybe you guys can tell me what am I doing wrong here, it 
> will benefit a lot of people I presume.
> 
> Here is what I did
> 
> I downloaded kernel-2.6.5-1.327.src.rpm and 
> NVIDIA-Linux-x86-1.0-5341-pkg1.run
> 
> 1. rpm -i kernel-2.6.5-1.327.src.rpm
> 2. commented out "Patch200: linux-2.6.5-nostack.patch" and "%patch200 
> -p1" from spec file (in /usr/src/redhat/SPECS)

Fine so far -- but you need to also manually edit the config files to
remove the 4K stacks default value of y, you should set them to:
# CONFIG_4KSTACKS is not set

If you do not use the minion.de patch, you MUST set register parameters
off as well:
# CONFIG_REGPARM is not set

> 3. rebuilt kernel with: rpmbuild -bb 
> /usr/src/redhat/SPECS/kernel-2.6.spec (It made the package: 
> kernel-2.6.5-1.327.root.i386.rpm) <-- why the suffix?

Suffix created to identify that this kernel was a custom built kernel,
you can change the behavior to be whatever you want in the spec... but
you should leave something on the end to know it is not the default
kernel (it makes no difference to its capabilities, etc...)

%define release %(R="$Revision: 1.327 $"; RR="${R##: }"; echo
${RR%%?})%{rhbsys}

On the end you see, rhbsys, which in the previous statement is set to
your username by the 'whoami' command.

> 4. installed new kernel-source: rpm -ivh /usr/src/redhat/RPMS/i386/
> -it placed linux-2.6.5-1.327.root into /usr/src/
> 5. did sh NVIDIA-Linux-x86-1.0-5341-pkg1.run --add-this-kernel (built 
> custom package)
> 6. tried running custom package: sh 
> NVIDIA-Linux-x86-1.0-5341-pkg1.custom.run, got error saying cannot find 
> kernel-sources

You must run that after you reboot to the target kernel, or specify that
you are not running the target.
--kernel-name=2.6.5-1.327.root

> 7. specified kernel sources with sh 
> NVIDIA-Linux-x86-1.0-5341-pkg1.custom.run 
> --kernel-source-path=/usr/src/linux-2.6.5-1.327.root
> 8. received error saying NVIDIA kernel was built with different 
> kernel-source

You may still need to specify the kernel-source-path, but the above is
the real issue.
-- 
Andrew Farris, CPE senior (California Polytechnic State University, SLO)
fedora at andrewfarris.com :: lmorgul on irc.freenode.net
"The only thing necessary for the triumph of evil is for good men
to do nothing." (Edmond Burke)





More information about the fedora-test-list mailing list