Attention is currently required from: Michał Żygowski.
Hello Michał Żygowski,
I'd like you to do a code review. Please visit
https://review.coreboot.org/c/coreboot/+/83385?usp=email
to review the following change.
Change subject: payloads/external/iPXE/Makefile: Build iPXE for EFI target if requested ......................................................................
payloads/external/iPXE/Makefile: Build iPXE for EFI target if requested
Change-Id: I7f247a59a65aeb18a67475d4d543f519af88aeb9 Signed-off-by: Michał Żygowski michal.zygowski@3mdeb.com --- M payloads/external/iPXE/Makefile 1 file changed, 11 insertions(+), 3 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/85/83385/1
diff --git a/payloads/external/iPXE/Makefile b/payloads/external/iPXE/Makefile index 7ec8126..a58d5f7 100644 --- a/payloads/external/iPXE/Makefile +++ b/payloads/external/iPXE/Makefile @@ -11,6 +11,14 @@ project_dir=ipxe project_git_repo=https://git.ipxe.org/ipxe.git
+ifeq ($(CONFIG_IPXE_BUILD_EFI),y) +IPXE_BUILD_TARGET := bin-x86_64-efi-sb/ipxe.efi +# Workaround problems with unrecognized ipxe/util/elf2efi relocations +PXE_MAKE_OPTS += EXTRA_CFLAGS="$(CFLAGS_x86_64) -fno-pic" +else +IPXE_BUILD_TARGET := bin/$(PXE_ROM_PCI_ID).rom +endif + all: build
$(project_dir): @@ -59,12 +67,12 @@ build: config $(CONFIG_SCRIPT) ifeq ($(CONFIG_HAS_SCRIPT),y) echo " MAKE $(project_name) $(TAG-y) EMBED=$(CONFIG_SCRIPT)" - $(MAKE) -C $(project_dir)/src bin/$(PXE_ROM_PCI_ID).rom EMBED=$(CONFIG_SCRIPT) + $(MAKE) -C $(project_dir)/src $(IPXE_BUILD_TARGET) EMBED=$(CONFIG_SCRIPT) $(PXE_MAKE_OPTS) else echo " MAKE $(project_name) $(TAG-y)" - $(MAKE) -C $(project_dir)/src bin/$(PXE_ROM_PCI_ID).rom + $(MAKE) -C $(project_dir)/src $(IPXE_BUILD_TARGET) $(PXE_MAKE_OPTS) endif - cp $(project_dir)/src/bin/$(PXE_ROM_PCI_ID).rom $(project_dir)/ipxe.rom + cp $(project_dir)/src/$(IPXE_BUILD_TARGET) $(project_dir)/ipxe.rom ifeq ($(CONSOLE_SERIAL),yy) cp "$(project_dir)/src/config/console.h.cb" "$(project_dir)/src/config/console.h" cp "$(project_dir)/src/config/serial.h.cb" "$(project_dir)/src/config/serial.h"