kconfig: Add -MP option so .d files include empty targets

Prevents make-level errors when switching IDF versions, as headers may be removed.

Similar to some mentioned here:
https://github.com/espressif/esp-idf/issues/712
This commit is contained in:
Angus Gratton 2019-08-19 11:42:39 +10:00 committed by Angus Gratton
parent ad565f27f7
commit a0a5e367d6

View file

@ -165,7 +165,7 @@ check-lxdialog := $(SRCDIR)/lxdialog/check-lxdialog.sh
# Use recursively expanded variables so we do not call gcc unless # Use recursively expanded variables so we do not call gcc unless
# we really need to do so. (Do not call gcc as part of make mrproper) # we really need to do so. (Do not call gcc as part of make mrproper)
CFLAGS += $(shell $(CONFIG_SHELL) $(check-lxdialog) -ccflags) \ CFLAGS += $(shell $(CONFIG_SHELL) $(check-lxdialog) -ccflags) \
-DLOCALE -MMD -DLOCALE -MMD -MP
%.o: $(SRCDIR)/%.c %.o: $(SRCDIR)/%.c
$(CC) -c $(CFLAGS) $(CPPFLAGS) $< -o $@ $(CC) -c $(CFLAGS) $(CPPFLAGS) $< -o $@