Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

add header files to make dependencies

  • Loading branch information...
commit 21463c607bcc341b2517d5fbd574fad612c5d6d1 1 parent d3a5cc7
@beerriot authored
Showing with 10 additions and 2 deletions.
  1. +1 −0  .gitignore
  2. +9 −2 Makefile
View
1  .gitignore
@@ -1,5 +1,6 @@
*~
*.o
+*.d
*.hex
*.ass
blockgame
View
11 Makefile
@@ -1,4 +1,4 @@
-VPATH=src
+VPATH=src:include
CC=avr-gcc
LIBNERDKITS=../libnerdkits
CFLAGS=-g -Os -Wall -mmcu=atmega168 -Iinclude -I$(LIBNERDKITS)
@@ -23,4 +23,11 @@ blockgame.ass: blockgame
.PHONY: clean
clean:
- -rm *.o blockgame blockgame.hex blockgame.ass
+ -rm *.o *.d blockgame blockgame.hex blockgame.ass
+
+-include $(OBJECTS:%.o=%.d)
+
+deps: $(OBJECTS:%.o=%.d)
+
+%.d: %.c
+ $(CC) $(CFLAGS) -MM $< > $@
Please sign in to comment.
Something went wrong with that request. Please try again.