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
9 include ../config/Makefile.${SYS_NAME}
11 KERNELDIR = ../libafs/
12 UKERNELDIR = ../libuafs/
13 INSTALL = ${SRCDIR}bin/install
14 MKDIR_IF_NEEDED=[ -d $$1 ] || mkdir -p $$1
16 OBJS=afsaux.o afscbint.cs.o afscbint.ss.o afscbint.xdr.o afsint.cs.o afsint.ss.o afsint.xdr.o
17 CFLAGS=${DBUG} -I${SRCDIR}include ${XCFLAGS}
18 KDSRCS=Kcallback.ss.c Kcallback.h Kvice.cs.c Kvice.h Kvice.xdr.c afscbint.h \
20 KSRCS=${KDSRCS} afsaux.c
22 UTILS=$(SRCDIR)/bin/rxgen
24 include ../config/Makefile.version
28 all: libafsint.a $(KSRCS)
30 libafsint.a: ${OBJS} AFS_component_version_number.o
32 ar rv $@ ${OBJS} AFS_component_version_number.o
35 afsaux.o: afsaux.c afsint.h
37 Kcallback.cs.c: common.xg afscbint.xg Kvice.h Kcallback.h $(UTILS)
38 ${SRCDIR}bin/rxgen -x -k -C -o Kcallback.cs.c afscbint.xg
40 Kcallback.ss.c: common.xg afscbint.xg Kvice.h Kcallback.h $(UTILS)
41 ${SRCDIR}bin/rxgen -x -k -S -o Kcallback.ss.c afscbint.xg
43 Kcallback.xdr.c: common.xg afscbint.xg Kvice.h Kcallback.h $(UTILS)
44 ${SRCDIR}bin/rxgen -x -k -y -c -o Kcallback.xdr.c afscbint.xg
46 Kvice.cs.c: common.xg afsint.xg Kvice.h $(UTILS)
47 ${SRCDIR}bin/rxgen -x -k -C -o Kvice.cs.c afsint.xg
49 Kvice.ss.c: common.xg afsint.xg Kvice.h $(UTILS)
50 ${SRCDIR}bin/rxgen -x -k -S -o Kvice.ss.c afsint.xg
52 Kvice.xdr.c: common.xg afsint.xg $(UTILS)
53 ${SRCDIR}bin/rxgen -x -k -c -o Kvice.xdr.c afsint.xg
55 Kvice.h: common.xg afsint.xg $(UTILS)
56 ${SRCDIR}bin/rxgen -x -k -h -o Kvice.h afsint.xg
58 Kcallback.h: common.xg afscbint.xg $(UTILS)
59 ${SRCDIR}bin/rxgen -x -k -h -o Kcallback.h afscbint.xg
61 afscbint.cs.c: common.xg afscbint.xg afsint.h afscbint.h $(UTILS)
62 ${SRCDIR}bin/rxgen -x -C -o afscbint.cs.c afscbint.xg
64 afscbint.ss.c: common.xg afscbint.xg afsint.h afscbint.h $(UTILS)
65 ${SRCDIR}bin/rxgen -x -S -o afscbint.ss.c afscbint.xg
67 afscbint.xdr.c: common.xg afscbint.xg afsint.h afscbint.h $(UTILS)
68 ${SRCDIR}bin/rxgen -x -y -c -o afscbint.xdr.c afscbint.xg
70 afsint.cs.c: common.xg afsint.xg afsint.h $(UTILS)
71 ${SRCDIR}bin/rxgen -x -C -o afsint.cs.c afsint.xg
73 afsint.ss.c: common.xg afsint.xg afsint.h $(UTILS)
74 ${SRCDIR}bin/rxgen -x -S -o afsint.ss.c afsint.xg
76 afsint.xdr.c: common.xg afsint.xg $(UTILS)
77 ${SRCDIR}bin/rxgen -x -c -o afsint.xdr.c afsint.xg
79 afsint.h: common.xg afsint.xg $(UTILS)
80 ${SRCDIR}bin/rxgen -x -h -o afsint.h afsint.xg
82 afscbint.h: common.xg afscbint.xg $(UTILS)
83 ${SRCDIR}bin/rxgen -x -h -o afscbint.h afscbint.xg
88 set ${KERNELDIR}afsint; $(MKDIR_IF_NEEDED)
89 ${INSTALL} $(KSRCS) ${KERNELDIR}afsint
90 ${INSTALL} $(SRCDIR)include/afs/rxgen_consts.h ${KERNELDIR}afsint
91 -${INSTALL} ${KERNELDIR}rx/rx.h ${KERNELDIR}afsint/rx.h
92 ${INSTALL} afscbint.h ${KERNELDIR}afs
94 ukinstall webinstall: ${UKSRCS}
95 set ${UKERNELDIR}afsint; $(MKDIR_IF_NEEDED)
96 ${INSTALL} $(UKSRCS) ${UKERNELDIR}afsint
97 ${INSTALL} $(SRCDIR)include/afs/rxgen_consts.h ${UKERNELDIR}afsint
98 -${INSTALL} ${UKERNELDIR}rx/rx.h ${UKERNELDIR}afsint/rx.h
99 ${INSTALL} afscbint.h ${UKERNELDIR}afs
101 install: all kinstall ukinstall
102 ${INSTALL} libafsint.a ${DESTDIR}lib/afs
103 ${INSTALL} afsint.h ${DESTDIR}include/afs
104 ${INSTALL} afscbint.h ${DESTDIR}include/afs
107 rm -f *.o *.cs.c *.ss.c *.er.c afsint.h afsint.xdr.c libafsint.a $(KDSRCS) core AFS_component_version_number.c