Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

Required fields*

9
  • 2
    Is gcc-11 set as the default on your system (i.e. does gcc --version show 11.x or 12.x)? My guess is that some step in the build is using gcc-11 (which lacks the -ftrivial-auto-var-init option) rather than gcc-12 Commented Jan 12, 2024 at 23:17
  • ... perhaps related to this bug More dkms fixes for exact cc compiler in which some dkms modules apparently don't honor a CC environment variable Commented Jan 13, 2024 at 0:01
  • Looks like the output of gcc --version is gcc (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0. So my default is 11. How do I change that? Is it possible to temporarily make that change only during the dmks build, in case switching from 11 to 12 has other ramifications? Commented Jan 13, 2024 at 16:09
  • I added the makefile and the DKMS config file since it appears these will probably be relevant. Commented Jan 13, 2024 at 16:41
  • I have pretty much zero experience with dkms, but as a first step you could try adding CC=gcc-12 or CC=/usr/bin/gcc-12 to the conf file. If that fails, then you could (at least temporarily) symlink /usr/bin/gcc to gcc-12 either via the update-alternatives mechanism or (as a last resort) manually. Commented Jan 13, 2024 at 17:09