Bug#940690: nvidia-kernel-dkms: build fails with kernel built with different gcc version

Andreas Beckmann anbe at debian.org
Thu Sep 19 11:07:54 BST 2019


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.


Andreas



More information about the pkg-nvidia-devel mailing list