bf600006fdfdf9d27f87bc82afb81c1a61344755
[openafs.git] / src / afsd / Makefile.in
1 ##XLATE_MANUAL##
2 # Copyright 2000, International Business Machines Corporation and others.
3 # All Rights Reserved.
4
5 # This software has been released under the terms of the IBM Public
6 # License.  For details, see the LICENSE file in the top-level source
7 # directory or online at http://www.openafs.org/dl/license10.html
8
9 srcdir=@srcdir@
10 include @TOP_OBJDIR@/src/config/Makefile.config
11 INSTALL = @INSTALL@
12 INSTALL_DATA = @INSTALL_DATA@
13 INSTALL_PROGRAM = @INSTALL_PROGRAM@
14 INSTALL_SCRIPT = @INSTALL_SCRIPT@
15
16 LDFLAGS = ${XLDFLAGS} ${ARCHFLAGS}
17
18 #
19 # What to make
20 #
21 all: afsd vsys
22
23 #
24 # Programs
25 #
26
27 AFSLIBS=${TOP_LIBDIR}/libauth.a ${TOP_LIBDIR}/libcmd.a ${TOP_LIBDIR}/libsys.a ${TOP_LIBDIR}/util.a ${TOP_LIBDIR}/librx.a ${TOP_LIBDIR}/liblwp.a ${TOP_LIBDIR}/util.a
28
29 afsd: afsd.o $(AFSLIBS) $(AFSD_LIBS)
30         ${CC} ${CFLAGS} -o afsd afsd.o @CFLAGS_NOERROR@ $(NON_SHARED) $(LDFLAGS) $(AFSD_LDFLAGS) $(AFSLIBS) ${XLIBS} ${AFSD_LIBS}
31
32 vsys: vsys.o
33         ${CC} ${CFLAGS} -o vsys vsys.o ${TOP_LIBDIR}/libsys.a $(LDFLAGS) ${XLIBS}
34
35 #
36 # Objects
37 #
38 afsd.o: afsd.c AFS_component_version_number.c
39         $(CC) $(CFLAGS) @CFLAGS_NOERROR@ -c $<
40
41 vsys.o: vsys.c AFS_component_version_number.c
42
43 clean:
44         $(RM) -f *.o vsys afsd core AFS_component_version_number.c
45
46 system: install
47
48 # XXX-INST: where to put the rc scripts?
49 install: afsd vsys
50         ${INSTALL} -d ${DESTDIR}${sbindir}
51         ${INSTALL} afsd ${DESTDIR}${sbindir}/afsd
52         ${INSTALL} vsys ${DESTDIR}${sbindir}/vsys
53
54 dest: afsd vsys
55         ${INSTALL} -d ${DEST}/root.client/usr/vice/etc
56         ${INSTALL} -d ${DEST}/etc
57         ${INSTALL} afsd ${DEST}/root.client/usr/vice/etc/afsd
58         ${INSTALL} vsys ${DEST}/etc/vsys
59         case ${SYS_NAME} in \
60                 rs_aix*)  \
61                         ${INSTALL} -d ${DEST}/root.client/usr/vice/etc/dkload ; \
62                         ${INSTALL_SCRIPT} ${srcdir}/rc.afs.rs_aix ${DEST}/root.client/usr/vice/etc/dkload/rc.afs ; \
63                         ${INSTALL_SCRIPT} ${srcdir}/rc.dkload.client.rs_aix ${DEST}/root.client/usr/vice/etc/dkload/rc.dkload.client ; \
64                         ${INSTALL_SCRIPT} ${srcdir}/rc.dkload.server.rs_aix ${DEST}/root.client/usr/vice/etc/dkload/rc.dkload.server ;; \
65                 sgi_65 ) \
66                         ${INSTALL} -d ${DEST}/root.client/usr/vice/etc/sgiload ; \
67                         ${INSTALL} -d ${DEST}/root.server/etc/init.d ; \
68                         ${INSTALL_SCRIPT} ${srcdir}/afs.rc.sgi_ipnos ${DEST}/root.client/usr/vice/etc/sgiload/afs.rc ;\
69                         ${INSTALL_SCRIPT} ${srcdir}/afs.rc.sgi_ipnos ${DEST}/root.server/etc/init.d/afs.rc ;;\
70                 sgi_* ) \
71                         ${INSTALL} -d ${DEST}/root.client/usr/vice/etc/sgiload ; \
72                         ${INSTALL} -d ${DEST}/root.server/etc/init.d ; \
73                         ${INSTALL_SCRIPT} ${srcdir}/afs.rc.sgi ${DEST}/root.client/usr/vice/etc/sgiload/afs.rc ;\
74                         ${INSTALL_SCRIPT} ${srcdir}/afs.rc.sgi ${DEST}/root.server/etc/init.d/afs.rc ;\
75                         case ${SYS_NAME} in \
76                                 sgi_53 | sgi_61 ) \
77                                 ${INSTALL_SCRIPT} ${srcdir}/afs_rtsymtab.pl.${SYS_NAME} ${DEST}/root.client/usr/vice/etc/sgiload/afs_rtsymtab.pl ;;\
78                         esac;; \
79                 sun4_52 | sun4_53 | sun4c_52 | sun4c_53 | sun4m_52 | sun4m_53 | sun4m_54 | sun4_54 | sun4c_54 | sunx86_54) \
80                         ${INSTALL} -d ${DEST}/root.client/usr/vice/etc/modload ; \
81                         ${INSTALL_SCRIPT} ${srcdir}/afs.rc.solaris ${DEST}/root.client/usr/vice/etc/modload/afs.rc ;;\
82                 sun*_57 ) \
83                         ${INSTALL} -d ${DEST}/root.client/usr/vice/etc/modload ; \
84                         ${INSTALL_SCRIPT} ${srcdir}/afs.rc.solaris.2.7 ${DEST}/root.client/usr/vice/etc/modload/afs.rc ;;\
85                 sun*_58 ) \
86                         ${INSTALL} -d ${DEST}/root.client/usr/vice/etc/modload ; \
87                         ${INSTALL_SCRIPT} ${srcdir}/afs.rc.solaris.2.8 ${DEST}/root.client/usr/vice/etc/modload/afs.rc ;;\
88                 sun*_59 | sun*_510 ) \
89                         ${INSTALL} -d ${DEST}/root.client/usr/vice/etc/modload ; \
90                         ${INSTALL_SCRIPT} ${srcdir}/afs.rc.solaris.2.9 ${DEST}/root.client/usr/vice/etc/modload/afs.rc ;;\
91                 sun4x_5? ) \
92                         ${INSTALL} -d ${DEST}/root.client/usr/vice/etc/modload ; \
93                         ${INSTALL_SCRIPT} ${srcdir}/afs.rc.solaris.2_5 ${DEST}/root.client/usr/vice/etc/modload/afs.rc ;;\
94                 alpha_osf* ) \
95                         ${INSTALL} -d ${DEST}/root.client/usr/vice/etc/dkload ; \
96                         ${INSTALL_SCRIPT} ${srcdir}/afs.rc.alpha ${DEST}/root.client/usr/vice/etc/dkload/afs.rc ;;\
97                 hp_ux1122 ) \
98                         ${INSTALL} -d ${DEST}/root.client/usr/vice/etc/dkload ; \
99                         ${INSTALL_SCRIPT} ${srcdir}/afs.rc.hpux10 ${DEST}/root.client/usr/vice/etc/dkload/afs.rc ;\
100                         ${INSTALL_DATA} ${srcdir}/afs.hpux1122.driver ${DEST}/root.client/usr/vice/etc/afs.driver ;;\
101                 hp_ux10? | hp_ux11? ) \
102                         ${INSTALL} -d ${DEST}/root.client/usr/vice/etc/dkload ; \
103                         ${INSTALL_SCRIPT} ${srcdir}/afs.rc.hpux10 ${DEST}/root.client/usr/vice/etc/dkload/afs.rc ;\
104                         ${INSTALL_DATA} ${srcdir}/afs.hpux102.driver ${DEST}/root.client/usr/vice/etc/afs.driver ;;\
105                 alpha_dux* ) \
106                         ${INSTALL} -d ${DEST}/root.client/usr/vice/etc/dkload ; \
107                         ${INSTALL_SCRIPT} ${srcdir}/afs.rc.alpha_dux40 ${DEST}/root.client/usr/vice/etc/dkload/afs.rc ;;\
108                 hp?00_ux10? ) \
109                         ${INSTALL} -d ${DEST}/root.client/usr/vice/etc/dkload ; \
110                         ${INSTALL_SCRIPT} ${srcdir}/afs.rc.hpux10 ${DEST}/root.client/usr/vice/etc/dkload/afs.rc ;;\
111                 *linux* ) \
112                         ${INSTALL} -d ${DEST}/root.client/usr/vice/etc ; \
113                         ${INSTALL_SCRIPT} -m 755 ${srcdir}/afs.rc.linux ${DEST}/root.client/usr/vice/etc/afs.rc; \
114                         ${INSTALL_DATA} ${srcdir}/afs.conf.linux ${DEST}/root.client/usr/vice/etc/afs.conf ;; \
115                 *_darwin*) \
116                         ${INSTALL} -d ${DEST}/root.client/usr/vice/etc ; \
117                         ${INSTALL_SCRIPT} -m 755 ${srcdir}/afs.rc.darwin ${DEST}/root.client/usr/vice/etc/afs.rc ; \
118                         ${INSTALL_DATA} ${srcdir}/afs.rc.darwin.plist ${DEST}/root.client/usr/vice/etc/StartupParameters.plist ;; \
119                 *fbsd*) \
120                         ${INSTALL} -d ${DEST}/root.client/usr/vice/etc ; \
121                         ${INSTALL_SCRIPT} ${srcdir}/afs.rc.fbsd ${DEST}/root.client/usr/vice/etc/afs.rc.fbsd ;; \
122                 * )  \
123                         echo No rc scripts installed for ${SYS_NAME} ;; \
124         esac
125
126 include ../config/Makefile.version