The delete-null-pointer-checks flag is not supported by current
clang versions. Do not add it to the CLFAGS in the clang case.
This gets rid of warnings like below when using clang as HOSTCC:
warning: optimization flag '-fno-delete-null-pointer-checks' is not supported
Signed-off-by: Stefan Agner <stefan@agner.ch>
ifeq ($(shell $(HOSTCC) -v 2>&1 | grep -c "clang version"), 1)
HOSTCFLAGS += -Wno-unused-value -Wno-unused-parameter \
- -Wno-missing-field-initializers -fno-delete-null-pointer-checks
+ -Wno-missing-field-initializers
endif
# Decide whether to build built-in, modular, or both.