Fixed some little errors with the drawing functions.
[luagame.git] / Makefile
blob128c317fab6bf3da082a8195d8d17efe6c614cc2
1 #Installation prefix
2 PREFIX = /usr
4 #compilation variables
5 CXX = g++
6 LDFLAGS := ${LDFLAGS} -llua -lSDL -lSDL_image -lSDL_mixer -lSDL_gfx -lSDL_ttf
7 CFLAGS := ${CFLAGS} -O2 -I/usr/include
9 objects = funcs_draw.o funcs_font.o funcs.o funcs_input.o funcs_sound.o funcs_video.o globals.o
10 doc_source = doc/class_eventmanager.txt doc/index.txt doc/class_objectlist.txt doc/class_object.txt doc/fun_ref.txt
12 all: luagame
14 luagame: main.o $(objects)
15 ${CXX} -o luagame main.o $(objects) ${LDFLAGS}
17 main.o : $(objects) main.cpp globals.h
18 ${CXX} -c main.cpp ${CFLAGS}
20 funcs_draw.o : funcs_draw.cpp funcs_draw.h globals.h
21 ${CXX} -c funcs_draw.cpp ${CFLAGS}
23 funcs_font.o : funcs_font.cpp funcs_font.h globals.h
24 ${CXX} -c funcs_font.cpp ${CFLAGS}
26 funcs.o : funcs.cpp funcs.h globals.h
27 ${CXX} -c funcs.cpp ${CFLAGS}
29 funcs_input.o : funcs_input.cpp funcs_input.h globals.h
30 ${CXX} -c funcs_input.cpp ${CFLAGS}
32 funcs_sound.o : funcs_sound.cpp funcs_sound.h globals.h
33 ${CXX} -c funcs_sound.cpp ${CFLAGS}
35 funcs_video.o : funcs_video.cpp funcs_video.h globals.h
36 ${CXX} -c funcs_video.cpp $(CFLAGS)
38 globals.o : globals.h globals.cpp
39 ${CXX} -c globals.cpp $(CFLAGS)
41 doc: $(doc_source)
42 cd doc
43 ./build_docs.sh
44 cd ..
46 clean:
47 rm -f main.o $(objects)
48 rm -f luagame
50 install: luagame
51 strip luagame
52 cp luagame ${PREFIX}/bin/
54 install-doc: doc
55 mkdir ${PREFIX}/share/luagame/
56 mkdir ${PREFIX}/share/luagame/doc
57 cd doc
58 cp *.html ${PREFIX}/share/luagame/doc/
59 cd ..
61 uninstall:
62 rm -f ${PREFIX}/bin/luagame
63 rm -rf ${PREFIX}/share/luagame