[linux-libre-headers] breaks DKMS, needs rebuild
emerge install acpi_call-dkms, with the latest linux-libre-headers installed, produces the following error:
(2/2) Install DKMS modules ==> dkms install --no-depmod acpi_call/1.2.2 -k 5.15.12-gnu-1 Error! Bad return status for module build on kernel: 5.15.12-gnu-1 (x86_64) Consult /var/lib/dkms/acpi_call/1.2.2/build/make.log for more information.
the contents of the log file are:
DKMS make.log for acpi_call-1.2.2 for kernel 5.15.12-gnu-1 (x86_64) Sat Feb 19 12:23:28 PM CET 2022 make -C /lib/modules/5.15.12-gnu-1/build M=/var/lib/dkms/acpi_call/1.2.2/build modules make: Entering directory '/usr/lib/modules/5.15.12-gnu-1/build' warning: the compiler differs from the one used to build the kernel The kernel was built by: gcc (GCC) 11.1.0 You are using: gcc (GCC) 11.2.0 CC [M] /var/lib/dkms/acpi_call/1.2.2/build/acpi_call.o cc1: error: incompatible gcc/plugin versions cc1: error: failed to initialize plugin ./scripts/gcc-plugins/structleak_plugin.so make: *** [scripts/Makefile.build:277: /var/lib/dkms/acpi_call/1.2.2/build/acpi_call.o] Error 1 make: *** [Makefile:1868: /var/lib/dkms/acpi_call/1.2.2/build] Error 2 make: Leaving directory '/usr/lib/modules/5.15.12-gnu-1/build' make: *** [Makefile:8: default] Error 2
the file scripts/gcc-plugins/structleak_plugin.so is owned by linux-libre-headers, and I think it needs to be rebuilt.
$ pacman -Qo /usr/src/linux-libre/scripts/gcc-plugins/structleak_plugin.so /usr/lib/modules/5.15.12-gnu-1/build/scripts/gcc-plugins/structleak_plugin.so is owned by linux-libre-headers 5.15.12-1
Updated by oaken-source 6 months ago
this seems to be a similar issue that came up in Fedora:
In my environment, when building the dkms module, an error occurred due to the difference in GCC version.
I'm attaching a text file because I got an error saying that the long output is an attachment.