4 # Don't build sample by default, and definitely don't install them
6 # plugins/locate/python
8 # plugins/preauth/cksum_body
9 SUBDIRS=util include lib \
14 plugins/kadm5_hook/test \
15 plugins/kadm5_auth/test \
16 plugins/hostrealm/test \
17 plugins/localauth/test \
19 plugins/authdata/greet_server \
20 plugins/authdata/greet_client \
21 plugins/certauth/test \
26 plugins/kdcpolicy/test \
28 plugins/preauth/pkinit \
29 plugins/preauth/spake \
30 plugins/preauth/test \
32 kdc kadmin kprop clients appl tests \
33 config-files build-tools man doc @po@
34 WINSUBDIRS=include util lib ccapi windows clients appl plugins\preauth\spake
40 # Why aren't these flags showing up in Windows builds?
41 ##DOS##CPPFLAGS=$(CPPFLAGS) -D_X86_=1 -DWIN32 -D_WIN32 -W3 -D_WINNT
43 # Lots of things will start to depend on the thread support, which
44 # needs autoconf.h, but building "all" in include requires that util/et
45 # have been built first. Until we can untangle this, let's just check
46 # that autoconf.h is up to date before going into any of the subdirectories.
47 all-prerecurse generate-files-mac-prerecurse: update-autoconf-h
49 (cd include && $(MAKE) autoconf.h osconf.h)
52 # This makefile doesn't use lib.in, but we still need shlib.conf here.
53 config.status: $(top_srcdir)/config/shlib.conf
56 all-windows: maybe-awk Makefile-windows
63 INSTALLMKDIRS = $(KRB5ROOT) $(KRB5MANROOT) $(KRB5OTHERMKDIRS) \
64 $(ADMIN_BINDIR) $(SERVER_BINDIR) $(CLIENT_BINDIR) \
65 $(ADMIN_MANDIR) $(SERVER_MANDIR) $(CLIENT_MANDIR) \
66 $(FILE_MANDIR) $(OVERVIEW_MANDIR) \
67 $(ADMIN_CATDIR) $(SERVER_CATDIR) $(CLIENT_CATDIR) \
68 $(FILE_CATDIR) $(OVERVIEW_CATDIR) \
69 $(KRB5_LIBDIR) $(KRB5_INCDIR) \
70 $(KRB5_DB_MODULE_DIR) $(KRB5_PA_MODULE_DIR) \
71 $(KRB5_AD_MODULE_DIR) \
72 $(KRB5_LIBKRB5_MODULE_DIR) $(KRB5_TLS_MODULE_DIR) \
73 @localstatedir@ @localstatedir@/krb5kdc \
74 @runstatedir@ @runstatedir@/krb5kdc \
75 $(KRB5_INCSUBDIRS) $(datadir) $(EXAMPLEDIR) \
79 $(MAKE) install INSTALL_STRIP=-s
81 install-recurse: install-mkdirs
84 @for i in $(INSTALLMKDIRS); do \
85 $(srcdir)/config/mkinstalldirs $(DESTDIR)$$i; \
88 install-headers-mkdirs:
89 $(srcdir)/config/mkinstalldirs $(DESTDIR)$(KRB5_INCDIR)
90 $(srcdir)/config/mkinstalldirs $(DESTDIR)$(KRB5_INCDIR)/gssapi
91 $(srcdir)/config/mkinstalldirs $(DESTDIR)$(KRB5_INCDIR)/gssrpc
92 install-headers-prerecurse: install-headers-mkdirs
94 clean-:: clean-windows
96 $(RM) *.o core skiptests
98 # Microsoft Windows build process...
101 config-windows: Makefile-windows
102 # @echo Making in include
108 # We need outpre-dir explicitly in here because we may
109 # try to build wconfig on a config-windows.
111 ##DOS##$(WCONFIG_EXE): outpre-dir wconfig.c
112 ##DOS## $(CC) -Fe$@ -Fo$*.obj wconfig.c $(CCLINKOPTION)
113 ##DOS## $(_VC_MANIFEST_EMBED_EXE)
115 ##DOS##MKFDEP=$(WCONFIG_EXE) config\win-pre.in config\win-post.in
117 WINMAKEFILES=Makefile \
118 appl\Makefile appl\gss-sample\Makefile \
120 ccapi\lib\win\Makefile \
121 ccapi\server\win\Makefile \
122 ccapi\test\Makefile \
123 clients\Makefile clients\kdestroy\Makefile \
124 clients\kinit\Makefile clients\klist\Makefile \
125 clients\kpasswd\Makefile clients\kvno\Makefile \
126 clients\kcpytkt\Makefile clients\kdeltkt\Makefile \
127 clients\kswitch\Makefile \
129 lib\Makefile lib\crypto\Makefile lib\crypto\krb\Makefile \
130 lib\crypto\builtin\Makefile lib\crypto\builtin\aes\Makefile \
131 lib\crypto\builtin\enc_provider\Makefile \
132 lib\crypto\builtin\des\Makefile lib\crypto\builtin\md5\Makefile \
133 lib\crypto\builtin\camellia\Makefile lib\crypto\builtin\md4\Makefile \
134 lib\crypto\builtin\hash_provider\Makefile \
135 lib\crypto\builtin\sha2\Makefile lib\crypto\builtin\sha1\Makefile \
136 lib\crypto\crypto_tests\Makefile \
137 lib\gssapi\Makefile lib\gssapi\generic\Makefile \
138 lib\gssapi\krb5\Makefile lib\gssapi\mechglue\Makefile \
139 lib\gssapi\spnego\Makefile \
141 lib\krb5\asn.1\Makefile lib\krb5\ccache\Makefile \
142 lib\krb5\ccache\ccapi\Makefile \
143 lib\krb5\error_tables\Makefile \
144 lib\krb5\keytab\Makefile \
145 lib\krb5\krb\Makefile \
146 lib\krb5\os\Makefile lib\krb5\posix\Makefile \
147 lib\krb5\rcache\Makefile \
148 lib\krb5\unicode\Makefile \
150 util\et\Makefile util\profile\Makefile util\profile\testmod\Makefile \
151 util\support\Makefile \
152 util\windows\Makefile \
153 windows\Makefile windows\lib\Makefile windows\ms2mit\Makefile \
154 windows\kfwlogon\Makefile windows\leashdll\Makefile \
155 windows\leash\Makefile windows\leash\htmlhelp\Makefile \
156 plugins\preauth\spake\Makefile
158 ##DOS##Makefile-windows: $(MKFDEP) $(WINMAKEFILES)
160 ##DOS##Makefile: Makefile.in $(MKFDEP)
161 ##DOS## $(WCONFIG) config < $@.in > $@
162 ##DOS##appl\Makefile: appl\Makefile.in $(MKFDEP)
163 ##DOS## $(WCONFIG) config < $@.in > $@
164 ##DOS##appl\gss-sample\Makefile: appl\gss-sample\Makefile.in $(MKFDEP)
165 ##DOS## $(WCONFIG) config < $@.in > $@
166 ##DOS##ccapi\Makefile: ccapi\Makefile.in $(MKFDEP)
167 ##DOS## $(WCONFIG) config < $@.in > $@
168 ##DOS##ccapi\lib\win\Makefile: ccapi\lib\win\Makefile.in $(MKFDEP)
169 ##DOS## $(WCONFIG) config < $@.in > $@
170 ##DOS##ccapi\server\win\Makefile: ccapi\server\win\Makefile.in $(MKFDEP)
171 ##DOS## $(WCONFIG) config < $@.in > $@
172 ##DOS##ccapi\test\Makefile: ccapi\test\Makefile.in $(MKFDEP)
173 ##DOS## $(WCONFIG) config < $@.in > $@
174 ##DOS##clients\Makefile: clients\Makefile.in $(MKFDEP)
175 ##DOS## $(WCONFIG) config < $@.in > $@
176 ##DOS##clients\kdestroy\Makefile: clients\kdestroy\Makefile.in $(MKFDEP)
177 ##DOS## $(WCONFIG) config < $@.in > $@
178 ##DOS##clients\kinit\Makefile: clients\kinit\Makefile.in $(MKFDEP)
179 ##DOS## $(WCONFIG) config < $@.in > $@
180 ##DOS##clients\klist\Makefile: clients\klist\Makefile.in $(MKFDEP)
181 ##DOS## $(WCONFIG) config < $@.in > $@
182 ##DOS##clients\kpasswd\Makefile: clients\kpasswd\Makefile.in $(MKFDEP)
183 ##DOS## $(WCONFIG) config < $@.in > $@
184 ##DOS##clients\kswitch\Makefile: clients\kswitch\Makefile.in $(MKFDEP)
185 ##DOS## $(WCONFIG) config < $@.in > $@
186 ##DOS##clients\kvno\Makefile: clients\kvno\Makefile.in $(MKFDEP)
187 ##DOS## $(WCONFIG) config < $@.in > $@
188 ##DOS##clients\kcpytkt\Makefile: clients\kcpytkt\Makefile.in $(MKFDEP)
189 ##DOS## $(WCONFIG) config < $@.in > $@
190 ##DOS##clients\kdeltkt\Makefile: clients\kdeltkt\Makefile.in $(MKFDEP)
191 ##DOS## $(WCONFIG) config < $@.in > $@
192 ##DOS##include\Makefile: include\Makefile.in $(MKFDEP)
193 ##DOS## $(WCONFIG) config < $@.in > $@
194 ##DOS##lib\Makefile: lib\Makefile.in $(MKFDEP)
195 ##DOS## $(WCONFIG) config < $@.in > $@
196 ##DOS##lib\crypto\Makefile: lib\crypto\Makefile.in $(MKFDEP)
197 ##DOS## $(WCONFIG) config < $@.in > $@
198 ##DOS##lib\crypto\krb\Makefile: lib\crypto\krb\Makefile.in $(MKFDEP)
199 ##DOS## $(WCONFIG) config < $@.in > $@
200 ##DOS##lib\crypto\builtin\aes\Makefile: lib\crypto\builtin\aes\Makefile.in $(MKFDEP)
201 ##DOS## $(WCONFIG) config < $@.in > $@
202 ##DOS##lib\crypto\builtin\enc_provider\Makefile: lib\crypto\builtin\enc_provider\Makefile.in $(MKFDEP)
203 ##DOS## $(WCONFIG) config < $@.in > $@
204 ##DOS##lib\crypto\builtin\des\Makefile: lib\crypto\builtin\des\Makefile.in $(MKFDEP)
205 ##DOS## $(WCONFIG) config < $@.in > $@
206 ##DOS##lib\crypto\builtin\md5\Makefile: lib\crypto\builtin\md5\Makefile.in $(MKFDEP)
207 ##DOS## $(WCONFIG) config < $@.in > $@
208 ##DOS##lib\crypto\builtin\camellia\Makefile: lib\crypto\builtin\camellia\Makefile.in $(MKFDEP)
209 ##DOS## $(WCONFIG) config < $@.in > $@
210 ##DOS##lib\crypto\builtin\md4\Makefile: lib\crypto\builtin\md4\Makefile.in $(MKFDEP)
211 ##DOS## $(WCONFIG) config < $@.in > $@
212 ##DOS##lib\crypto\builtin\hash_provider\Makefile: lib\crypto\builtin\hash_provider\Makefile.in $(MKFDEP)
213 ##DOS## $(WCONFIG) config < $@.in > $@
214 ##DOS##lib\crypto\builtin\sha2\Makefile: lib\crypto\builtin\sha2\Makefile.in $(MKFDEP)
215 ##DOS## $(WCONFIG) config < $@.in > $@
216 ##DOS##lib\crypto\builtin\sha1\Makefile: lib\crypto\builtin\sha1\Makefile.in $(MKFDEP)
217 ##DOS## $(WCONFIG) config < $@.in > $@
218 ##DOS##lib\crypto\builtin\Makefile: lib\crypto\builtin\Makefile.in $(MKFDEP)
219 ##DOS## $(WCONFIG) config < $@.in > $@
220 ##DOS##lib\crypto\crypto_tests\Makefile: lib\crypto\crypto_tests\Makefile.in $(MKFDEP)
221 ##DOS## $(WCONFIG) config < $@.in > $@
222 ##DOS##lib\gssapi\Makefile: lib\gssapi\Makefile.in $(MKFDEP)
223 ##DOS## $(WCONFIG) config < $@.in > $@
224 ##DOS##lib\gssapi\generic\Makefile: lib\gssapi\generic\Makefile.in $(MKFDEP)
225 ##DOS## $(WCONFIG) config < $@.in > $@
226 ##DOS##lib\gssapi\mechglue\Makefile: lib\gssapi\mechglue\Makefile.in $(MKFDEP)
227 ##DOS## $(WCONFIG) config < $@.in > $@
228 ##DOS##lib\gssapi\spnego\Makefile: lib\gssapi\spnego\Makefile.in $(MKFDEP)
229 ##DOS## $(WCONFIG) config < $@.in > $@
230 ##DOS##lib\gssapi\krb5\Makefile: lib\gssapi\krb5\Makefile.in $(MKFDEP)
231 ##DOS## $(WCONFIG) config < $@.in > $@
232 ##DOS##lib\krb5\Makefile: lib\krb5\Makefile.in $(MKFDEP)
233 ##DOS## $(WCONFIG) config < $@.in > $@
234 ##DOS##lib\krb5\asn.1\Makefile: lib\krb5\asn.1\Makefile.in $(MKFDEP)
235 ##DOS## $(WCONFIG) config < $@.in > $@
236 ##DOS##lib\krb5\ccache\Makefile: lib\krb5\ccache\Makefile.in $(MKFDEP)
237 ##DOS## $(WCONFIG) config < $@.in > $@
238 ##DOS##lib\krb5\ccache\ccapi\Makefile: lib\krb5\ccache\ccapi\Makefile.in $(MKFDEP)
239 ##DOS## $(WCONFIG) config < $@.in > $@
240 ##DOS##lib\krb5\error_tables\Makefile: lib\krb5\error_tables\Makefile.in $(MKFDEP)
241 ##DOS## $(WCONFIG) config < $@.in > $@
242 ##DOS##lib\krb5\keytab\Makefile: $$@.in $(MKFDEP)
243 ##DOS## $(WCONFIG) config < $@.in > $@
244 ##DOS##lib\krb5\krb\Makefile: lib\krb5\krb\Makefile.in $(MKFDEP)
245 ##DOS## $(WCONFIG) config < $@.in > $@
246 ##DOS##lib\krb5\os\Makefile: lib\krb5\os\Makefile.in $(MKFDEP)
247 ##DOS## $(WCONFIG) config < $@.in > $@
248 ##DOS##lib\krb5\posix\Makefile: lib\krb5\posix\Makefile.in $(MKFDEP)
249 ##DOS## $(WCONFIG) config < $@.in > $@
250 ##DOS##lib\krb5\rcache\Makefile: lib\krb5\rcache\Makefile.in $(MKFDEP)
251 ##DOS## $(WCONFIG) config < $@.in > $@
252 ##DOS##lib\krb5\unicode\Makefile: lib\krb5\unicode\Makefile.in $(MKFDEP)
253 ##DOS## $(WCONFIG) config < $@.in > $@
254 ##DOS##util\Makefile: util\Makefile.in $(MKFDEP)
255 ##DOS## $(WCONFIG) config < $@.in > $@
256 ##DOS##util\et\Makefile: util\et\Makefile.in $(MKFDEP)
257 ##DOS## $(WCONFIG) config < $@.in > $@
258 ##DOS##util\profile\Makefile: util\profile\Makefile.in $(MKFDEP)
259 ##DOS## $(WCONFIG) config < $@.in > $@
260 ##DOS##util\profile\testmod\Makefile: util\profile\testmod\Makefile.in $(MKFDEP)
261 ##DOS## $(WCONFIG) config < $@.in > $@
262 ##DOS##util\support\Makefile: util\support\Makefile.in $(MKFDEP)
263 ##DOS## $(WCONFIG) config < $@.in > $@
264 ##DOS##util\windows\Makefile: util\windows\Makefile.in $(MKFDEP)
265 ##DOS## $(WCONFIG) config < $@.in > $@
266 ##DOS##windows\Makefile: windows\Makefile.in $(MKFDEP)
267 ##DOS## $(WCONFIG) config < $@.in > $@
268 ##DOS##windows\lib\Makefile: windows\lib\Makefile.in $(MKFDEP)
269 ##DOS## $(WCONFIG) config < $@.in > $@
270 ##DOS##windows\ms2mit\Makefile: windows\ms2mit\Makefile.in $(MKFDEP)
271 ##DOS## $(WCONFIG) config < $@.in > $@
272 ##DOS##windows\kfwlogon\Makefile: windows\kfwlogon\Makefile.in $(MKFDEP)
273 ##DOS## $(WCONFIG) config < $@.in > $@
274 ##DOS##windows\leashdll\Makefile: windows\leashdll\Makefile.in $(MKFDEP)
275 ##DOS## $(WCONFIG) config < $@.in > $@
276 ##DOS##windows\leash\Makefile: windows\leash\Makefile.in $(MKFDEP)
277 ##DOS## $(WCONFIG) config < $@.in > $@
278 ##DOS##windows\leash\htmlhelp\Makefile: windows\leash\htmlhelp\Makefile.in $(MKFDEP)
279 ##DOS## $(WCONFIG) config < $@.in > $@
280 ##DOS##plugins\preauth\spake\Makefile: plugins\preauth\spake\Makefile.in $(MKFDEP)
281 ##DOS## $(WCONFIG) config < $@.in > $@
283 clean-windows:: Makefile-windows
286 # Renames DOS 8.3 filenames back to their proper, longer names.
292 # Helper for the windows build
297 # Building error tables requires awk.
300 AH = util/et/et_h.awk
301 AC = util/et/et_c.awk
303 ET = lib/krb5/error_tables/
304 GG = lib/gssapi/generic/
305 GK = lib/gssapi/krb5/
311 $(INC)asn1_err.h $(ET)asn1_err.c \
312 $(INC)kdb5_err.h $(ET)kdb5_err.c \
313 $(INC)krb5_err.h $(ET)krb5_err.c \
314 $(INC)k5e1_err.h $(ET)k5e1_err.c \
315 $(INC)kv5m_err.h $(ET)kv5m_err.c \
316 $(INC)krb524_err.h $(ET)krb524_err.c \
317 $(PR)prof_err.h $(PR)prof_err.c \
318 $(GG)gssapi_err_generic.h $(GG)gssapi_err_generic.c \
319 $(GK)gssapi_err_krb5.h $(GK)gssapi_err_krb5.c \
320 $(CCL)ccapi_err.h $(CCL)ccapi_err.c
322 HOUT = $(INC)krb5/krb5.h $(GG)gssapi.h $(PR)profile.h
324 CLEANUP= Makefile $(ETOUT) $(HOUT) \
325 include/profile.h include/osconf.h
329 cat config/win-pre.in Makefile.in config/win-post.in | \
330 sed -e "s/^##DOS##//" -e "s/^##DOS//" > Makefile.tmp
331 mv Makefile.tmp Makefile
333 prep-windows: dos-Makefile awk-windows-mac
336 $(INC)asn1_err.h: $(AH) $(ET)asn1_err.et
337 $(AWK) -f $(AH) outfile=$@ $(ET)asn1_err.et
338 $(INC)kdb5_err.h: $(AH) $(ET)kdb5_err.et
339 $(AWK) -f $(AH) outfile=$@ $(ET)kdb5_err.et
340 $(INC)krb5_err.h: $(AH) $(ET)krb5_err.et
341 $(AWK) -f $(AH) outfile=$@ $(ET)krb5_err.et
342 $(INC)k5e1_err.h: $(AH) $(ET)k5e1_err.et
343 $(AWK) -f $(AH) outfile=$@ $(ET)k5e1_err.et
344 $(INC)kv5m_err.h: $(AH) $(ET)kv5m_err.et
345 $(AWK) -f $(AH) outfile=$@ $(ET)kv5m_err.et
346 $(INC)krb524_err.h: $(AH) $(ET)krb524_err.et
347 $(AWK) -f $(AH) outfile=$@ $(ET)krb524_err.et
348 $(PR)prof_err.h: $(AH) $(PR)prof_err.et
349 $(AWK) -f $(AH) outfile=$@ $(PR)prof_err.et
350 $(GG)gssapi_err_generic.h: $(AH) $(GG)gssapi_err_generic.et
351 $(AWK) -f $(AH) outfile=$@ $(GG)gssapi_err_generic.et
352 $(GK)gssapi_err_krb5.h: $(AH) $(GK)gssapi_err_krb5.et
353 $(AWK) -f $(AH) outfile=$@ $(GK)gssapi_err_krb5.et
354 $(CCL)ccapi_err.h: $(AH) $(CCL)ccapi_err.et
355 $(AWK) -f $(AH) outfile=$@ $(CCL)ccapi_err.et
356 $(CE)test1.h: $(AH) $(CE)test1.et
357 $(AWK) -f $(AH) outfile=$@ $(CE)test1.et
358 $(CE)test2.h: $(AH) $(CE)test2.et
359 $(AWK) -f $(AH) outfile=$@ $(CE)test2.et
361 $(ET)asn1_err.c: $(AC) $(ET)asn1_err.et
362 $(AWK) -f $(AC) outfile=$@ $(ET)asn1_err.et
363 $(ET)kdb5_err.c: $(AC) $(ET)kdb5_err.et
364 $(AWK) -f $(AC) outfile=$@ $(ET)kdb5_err.et
365 $(ET)krb5_err.c: $(AC) $(ET)krb5_err.et
366 $(AWK) -f $(AC) outfile=$@ $(ET)krb5_err.et
367 $(ET)k5e1_err.c: $(AC) $(ET)k5e1_err.et
368 $(AWK) -f $(AC) outfile=$@ $(ET)k5e1_err.et
369 $(ET)kv5m_err.c: $(AC) $(ET)kv5m_err.et
370 $(AWK) -f $(AC) outfile=$@ $(ET)kv5m_err.et
371 $(ET)krb524_err.c: $(AC) $(ET)krb524_err.et
372 $(AWK) -f $(AC) outfile=$@ $(ET)krb524_err.et
373 $(PR)prof_err.c: $(AC) $(PR)prof_err.et
374 $(AWK) -f $(AC) outfile=$@ $(PR)prof_err.et
375 $(GG)gssapi_err_generic.c: $(AC) $(GG)gssapi_err_generic.et
376 $(AWK) -f $(AC) outfile=$@ $(GG)gssapi_err_generic.et
377 $(GK)gssapi_err_krb5.c: $(AC) $(GK)gssapi_err_krb5.et
378 $(AWK) -f $(AC) outfile=$@ $(GK)gssapi_err_krb5.et
379 $(CCL)ccapi_err.c: $(AC) $(CCL)ccapi_err.et
380 $(AWK) -f $(AC) outfile=$@ $(CCL)ccapi_err.et
381 $(CE)test1.c: $(AC) $(CE)test1.et
382 $(AWK) -f $(AC) outfile=$@ $(CE)test1.et
383 $(CE)test2.c: $(AC) $(CE)test2.et
384 $(AWK) -f $(AC) outfile=$@ $(CE)test2.et
386 KRBHDEP = $(INC)krb5/krb5.hin $(INC)krb5_err.h $(INC)k5e1_err.h \
387 $(INC)kdb5_err.h $(INC)kv5m_err.h $(INC)krb524_err.h $(INC)asn1_err.h
389 $(INC)krb5/krb5.h: $(KRBHDEP)
392 $(PR)profile.h: $(PR)profile.hin $(PR)prof_err.h
394 cat $(PR)profile.hin $(PR)prof_err.h > $@
395 $(GG)gssapi.h: $(GG)gssapi.hin
397 cat $(GG)gssapi.hin > $@
399 awk-windows-mac: $(ETOUT) $(HOUT)
402 # The maybe-awk target needs to happen after AWK is defined.
406 ##DOS##!ifdef WHICH_CMD
407 ##DOS##!if ![ $(WHICH_CMD) $(AWK) ]
408 ##DOS##maybe-awk: awk-windows-mac
416 config\rm.bat $(CLEANUP:^/=^\)
417 config\rm.bat $(WINMAKEFILES)
418 config\rm.bat $(KBINDIR)\*.dll $(KBINDIR)\*.exe
419 @if exist $(KBINDIR)\nul rmdir $(KBINDIR)
421 # Avoid using $(CP) here because the nul+ hack breaks implicit
422 # destination filenames.
424 @if "$(KRB_INSTALL_DIR)"=="" @echo KRB_INSTALL_DIR is not defined! Please define it.
425 @if "$(KRB_INSTALL_DIR)"=="" @dir /b \nul\nul
426 @if not exist "$(KRB_INSTALL_DIR)\$(NULL)" @echo The directory $(KRB_INSTALL_DIR) does not exist. Please create it.
427 @if not exist "$(KRB_INSTALL_DIR)\$(NULL)" @dir /b $(KRB_INSTALL_DIR)\nul
428 @if not exist "$(KRB_INSTALL_DIR)\include\$(NULL)" @mkdir "$(KRB_INSTALL_DIR)\include"
429 @if not exist "$(KRB_INSTALL_DIR)\include\krb5\$(NULL)" @mkdir "$(KRB_INSTALL_DIR)\include\krb5"
430 @if not exist "$(KRB_INSTALL_DIR)\include\gssapi\$(NULL)" @mkdir "$(KRB_INSTALL_DIR)\include\gssapi"
431 @if not exist "$(KRB_INSTALL_DIR)\lib\$(NULL)" @mkdir "$(KRB_INSTALL_DIR)\lib"
432 @if not exist "$(KRB_INSTALL_DIR)\bin\$(NULL)" @mkdir "$(KRB_INSTALL_DIR)\bin"
433 @if not exist "$(KRB_INSTALL_DIR)\bin\plugins\$(NULL)" @mkdir "$(KRB_INSTALL_DIR)\bin\plugins"
434 @if not exist "$(KRB_INSTALL_DIR)\bin\plugins\preauth\$(NULL)" @mkdir "$(KRB_INSTALL_DIR)\bin\plugins\preauth"
435 copy include\krb5.h "$(KRB_INSTALL_DIR)\include\."
436 copy include\krb5\krb5.h "$(KRB_INSTALL_DIR)\include\krb5\."
437 copy include\win-mac.h "$(KRB_INSTALL_DIR)\include\."
438 copy include\profile.h "$(KRB_INSTALL_DIR)\include\."
439 copy include\com_err.h "$(KRB_INSTALL_DIR)\include\."
440 copy include\gssapi\gssapi.h "$(KRB_INSTALL_DIR)\include\gssapi\."
441 copy include\gssapi\gssapi_alloc.h "$(KRB_INSTALL_DIR)\include\gssapi\."
442 copy include\gssapi\gssapi_krb5.h "$(KRB_INSTALL_DIR)\include\gssapi\."
443 copy include\gssapi\gssapi_ext.h "$(KRB_INSTALL_DIR)\include\gssapi\."
444 copy lib\$(OUTPRE)*.lib "$(KRB_INSTALL_DIR)\lib\."
445 copy lib\$(OUTPRE)*.dll "$(KRB_INSTALL_DIR)\bin\."
446 $(INSTALLDBGSYMS) lib\$(OUTPRE)*.pdb "$(KRB_INSTALL_DIR)\bin\."
447 copy appl\gss-sample\$(OUTPRE)gss-server.exe "$(KRB_INSTALL_DIR)\bin\."
448 $(INSTALLDBGSYMS) appl\gss-sample\$(OUTPRE)gss-server.pdb "$(KRB_INSTALL_DIR)\bin\."
449 copy appl\gss-sample\$(OUTPRE)gss-client.exe "$(KRB_INSTALL_DIR)\bin\."
450 $(INSTALLDBGSYMS) appl\gss-sample\$(OUTPRE)gss-client.pdb "$(KRB_INSTALL_DIR)\bin\."
451 copy windows\ms2mit\$(OUTPRE)*.exe "$(KRB_INSTALL_DIR)\bin\."
452 $(INSTALLDBGSYMS) windows\ms2mit\$(OUTPRE)*.pdb "$(KRB_INSTALL_DIR)\bin\."
453 copy windows\leashdll\$(OUTPRE)*.lib "$(KRB_INSTALL_DIR)\lib\."
454 copy windows\leashdll\$(OUTPRE)*.dll "$(KRB_INSTALL_DIR)\bin\."
455 $(INSTALLDBGSYMS) windows\leashdll\$(OUTPRE)*.pdb "$(KRB_INSTALL_DIR)\bin\."
456 ##DOS##!ifndef NO_LEASH
457 copy windows\leash\$(OUTPRE)*.exe "$(KRB_INSTALL_DIR)\bin\."
458 $(INSTALLDBGSYMS) windows\leash\$(OUTPRE)*.pdb "$(KRB_INSTALL_DIR)\bin\."
459 copy windows\leash\$(OUTPRE)*.chm "$(KRB_INSTALL_DIR)\bin\."
460 copy windows\leash\htmlhelp\*.chm "$(KRB_INSTALL_DIR)\bin\."
462 copy windows\kfwlogon\$(OUTPRE)*.lib "$(KRB_INSTALL_DIR)\lib\."
463 copy windows\kfwlogon\$(OUTPRE)*.exe "$(KRB_INSTALL_DIR)\bin\."
464 copy windows\kfwlogon\$(OUTPRE)*.dll "$(KRB_INSTALL_DIR)\bin\."
465 $(INSTALLDBGSYMS) windows\kfwlogon\$(OUTPRE)*.pdb "$(KRB_INSTALL_DIR)\bin\."
466 copy ccapi\lib\win\srctmp\$(OUTPRE)$(CCLIB).dll "$(KRB_INSTALL_DIR)\bin\."
467 $(INSTALLDBGSYMS) ccapi\lib\win\srctmp\$(OUTPRE)$(CCLIB).pdb "$(KRB_INSTALL_DIR)\bin\."
468 copy ccapi\lib\win\srctmp\$(CCLIB).lib "$(KRB_INSTALL_DIR)\lib\."
469 copy ccapi\server\win\srctmp\$(OUTPRE)ccapiserver.exe "$(KRB_INSTALL_DIR)\bin\."
470 copy clients\kvno\$(OUTPRE)kvno.exe "$(KRB_INSTALL_DIR)\bin\."
471 copy clients\klist\$(OUTPRE)klist.exe "$(KRB_INSTALL_DIR)\bin\."
472 copy clients\kinit\$(OUTPRE)kinit.exe "$(KRB_INSTALL_DIR)\bin\."
473 copy clients\kdestroy\$(OUTPRE)kdestroy.exe "$(KRB_INSTALL_DIR)\bin\."
474 copy clients\kcpytkt\$(OUTPRE)kcpytkt.exe "$(KRB_INSTALL_DIR)\bin\."
475 copy clients\kdeltkt\$(OUTPRE)kdeltkt.exe "$(KRB_INSTALL_DIR)\bin\."
476 copy clients\kpasswd\$(OUTPRE)kpasswd.exe "$(KRB_INSTALL_DIR)\bin\."
477 copy clients\kswitch\$(OUTPRE)kswitch.exe "$(KRB_INSTALL_DIR)\bin\."
478 $(INSTALLDBGSYMS) ccapi\server\win\srctmp\$(OUTPRE)ccapiserver.pdb "$(KRB_INSTALL_DIR)\bin\."
479 $(INSTALLDBGSYMS) clients\kvno\$(OUTPRE)kvno.pdb "$(KRB_INSTALL_DIR)\bin\."
480 $(INSTALLDBGSYMS) clients\klist\$(OUTPRE)klist.pdb "$(KRB_INSTALL_DIR)\bin\."
481 $(INSTALLDBGSYMS) clients\kinit\$(OUTPRE)kinit.pdb "$(KRB_INSTALL_DIR)\bin\."
482 $(INSTALLDBGSYMS) clients\kdestroy\$(OUTPRE)kdestroy.pdb "$(KRB_INSTALL_DIR)\bin\."
483 $(INSTALLDBGSYMS) clients\kcpytkt\$(OUTPRE)kcpytkt.pdb "$(KRB_INSTALL_DIR)\bin\."
484 $(INSTALLDBGSYMS) clients\kdeltkt\$(OUTPRE)kdeltkt.pdb "$(KRB_INSTALL_DIR)\bin\."
485 $(INSTALLDBGSYMS) clients\kpasswd\$(OUTPRE)kpasswd.pdb "$(KRB_INSTALL_DIR)\bin\."
486 $(INSTALLDBGSYMS) clients\kswitch\$(OUTPRE)kswitch.pdb "$(KRB_INSTALL_DIR)\bin\."
487 copy plugins\preauth\spake\$(OUTPRE)$(SPAKELIB).dll "$(KRB_INSTALL_DIR)\bin\plugins\preauth\."
488 $(INSTALLDBGSYMS) plugins\preauth\spake\$(OUTPRE)$(SPAKELIB).pdb "$(KRB_INSTALL_DIR)\bin\plugins\preauth\."
490 check-prerecurse: runenv.py
494 check-unix: check-lmdb-$(HAVE_LMDB)
497 check-pytests-no: check-postrecurse
498 @echo 'Skipped python test scripts: python 2.5 or later required' >> \
501 check-cmocka-no: check-postrecurse
502 @echo 'Skipped cmocka tests: cmocka library or header not found' >> \
507 @echo 'Skipped LMDB tests: LMDB KDB module not built' >> $(SKIPTESTS)
509 # Create a test realm and spawn a shell in an environment pointing to it.
510 # If CROSSNUM is set, create that many fully connected test realms and
511 # point the shell at the first one.
513 PYTHONPATH=$(top_srcdir)/util $(PYTHON) $(srcdir)/util/testrealm.py \
516 # environment variable settings to propagate to Python-based tests
518 pyrunenv.vals: Makefile
520 for i in $(RUN_VARS); do \
521 eval echo 'env['\\\'$$i\\\''] = '\\\'\$$$$i\\\'; \
523 echo "tls_impl = '$(TLS_IMPL)'" >> $@
524 echo "have_sasl = '$(HAVE_SASL)'" >> $@
525 echo "have_spake_openssl = '$(HAVE_SPAKE_OPENSSL)'" >> $@
526 echo "have_lmdb = '$(HAVE_LMDB)'" >> $@
527 echo "sizeof_time_t = $(SIZEOF_TIME_T)" >> $@
529 runenv.py: pyrunenv.vals
531 cat pyrunenv.vals >> $@
534 $(RM) runenv.py runenv.pyc pyrunenv.vals
538 COV_ANALYZE= cov-analyze
539 COV_COMMIT= cov-commit-defects --product "$(COV_PRODUCT)" --user "$(COV_USER)" --target "$(COV_TARGET)" --description "$(COV_DESC)"
540 COV_MAKE_LIB= cov-make-library
548 # Set to, e.g., "--all" or "--security".
550 # Temporary directory, might as well put it in the build tree.
551 COV_TEMPDIR= cov-temp
552 # Sources modeling some functions or macros confusing Prevent.
554 $(top_srcdir)/util/coverity-models/threads.c
556 # Depend on Makefiles to ensure that (in maintainer mode) the configure
557 # scripts won't get rerun under cov-build.
558 coverity prevent cov: Makefiles
559 $(COV_BUILD) --dir $(COV_TEMPDIR) $(MAKE) all
560 $(COV_ANALYZE) $(COV_ANALYSES) --dir $(COV_TEMPDIR)
561 if test "$(COV_DATADIR)" != ""; then \
562 $(COV_COMMIT) --dir $(COV_TEMPDIR) --datadir $(COV_DATADIR); \
564 echo "** Coverity Prevent analysis results not commit to Defect Manager"; \
591 kadmin/server/ipropd_svc.c \
592 kadmin/server/kadm_rpc_svc.c \
593 lib/apputils/daemon.c \
594 lib/kadm5/admin_xdr.h \
595 lib/kadm5/clnt/client_rpc.c \
596 lib/kadm5/kadm_rpc.h \
597 lib/kadm5/kadm_rpc_xdr.c \
598 lib/kadm5/srv/adb_xdr.c \
599 lib/krb5/krb/strptime.c \
601 util/support/getopt.c \
602 util/support/getopt_long.c \
603 util/support/mkstemp.c \
604 util/support/strlcpy.c
608 include/k5-platform.h \
610 lib/apputils/dummy.c \
611 lib/crypto/crypto_tests/camellia-test.c \
612 lib/crypto/builtin/aes \
613 lib/crypto/builtin/camellia \
614 lib/crypto/builtin/sha2 \
615 lib/gssapi/generic/gssapiP_generic.h \
616 lib/gssapi/generic/gssapi_ext.h \
617 lib/gssapi/krb5/gssapiP_krb5.h \
618 lib/gssapi/mechglue \
620 lib/krb5/krb/deltat.c \
622 plugins/kdb/db2/libdb2 \
623 plugins/kdb/db2/pol_xdr.c \
624 plugins/preauth/pkinit/pkcs11.h \
625 plugins/preauth/pkinit/pkinit_accessor.h \
626 plugins/preauth/pkinit/pkinit_crypto.h \
627 plugins/preauth/pkinit/pkinit.h \
628 plugins/preauth/pkinit/pkinit_crypto_openssl.h \
629 tests/asn.1/ktest.h \
630 tests/asn.1/ktest_equal.h \
631 tests/asn.1/utility.h \
632 tests/gss-threads/gss-misc.c \
633 tests/gss-threads/gss-misc.h \
634 tests/hammer/kdc5_hammer.c \
636 util/profile/prof_int.h \
637 util/profile/profile.hin \
638 util/profile/profile_tcl.c \
639 util/support/fnmatch.c \
643 EXCLUDES = `for i in $(BSDFILES) $(OTHEREXCLUDES); do echo $$i; done | $(AWK) '{ print "-path", $$1, "-o" }'` -path /dev/null
645 FIND_REINDENT = cd $(top_srcdir) && \
646 $(FIND) $(INDENTDIRS) \( $(EXCLUDES) \) -prune -o \
647 \( -name '*.[ch]' -o -name '*.hin' -o -name '*.[ch].in' \)
650 ($(FIND_REINDENT) -print)
654 -print0 | $(XARGS) -0 $(EMACS) -q -batch \
655 -l util/krb5-c-style.el \
656 -l util/krb5-batch-reindent.el)
658 mark-cstyle: mark-cstyle-krb5 mark-cstyle-bsd
661 (cd $(top_srcdir) && \
662 $(FIND) $(INDENTDIRS) \( $(EXCLUDES) \) -prune -o \
664 -print0 | $(XARGS) -0 $(PYTHON) util/krb5-mark-cstyle.py \
668 (cd $(top_srcdir) && $(FIND) $(BSDFILES) -print0 | $(XARGS) -0 \
669 $(PYTHON) util/krb5-mark-cstyle.py --cstyle=bsd)
672 (cd $(top_srcdir) && \
673 $(FIND) . \( -name '*.[ch]' -o -name '*.hin' \) -print0 | \
674 $(XARGS) -0 python util/krb5-check-copyright.py)
677 (cd $(top_srcdir) && \
678 $(FIND) . \( -name '*.[ch]' -o -name '*.hin' \) -print | \
679 etags --lang=c - && \
680 $(FIND) . -name '*.cpp' -print | etags --lang=c++ --append - && \
681 $(FIND) . -name '*.y' -print | etags --lang=yacc --append -)
686 $(RM) $(top_srcdir)/TAGS