make-install-support-for-transarc-and-prefix-style-universes-20010907
[openafs.git] / src / rsh / Makefile.in
1 #
2 # Copyright (c) 1988 Regents of the University of California.
3 # All rights reserved.
4 #
5 # Redistribution and use in source and binary forms are permitted
6 # provided that the above copyright notice and this paragraph are
7 # duplicated in all such forms and that any documentation, advertising
8 # materials, and other materials related to such redistribution and
9 # use acknowledge that the software was developed by the University
10 # of California, Berkeley.  The name of the University may not be
11 # used to endorse or promote products derived from this software
12 # without specific prior written permission.  THIS SOFTWARE IS PROVIDED
13 # ``AS IS'' AND WITHOUT ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING,
14 # WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF MERCHANTIBILITY AND
15 # FITNESS FOR A PARTICULAR PURPOSE.
16 #
17 # @(#)Makefile  5.1 (Berkeley) 9/20/88
18 #
19 DEST=@DEST@
20 TOP_INCDIR=@TOP_INCDIR@
21 TOP_LIBDIR=@TOP_LIBDIR@
22 prefix=@prefix@
23 exec_prefix=@exec_prefix@
24 bindir=@bindir@
25 sbindir=@sbindir@
26 libexecdir=@libexecdir@
27 libdir=@libdir@
28 includedir=@includedir@
29 mandir=@mandir@
30 afssrvbindir=@afssrvbindir@
31 afssrvsbindir=@afssrvsbindir@
32 afssrvlibexecdir=@afssrvlibexecdir@
33 COMPILE_ET=${TOP_SRCDIR}/comerr/compile_et
34 RXGEN=${TOP_SRCDIR}/rxgen/rxgen
35 TOP_SRCDIR=@TOP_SRCDIR@
36 SYS_NAME=@AFS_SYSNAME@
37
38 SHELL=/bin/sh
39
40 include ../config/Makefile.${SYS_NAME}
41
42 INCLUDES=-I${TOP_SRCDIR}/config -I${TOP_INCDIR}
43 CFLAGS= ${DBUG} ${INCLUDES} ${XCFLAGS}
44 LIBC=   /lib/libc.a
45 OBJS=   rcmd.o ../inetd/ta-rauth.o herror.o
46 MAN=    
47 SRCS=   rsh.c rcmd.c ../inetd/ta-rauth.c herror.c AFS_component_version_number.c
48 AFSLIBS = ${TOP_LIBDIR}/libkauth.a ${TOP_LIBDIR}/libubik.a \
49           ${TOP_LIBDIR}/libauth.a ${TOP_LIBDIR}/libsys.a \
50           ${TOP_LIBDIR}/librx.a ${TOP_LIBDIR}/liblwp.a \
51           ${TOP_LIBDIR}/librxkad.a ${TOP_LIBDIR}/libsys.a \
52           ${TOP_LIBDIR}/libdes.a ${TOP_LIBDIR}/libcmd.a \
53           ${TOP_LIBDIR}/libcom_err.a ${TOP_LIBDIR}/util.a
54 LIBS = ${AFSLIBS} 
55
56 include ../config/Makefile.version
57
58 all: rsh
59
60 rsh: rsh.o ${OBJS} ${LIBS}
61         ${CC} -o $@ ${CFLAGS} rsh.o ${OBJS} ${LIBS} ${XLIBS}
62
63 rlogin: rlogin.o ${OBJS} ${LIBS}
64         ${CC} -o $@ ${CFLAGS} rlogin.o ${OBJS} ${LIBS} ${XLIBS}
65
66 rlogin.o: rlogin.c AFS_component_version_number.c
67 rsh.o: rsh.c AFS_component_version_number.c
68
69 ../rlogind/herror.o: ../rlogind/herror.c
70         (cd ../rlogind ; $(MAKE) herror.o )
71 ../inetd/ta-rauth.o : ../inetd/ta-rauth.c
72         (cd ../inetd ; $(MAKE) ta-rauth.o DESTDIR=${DESTDIR})
73
74 clean:
75         $(RM) -f ${OBJS} core rsh *.BAK AFS_component_version_number.c rlogin rlogin.o rsh.o
76
77 cleandir: clean
78         $(RM) -f ${MAN} tags .depend
79
80 depend: ${SRCS}
81         mkdep -p ${CFLAGS} ${SRCS}
82
83 install: rsh
84         set -x; \
85         case "${SYS_NAME}" in \
86         hp* ) \
87                 ${INSTALL} -m 4755 -f rsh ${DESTDIR}${bindir}/remsh ;; \
88         * ) \
89                 ${INSTALL} -m 4755 rsh ${DESTDIR}${bindir}/rsh ;; \
90         esac
91
92 dest: rsh
93         set -x; \
94         case "${SYS_NAME}" in \
95         hp* ) \
96                 ${INSTALL} -m 4755 -f rsh ${DEST}/bin/remsh ;; \
97         * ) \
98                 ${INSTALL} -m 4755 rsh ${DEST}/bin/rsh ;; \
99         esac