initial XMLDocument class
[Tsunagari.git] / src / Makefile
blob20b0cfd293f1756b375824593fa7b98197825a56
1 ############################################################
2 # Tsunagari Tile Engine primary source Makefile (gnu make) #
3 ############################################################
6 ### --- VARIABLES SECTION --- ###
8 # Compiler to use. (Suggested: "g++" or "clang")
9 CXX = g++
11 # Warning flags to enable.
12 WFLAGS = -Wall -Wextra -Wconversion
14 # Internal Lua library.
15 LUACFLAGS = -I../deps/lua
16 LUALIB = ../deps/lua/liblua.a
18 # Libraries to include.
19 LIBS = $(LUALIB) -lgosu -lzip -lboost_program_options \
20 $(shell xml2-config --libs)
22 # Compiler and linker flags.
23 CXXFLAGS = $(MYCFLAGS) -pedantic -ansi $(WFLAGS) \
24 $(shell xml2-config --cflags) $(LUACFLAGS)
25 LDFLAGS = $(MYLDFLAGS) $(LIBS)
27 # Name of testing world.
28 TESTWORLD = babysfirst.world
31 ### --- MAIN SECTION --- ###
33 all: tsunagari $(TESTWORLD)
35 depend:
36 @$(CXX) $(CXXFLAGS) -MM *.cpp | perl filter-depend.pl
38 tsunagari: $(LUALIB) animation.o area.o cmd.o common.o entity.o entity-lua.o \
39 log.o main.o player.o resourcer.o script.o script-sound.o tile.o \
40 window.o world.o xml.o
41 $(CXX) -o tsunagari *.o $(LDFLAGS)
43 %.world: %/*
44 cd $(basename $@) && zip -r -0 ../$@ *
46 clean:
47 $(RM) tsunagari *.o $(TESTWORLD)
50 ### --- DEPENDS SECTION --- ###
52 # The following tells make when an object depends on a header so it can rebuild
53 # the object automatically. If an object isn't rebuilt it might crash the
54 # program. Generated by 'make depend'. Update if you change/add/remove
55 # a #include anywhere or if you add/remove a C++ file.
57 animation.o: animation.cpp animation.h common.h log.h resourcer.h \
58 ../deps/lua/lauxlib.h ../deps/lua/lua.h ../deps/lua/lua.h \
59 ../deps/lua/luaconf.h ../deps/lua/lualib.h
60 area.o: animation.h area.cpp area.h common.h entity.h log.h player.h \
61 resourcer.h tile.h window.h world.h xml.h ../deps/lua/lauxlib.h \
62 ../deps/lua/lua.h ../deps/lua/lua.h ../deps/lua/luaconf.h \
63 ../deps/lua/lualib.h
64 cmd.o: cmd.cpp cmd.h common.h log.h
65 common.o: common.cpp common.h log.h
66 entity-lua.o: animation.h common.h entity-lua.cpp entity-lua.h entity.h \
67 log.h resourcer.h script.h tile.h ../deps/lua/lauxlib.h ../deps/lua/lua.h \
68 ../deps/lua/lua.h ../deps/lua/luaconf.h ../deps/lua/lualib.h
69 entity.o: animation.h area.h common.h config.h entity-lua.h entity.cpp \
70 entity.h log.h player.h resourcer.h script.h tile.h window.h xml.h \
71 ../deps/lua/lauxlib.h ../deps/lua/lua.h ../deps/lua/lua.h \
72 ../deps/lua/luaconf.h ../deps/lua/lualib.h
73 log.o: config.h log.cpp log.h
74 main.o: cmd.h common.h config.h log.h main.cpp window.h
75 player.o: animation.h area.h common.h config.h entity.h log.h player.cpp \
76 player.h resourcer.h tile.h window.h world.h ../deps/lua/lauxlib.h \
77 ../deps/lua/lua.h ../deps/lua/lua.h ../deps/lua/luaconf.h \
78 ../deps/lua/lualib.h
79 resourcer.o: common.h config.h log.h resourcer.cpp resourcer.h window.h \
80 xml.h ../deps/lua/lauxlib.h ../deps/lua/lua.h ../deps/lua/lua.h \
81 ../deps/lua/luaconf.h ../deps/lua/lualib.h
82 script-sound.o: common.h log.h resourcer.h script-sound.cpp script-sound.h \
83 script.h ../deps/lua/lauxlib.h ../deps/lua/lua.h ../deps/lua/lua.h \
84 ../deps/lua/luaconf.h ../deps/lua/lualib.h
85 script.o: common.h log.h resourcer.h script-sound.h script.cpp script.h \
86 ../deps/lua/lauxlib.h ../deps/lua/lua.h ../deps/lua/lua.h \
87 ../deps/lua/luaconf.h ../deps/lua/lualib.h
88 tile.o: animation.h area.h common.h entity-lua.h entity.h log.h player.h \
89 resourcer.h script.h tile.cpp tile.h window.h ../deps/lua/lauxlib.h \
90 ../deps/lua/lua.h ../deps/lua/lua.h ../deps/lua/luaconf.h \
91 ../deps/lua/lualib.h
92 window.o: common.h config.h log.h resourcer.h window.cpp window.h world.h \
93 ../deps/lua/lauxlib.h ../deps/lua/lua.h ../deps/lua/lua.h \
94 ../deps/lua/luaconf.h ../deps/lua/lualib.h
95 world.o: animation.h area.h common.h entity.h log.h player.h resourcer.h \
96 tile.h window.h world.cpp world.h xml.h ../deps/lua/lauxlib.h \
97 ../deps/lua/lua.h ../deps/lua/lua.h ../deps/lua/luaconf.h \
98 ../deps/lua/lualib.h
99 xml.o: log.h xml.cpp xml.h