summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--include.mk10
1 files changed, 5 insertions, 5 deletions
diff --git a/include.mk b/include.mk
index 3d2bb22..b68db33 100644
--- a/include.mk
+++ b/include.mk
@@ -53,7 +53,7 @@ clean-external: $(EXTERNAL_LIBS:%=clean-%)
export
build-lufa: liblufa.a
-liblufa.a:
+liblufa.a: Makefile
@echo "building external LUFA lib ($(LUFA_PATH))"
make -f ../lufa.mk liblufa.a
make -f ../lufa.mk clean
@@ -65,13 +65,13 @@ clean-lufa:
## project-specific objects
-lib-%.d: $(LIB_DIR)/%.c
+lib-%.d: $(LIB_DIR)/%.c Makefile
@set -e; rm -f $@; \
$(CC) -MM $(CFLAGS) $< > $@.$$$$; \
sed 's,\($*\)\.o[ :]*,lib-\1.o $@ : ,g' < $@.$$$$ > $@; \
rm -f $@.$$$$; echo '(re)building $@'
-%.d: %.c
+%.d: %.c Makefile
@set -e; rm -f $@; \
$(CC) -MM $(CFLAGS) $< > $@.$$$$; \
sed 's,\($*\)\.o[ :]*,\1.o $@ : ,g' < $@.$$$$ > $@; \
@@ -82,10 +82,10 @@ ifneq ($(MAKECMDGOALS),distclean)
-include $(DEP_LIB)
endif
-lib-%.o: $(LIB_DIR)/%.c
+lib-%.o: $(LIB_DIR)/%.c Makefile
$(CC) $(CFLAGS) -c $< -o $@
-%.o: %.c
+%.o: %.c Makefile
$(CC) $(CFLAGS) -c $< -o $@
$(ELFFILE): $(OBJ) $(OBJ_LIB) $(EXTERNAL_LIBS:%=lib%.a)