diff mbox series

[v2,2/2] Makefile: pass -Wno-pendantic under GENERATE_COMPILATION_DATABASE=yes

Message ID patch-v2-2.2-6b18bd08894-20210922T220532Z-avarab@gmail.com (mailing list archive)
State Accepted
Commit 93cccedb8f057c649ed59c284f0d5074e663d7d9
Headers show
Series Makefile: "pedantic" fallout on .depend and "compdb" | expand

Commit Message

Ævar Arnfjörð Bjarmason Sept. 22, 2021, 10:08 p.m. UTC
The same bug fixed in the "COMPUTE_HEADER_DEPENDENCIES=auto" mode in
the preceding commit was also present with
"GENERATE_COMPILATION_DATABASE=yes". Let's fix it so it works again
with "DEVOPTS=1".

Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com>
---
 Makefile | 1 +
 1 file changed, 1 insertion(+)

Comments

Carlo Marcelo Arenas Belón Sept. 23, 2021, 12:05 a.m. UTC | #1
FWIW a simpler fix was posted[1] earlier, and you were CC; sorry for the mess

Carlo

[1] https://lore.kernel.org/git/20210922185702.4328-1-carenas@gmail.com/
Junio C Hamano Sept. 23, 2021, 9:33 p.m. UTC | #2
Ævar Arnfjörð Bjarmason  <avarab@gmail.com> writes:

> The same bug fixed in the "COMPUTE_HEADER_DEPENDENCIES=auto" mode in
> the preceding commit was also present with
> "GENERATE_COMPILATION_DATABASE=yes". Let's fix it so it works again
> with "DEVOPTS=1".
>
> Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com>
> ---
>  Makefile | 1 +
>  1 file changed, 1 insertion(+)
>
> diff --git a/Makefile b/Makefile
> index 10ea12aae21..94b116d4b37 100644
> --- a/Makefile
> +++ b/Makefile
> @@ -1304,6 +1304,7 @@ endif
>  
>  ifeq ($(GENERATE_COMPILATION_DATABASE),yes)
>  compdb_check = $(shell $(CC) $(ALL_CFLAGS) \
> +	-Wno-pedantic \

Yup, I like reusing the same approach from the other fix;
removing $(ALL_CFLAGS) may work fine, too, and that is what I
already queued, but I may swap it out with this later (if I do not
forget, that is).

>  	-c -MJ /dev/null \
>  	-x c /dev/null -o /dev/null 2>&1; \
>  	echo $$?)
diff mbox series

Patch

diff --git a/Makefile b/Makefile
index 10ea12aae21..94b116d4b37 100644
--- a/Makefile
+++ b/Makefile
@@ -1304,6 +1304,7 @@  endif
 
 ifeq ($(GENERATE_COMPILATION_DATABASE),yes)
 compdb_check = $(shell $(CC) $(ALL_CFLAGS) \
+	-Wno-pedantic \
 	-c -MJ /dev/null \
 	-x c /dev/null -o /dev/null 2>&1; \
 	echo $$?)