b15bee887c249b556001a1a7ef3e14ff433896d5
[openafs.git] / src / log / Makefile
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 COMPONENT=log
9 include ../config/Makefile.${SYS_NAME}
10
11 INCDIRS= -I${DESTDIR}include -I${DESTDIR}include/afs 
12 utilib=${DESTDIR}lib/afs/util.a
13
14 CFLAGS = ${OPTMZ} ${INCDIRS} ${XCFLAGS} ${DBUG}
15
16 PROGRAMS=       unlog tokens tokens.krb kseal
17
18 INSTALL = ${SRCDIR}bin/install
19 INSTALLro = ${SRCDIR}bin/install -m 644
20
21 INCLS=${SRCDIR}include/afs/auth.h ${SRCDIR}include/rx/rx.h \
22 ${SRCDIR}include/rx/xdr.h ${SRCDIR}include/des.h ${SRCDIR}include/rx/rxkad.h \
23 ${SRCDIR}include/afs/cellconfig.h
24
25 LIBRARIES=      ${SRCDIR}lib/afs/libauth.a \
26                 ${SRCDIR}lib/librxkad.a \
27                 ${SRCDIR}lib/libdes.a \
28                 ${SRCDIR}lib/afs/libsys.a ${SRCDIR}lib/librx.a \
29                 ${SRCDIR}lib/afs/libsys.a \
30                 ${SRCDIR}lib/liblwp.a ${SRCDIR}lib/afs/libcmd.a \
31                 ${SRCDIR}lib/afs/util.a
32 KLIBRARIES=     ${SRCDIR}lib/afs/libauth.krb.a \
33                 ${SRCDIR}lib/librxkad.a \
34                 ${SRCDIR}lib/libdes.a \
35                 ${SRCDIR}lib/afs/libsys.a ${SRCDIR}lib/librx.a \
36                 ${SRCDIR}lib/afs/libsys.a \
37                 ${SRCDIR}lib/liblwp.a ${SRCDIR}lib/afs/libcmd.a \
38                 ${SRCDIR}lib/afs/util.a
39
40 include ../config/Makefile.version
41
42 # top-level options
43
44 all:    ${PROGRAMS}
45
46 install:        all
47         ${INSTALL} -s unlog tokens tokens.krb ${DESTDIR}bin
48         ${INSTALL} -s tokens tokens.krb ${DESTDIR}root.server/usr/afs/bin
49         ${INSTALL} -s kseal ${DESTDIR}etc
50
51 lint:   log.c passwd.c unlog.c testlog.c
52         lint  ${INCDIRS} log.c 
53         lint  ${INCDIRS} unlog.c 
54         lint  ${INCDIRS} passwd.c
55
56 clean:  
57         rm -f *.o log passwd unlog tokens kseal core AFS_component_version_number.c
58
59 beancount:
60         wc -l log.c passwd.c unlog.c 
61
62 # programs
63
64 kseal: kseal.o ${LIBRARIES}
65         ${CC} -o kseal kseal.o ${LIBRARIES} ${XLIBS} ${CFLAGS}
66
67 log: log.o ${LIBRARIES}
68         ${CC} -o log log.o ${LIBRARIES} ${XLIBS} ${CFLAGS}
69
70 unlog: unlog.o ${LIBRARIES}
71         ${CC} -o unlog unlog.o ${LIBRARIES} ${XLIBS} ${CFLAGS}
72
73 passwd: passwd.o ${LIBRARIES}
74         ${CC} -o passwd passwd.o ${LIBRARIES} ${XLIBS} ${CFLAGS}
75
76 tokens: tokens.o ${LIBRARIES}
77         ${CC} -o tokens tokens.o ${LIBRARIES} ${XLIBS} ${CFLAGS}
78
79 tokens.krb: tokens.o ${KLIBRARIES}
80         ${CC} -o tokens.krb tokens.o ${KLIBRARIES} ${XLIBS} ${CFLAGS}
81
82 # objects
83
84 kseal.o:                kseal.c ${INCLS} AFS_component_version_number.c
85 unlog.o:                unlog.c AFS_component_version_number.c
86 tokens.o:               tokens.c ${SRCDIR}include/rx/xdr.h AFS_component_version_number.c
87 #log.o:         log.c ${SRCDIR}include/afs/comauth.h ${SRCDIR}include/r/xdr.h
88 #passwd.o:      passwd.c ${SRCDIR}include/afs/comauth.h ${SRCDIR}include/r/xdr.h ${SRCDIR}include/r/r.h
89
90 test:
91         cd test; $(MAKE)