introduce-autoconf-for-openafs-20010628
[openafs.git] / src / sgistuff / 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 SHELL=/bin/sh
9 #
10 # This must be built after inetd has built ta-rauth.o and after rsh
11 # XXX want these to end up in /usr/afsws ...
12 # Note that if afskauthlib.so gets installed on a client
13 # machine then that will be used ..
14 #
15 include ../config/Makefile.${SYS_NAME}
16 OPTIMIZE=-g
17 CFLAGS = ${OPTIMIZE} -I${SRCDIR}include ${XCFLAGS}
18 LDFLAGS = ${OPTIMIZE} ${XLDFLAGS}
19 LIBDIR = ${DESTDIR}lib/
20 AFSLIBS = ${LIBDIR}afs/libkauth.a ${LIBDIR}afs/libprot.a ${LIBDIR}libubik.a \
21           ${LIBDIR}afs/libauth.a ${DESTDIR}lib/librxkad.a ${LIBDIR}afs/libsys.a \
22           ${DESTDIR}lib/libdes.a ${LIBDIR}librx.a ${LIBDIR}liblwp.a \
23           ${LIBDIR}afs/libcmd.a ${LIBDIR}afs/libcom_err.a ${LIBDIR}afs/util.a
24 KAFSLIBS = ${LIBDIR}afs/libkauth.krb.a ${LIBDIR}afs/libprot.a ${LIBDIR}libubik.a \
25           ${LIBDIR}afs/libauth.krb.a ${DESTDIR}lib/librxkad.a ${LIBDIR}afs/libsys.a \
26           ${DESTDIR}lib/libdes.a ${LIBDIR}librx.a ${LIBDIR}liblwp.a \
27           ${LIBDIR}afs/libcmd.a ${LIBDIR}afs/libcom_err.a ${LIBDIR}afs/util.a
28 AUTHFILES=../inetd/ta-rauth.o ../rsh/rcmd.o ../rsh/herror.o
29 AUTHLIBS=afsauthlib.so afskauthlib.so
30 TARGETS=$(AUTHLIBS) 
31
32 default:$(TARGETS)
33         ${INSTALL} afsauthlib.so ${DESTDIR}root.client/usr/vice/etc
34         ${INSTALL} afskauthlib.so ${DESTDIR}root.client/usr/vice/etc
35
36 all:$(TARGETS)
37
38 install install.noversion: all default
39
40 clean:
41         rm -f $(AUTHLIBS) $(AUTHFILES) 
42
43 afsauthlib.so: sgi_auth.o ${AFSLIBS} ${AUTHFILES}
44         $(LD) ${LDFLAGS} -shared -all -o afsauthlib.so sgi_auth.o $(AFSLIBS) ${AUTHFILES}
45
46 afskauthlib.so: sgi_auth.o ${KAFSLIBS} ${AUTHFILES}
47         $(LD) ${LDFLAGS} -shared -all -o afskauthlib.so sgi_auth.o $(KAFSLIBS) ${AUTHFILES}
48
49 ../inetd/ta-rauth.o: ../inetd/ta-rauth.c
50         (cd ../inetd ; $(MAKE) ta-rauth.o )
51
52 ../rsh/rcmd.o: ../rsh/rcmd.c
53         (cd ../rsh ; $(MAKE) rcmd.o )
54
55 ../rsh/herror.o: ../rsh/herror.c
56         (cd ../rsh ; $(MAKE) herror.o )
57
58 sgi_auth.o: sgi_auth.c
59         ${CC} ${CFLAGS} -c sgi_auth.c