summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Makefile.inc2
-rw-r--r--payloads/coreinfo/Makefile2
-rw-r--r--payloads/libpayload/Makefile.inc2
-rw-r--r--payloads/linuxcheck/Makefile2
-rw-r--r--payloads/nvramcui/Makefile2
5 files changed, 5 insertions, 5 deletions
diff --git a/Makefile.inc b/Makefile.inc
index c275d1efa5..ffb22d393a 100644
--- a/Makefile.inc
+++ b/Makefile.inc
@@ -402,7 +402,7 @@ endif
CFLAGS_common += -pipe -g -nostdinc -std=gnu11
CFLAGS_common += -nostdlib -Wall -Wundef -Wstrict-prototypes -Wmissing-prototypes
CFLAGS_common += -Wwrite-strings -Wredundant-decls -Wno-trigraphs -Wimplicit-fallthrough
-CFLAGS_common += -Wstrict-aliasing -Wshadow -Wdate-time -Wtype-limits
+CFLAGS_common += -Wstrict-aliasing -Wshadow -Wdate-time -Wtype-limits -Wvla
CFLAGS_common += -fno-common -ffreestanding -fno-builtin -fomit-frame-pointer
CFLAGS_common += -ffunction-sections -fdata-sections -fno-pie
ifeq ($(CONFIG_COMPILER_GCC),y)
diff --git a/payloads/coreinfo/Makefile b/payloads/coreinfo/Makefile
index 1e9eb80d20..34c45d9855 100644
--- a/payloads/coreinfo/Makefile
+++ b/payloads/coreinfo/Makefile
@@ -83,7 +83,7 @@ OBJCOPY := $(OBJCOPY_$(ARCH-y))
LPCC := CC="$(CC)" $(LIBPAYLOAD_OBJ)/bin/lpgcc
LPAS := AS="$(AS)" $(LIBPAYLOAD_OBJ)/bin/lpas
-CFLAGS += -Wall -Wextra -Wmissing-prototypes -Werror
+CFLAGS += -Wall -Wextra -Wmissing-prototypes -Wvla -Werror
CFLAGS += -Os -fno-builtin $(CFLAGS_$(ARCH-y)) $(INCLUDES)
ifneq ($(strip $(HAVE_DOTCONFIG)),)
diff --git a/payloads/libpayload/Makefile.inc b/payloads/libpayload/Makefile.inc
index f0aaa2727f..4863d3f1da 100644
--- a/payloads/libpayload/Makefile.inc
+++ b/payloads/libpayload/Makefile.inc
@@ -62,7 +62,7 @@ INCLUDES := -Iinclude -Iinclude/$(ARCHDIR-y) -I$(obj) -include include/kconfig.h
CFLAGS += $(EXTRA_CFLAGS) $(INCLUDES) -Os -pipe -nostdinc -ggdb3
CFLAGS += -nostdlib -fno-builtin -ffreestanding -fomit-frame-pointer
CFLAGS += -ffunction-sections -fdata-sections
-CFLAGS += -Wall -Wundef -Wstrict-prototypes -Wmissing-prototypes
+CFLAGS += -Wall -Wundef -Wstrict-prototypes -Wmissing-prototypes -Wvla
CFLAGS += -Wwrite-strings -Wredundant-decls -Wno-trigraphs -Wimplicit-fallthrough
CFLAGS += -Wstrict-aliasing -Wshadow -Werror
diff --git a/payloads/linuxcheck/Makefile b/payloads/linuxcheck/Makefile
index b967369e1a..838c90df0c 100644
--- a/payloads/linuxcheck/Makefile
+++ b/payloads/linuxcheck/Makefile
@@ -3,7 +3,7 @@ XCOMPILE=$(LIBPAYLOAD_DIR)/libpayload.xcompile
# build libpayload and put .config file in $(CURDIR) instead of ../libpayload
# to avoid pollute the libpayload source directory and possible conflicts
LPOPTS=obj="$(CURDIR)/build" DESTDIR="$(CURDIR)" DOTCONFIG="$(CURDIR)/.config"
-CFLAGS += -Wall -Werror -Os -ffreestanding -nostdinc -nostdlib
+CFLAGS += -Wall -Wvla -Werror -Os -ffreestanding -nostdinc -nostdlib
ifeq ($(CONFIG_ARCH_X86),y)
TARGETARCH = i386
endif
diff --git a/payloads/nvramcui/Makefile b/payloads/nvramcui/Makefile
index c6a9cd0cf4..bf7053b9a6 100644
--- a/payloads/nvramcui/Makefile
+++ b/payloads/nvramcui/Makefile
@@ -3,7 +3,7 @@ XCOMPILE=$(LIBPAYLOAD_DIR)/libpayload.xcompile
# build libpayload and put .config file in $(CURDIR) instead of ../libpayload
# to avoid pollute the libpayload source directory and possible conflicts
LPOPTS=obj="$(CURDIR)/build" DESTDIR="$(CURDIR)" DOTCONFIG="$(CURDIR)/.config"
-CFLAGS += -Wall -Werror -Os -ffreestanding -nostdinc -nostdlib
+CFLAGS += -Wall -Wvla -Werror -Os -ffreestanding -nostdinc -nostdlib
all: nvramcui.elf