diff options
Diffstat (limited to 'src/tests/Makefile')
-rw-r--r-- | src/tests/Makefile | 61 |
1 files changed, 61 insertions, 0 deletions
diff --git a/src/tests/Makefile b/src/tests/Makefile new file mode 100644 index 0000000..a6cc02f --- /dev/null +++ b/src/tests/Makefile | |||
@@ -0,0 +1,61 @@ | |||
1 | CXX=g++ | ||
2 | CXXFLAGS= -I.. -I../FbTk -DDEBUG -DUSE_XFT -Wall -g -O2 | ||
3 | LIBS= | ||
4 | XFLAGS= -I/usr/X11R6/include | ||
5 | XLIBS= -L/usr/X11R6/lib -lX11 -lXft | ||
6 | COMPILEFILE=$(CXX) -c $(CXXFLAGS) | ||
7 | FONT_OBJ = ../BaseDisplay.o ../FbTk/Font.o ../FbTk/XFontImp.o ../FbTk/XftFontImp.o ../FbTk/XmbFontImp.o \ | ||
8 | ../FbTk/Timer.o ../StringUtil.o ../i18n.o | ||
9 | |||
10 | all: testLayers testStringUtil testKeys testResource testSignal | ||
11 | |||
12 | .cc.o: | ||
13 | $(CXX) -c $(CXXFLAGS) $< -o $@ | ||
14 | |||
15 | ../FbTk/XftFontImp.o: ../FbTk/XftFontImp.hh ../FbTk/XftFontImp.cc | ||
16 | |||
17 | ../FbTk/XmbFontImp.o: ../FbTk/XmbFontImp.hh ../FbTk/XmbFontImp.cc | ||
18 | |||
19 | ../FbTk/XFontImp.o: ../FbTk/XFontImp.hh ../FbTk/XFontImp.cc | ||
20 | |||
21 | ../FbTk/Font.o: ../FbTk/XFontImp.hh ../FbTk/XftFontImp.hh ../FbTk/XmbFontImp.hh ../FbTk/Font.hh ../FbTk/Font.cc | ||
22 | |||
23 | StringUtil.o: ../StringUtil.cc ../StringUtil.hh | ||
24 | $(CXX) -c $(CXXFLAGS) ../StringUtil.cc -o StringUtil.o | ||
25 | |||
26 | Keys.o: ../Keys.cc ../Keys.hh | ||
27 | $(CXX) -c $(CXXFLAGS) $(XFLAGS) ../Keys.cc -o Keys.o | ||
28 | |||
29 | Resource.o: ../Resource.cc ../Resource.hh | ||
30 | $(CXX) -c $(CXXFLAGS) $(XFLAGS) ../Resource.cc -o Resource.o | ||
31 | |||
32 | ../FbTk/SignalHandler.o: | ||
33 | ${COMPILEFILE} ../FbTk/SignalHandler.cc -o ../FbTk/SignalHandler.o | ||
34 | |||
35 | testStringUtil: StringUtiltest.o StringUtil.o | ||
36 | $(CXX) $(LIBS) StringUtiltest.o StringUtil.o -o testStringUtil | ||
37 | |||
38 | testKeys: Keys.o testKeys.o StringUtil.o | ||
39 | $(CXX) $(LIBS) $(XLIBS) StringUtil.o Keys.o testKeys.o -o testKeys | ||
40 | |||
41 | testResource: Resourcetest.o Resource.o | ||
42 | ${CXX} ${LIBS} ${XLIBS} Resourcetest.o Resource.o -o testResource | ||
43 | |||
44 | testSignal: signaltest.cc ../FbTk/SignalHandler.o | ||
45 | ${CXX} ${LIBS} signaltest.cc ../FbTk/SignalHandler.o -o testSignal | ||
46 | |||
47 | testFont: testFont.cc ${FONT_OBJ} | ||
48 | ${CXX} ${CXXFLAGS} ${XLIBS} testFont.cc ${FONT_OBJ} -o testFont | ||
49 | |||
50 | testLayers: testLayers.cc | ||
51 | ${CXX} ${CXXFLAGS} ${XLIBS} testLayers.cc ../FbTk/libFbTk.a -o testLayers | ||
52 | |||
53 | run: testLayers testResource testKeys testStringUtil testFont | ||
54 | ./testLayers | ||
55 | ./testKeys | ||
56 | ./testStringUtil | ||
57 | ./testResource | ||
58 | ./testSignal | ||
59 | ./testFont | ||
60 | clean: | ||
61 | rm -f *.o | ||