View previous topic :: View next topic |
Author |
Message |
hujuice Guru
Joined: 16 Oct 2007 Posts: 336 Location: Rome, Italy
|
Posted: Sat Mar 23, 2024 4:38 pm Post subject: kernel compilation failure with Error2 and nothing else |
|
|
I have an error with no explanation while building my gentoo-sources:
make: | ...
CC [M] drivers/gpu/drm/i915/i915_hwmon.o
LD [M] drivers/gpu/drm/i915/i915.o
AR drivers/gpu/built-in.a
make[2]: *** [scripts/Makefile.build:480: drivers] Error 2
make[1]: *** [/usr/src/linux-6.6.21-gentoo/Makefile:1913: .] Error 2
make: *** [Makefile:234: __sub-make] Error 2 |
What to do?
I had the same error before, but after this:
make: | AR drivers/scsi/built-in.a |
So I gave mrproper and clean, and now I have the same error after another driver.
Kernel: sys-kernel/gentoo-sources-6.6.21
Kernel .config: https://pastebin.com/1vLqUL4q
As a further note, I had to switch to new profiles during the installation (the stage file was old profile, I've found the new profile after sync).
I followed the instructions without problems. _________________ Who hasn't a spine, should have a method.
Chi non ha carattere, deve pur avere un metodo. |
|
Back to top |
|
|
hujuice Guru
Joined: 16 Oct 2007 Posts: 336 Location: Rome, Italy
|
Posted: Sun Mar 24, 2024 11:16 am Post subject: |
|
|
After many failures, without changing the configuration, I realised that my CONFIG_EXTRA_FIRMWARE string was wrong (just a copy and paste mistake). After pasting the right string, the compilation was successful.
I don't arrive to understand why this mistake leads to that error with no messages. _________________ Who hasn't a spine, should have a method.
Chi non ha carattere, deve pur avere un metodo. |
|
Back to top |
|
|
Hu Moderator
Joined: 06 Mar 2007 Posts: 21639
|
Posted: Sun Mar 24, 2024 3:17 pm Post subject: |
|
|
I seem to recall other users who had that mistake, who did get a message. Per Guidelines item #4, please show us the exact command you used to build the kernel, and the full output it produced, starting from the command and ending when your shell prompt appears again. |
|
Back to top |
|
|
hujuice Guru
Joined: 16 Oct 2007 Posts: 336 Location: Rome, Italy
|
Posted: Sun Mar 24, 2024 9:37 pm Post subject: |
|
|
Hu wrote: | I seem to recall other users who had that mistake, who did get a message. Per Guidelines item #4, please show us the exact command you used to build the kernel, and the full output it produced, starting from the command and ending when your shell prompt appears again. |
I normally don't redirect the output to be ready to share it. And I don't look at the output lines scrolling fast.
But we are lucky: I saved the wrong config and I can reproduce it.
You will see that the error is declared in the output, but the build process didn't stop for long.
The exact command was (this time with redirect):
Code: | nice make -j11 &>/tmp/make.out |
Not working config file: https://filebin.net/nx24u9iv0zsojhxu/not_working-kernel-config
make.out: https://filebin.net/nx24u9iv0zsojhxu/make.out
If you grep for "No rule to make target" you find the mistake. It's a thousand of lines before the end.
Once the mistake is corrected (and with this change only) make is successful.
Code: | CONFIG_EXTRA_FIRMWARE="intel-ucode/06-9e-0a" |
_________________ Who hasn't a spine, should have a method.
Chi non ha carattere, deve pur avere un metodo. |
|
Back to top |
|
|
Hu Moderator
Joined: 06 Mar 2007 Posts: 21639
|
Posted: Sun Mar 24, 2024 10:27 pm Post subject: |
|
|
Highly parallel make may allow a large volume of additional output after an error before the job finally stops. For this reason, we sometimes suggest that users reproduce the error with -j1, so that there is no parallelism and the job stops immediately on error, making the message easy to find. Saving the full output and reviewing it in a pager also works. |
|
Back to top |
|
|
hujuice Guru
Joined: 16 Oct 2007 Posts: 336 Location: Rome, Italy
|
Posted: Mon Mar 25, 2024 10:27 am Post subject: |
|
|
Hu wrote: | Highly parallel make may allow a large volume of additional output after an error before the job finally stops. For this reason, we sometimes suggest that users reproduce the error with -j1, so that there is no parallelism and the job stops immediately on error, making the message easy to find. Saving the full output and reviewing it in a pager also works. |
There's not so much to debug, in terms of errors.
The strange behaviour for me is the so long progression after the error. It's clearly related to parallelism, but when I read my output with less I see it is at 67% of the progress (3k lines or more). It's a lot!
What I did, first, was to scroll up, and there was nothing. _________________ Who hasn't a spine, should have a method.
Chi non ha carattere, deve pur avere un metodo. |
|
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
|
|