[PATCH 2/3] EFI: Make EFI loader depend sandbox HOST_ARCH

Jiaxun Yang jiaxun.yang at flygoat.com
Sat May 18 00:09:28 CEST 2024


Since EFI loader on sandbox requires some architecture
code, make it depend on HOST_ARCH to ensure it's only
compiled on desired host.

Signed-off-by: Jiaxun Yang <jiaxun.yang at flygoat.com>
---
 lib/efi_loader/Kconfig | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)

diff --git a/lib/efi_loader/Kconfig b/lib/efi_loader/Kconfig
index 430bb7f0f7dc..54d180fe31c1 100644
--- a/lib/efi_loader/Kconfig
+++ b/lib/efi_loader/Kconfig
@@ -1,11 +1,14 @@
 config EFI_LOADER
 	bool "Support running UEFI applications"
-	depends on OF_LIBFDT && ( \
+	depends on OF_LIBFDT && (( \
 		ARM && (SYS_CPU = arm1136 || \
 			SYS_CPU = arm1176 || \
 			SYS_CPU = armv7   || \
 			SYS_CPU = armv8)  || \
-		X86 || RISCV || SANDBOX)
+		X86 || RISCV) || \
+		(SANDBOX && (HOST_ARCH_X86 || HOST_ARCH_X86_64 || \
+			     HOST_ARCH_ARM || HOST_ARCH_AARCH64 || \
+			     HOST_ARCH_RISCV32 || HOST_ARCH_RISCV64)))
 	# We need EFI_STUB_64BIT to be set on x86_64 with EFI_STUB
 	depends on !EFI_STUB || !X86_64 || EFI_STUB_64BIT
 	# We need EFI_STUB_32BIT to be set on x86_32 with EFI_STUB

-- 
2.34.1



More information about the U-Boot mailing list