8634070ee8344474786b6c43257ae54c450f39da
[openafs.git] / src / dir / 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 DESTDIR=@DESTDIR@
9 SRCDIR=@SRCDIR@
10 TOP_SRCDIR=@TOP_SRCDIR@
11 SYS_NAME=@AFS_SYSNAME@
12
13 SHELL = /bin/sh
14
15 include ../config/Makefile.${SYS_NAME}
16
17 KERNELDIR = ../libafs/
18 UKERNELDIR = ../libuafs/
19
20 INCDIRS= -I${TOP_SRCDIR}/config -I${DESTDIR}/include ${XINCLS}
21 CFLAGS = ${OPTMZ} ${INCDIRS} ${XCFLAGS}
22
23 OBJS=buffer.o dir.o salvage.o
24 include ../config/Makefile.version
25
26 system noversion: install
27
28 cmdall: all test
29
30 all: libdir.a
31
32 libdir.a: ${OBJS} AFS_component_version_number.o
33         $(RM) -f libdir.a
34         ar rv libdir.a $(OBJS) AFS_component_version_number.o
35         $(RANLIB) libdir.a
36
37 kinstall:
38         ${INSTALL} dir.h ${KERNELDIR}/afs
39         ${INSTALL} dir.c ${KERNELDIR}/afs/afs_dir.c
40
41 ukinstall webinstall: ${UKERNELDIR}/afs
42         ${INSTALL} dir.h ${UKERNELDIR}/afs
43         ${INSTALL} dir.c ${UKERNELDIR}/afs/afs_dir.c
44
45 ${UKERNELDIR}/afs:
46         mkdir -p $@
47
48 install:        all kinstall ukinstall
49         ${INSTALL} libdir.a ${DESTDIR}/lib/afs
50         ${INSTALL} dir.h ${DESTDIR}/include/afs
51
52 test: 
53         (cd test; $(MAKE) )
54
55 buffer.o: buffer.c
56
57 dir.o: dir.c dir.h
58
59 salvage.o: salvage.c dir.h
60
61 clean:
62         $(RM) -f *.o *.a core AFS_component_version_number.c