diff options
author | Petr Štetiar <ynezz@true.cz> | 2019-01-23 22:25:38 +0100 |
---|---|---|
committer | Mathias Kresin <dev@kresin.me> | 2019-01-26 21:46:32 +0100 |
commit | 66a4978b4355e3e8f860a87ca14c0f293931d038 (patch) | |
tree | f563fbd9840f61b7887e2fc65d4bcefefbc54a30 /include/u-boot.mk | |
parent | 52d7a1d3b2c940e9db26aaffc674afdd2f884463 (diff) | |
download | upstream-66a4978b4355e3e8f860a87ca14c0f293931d038.tar.gz upstream-66a4978b4355e3e8f860a87ca14c0f293931d038.tar.bz2 upstream-66a4978b4355e3e8f860a87ca14c0f293931d038.zip |
u-boot.mk: Fix building of recent U-Boot sources
This patch fixes following error with U-Boot 2019.01 on imx6:
In file included from tools/lib/crc16.c:1:0:
./tools/../lib/crc16.c: In function 'crc16_ccitt':
./tools/../lib/crc16.c:70:2: error: 'for' loop initial declarations are only allowed in C99 mode
for (int i = 0; i < len; i++)
^
./tools/../lib/crc16.c:70:2: note: use option -std=c99 or -std=gnu99 to compile your code
Code was introduced in the upstream v2019.01-rc1-154-g51c2345:
commit 51c2345bd24837f9f67f16268da6dc71573f1325
Author: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
Date: Sun Nov 25 19:22:19 2018 +0100
Roll CRC16-CCITT into the hash infrastructure
Upstream has added -std=gnu11 host flag in v2018.07-rc2-1-gfa89399:
commit fa893990e9b53425af5f5059e04a2bffde91ccf9
Author: Tom Rini <trini@konsulko.com>
Date: Tue Jun 19 23:53:54 2018 -0400
Makefile: Ensure we build with -std=gnu11
Build tested on imx6: apalis, mx6sabresd, nitrogen6dl, nitrogen6dl2g,
nitrogen6q, nitrogen6q2g, nitrogen6s, nitrogen6s1g,
wandboard
Run tested: apalis (pending PR #1595)
Signed-off-by: Petr Štetiar <ynezz@true.cz>
Diffstat (limited to 'include/u-boot.mk')
-rw-r--r-- | include/u-boot.mk | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/include/u-boot.mk b/include/u-boot.mk index babb76497a..26e1685b8e 100644 --- a/include/u-boot.mk +++ b/include/u-boot.mk @@ -42,7 +42,7 @@ TARGET_DEP = TARGET_$(BUILD_TARGET)$(if $(BUILD_SUBTARGET),_$(BUILD_SUBTARGET)) UBOOT_MAKE_FLAGS = \ HOSTCC="$(HOSTCC)" \ - HOSTCFLAGS="$(HOST_CFLAGS) $(HOST_CPPFLAGS)" \ + HOSTCFLAGS="$(HOST_CFLAGS) $(HOST_CPPFLAGS) -std=gnu11" \ HOSTLDFLAGS="$(HOST_LDFLAGS)" define Build/U-Boot/Target |