diff options
| author | Michael Brown | 2022-12-14 01:51:00 +0100 |
|---|---|---|
| committer | Michael Brown | 2022-12-14 01:54:13 +0100 |
| commit | 54c4c1d403c1730d3c8e467910d7044a649bfbee (patch) | |
| tree | e83f0477d7d454aabf4d1dbc84ca9f53b0b094c5 /src | |
| parent | [intel] Add PCI ID for I219-V and -LM 16,17 (diff) | |
| download | ipxe-54c4c1d403c1730d3c8e467910d7044a649bfbee.tar.gz ipxe-54c4c1d403c1730d3c8e467910d7044a649bfbee.tar.xz ipxe-54c4c1d403c1730d3c8e467910d7044a649bfbee.zip | |
[build] Disable array bounds checking for GCC
The array bounds checker on GCC 12 and newer reports a very large
number of false positives that result in build failures. In
particular, accesses through pointers to zero-length arrays (such as
those used by the linker table mechanism in include/ipxe/tables.h) are
reported as errors, contrary to the GCC documentation.
Work around this GCC issue by unconditionally disabling the warning.
Signed-off-by: Michael Brown <mcb30@ipxe.org>
Diffstat (limited to 'src')
| -rw-r--r-- | src/Makefile.housekeeping | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/Makefile.housekeeping b/src/Makefile.housekeeping index 9bf34b2e6..61a9cf07e 100644 --- a/src/Makefile.housekeeping +++ b/src/Makefile.housekeeping @@ -461,8 +461,8 @@ CFLAGS += -g ifeq ($(CCTYPE),gcc) CFLAGS += -ffreestanding CFLAGS += -fcommon -CFLAGS += -Wall -W -Wformat-nonliteral -HOST_CFLAGS += -Wall -W -Wformat-nonliteral +CFLAGS += -Wall -W -Wformat-nonliteral -Wno-array-bounds +HOST_CFLAGS += -Wall -W -Wformat-nonliteral -Wno-array-bounds endif CFLAGS += $(WORKAROUND_CFLAGS) $(EXTRA_CFLAGS) ASFLAGS += $(WORKAROUND_ASFLAGS) $(EXTRA_ASFLAGS) |
