aboutsummaryrefslogtreecommitdiff
path: root/src/tests/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'src/tests/Makefile')
-rw-r--r--src/tests/Makefile45
1 files changed, 45 insertions, 0 deletions
diff --git a/src/tests/Makefile b/src/tests/Makefile
new file mode 100644
index 0000000..978167f
--- /dev/null
+++ b/src/tests/Makefile
@@ -0,0 +1,45 @@
1OBJ=StringUtiltest.o ../StringUtil.o
2CXX=g++
3CXXFLAGS= -I.. -DDEBUG -Wall -g -O2
4LIBS=
5XFLAGS= -I/usr/X11R6/include
6XLIBS= -L/usr/X11R6/lib -lX11
7COMPILEFILE=$(CXX) -c $(CXXFLAGS)
8
9all: testStringUtil testKeys testResource testSignal
10
11.cc.o:
12 $(CXX) -c $(CXXFLAGS) $<
13
14StringUtil.o: ../StringUtil.cc ../StringUtil.hh
15 $(CXX) -c $(CXXFLAGS) ../StringUtil.cc -o StringUtil.o
16
17Keys.o: ../Keys.cc ../Keys.hh
18 $(CXX) -c $(CXXFLAGS) $(XFLAGS) ../Keys.cc -o Keys.o
19
20Resource.o: ../Resource.cc ../Resource.hh
21 $(CXX) -c $(CXXFLAGS) $(XFLAGS) ../Resource.cc -o Resource.o
22
23../SignalHandler.o:
24 ${COMPILEFILE} ../SignalHandler.cc -o ../SignalHandler.o
25
26testStringUtil: StringUtiltest.o StringUtil.o
27 $(CXX) $(LIBS) StringUtiltest.o StringUtil.o -o testStringUtil
28
29testKeys: Keys.o testKeys.o StringUtil.o
30 $(CXX) $(LIBS) $(XLIBS) StringUtil.o Keys.o testKeys.o -o testKeys
31
32testResource: Resourcetest.o Resource.o
33 ${CXX} ${LIBS} ${XLIBS} Resourcetest.o Resource.o -o testResource
34
35testSignal: signaltest.cc ../SignalHandler.o
36 ${CXX} ${LIBS} signaltest.cc ../SignalHandler.o -o testSignal
37
38
39run: testResource testKeys testStringUtil
40 ./testKeys
41 ./testStringUtil
42 ./testResource
43 ./testSignal
44clean:
45 rm -f *.o