mirror of
https://github.com/oliverschmidt/contiki.git
synced 2024-12-22 10:30:13 +00:00
Allow a target-specific makesfile to supply a custom rule for dependency file generation in the same way it is done for all other rules.
This commit is contained in:
parent
07a26c584a
commit
859ab1b706
@ -119,12 +119,13 @@ ifndef CDEPFLAGS
|
|||||||
CDEPFLAGS = $(CFLAGS)
|
CDEPFLAGS = $(CFLAGS)
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
ifndef CUSTOM_RULE_C_TO_OBJECTDIR_D
|
||||||
$(OBJECTDIR)/%.d: %.c
|
$(OBJECTDIR)/%.d: %.c
|
||||||
@set -e; rm -f $@; \
|
@set -e; rm -f $@; \
|
||||||
$(CCDEP) -MM $(CDEPFLAGS) $< > $@.$$$$; \
|
$(CCDEP) -MM $(CDEPFLAGS) $< > $@.$$$$; \
|
||||||
sed 's,\($*\)\.o[ :]*,$(OBJECTDIR)/\1.o $@ : ,g' < $@.$$$$ > $@; \
|
sed 's,\($*\)\.o[ :]*,$(OBJECTDIR)/\1.o $@ : ,g' < $@.$$$$ > $@; \
|
||||||
rm -f $@.$$$$
|
rm -f $@.$$$$
|
||||||
|
endif
|
||||||
|
|
||||||
# The line below is needed so that GNU make does not remove the
|
# The line below is needed so that GNU make does not remove the
|
||||||
# generated file.
|
# generated file.
|
||||||
|
Loading…
Reference in New Issue
Block a user