1 # Copyright 2000, International Business Machines Corporation and others.
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
10 TOP_SRCDIR=@TOP_SRCDIR@
11 SYS_NAME=@AFS_SYSNAME@
13 BACKDIR=../../../../PARENT/dest/
14 include ../../config/Makefile.${SYS_NAME}
18 INCDIRS= -I${DESTDIR}include -I.. -I${BACKDIR}include
20 HEADERS = ../rxkad.h stress.h stress_internal.h stress_errs.h
23 ULIBS = ${LDIR}afs/libcmd.a ${LDIR}afs/libcom_err.a ${DESTDIR}lib/afs/util.a
25 LIBS = ../librxkad.a ${LDIR}librx.a ${LDIR}libdes.a \
26 ${LDIR}liblwp.a ${ULIBS} ${XLIBS}
28 LIBRPC = ../../librpc/libafsrpc.so
29 THLIBS= ${LDIR}afs/libcmd.a ${LDIR}afs/libcom_err.a \
30 ${ULIBS} ${XLIBS} ${LIBRPC} -lpthread
32 CFLAGS = ${OPTIMIZE} ${INCDIRS} ${XCFLAGS}
35 THFLAGS = -mt -DAFS_PTHREAD_ENV
37 THRULE = ${CC} ${CFLAGS} ${THFLAGS} -c $?
39 COMPILE_ET = ${SRCDIR}bin/compile_et
41 noversion all test system: stress
44 rm -f *.o stress.cs.c stress.ss.c stress.xdr.c stress.h \
45 stress_errs.c stress_errs.h stress th_*
47 stress.ss.o: stress.ss.c
48 stress.cs.o: stress.cs.c
49 stress.xdr.o: stress.xdr.c stress.h
51 th_stress.ss.o: stress.ss.c
52 ${THRULE} -o th_stress.ss.o
54 th_stress.cs.o: stress.cs.c
55 ${THRULE} -o th_stress.cs.o
57 th_stress.xdr.o: stress.xdr.c stress.h
58 ${THRULE} -o th_stress.xdr.o
60 stress.ss.c stress.cs.c stress.xdr.c stress.h: stress.rg
61 ${SRCDIR}bin/rxgen stress.rg
63 stress_errs.o: stress_errs.c
65 th_stress_errs.o: stress_errs.c
66 ${THRULE} -o th_stress_errs.o
68 stress_errs.c stress_errs.h: stress_errs.et
69 rm -f stress_errs.h stress_errs.c; ${COMPILE_ET} stress_errs -h stress_errs
71 stress.o stress_c.o stress_s.o: ${HEADERS}
73 th_stress.o: stress.c ${HEADERS}
74 ${THRULE} -o th_stress.o
76 th_stress_c.o: stress_c.c ${HEADERS}
77 ${THRULE} -o th_stress_c.o
79 th_stress_s.o: stress_s.c ${HEADERS}
80 ${THRULE} -o th_stress_s.o
82 stress: stress.o stress.xdr.o stress_c.o stress_s.o stress.cs.o \
83 stress.ss.o stress_errs.o
84 $(CC) $(CFLAGS) -o stress stress.o stress.xdr.o stress_c.o \
85 stress_s.o stress.cs.o stress.ss.o stress_errs.o ${LIBS}
87 th_stress: th_stress.o th_stress.xdr.o th_stress_c.o th_stress_s.o \
88 th_stress.cs.o th_stress.ss.o stress_errs.o \
90 ${CC} ${CFLAGS} ${THFLAGS} -o th_stress th_stress.o th_stress.xdr.o \
91 th_stress_c.o th_stress_s.o th_stress.cs.o th_stress.ss.o \
92 stress_errs.o ${THLIBS}