autoconf-likes-relative-paths-20060802
[openafs.git] / src / rx / test / Makefile.in
1 # Copyright 2000, International Business Machines Corporation and others.
2 # All Rights Reserved.
3
4 # This software has been released under the terms of the IBM Public
5 # License.  For details, see the LICENSE file in the top-level source
6 # directory or online at http://www.openafs.org/dl/license10.html
7
8 srcdir=@srcdir@
9 include @TOP_OBJDIR@/src/config/Makefile.config
10 INSTALL = @INSTALL@
11 INSTALL_DATA = @INSTALL_DATA@
12 INSTALL_PROGRAM = @INSTALL_PROGRAM@
13 INSTALL_SCRIPT = @INSTALL_SCRIPT@
14
15
16
17 INCDIRS= -I${TOP_INCDIR} -I.. -I. -I${srcdir} -I${srcdir}/.. -I${TOP_OBJDIR}/src/config 
18 LDIRS= -L.. -L${TOP_LIBDIR}
19 LIBS= ${TOP_LIBDIR}/libcmd.a  ../librx.a ${TOP_LIBDIR}/liblwp.a \
20          ${TOP_LIBDIR}/util.a ${TOP_LIBDIR}/libsys.a ${XLIBS}
21
22 CFLAGS = ${OPTIMIZE} ${INCDIRS} -DRXDEBUG ${LDIRS} ${XCFLAGS} ${ARCHFLAGS}
23
24 RXTESTOBJS = testclient.o testserver.o kstest.o kctest.o
25
26 BASICINCLS =  ../rx_clock.h ../rx_queue.h ../rx_event.h
27
28 LINK = ${CC} ${CFLAGS} -o $@ $@.o ${LIBS}
29
30 TESTS = testclient testserver kstest kctest testqueue tableGen generator
31
32 TH_TESTS = th_testserver th_testclient
33
34 .IGNORE: 
35
36 all: test
37
38 test tests: ${TESTS}
39
40 th_test th_tests: ${TH_TESTS}
41
42 testclient: ../librx.a testclient.o
43         -${LINK}
44
45 testserver: ../librx.a testserver.o
46         -${LINK}
47
48 kstest: ../librx.a kstest.o
49         -${LINK}
50
51 kctest: ../librx.a kctest.o
52         -${LINK}
53
54 # th_ versions only have link lines for Solaris now.
55 th_testclient: th_testclient.o ../../libafsrpc/libafsrpc.so 
56         ${CC} ${CFLAGS} -mt -o th_testclient th_testclient.o \
57                 ../../libafsrpc/libafsrpc.so -lpthread
58
59 th_testclient.o: testclient.c
60         ${CC} ${CFLAGS} -DAFS_PTHREAD_ENV -mt -c -o th_testclient.o \
61                 ${srcdir}/testclient.c
62
63 th_testserver: th_testserver.o ../../libafsrpc/libafsrpc.so 
64         ${CC} ${CFLAGS} -mt -o th_testserver th_testserver.o \
65                 ../../libafsrpc/libafsrpc.so -lpthread
66
67 th_testserver.o: testserver.c
68         ${CC} ${CFLAGS} -DAFS_PTHREAD_ENV -mt -c -o th_testserver.o \
69                 ${srcdir}/testserver.c
70
71 testqueue: ../librx.a testqueue.o
72         -${LINK}
73
74 ${RXTESTOBJS}: ${BASICINCLS} ../rx.h
75
76 clean:
77         $(RM) -f *.o *.a ${TESTS} ${TH_TESTS} core