diff options
author | Thomas Heijligen <thomas.heijligen@secunet.de> | 2021-10-12 16:47:43 +0200 |
---|---|---|
committer | Nico Huber <nico.h@gmx.de> | 2021-10-15 14:35:38 +0000 |
commit | b5836478888acf38780ae1ec0315282778916d2a (patch) | |
tree | 72cbf84d1371dc51b0cf0d971be93e4e13d9e264 /Makefile | |
parent | ba1c5eb12591c306604929b94b9046a37170c5ff (diff) | |
download | flashrom-b5836478888acf38780ae1ec0315282778916d2a.tar.gz flashrom-b5836478888acf38780ae1ec0315282778916d2a.tar.bz2 flashrom-b5836478888acf38780ae1ec0315282778916d2a.zip |
buildsystem: Determine the endianness only in the buildsystem
Let the buildsystem (make / meson) handle the endianness determination
and set the __FLASHROM_LITTLE_ENDIAN__ or __FLASHROM_BIG_ENDIAN__ macro
as cflag.
Change-Id: I37093528ae55e712cc30a0267a8ceac332750e7d
Signed-off-by: Thomas Heijligen <thomas.heijligen@secunet.de>
Reviewed-on: https://review.coreboot.org/c/flashrom/+/58273
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Nico Huber <nico.h@gmx.de>
Reviewed-by: Felix Singer <felixsinger@posteo.net>
Diffstat (limited to 'Makefile')
-rw-r--r-- | Makefile | 7 |
1 files changed, 7 insertions, 0 deletions
@@ -248,6 +248,13 @@ ifneq ($(ARCH)-little, $(filter $(ARCH),x86 mips)-$(ENDIAN)) $(call mark_unsupported,CONFIG_INTERNAL) endif +ifeq ($(ENDIAN), little) +FEATURE_CFLAGS += -D'__FLASHROM_LITTLE_ENDIAN__=1' +endif +ifeq ($(ENDIAN), big) +FEATURE_CFLAGS += -D'__FLASHROM_BIG_ENDIAN__=1' +endif + # PCI port I/O support is unimplemented on PPC/MIPS/SPARC and unavailable on ARM. # Right now this means the drivers below only work on x86. ifneq ($(ARCH), x86) |