fiddling with makefile

This commit is contained in:
Philippe Teuwen 2020-05-12 01:49:01 +02:00
parent 8dcf670f72
commit 61610a5c61
2 changed files with 15 additions and 6 deletions

View file

@ -52,6 +52,13 @@ DEFCFLAGS += -Wbad-function-cast -Wredundant-decls -Wmissing-prototypes -Wchar-s
DEFCFLAGS += -Wcast-align -Wno-error=cast-align
DEFCFLAGS += -Wswitch-enum -Wno-error=switch-enum
ifeq ($(platform),Darwin)
# their readline has strict-prototype issues
DEFCFLAGS += -Wno-strict-prototypes
else
DEFCFLAGS += -Wstrict-prototypes
endif
# Next ones are activated only if GCCEXTRA=1 or CLANGEXTRA=1
EXTRACFLAGS =
EXTRACFLAGS += -Wunused-parameter -Wno-error=unused-parameter
@ -84,10 +91,9 @@ CLANGEXTRACFLAGS += -Wimplicit-fallthrough
ifeq ($(CLANGEXTRA),1)
DEFCFLAGS += $(CLANGEXTRACFLAGS) $(EXTRACFLAGS)
endif
ifeq ($(platform),Darwin)
# their readline has strict-prototype issues
DEFCFLAGS += -Wstrict-prototypes -Wno-error=strict-prototypes
else
DEFCFLAGS += -Wstrict-prototypes
ifeq ($(CLANGEVERYTHING),1)
DEFCFLAGS += -Weverything -Wno-error
endif
ifeq ($(NOERROR),1)
DEFCFLAGS += -Wno-error
endif

View file

@ -84,6 +84,9 @@ GCCEXTRACFLAGS += -Wcast-align -Wno-error=cast-align
ifeq ($(GCCEXTRA),1)
DEFCFLAGS += $(GCCEXTRACFLAGS) $(EXTRACFLAGS)
endif
ifeq ($(NOERROR),1)
DEFCFLAGS += -Wno-error
endif
CFLAGS ?= $(DEFCFLAGS)
CFLAGS += $(ARMCFLAGS) -c $(INCLUDE) -std=c99 $(APP_CFLAGS)