Commit | Line | Data |
---|---|---|
805e021f CE |
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 | srcdir=@srcdir@ | |
9 | include @TOP_OBJDIR@/src/config/Makefile.config | |
10 | include @TOP_OBJDIR@/src/config/Makefile.lwp | |
11 | include @TOP_OBJDIR@/src/config/Makefile.lwptool | |
12 | ||
13 | BASE_objs= cellconfig.lo keys.lo userok.lo writeconfig.lo authcon.lo \ | |
14 | acfg_errors.lo ktc_errors.lo netrestrict.lo token.xdr.lo token.lo \ | |
15 | realms.lo | |
16 | ||
17 | LT_objs= ktc.lo $(BASE_objs) | |
18 | KRB_objs = ktc.krb.lo $(BASE_objs) | |
19 | ||
20 | LT_deps= $(top_builddir)/src/opr/liboafs_opr.la \ | |
21 | $(top_builddir)/src/comerr/liboafs_comerr.la \ | |
22 | $(top_builddir)/src/rx/liboafs_rx.la \ | |
23 | $(top_builddir)/src/rxkad/liboafs_rxkad.la \ | |
24 | $(top_builddir)/src/audit/liboafs_audit.la \ | |
25 | $(top_builddir)/src/util/liboafs_util.la \ | |
26 | $(top_builddir)/src/sys/liboafs_sys.la | |
27 | ||
28 | LT_libs= $(LDFLAGS_roken) $(LIB_roken) | |
29 | ||
30 | LIBS=libauth.a \ | |
31 | ${TOP_LIBDIR}/librxkad.a \ | |
32 | ${TOP_LIBDIR}/libafsrfc3961.a \ | |
33 | ${TOP_LIBDIR}/librx.a \ | |
34 | ${TOP_LIBDIR}/libsys.a \ | |
35 | ${TOP_LIBDIR}/liblwp.a \ | |
36 | ${TOP_LIBDIR}/util.a | |
37 | ||
38 | INCLS=cellconfig.h auth.h keys.h internal.h token.h | |
39 | ||
40 | all: liboafs_auth.la libauth_pic.la libpam_auth.la \ | |
41 | ${TOP_LIBDIR}/libauth.a ${TOP_LIBDIR}/libauth.krb.a \ | |
42 | depinstall | |
43 | ||
44 | depinstall: ${TOP_INCDIR}/afs/keys.h \ | |
45 | ${TOP_INCDIR}/afs/cellconfig.h \ | |
46 | ${TOP_INCDIR}/afs/auth.h \ | |
47 | ${TOP_INCDIR}/afs/ktc.h \ | |
48 | ${TOP_INCDIR}/afs/token.h \ | |
49 | token.h \ | |
50 | Ktoken.xdr.c \ | |
51 | token.xdr.c | |
52 | ||
53 | ${TOP_INCDIR}/afs/token.h: token.h | |
54 | ${INSTALL_DATA} $? $@ | |
55 | ||
56 | generated: acfg_errors.c cellconfig.h ktc_errors.c auth.h | |
57 | ||
58 | ${TOP_INCDIR}/afs/keys.h: keys.h | |
59 | ${INSTALL_DATA} $? $@ | |
60 | ||
61 | ${TOP_INCDIR}/afs/cellconfig.h: cellconfig.h | |
62 | ${INSTALL_DATA} cellconfig.h $@ | |
63 | ||
64 | ${TOP_INCDIR}/afs/auth.h: auth.h | |
65 | ${INSTALL_DATA} $? $@ | |
66 | ||
67 | ${TOP_INCDIR}/afs/ktc.h: ktc.h | |
68 | ${INSTALL_DATA} $? $@ | |
69 | ||
70 | ${TOP_LIBDIR}/libauth.a: libauth.a | |
71 | ${INSTALL_DATA} libauth.a $@ | |
72 | ||
73 | ${TOP_LIBDIR}/libauth.krb.a: libauth.krb.a | |
74 | ${INSTALL_DATA} libauth.krb.a $@ | |
75 | ||
76 | cellconfig.lo: cellconfig.c ${INCLS} | |
77 | keys.lo: keys.c ${INCLS} | |
78 | ktc.lo: ktc.c ${INCLS} ${TOP_INCDIR}/afs/vice.h | |
79 | writeconfig.lo: writeconfig.c ${INCLS} | |
80 | authcon.lo: authcon.c ${INCLS} | |
81 | userok.lo: userok.c ${INCLS} | |
82 | cellconfig.lo: cellconfig.c ${INCLS} | |
83 | realms.lo: realms.c ${INCLS} | |
84 | netrestrict.lo: ${INCLS} | |
85 | ||
86 | copyauth.o: copyauth.c ${INCLS} AFS_component_version_number.o | |
87 | setkey.o: setkey.c ${INCLS} AFS_component_version_number.o | |
88 | ||
89 | $(LT_objs): $(INCLS) | |
90 | ||
91 | CFLAGS_ktc.krb.lo = -DAFS_KERBEROS_ENV | |
92 | ktc.krb.lo: ktc.c ${INCLS} ${TOP_INCDIR}/afs/vice.h | |
93 | $(LTLWP_CCRULE) $(srcdir)/ktc.c | |
94 | ||
95 | libauth.a: $(LT_objs) | |
96 | $(LT_LDLIB_lwp) $(LT_objs) | |
97 | ||
98 | libauth.krb.a: $(KRB_objs) | |
99 | $(LT_LDLIB_lwp) $(KRB_objs) | |
100 | ||
101 | liboafs_auth.la: liboafs_auth.la.sym $(LT_objs) $(LT_deps) | |
102 | $(LT_LDLIB_shlib) $(LT_objs) $(LT_deps) $(LT_libs) | |
103 | ||
104 | libauth_pic.la: $(LT_objs) | |
105 | $(LT_LDLIB_pic) $(LT_objs) | |
106 | ||
107 | libpam_auth.la: $(BASE_objs) | |
108 | $(LT_LDLIB_pic) $(BASE_objs) | |
109 | ||
110 | copyauth: copyauth.o ${LIBS} | |
111 | $(AFS_LDRULE) copyauth.o ${LIBS} ${XLIBS} | |
112 | ||
113 | setkey: setkey.o ${LIBS} | |
114 | $(AFS_LDRULE) setkey.o ${LIBS} ${XLIBS} | |
115 | ||
116 | acfg_errors.c: acfg_errors.et | |
117 | ${COMPILE_ET_C} -p ${srcdir} acfg_errors | |
118 | ||
119 | cellconfig.h: acfg_errors.et cellconfig.p.h | |
120 | ${COMPILE_ET_H} -p ${srcdir} acfg_errors -h cellconfig | |
121 | ||
122 | authcon.lo: cellconfig.h | |
123 | cellconfig.lo: cellconfig.h | |
124 | copyauth.o: cellconfig.h | |
125 | keys.lo: cellconfig.h | |
126 | ktc.lo: cellconfig.h | |
127 | netrestrict.lo: cellconfig.h | |
128 | realms.lo: cellconfig.h | |
129 | setkey.o: cellconfig.h | |
130 | userok.lo: cellconfig.h | |
131 | writeconfig.lo: cellconfig.h | |
132 | ||
133 | ktc_errors.c: ktc_errors.et | |
134 | ${COMPILE_ET_C} -p ${srcdir} ktc_errors | |
135 | ||
136 | auth.h: ktc_errors.et auth.p.h | |
137 | ${COMPILE_ET_H} -p ${srcdir} ktc_errors -h auth | |
138 | ||
139 | authcon.lo: auth.h | |
140 | copyauth.o: auth.h | |
141 | ktc.lo: auth.h | |
142 | token.lo: auth.h | |
143 | userok.lo: auth.h | |
144 | ||
145 | Ktoken.xdr.c: token.xg | |
146 | $(RXGEN) -A -x -k -c -o $@ $(srcdir)/token.xg | |
147 | ||
148 | token.xdr.c: token.xg | |
149 | $(RXGEN) -A -x -c -o $@ ${srcdir}/token.xg | |
150 | ||
151 | token.h : token.xg | |
152 | $(RXGEN) -A -x -h -o $@ ${srcdir}/token.xg | |
153 | ||
154 | # | |
155 | # Install targets | |
156 | # | |
157 | install: libauth.a libauth.krb.a auth.h cellconfig.h | |
158 | ${INSTALL} -d ${DESTDIR}${libdir}/afs | |
159 | ${INSTALL} -d ${DESTDIR}${includedir}/afs | |
160 | ${INSTALL_DATA} libauth.a ${DESTDIR}${libdir}/afs/libauth.a | |
161 | ${INSTALL_DATA} libauth.krb.a ${DESTDIR}${libdir}/afs/libauth.krb.a | |
162 | ${INSTALL_DATA} ${srcdir}/keys.h ${DESTDIR}${includedir}/afs/keys.h | |
163 | ${INSTALL_DATA} cellconfig.h ${DESTDIR}${includedir}/afs/cellconfig.h | |
164 | ${INSTALL_DATA} auth.h ${DESTDIR}${includedir}/afs/auth.h | |
165 | ${INSTALL_DATA} ${srcdir}/ktc.h ${DESTDIR}${includedir}/afs/ktc.h | |
166 | ||
167 | dest: libauth.a libauth.krb.a auth.h cellconfig.h | |
168 | ${INSTALL} -d ${DEST}/lib/afs | |
169 | ${INSTALL} -d ${DEST}/include/afs | |
170 | ${INSTALL_DATA} libauth.a ${DEST}/lib/afs/libauth.a | |
171 | ${INSTALL_DATA} libauth.krb.a ${DEST}/lib/afs/libauth.krb.a | |
172 | ${INSTALL_DATA} ${srcdir}/keys.h ${DEST}/include/afs/keys.h | |
173 | ${INSTALL_DATA} cellconfig.h ${DEST}/include/afs/cellconfig.h | |
174 | ${INSTALL_DATA} auth.h ${DEST}/include/afs/auth.h | |
175 | ${INSTALL_DATA} ${srcdir}/ktc.h ${DEST}/include/afs/ktc.h | |
176 | ||
177 | # | |
178 | # Misc. targets | |
179 | # | |
180 | test: | |
181 | cd test; $(MAKE) | |
182 | ||
183 | clean: | |
184 | $(LT_CLEAN) | |
185 | $(RM) -f *.o *.a copyauth setkey auth.h cellconfig.h acfg_errors.c \ | |
186 | ktc_errors.c token.h token.xdr.c core Ktoken.xdr.c \ | |
187 | AFS_component_version_number.c | |
188 | ||
189 | include ../config/Makefile.version |