Skip to content

Commit df32729

Browse files
ttaylorrgitster
authored andcommitted
config.mak.dev: fix typo when enabling -Wpedantic
In ebd2e4a (Makefile: restrict -Wpedantic and -Wno-pedantic-ms-format better, 2021-09-28), we tightened our Makefile's behavior to only enable -Wpedantic when compiling with either gcc5/clang4 or greater as older compiler versions did not have support for -Wpedantic. Commit ebd2e4a was looking for either "gcc5" or "clang4" to appear in the COMPILER_FEATURES variable, combining the two "$(filter ...)" searches with an "$(or ...)". But ebd2e4a has a typo where instead of writing: ifneq ($(or ($filter ...),$(filter ...)),) we wrote: ifneq (($or ($filter ...),$(filter ...)),) Causing our Makefile (when invoked with DEVELOPER=1, and a sufficiently recent compiler version) to barf: $ make DEVELOPER=1 config.mak.dev:13: extraneous text after 'ifneq' directive [...] Correctly combine the results of the two "$(filter ...)" operations by using "$(or ...)", not "$or". Signed-off-by: Taylor Blau <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent dbecc61 commit df32729

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

config.mak.dev

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ endif
1010
DEVELOPER_CFLAGS += -Wall
1111
ifeq ($(filter no-pedantic,$(DEVOPTS)),)
1212
DEVELOPER_CFLAGS += -pedantic
13-
ifneq (($or $(filter gcc5,$(COMPILER_FEATURES)),$(filter clang4,$(COMPILER_FEATURES))),)
13+
ifneq ($(or $(filter gcc5,$(COMPILER_FEATURES)),$(filter clang4,$(COMPILER_FEATURES))),)
1414
DEVELOPER_CFLAGS += -Wpedantic
1515
ifneq ($(filter gcc10,$(COMPILER_FEATURES)),)
1616
ifeq ($(uname_S),MINGW)

0 commit comments

Comments
 (0)