Bug#908568: nvidia-driver: build error
Vincent Lefevre
vincent at vinc17.net
Fri Sep 14 13:15:44 BST 2018
On 2018-09-14 13:15:07 +0200, Andreas Beckmann wrote:
> On 2018-09-12 10:18, Vincent Lefevre wrote:
> > On 2018-09-11 19:15:25 -0700, Russ Allbery wrote:
> >> If you set IGNORE_CC_MISMATCH=1 in the environment before installing the
> >> package, does everything build and work correctly?
> >
> > Yes, everything is fine.
>
> It is probably very fragile. When upgrading from stretch/gcc-6 to
> sid/gcc-6 the whole toolchain gets updated, too (binutils ...).
>
> I have (for an older stretch kernel and cannot reboot to the current
> one, but that should not matter) for 396.45 two modules - one built in a
> mixed sid environment, unloadable, and a working one built in clean
> stretch.
[...]
And indeed, these problems do not seem to come from a different
GCC version, but from different binutils. Note that between what
was used to build the kernel and what was used to build the modules,
it is possible to have matching GCC versions but different binutils
versions, and conversely. Thus for the binutils issue, testing the
GCC version is the wrong test. It may happen that differing GCC
versions means different binutils versions with an up-to-date sid,
but this is not guaranteed.
Note that according to the Debian changelog:
linux (4.14~rc5-1~exp1) experimental; urgency=medium
[...]
* Compile with gcc-7 on all architectures
[...]
-- Ben Hutchings <ben at decadent.org.uk> Tue, 17 Oct 2017 23:37:52 +0100
and to unstable on 30 Nov 2017. At that time, it was GCC 7.2.
GCC 7.3 appeared on 23 Jan 2018. So, after this upgrade, the build
of the NVIDIA kernels module would be refused due to mismatch GCC
versions, until the release of the next kernel on 14 Feb 2018 (and
previous kernels would no longer be usable as a fallback). There
were no issues because at that time, __GNUC_MINOR__ was ignored,
as you should know:
nvidia-graphics-drivers (352.79-8) unstable; urgency=medium
[ Andreas Beckmann ]
* cc_version_check-gcc5.patch: New, ignore __GNUC_MINOR__ mismatch from
GCC 5 onwards.
[...]
-- Andreas Beckmann <anbe at debian.org> Tue, 07 Jun 2016 01:49:35 +0200
which is what you removed in the latest version:
nvidia-graphics-drivers (390.87-1) unstable; urgency=medium
[...]
[ Andreas Beckmann ]
* Remove cc_version_check-gcc5.patch and re-enable strict version checks,
using mismatching compiler versions may create unloadable modules due to
mismatching symvers.
[...]
-- Andreas Beckmann <anbe at debian.org> Mon, 10 Sep 2018 15:24:08 +0200
This doesn't even solve the real issue, since if the modules are
not built, they cannot be loaded anyway. Thus this is not really
useful. Users should just be aware that when there is a major
change in binutils, things may break. :(
--
Vincent Lefèvre <vincent at vinc17.net> - Web: <https://www.vinc17.net/>
100% accessible validated (X)HTML - Blog: <https://www.vinc17.net/blog/>
Work: CR INRIA - computer arithmetic / AriC project (LIP, ENS-Lyon)
More information about the pkg-nvidia-devel
mailing list