-
Notifications
You must be signed in to change notification settings - Fork 0
/
makefile
34 lines (34 loc) · 1.12 KB
/
makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
CC = g++
OBJS = Creature.o Zombie.o Vampire.o Archer.o Wizard.o Black_Dragon.o Hero.o Warrior.o Thief.o Necromancer.o Game.o main.o
EXEC = Heroes
DEBUG_FLAG = -g
COMP_FLAG = -c
CLEAN = clean
$(EXEC):$(OBJS)
$(CC) $(DEBUG_FLAG) $(OBJS) -o $@
Creature.o:Creature.h GameException.h Creature.cpp
$(CC) $(COMP_FLAG) $*.cpp
Zombie.o:Zombie.h Zombie.cpp Creature.h
$(CC) $(COMP_FLAG) $*.cpp
Vampire.o:Vampire.h Vampire.cpp Creature.h
$(CC) $(COMP_FLAG) $*.cpp
Archer.o:Archer.h Archer.cpp Creature.h
$(CC) $(COMP_FLAG) $*.cpp
Wizard.o:Wizard.h Wizard.cpp Creature.h
$(CC) $(COMP_FLAG) $*.cpp
Black_Dragon.o:Black_Dragon.h Black_Dragon.cpp Creature.h
$(CC) $(COMP_FLAG) $*.cpp
Hero.o:Hero.h Hero.cpp Vampire.h Zombie.h Archer.h Wizard.h Black_Dragon.h
$(CC) $(COMP_FLAG) $*.cpp
Thief.o:Thief.h Thief.cpp Hero.h
$(CC) $(COMP_FLAG) $*.cpp
Warrior.o:Warrior.h Warrior.cpp Hero.h
$(CC) $(COMP_FLAG) $*.cpp
Necromancer.o:Necromancer.h Necromancer.cpp Hero.h
$(CC) $(COMP_FLAG) $*.cpp
Game.o:Necromancer.h Thief.h Warrior.h Game.h Game.cpp
$(CC) $(COMP_FLAG) $*.cpp
main.o:main.cpp Game.h
$(CC) $(COMP_FLAG) $*.cpp
clean:
rm -f $(OBJS) $(EXEC)