diff options
author | Michael Brown <mcb30@ipxe.org> | 2023-01-23 01:26:46 +0000 |
---|---|---|
committer | Michael Brown <mcb30@ipxe.org> | 2023-01-23 01:26:46 +0000 |
commit | 9de6c45dd3019c7074dc34954e008633409b38df (patch) | |
tree | 24339e065faab86e8d1bda60d9cff01f181345ee /src | |
parent | 8f59911b201a89b99a2b0c8930b505cc3820b423 (diff) | |
download | ipxe-9de6c45dd3019c7074dc34954e008633409b38df.zip ipxe-9de6c45dd3019c7074dc34954e008633409b38df.tar.gz ipxe-9de6c45dd3019c7074dc34954e008633409b38df.tar.bz2 |
[arm] Use -fno-short-enums for all 32-bit ARM builds
The EFI ABI requires the use of -fno-short-enums, and the EDK2 headers
will perform a compile-time check that enums are 32 bits.
The EDK2 headers may be included even in builds for non-EFI platforms,
and so the -fno-short-enums flag must be used in all 32-bit ARM
builds. Fortunately, nothing else currently cares about enum sizes.
Signed-off-by: Michael Brown <mcb30@ipxe.org>
Diffstat (limited to 'src')
-rw-r--r-- | src/arch/arm32/Makefile | 5 | ||||
-rw-r--r-- | src/arch/arm32/Makefile.efi | 4 |
2 files changed, 5 insertions, 4 deletions
diff --git a/src/arch/arm32/Makefile b/src/arch/arm32/Makefile index 3a7c092..d32ab6a 100644 --- a/src/arch/arm32/Makefile +++ b/src/arch/arm32/Makefile @@ -13,6 +13,11 @@ ASFLAGS += -mthumb -mcpu=cortex-a15 # CFLAGS += -fshort-wchar +# EFI requires that enums are always 32 bits, and nothing else +# currently cares +# +CFLAGS += -fno-short-enums + # Include common ARM Makefile MAKEDEPS += arch/arm/Makefile include arch/arm/Makefile diff --git a/src/arch/arm32/Makefile.efi b/src/arch/arm32/Makefile.efi index e139a05..a06354f 100644 --- a/src/arch/arm32/Makefile.efi +++ b/src/arch/arm32/Makefile.efi @@ -1,9 +1,5 @@ # -*- makefile -*- : Force emacs to use Makefile mode -# UEFI requires that enums are always 32 bits -# -CFLAGS += -fno-short-enums - # Specify EFI image builder # ELF2EFI = $(ELF2EFI32) |