Bug#940690: nvidia-kernel-dkms: build fails with kernel built with different gcc version
Celejar
celejar at gmail.com
Wed Oct 2 21:35:46 BST 2019
On Thu, 19 Sep 2019 12:07:54 +0200 Andreas Beckmann <anbe at debian.org>
wrote:
> Control: tag -1 wontfix
>
> On 19/09/2019 05.52, Celejar wrote:
> > Build fails on a Sid system, with gcc symlinked to gcc-9, running a
> > kernel built on a Buster system with gcc-8. Based on make.log and the
>
> The kernel headers store information which compiler was used to build
> the kernel, and this compiler is used for the out-of-tree modules, too.
> In your case the kernel was built with (unversioned) 'gcc' and that will
> be used for the out-of-tree modules, too, even if the symlink now points
> elsewhere. (Official Debian kernels are built with versioned compiler
> binaries (e.g. gcc-8, gcc-9) only, and the headers have dependencies on
> the corresponding packages, to avoid mismatches if the default compiler
> changes. (The kernel compiler is usually switched independently from the
> default system compiler.)
>
> Therefore: Always build custom kernels with versioned compilers.
Ah, thanks. Just one question: how do I do that, and where is this
documented, either in the Debian kernel handbook or in general kernel
build guides? I can't find an option within the kernel config system for
versioned compilers. Do I need to use environment variables?
Celejar
More information about the pkg-nvidia-devel
mailing list