123456789101112131415161718192021222324252627282930313233343536373839 |
- NAME = zombies
- YACC_FILES = save.tab.c save.tab.h
- LEX_FILES = lex.yy.c
- PARSE_FILES = save.tab.c $(LEX_FILES)
- CODE_FILES = main.c Character.c Creature.c Maths.c Game.c Curses.c Map.c Menu.c
- DOC_FILES = docs
- DEBUG = YES
- ifeq ($(DEBUG),YES)
- D = -g
- else
- D =
- endif
- RESOURCES = ncurses menu
- CFLAGS += $(shell pkg-config --cflags $(RESOURCES))
- LIBS += $(shell pkg-config --libs $(RESOURCES))
- .PHONY: all clean docs
- all: $(PARSE_FILES)
- gcc -g -o $(NAME) -lm $(CFLAGS) $(LIBS) $(PARSE_FILES) $(CODE_FILES)
- $(YACC_FILES): save.y
- bison -d -t save.y
- $(LEX_FILES): save.tab.h save.l
- flex save.l
- docs: Doxyfile
- doxygen Doxyfile
- Doxyfile:
- doxygen -g
- clean:
- rm -rf $(NAME) $(PARSE_FILES) $(DOC_FILES) *.o
|