recently I tried to switch from grub to systemd-boot, since grub took too long time for me until the boot started. Installing systemd-boot was fairly easy and everything work perfectly. Then I found systemd-boot-manager to update the systemd-boot files as well as the kernels after pacman installs. The problem: My EFI partition is /boot/efi, the kernels are installed unter /boot.
If I use systemd-boot in this condition, no boot entry would be generated since the tool searches in the EFI partition (/boot/efi) for kernels, does not find one and creates no entry therefore. In my case it indeed removes the exising entry which would have made my system unbootable hadn’t I still installed grub as a fallback.
My proposal would be to use kernel-install from systemd which works perfectly. If additional configuration from sdboot-manage.conf shall be applied, the generated loader/entries/* files could be adapted by e.g. sed with the options.
I responded more fully on gitlab but to me kernel-install is an alternative to what systemd-boot-manager does. It provides similar automation in a very different way.
mkinitcpio is what is putting your kernels in /boot. You need to either use a hook/script to move them to the right place or override the mkinitcpio presets to put them in the right place to begin with.
While using /efi or /boot is the recommended convention, it isn’t a requirement. You can run systemd-boot from /boot/efi if you want to. It is, however, a very odd thing to do.
It makes sense if those distros use grub or some other bootloader which keeps the kernels separate from the esp. It makes less sense if you are using systemd-boot where the kernels need to be in the efi partition.
But, either way, it should work if that is your preference.
That being said, I like kernel-install too, especially for multi-booting. Getting it working smoothly and in an automatic was on Arch-based distros has been some fun. It definitely isn’t ideal out-of-the-box because of the Arch reliance on the kernels/initrams being in a consistent location.
I created and edited new config file Manjaro.conf in /boot/efi/loader/entries.
Then I copied all imgs and vmlinuz from /boot into /boot/efi/EFI/ManjaroBoot. It worked fine.
But my change is gone after pacman update.
I do not know how to change pacman’s hook.
I think bootctl can not access /boot as ext4 in the same partition of / or I am wrong.
But you can copy img files into /boot/efi/. But the files are not updated in /boot/efi or there is no automation of update. Or you create new bash-script and write own command to update them.