comparison Makefile @ 18:5937504619f2

rename game.h -> modules.h; added some error handling; and more
author meillo@marmaro.de
date Wed, 23 Jul 2008 17:40:55 +0200
parents bbc214c6fa6f
children
comparison
equal deleted inserted replaced
17:5e6c9260913a 18:5937504619f2
19 DEBUG = -g 19 DEBUG = -g
20 CFLAGS = -Wall -c ${DEBUG} 20 CFLAGS = -Wall -c ${DEBUG}
21 LDFLAGS = -Wall ${DEBUG} -lsqlite3 21 LDFLAGS = -Wall ${DEBUG} -lsqlite3
22 22
23 # files 23 # files
24 DEP = db.h game.h 24 DEP = db.h
25 SRC = main.c clock.c environment.c weather.c growth.c db.c 25 SRC = main.c clock.c environment.c weather.c growth.c db.c
26 OBJ = $(SRC:.c=.o) 26 OBJ = $(SRC:.c=.o)
27 27
28 28
29 .PHONY: all 29 .PHONY: all
42 .PHONY: build 42 .PHONY: build
43 build: options ${NAME} 43 build: options ${NAME}
44 44
45 45
46 $(OBJ): $(SRC) $(DEP) 46 $(OBJ): $(SRC) $(DEP)
47
48 main.o: main.c $(DEP) modules.h
47 49
48 ${NAME}: $(DEP) $(OBJ) 50 ${NAME}: $(DEP) $(OBJ)
49 gcc -o $(NAME) $(LDFLAGS) $(OBJ) 51 gcc -o $(NAME) $(LDFLAGS) $(OBJ)
50 52
51 53