Commit | Line | Data |
---|---|---|
ad9f1fb6 | 1 | |
ad9f1fb6 PG |
2 | LIBGL = -lGL -lGLU |
3 | LIBSDL = `sdl-config --libs` | |
4 | LIBS = ${LIBSDL} ${LIBGL} | |
5 | ||
6 | CXX = g++ | |
7 | CXXFLAGS = -ggdb -Wall -pedantic | |
8 | ||
046b034c PG |
9 | SRCS := entityManager.cpp |
10 | SRCS += game.cpp | |
11 | SRCS += graphics.cpp | |
12 | SRCS += main.cpp | |
13 | SRCS += mathw.cpp | |
14 | SRCS += ticks.cpp | |
15 | SRCS += Vector2.cpp | |
16 | ||
17 | SRCS += Entities/Ball.cpp | |
18 | SRCS += Entities/Entity.cpp | |
19 | SRCS += Entities/Line.cpp | |
20 | SRCS += Entities/Particle.cpp | |
21 | SRCS += Entities/PhysicsEntity.cpp | |
22 | SRCS += Entities/Point.cpp | |
23 | SRCS += Entities/Polygon.cpp | |
24 | SRCS += Entities/WindParticle.cpp | |
25 | ||
26 | SRCS += GameStates/CreatingPolygon.cpp | |
27 | SRCS += GameStates/GameState.cpp | |
28 | SRCS += GameStates/Paused.cpp | |
29 | SRCS += GameStates/Running.cpp | |
30 | ||
f7b3b2eb PG |
31 | SRCS += input/inputManager.cpp |
32 | ||
ad9f1fb6 PG |
33 | OBJS = ${SRCS:.cpp=.o} |
34 | ||
046b034c | 35 | TARGET = ../run_physics |
ad9f1fb6 PG |
36 | DEPEND = depend.mk |
37 | ||
ad9f1fb6 | 38 | |
046b034c PG |
39 | .PHONY: all |
40 | all: ${TARGET} | |
ad9f1fb6 | 41 | |
046b034c PG |
42 | ${TARGET}: ${OBJS} |
43 | ${CXX} ${CXXFLAGS} -o ${TARGET} $^ ${LIBS} | |
ad9f1fb6 | 44 | |
046b034c PG |
45 | .PHONY: depend |
46 | depend: ${SRCS} | |
47 | ${CXX} -MM $^ > ${DEPEND} | |
ad9f1fb6 | 48 | |
ad9f1fb6 | 49 | |
046b034c | 50 | .PHONY: clean |
ad9f1fb6 | 51 | clean: |
046b034c | 52 | rm -f ${OBJS} ${TARGET} *~ |
ad9f1fb6 | 53 | |
046b034c | 54 | .PHONY: distclean |
ad9f1fb6 PG |
55 | distclean: clean |
56 | rm -f tags depend.mk | |
57 | touch depend.mk | |
58 | ||
046b034c PG |
59 | tags: ${SRCS} |
60 | ctags $^ | |
61 | ||
ad9f1fb6 PG |
62 | tar: clean |
63 | cd ..; tar -cjf bluestar.tar.bz2 images/ source/ | |
64 | ||
65 | ||
046b034c PG |
66 | .PHONY: run |
67 | run: all | |
27b74820 | 68 | ${TARGET} |
ad9f1fb6 PG |
69 | |
70 | include ${DEPEND} | |
71 |