summaryrefslogtreecommitdiffstats
path: root/src/Makefile.housekeeping
diff options
context:
space:
mode:
authorMichael Brown2009-01-07 03:05:51 +0100
committerMichael Brown2009-01-07 23:59:05 +0100
commit314779eb369db746be5373b398111d5b746d67de (patch)
tree0856694401b250357ad6ece6e2845c4611b58d01 /src/Makefile.housekeeping
parent[build] Avoid strict-aliasing warnings when building with gcc 4.4 (diff)
downloadipxe-314779eb369db746be5373b398111d5b746d67de.tar.gz
ipxe-314779eb369db746be5373b398111d5b746d67de.tar.xz
ipxe-314779eb369db746be5373b398111d5b746d67de.zip
[efi] Use elf2efi utility in place of efilink
elf2efi converts a suitable ELF executable (containing relocation information, and with appropriate virtual addresses) into an EFI executable. It is less tightly coupled with the gPXE build process and, in particular, does not require the use of a hand-crafted PE image header in efiprefix.S. elf2efi correctly handles .bss sections, which significantly reduces the size of the gPXE EFI executable.
Diffstat (limited to 'src/Makefile.housekeeping')
-rw-r--r--src/Makefile.housekeeping13
1 files changed, 9 insertions, 4 deletions
diff --git a/src/Makefile.housekeeping b/src/Makefile.housekeeping
index 39771e36..2a1a1a24 100644
--- a/src/Makefile.housekeeping
+++ b/src/Makefile.housekeeping
@@ -703,12 +703,17 @@ CLEANUP += $(ZBIN)
###############################################################################
#
-# The EFI custom linker
+# The EFI image converter
#
-$(EFILINK) : util/efilink.c $(MAKEDEPS)
+$(ELF2EFI32) : util/elf2efi.c $(MAKEDEPS)
$(QM)$(ECHO) " [HOSTCC] $@"
- $(Q)$(HOST_CC) -O2 -o $@ $< -lbfd -liberty
-CLEANUP += $(EFILINK)
+ $(Q)$(HOST_CC) -DMDE_CPU_IA32 -O2 -o $@ $< -lbfd -liberty
+CLEANUP += $(ELF2EFI32)
+
+$(ELF2EFI64) : util/elf2efi.c $(MAKEDEPS)
+ $(QM)$(ECHO) " [HOSTCC] $@"
+ $(Q)$(HOST_CC) -DMDE_CPU_X64 -O2 -o $@ $< -lbfd -liberty
+CLEANUP += $(ELF2EFI64)
###############################################################################
#