From d141e638442ea37ae64b5ddd375349aaa1870c2d Mon Sep 17 00:00:00 2001 From: Boyan Karatotev Date: Mon, 21 Nov 2022 14:49:05 +0000 Subject: [PATCH] build: add -Wunused-const-variable=2 to W=2 TF-A is quite strict with warnings and redundant code. This flag furthers this so it would be useful to have it. Add it to W=2 as it sets off a few platforms which require a somewhat involved fix. Signed-off-by: Boyan Karatotev Change-Id: Id52b3d477b4ada7dd69a36101ab22c575ab4ef19 --- Makefile | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Makefile b/Makefile index 03105d700..6d7865a82 100644 --- a/Makefile +++ b/Makefile @@ -374,6 +374,8 @@ WARNING2 += -Wmissing-prototypes WARNING2 += -Wmissing-format-attribute # TF-A aims to comply with this eventually. Effort too large at present WARNING2 += -Wundef +# currently very involved and many platforms set this off +WARNING2 += -Wunused-const-variable=2 # Level 3 - very pedantic, frequently ignored WARNING3 := -Wbad-function-cast