A few comments.
I think this approach is increasingly fragile, because a change for one
architecture will affect others.
> -.elif ${MACHINE} == "armv7" || ${MACHINE} == "arm64"
> +.elif ${MACHINE} == "armv7" || ${MACHINE} == "arm64" || ${MACHINE} ==
> "riscv64"
> SRCS += armv7_installboot.c
How about copying armv7_installboot.c to a new file, and then it even becomes
possible to perform this operation in the C code also:
> echo bootriscv64.efi > /mnt/mnt/efi/boot/startup.nsh
As a bonus, it will umount the disk... which the current shell function forgets
to do.
I think a new file is better, if this addition is made, rather than hiding it
behind a #ifdef inside a .if file