[Concept,14/17] ulib: riscv: Enable demo EFI binary for efi-riscv_app64

Message ID 20260216013511.4079770-15-sjg@u-boot.org
State New
Headers
Series ulib: Add multi-arch demo and EFI app support |

Commit Message

Simon Glass Feb. 16, 2026, 1:35 a.m. UTC
  From: Simon Glass <simon.glass@canonical.com>

Enable CONFIG_ULIB and CONFIG_EXAMPLES in efi-riscv_app64_defconfig so
that the demo-app.efi binary is built.

Skip the prelink-riscv step on EFI builds since the shared-object
linking style has no dynamic section for prelink to process.

Co-developed-by: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: Simon Glass <simon.glass@canonical.com>
---

 arch/riscv/Makefile               | 2 +-
 configs/efi-riscv_app64_defconfig | 2 ++
 2 files changed, 3 insertions(+), 1 deletion(-)
  

Patch

diff --git a/arch/riscv/Makefile b/arch/riscv/Makefile
index afae33812e4..acfdb9e167f 100644
--- a/arch/riscv/Makefile
+++ b/arch/riscv/Makefile
@@ -66,6 +66,6 @@  libs-y += arch/riscv/lib/
 ifdef CONFIG_EXAMPLES
 EXAMPLE_ARCH := riscv
 EXAMPLE_APPEND_DTB := y
-EXAMPLE_POST_LINK = @tools/prelink-riscv $@
+EXAMPLE_POST_LINK = $(if $(CONFIG_EFI_APP),,@tools/prelink-riscv $@)
 include scripts/Makefile.ulib-example
 endif
diff --git a/configs/efi-riscv_app64_defconfig b/configs/efi-riscv_app64_defconfig
index f18bfb653ad..d48ecf19585 100644
--- a/configs/efi-riscv_app64_defconfig
+++ b/configs/efi-riscv_app64_defconfig
@@ -52,4 +52,6 @@  CONFIG_CONSOLE_TRUETYPE=y
 CONFIG_SYS_WHITE_ON_BLACK=y
 CONFIG_CONSOLE_SCROLL_LINES=5
 CONFIG_FAT_WRITE=y
+CONFIG_ULIB=y
+CONFIG_EXAMPLES=y
 CONFIG_CMD_DHRYSTONE=y