View previous topic :: View next topic |
Author |
Message |
saikou n00b
Joined: 15 Nov 2023 Posts: 2
|
Posted: Wed Nov 15, 2023 3:38 am Post subject: [SOLVED] Kernel compilation failed |
|
|
I was switching my kernel from binary kernel to source kernel.
After I run make, it compiles normally as usual, but after a while, the compilation stopped with this error:
Code: | make[1]: *** [/usr/src/linux-6.6.1-gentoo/Makefile:1913: .] Error 2
make: *** [Makefile:234: __sub-make] Error 2 |
I tried running make clean and make distclean, but the compilation stopped at the same point. |
|
Back to top |
|
|
saikou n00b
Joined: 15 Nov 2023 Posts: 2
|
Posted: Wed Nov 15, 2023 5:36 am Post subject: |
|
|
solved by changing CONFIG_MODULE_SIG_KEY="/tmp/signing_key.pem" to CONFIG_MODULE_SIG_KEY="certs/signing_key.pem" |
|
Back to top |
|
|
VoVaN l33t
Joined: 02 Jul 2003 Posts: 701 Location: The Netherlands
|
Posted: Tue Nov 21, 2023 10:14 am Post subject: Re: [SOLVED] Kernel compilation failed |
|
|
saikou wrote: | I was switching my kernel from binary kernel to source kernel.
After I run make, it compiles normally as usual, but after a while, the compilation stopped with this error:
Code: | make[1]: *** [/usr/src/linux-6.6.1-gentoo/Makefile:1913: .] Error 2
make: *** [Makefile:234: __sub-make] Error 2 |
I tried running make clean and make distclean, but the compilation stopped at the same point. |
I have exactly the same issue. While kernel 6.6.1 was successfully compiled 10 days ago now it's not possible with the same custom .config. However I even don't have CONFIG_MODULE_SIG enabled. |
|
Back to top |
|
|
Hu Administrator
Joined: 06 Mar 2007 Posts: 23091
|
Posted: Tue Nov 21, 2023 1:13 pm Post subject: Re: [SOLVED] Kernel compilation failed |
|
|
saikou wrote: | After I run make, it compiles normally as usual, but after a while, the compilation stopped with this error: Code: | make[1]: *** [/usr/src/linux-6.6.1-gentoo/Makefile:1913: .] Error 2
make: *** [Makefile:234: __sub-make] Error 2 |
| As I read the relevant Makefile, this reports that an error occurred running some other Make target, which you did not quote. Therefore, from this output alone, there is nothing we can say. This is why we always direct users to post the full output of the failure. I see that you did subsequently find a solution, but I want to note that the original data was insufficient for us to diagnose the problem. VoVaN wrote: | I have exactly the same issue. While kernel 6.6.1 was successfully compiled 10 days ago now it's not possible with the same custom .config. However I even don't have CONFIG_MODULE_SIG enabled. | If you have the same issue, then the fix should be the same. However, as you are not using module signing and OP was using module signing, it seems likely that you have a different issue. Please follow the standard debugging procedure here: give us the full kernel output and post the .config to a pastebin. |
|
Back to top |
|
|
VoVaN l33t
Joined: 02 Jul 2003 Posts: 701 Location: The Netherlands
|
Posted: Tue Nov 21, 2023 1:25 pm Post subject: Re: [SOLVED] Kernel compilation failed |
|
|
Hu wrote: | However, as you are not using module signing and OP was using module signing, it seems likely that you have a different issue. Please follow the standard debugging procedure here: give us the full kernel output and post the .config to a pastebin. |
I've been able to investigate what the problem is and @Nu you're right the problem is different. I'll explain here anyway maybe it will be useful for somebody else as well. First of all the emerge log file is quite misleading as the error is exactly the same in my case. However when I tried manually compile the kernel the actual error was:
Code: | make[6]: *** No rule to make target '/lib/firmware/amdgpu/polaris12_sdma1.bin', needed by 'drivers/base/firmware_loader/builtin/amdgpu/polaris12_sdma1.bin.gen.o'. Stop. |
The problem is in the updated linux-firmware package where I have an option savedconfig enabled and install only what I need. In the latest sys-kernel/linux-firmware-20231111 some files have been replaced with symlinks, like polaris12_sdma1.bin is now symlink to polaris10_sdma1.bin, so in my case a few symlinks were broken because polaris10_sdma1.bin isn't installed in my case. After extending the saved config for linux-firmware end reinstalling, kernel compilation was successful. |
|
Back to top |
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|