mirror of
https://github.com/ipxe/ipxe
synced 2025-12-28 02:28:57 +03:00
Currently the only supported platform for x86_64 is EFI. Building an EFI64 gPXE requires a version of gcc that supports __attribute__((ms_abi)). This currently means a development build of gcc; the feature should be present when gcc 4.4 is released. In the meantime; you can grab a suitable gcc tree from git://git.etherboot.org/scm/people/mcb30/gcc/.git
42 lines
944 B
Makefile
42 lines
944 B
Makefile
# Code size reduction.
|
|
#
|
|
CFLAGS += -fstrength-reduce -fomit-frame-pointer
|
|
|
|
# Code size reduction. gcc3 needs a different syntax to gcc2 if you
|
|
# want to avoid spurious warnings.
|
|
#
|
|
CFLAGS += -falign-jumps=1 -falign-loops=1 -falign-functions=1
|
|
|
|
# Use %rip-relative addressing wherever possible.
|
|
#
|
|
CFLAGS += -fpie
|
|
|
|
# Force 64-bit code
|
|
#
|
|
CFLAGS += -m64
|
|
ASFLAGS += --64
|
|
LDFLAGS += -m elf_x86_64
|
|
|
|
# EFI requires -fshort-wchar, and nothing else currently uses wchar_t
|
|
#
|
|
CFLAGS += -fshort-wchar
|
|
|
|
# We need to undefine the default macro "i386" when compiling .S
|
|
# files, otherwise ".arch i386" translates to ".arch 1"...
|
|
#
|
|
CFLAGS += -Ui386
|
|
|
|
# x86_64-specific directories containing source files
|
|
#
|
|
SRCDIRS += arch/x86_64/prefix
|
|
|
|
# Include common x86 Makefile
|
|
#
|
|
MAKEDEPS += arch/x86/Makefile
|
|
include arch/x86/Makefile
|
|
|
|
# Include platform-specific Makefile
|
|
#
|
|
MAKEDEPS += arch/x86_64/Makefile.$(PLATFORM)
|
|
include arch/x86_64/Makefile.$(PLATFORM)
|