Closed Nowa-Ammerlaan closed 4 months ago
Ah so the entry is not created only for the UKI? I misunderstood what you wrote in the PR and thought no entry was added.
If this is the case the fix is trivial, uefi-mkconfig just doesn't have "linux-" in the list of prefixes the image can have.
UKI: uki entry is added
UKI + efisub: no entries are added
If this is the case the fix is trivial, uefi-mkconfig just doesn't have "linux-" in the list of prefixes the image can have.
It does because "linux" is my /etc/kernel/entry-token
I think it would be very useful to make some testing mode and add there some test cases.
can you cat /etc/kernel/entry-token so I can see how it looks? To see if the script is parsing values correctly
Indeed automated testing is the next thing on my list
cat /etc/kernel/entry-token
linux
That is not the problem I think, I think it's something with looping, sorting, or finding.
If this is not causing your problem, I have found another bug.
* Running uefi-mkconfig...
* Using kernel commands from "/etc/default/uefi-mkconfig"
* Warning! Loaded empty uefi-mkconfig configuration file!
/etc/os-release: line 1: linux: command not found
vmlinuz vmlinux- kernel- bzImage zImage -
* Warning! Kernel command "root=" is missing from loaded configuration!
* Ignoring "/boot/test/vmlinuz-6.8.9-gentoo-old.efi" on "nvme0n1p1"
* Ignoring "/boot/test/vmlinuz-6.8.9-gentoo.efi" on "nvme0n1p1"
* Ignoring "/boot/EFI/Gentoo/vmlinuz-6.9.2-gentoo-dist.efi" on "nvme0n1p1"
* Ignoring "/boot/EFI/Gentoo/vmlinuz-6.9.3-gentoo-dist.efi" on "nvme0n1p1"
* Ignoring "/boot/EFI/Gentoo/vmlinuz-6.9.4-gentoo-dist.efi" on "nvme0n1p1"
* Ignoring "/boot/EFI/Gentoo/vmlinuz-6.9.5-gentoo-dist.efi" on "nvme0n1p1"
* Ignoring "/boot/EFI/Gentoo/vmlinuz-6.9.6-gentoo-dist.efi" on "nvme0n1p1"
* Creating UEFI entry "0200" for "/boot/EFI/Gentoo/vmlinuz-6.9.8-gentoo-dist.efi" found on "nvme0n1p1"
* Creating UEFI entry "01FF" for "/boot/EFI/Gentoo/vmlinuz-6.9.9-gentoo-dist.efi" found on "nvme0n1p1"
* Done
Sorry just noticed you've mentioned /etc/kernel/entry-token
not /etc/os-release
.
...however it reaaally is not good that uefi-mkconfig executes anything in /etc/os-release as command with root.
Ok found the problem. It was indeed related to the find
command
Could you please test code from #18 when you'll have time ?
Merged PR with fix
This configuration results in no added entries:
Note it does work if we have only the UKI, it is adding the efistub variant that causes things to break.