build: Remove binaries and libraries build groups
[Samba/gebeck_regimport.git] / source4 / heimdal_build / wscript_build
blob44634b4d838bc117e172bebad5c44e3e67c2f2f2
1 #!/usr/bin/env python
3 import os, Utils
4 from samba_utils import SET_TARGET_TYPE
5 from samba_autoconf import CURRENT_CFLAGS
7 def to_list(str):
8 '''Split a list, preserving quoted strings and existing lists'''
9 if str is None:
10 return []
11 if isinstance(str, list):
12 return str
13 return str.split(None)
15 def heimdal_path(p, absolute=False):
16 hpath = os.path.join("../heimdal", p)
17 if not absolute:
18 return hpath
19 return os.path.normpath(os.path.join(bld.curdir, hpath))
21 def heimdal_paths(ps):
22 return [heimdal_path(p) for p in to_list(ps)]
24 # waf build tool for building .et files with compile_et
25 def HEIMDAL_ASN1(name, source,
26 options='',
27 directory='',
28 option_file=None,
29 includes=''):
30 '''Build a ASN1 file using the asn1 compiler.
31 This will produce 2 output files'''
32 source = heimdal_path(source)
33 bname = os.path.basename(source)[0:-5];
34 dname = os.path.dirname(source)
35 asn1name = "%s_asn1" % bname
37 if option_file:
38 option_file = heimdal_path(option_file)
40 if not SET_TARGET_TYPE(bld, name, 'ASN1'):
41 return
43 # for ASN1 compilation, I always put it in build_source, as it doesn't make
44 # sense elsewhere
45 bld.set_group('build_source')
47 out_files = heimdal_paths([
48 "%s/asn1_%s_asn1.x" % (directory, bname),
49 "%s/%s_asn1.hx" % (directory, bname),
50 "%s/%s_asn1-priv.hx" % (directory, bname),
53 # the ${TGT[0].parent.abspath(env)} expression gives us the parent directory of
54 # the first target in the build directory
55 # SRC[0].abspath(env) gives the absolute path to the source directory for the first
56 # source file. Note that in the case of a option_file, we have more than
57 # one source file
58 cd_rule = 'cd "${TGT[0].parent.abspath(env)}"'
59 asn1_rule = cd_rule + ' && "${ASN1_COMPILE}" ${OPTION_FILE} ${ASN1OPTIONS} --one-code-file "${SRC[0].abspath(env)}" ${ASN1NAME}'
61 source = to_list(source)
63 if option_file is not None:
64 source.append(option_file)
66 deps = ''
67 if not bld.CONFIG_SET('USING_SYSTEM_ASN1_COMPILE'):
68 deps = 'asn1_compile'
70 t = bld(rule=asn1_rule,
71 ext_out = '.x',
72 before = 'cc',
73 on_results = True,
74 shell = True,
75 source = source,
76 target = out_files,
77 depends_on = deps,
78 name=name + '_ASN1')
80 t.env.ASN1NAME = asn1name
81 t.env.ASN1OPTIONS = options
82 t.env.BLDBIN = os.path.normpath(os.path.join(bld.srcnode.abspath(bld.env), '..'))
83 if option_file is not None:
84 t.env.OPTION_FILE = "--option-file='%s'" % os.path.normpath(os.path.join(bld.curdir, option_file))
86 cfile = out_files[0][0:-2] + '.c'
87 hfile = out_files[1][0:-3] + '.h'
88 hpriv = out_files[2][0:-3] + '.h'
90 # now generate a .c file from the .x file
91 t = bld(rule='''( echo '#include "config.h"' && cat ${SRC} ) > ${TGT}''',
92 source = out_files[0],
93 target = cfile,
94 shell = True,
95 on_results=True,
96 ext_out = '.c',
97 ext_in = '.x',
98 depends_on = name + '_ASN1',
99 name = name + '_C')
101 # and generate a .h file from the .hx file
102 t = bld(rule='cp ${SRC} ${TGT}',
103 source = out_files[1],
104 ext_out = '.c',
105 ext_in = '.x',
106 on_results=True,
107 target = hfile,
108 depends_on = name + '_ASN1',
109 name = name + '_H')
111 # and generate a .h file from the .hx file
112 t = bld(rule='cp ${SRC} ${TGT}',
113 source = out_files[2],
114 ext_out = '.c',
115 ext_in = '.x',
116 on_results=True,
117 target = hpriv,
118 depends_on = name + '_ASN1',
119 name = name + '_PRIV_H')
121 bld.set_group('main')
123 includes = to_list(includes)
124 includes.append(os.path.dirname(out_files[0]))
126 t = bld(features = 'cc',
127 source = cfile,
128 target = name,
129 samba_cflags = CURRENT_CFLAGS(bld, name, ''),
130 depends_on = '',
131 samba_deps = to_list('roken replace'),
132 samba_includes = includes + ["/usr/include/heimdal"],
133 local_include = True)
136 def HEIMDAL_ERRTABLE(name, source):
137 '''Build a heimdal errtable from a .et file'''
139 source = heimdal_path(source)
141 bname = source[0:-3]; # strip off the .et suffix
143 if not SET_TARGET_TYPE(bld, name, 'ET'):
144 return
146 bld.set_group('build_source')
148 out_files = []
149 out_files.append('%s.c' % bname)
150 out_files.append('%s.h' % bname)
152 sources = [source, 'et_compile_wrapper.sh']
154 deps = ''
155 if not bld.CONFIG_SET('USING_SYSTEM_COMPILE_ET'):
156 deps = 'compile_et'
158 t = bld(rule='"${SRC[1].abspath(env)}" "${TGT[0].parent.abspath(env)}" "${COMPILE_ET}" "${SRC[0].abspath(env)}" ${TGT[0].bldpath(env)}',
159 ext_out = '.c',
160 before = 'cc',
161 on_results = True,
162 shell = True,
163 source = sources,
164 target = out_files,
165 depends_on = deps,
166 name = name)
168 def HEIMDAL_AUTOPROTO(header, source, options=None, group='prototypes'):
169 '''rule for heimdal prototype generation'''
170 header = heimdal_path(header)
171 bld.set_group(group)
172 if options is None:
173 options='-q -P comment -o'
174 SET_TARGET_TYPE(bld, header, 'PROTOTYPE')
175 source = heimdal_paths(source)
176 t = bld(rule='${PERL} "${HEIMDAL}/cf/make-proto.pl" ${OPTIONS} "${TGT[0].abspath(env)}" ${SRC}',
177 source=source,
178 target=header,
179 on_results=True,
180 ext_out='.c',
181 before='cc')
182 t.env.HEIMDAL = os.path.join(bld.srcnode.abspath(), 'source4/heimdal')
183 t.env.OPTIONS = options
186 def HEIMDAL_AUTOPROTO_PRIVATE(header, source):
187 '''rule for private heimdal prototype generation'''
188 HEIMDAL_AUTOPROTO(header, source, options='-q -P comment -p')
191 def HEIMDAL_GENERATOR(name, rule, source='', target='',
192 group='generators'):
193 '''A generic source generator target'''
195 if not SET_TARGET_TYPE(bld, name, 'GENERATOR'):
196 return
198 bld.set_group(group)
199 return bld(
200 rule=rule,
201 source=source,
202 target=target,
203 shell=isinstance(rule, str),
204 on_results=True,
205 before='cc',
206 ext_out='.c',
207 vars=[rule],
208 samba_type='GENERATOR',
209 name=name)
212 def HEIMDAL_LIBRARY(libname, source, deps, vnum, version_script, includes=''):
213 '''define a Heimdal library'''
215 obj_target = libname + '.objlist'
217 # first create a target for building the object files for this library
218 # by separating in this way, we avoid recompiling the C files
219 # separately for the install library and the build library
220 HEIMDAL_SUBSYSTEM(obj_target,
221 source = source,
222 deps = deps,
223 includes = includes,
224 group = 'main')
226 if not SET_TARGET_TYPE(bld, libname, "LIBRARY"):
227 return
229 # the library itself will depend on that object target
230 deps = to_list(deps)
231 deps.append(obj_target)
233 ldflags = []
235 # FIXME: When building upstream heimdal, we should not be adding this
236 # suffix.
237 bundled_build = True
238 if bundled_build:
239 bundled_name = libname + '-samba4'
240 else:
241 bundled_name = libname
242 version = "%s_%s" % (Utils.g_module.APPNAME, Utils.g_module.VERSION)
244 features = 'cc cshlib symlink_lib install_lib'
246 bld.set_group('main')
247 t = bld(
248 features = features,
249 source = [],
250 target = bundled_name,
251 samba_deps = deps,
252 samba_includes = includes,
253 vnum = vnum,
254 install_path = None,
255 name = libname,
256 ldflags = ldflags,
257 vars = [version],
258 private_library = bundled_build,
259 version_script = heimdal_path(version_script, absolute=True),
263 def HEIMDAL_SUBSYSTEM(modname, source,
264 deps='',
265 includes='',
266 cflags='',
267 group='main',
268 use_hostcc=False,
269 use_global_deps=True):
270 '''define a Heimdal subsystem'''
272 if not SET_TARGET_TYPE(bld, modname, 'SUBSYSTEM'):
273 return
275 source = heimdal_paths(source)
277 bld.set_group(group)
279 return bld(
280 features = 'cc',
281 source = source,
282 target = modname,
283 samba_cflags = CURRENT_CFLAGS(bld, modname, cflags),
284 depends_on = '',
285 samba_deps = to_list(deps),
286 samba_includes = includes,
287 local_include = True,
288 local_include_first = True,
289 samba_use_hostcc = use_hostcc,
290 samba_use_global_deps = use_global_deps
294 def HEIMDAL_BINARY(binname, source,
295 deps='',
296 includes='',
297 cflags='',
298 use_hostcc=False,
299 use_global_deps=True,
300 compiler=None,
301 group='main',
302 install=True,
303 install_path=None):
304 '''define a Samba binary'''
306 if not SET_TARGET_TYPE(bld, binname, 'BINARY'):
307 return
309 features = 'cc cprogram symlink_bin install_bin'
311 obj_target = binname + '.objlist'
313 if group == 'binaries':
314 subsystem_group = 'main'
315 else:
316 subsystem_group = group
318 # first create a target for building the object files for this binary
319 # by separating in this way, we avoid recompiling the C files
320 # separately for the install binary and the build binary
321 HEIMDAL_SUBSYSTEM(obj_target,
322 source = source,
323 deps = deps,
324 includes = includes,
325 cflags = cflags,
326 group = subsystem_group,
327 use_hostcc = use_hostcc,
328 use_global_deps= use_global_deps)
330 bld.set_group(group)
332 # the binary itself will depend on that object target
333 deps = to_list(deps)
334 deps.append(obj_target)
336 t = bld(
337 features = features,
338 source = [],
339 target = binname,
340 samba_deps = deps,
341 samba_includes = includes,
342 local_include = True,
343 top = True,
344 install_path = None,
345 samba_install = install
349 if not bld.CONFIG_SET('USING_SYSTEM_ROKEN'):
351 if not bld.CONFIG_SET('HAVE_IFADDRS_H'):
352 HEIMDAL_GENERATOR(
353 name="HEIMDAL_IFADDRS_H",
354 rule="rm -f ${TGT} && ln ${SRC} ${TGT}",
355 source = 'ifaddrs.hin',
356 target = 'ifaddrs.h',
359 if not bld.CONFIG_SET('HAVE_ERR_H'):
360 HEIMDAL_GENERATOR(
361 group='build_compiler_source',
362 name="HEIMDAL_ERR_H",
363 rule="rm -f ${TGT} && ln ${SRC} ${TGT}",
364 source = '../heimdal/lib/roken/err.hin',
365 target = '../heimdal/lib/roken/err.h',
368 ROKEN_HOSTCC_SOURCE = '''
369 lib/roken/base64.c
370 lib/roken/ct.c
371 lib/roken/hex.c
372 lib/roken/bswap.c
373 lib/roken/dumpdata.c
374 lib/roken/emalloc.c
375 lib/roken/ecalloc.c
376 lib/roken/getarg.c
377 lib/roken/get_window_size.c
378 lib/roken/getdtablesize.c
379 lib/roken/h_errno.c
380 lib/roken/issuid.c
381 lib/roken/net_read.c
382 lib/roken/net_write.c
383 lib/roken/parse_time.c
384 lib/roken/parse_units.c
385 lib/roken/vis.c
386 lib/roken/strlwr.c
387 lib/roken/strsep_copy.c
388 lib/roken/strsep.c
389 lib/roken/strupr.c
390 lib/roken/strpool.c
391 lib/roken/estrdup.c
392 lib/roken/erealloc.c
393 lib/roken/simple_exec.c
394 lib/roken/strcollect.c
395 lib/roken/rtbl.c
396 lib/roken/rand.c
397 lib/roken/cloexec.c
398 lib/roken/xfree.c
399 ../heimdal_build/replace.c
402 if not bld.CONFIG_SET('HAVE_CLOSEFROM'):
403 ROKEN_HOSTCC_SOURCE += '''
404 lib/roken/closefrom.c
407 ROKEN_SOURCE = ROKEN_HOSTCC_SOURCE + '''
408 lib/roken/resolve.c
409 lib/roken/socket.c
410 lib/roken/roken_gethostby.c
411 lib/roken/strerror_r.c
414 HEIMDAL_LIBRARY('roken',
415 ROKEN_SOURCE,
416 includes='../heimdal/lib/roken ../heimdal/include',
417 deps='resolv util replace',
418 vnum='19.0.1',
419 version_script='lib/roken/version-script.map',
422 HEIMDAL_SUBSYSTEM('ROKEN_HOSTCC',
423 ROKEN_HOSTCC_SOURCE,
424 use_hostcc=True,
425 use_global_deps=False,
426 includes='../heimdal/lib/roken',
427 cflags='-DSOCKET_WRAPPER_DISABLE=1 -DNSS_WRAPPER_DISABLE=1 -D_SAMBA_HOSTCC_',
428 group='compiler_libraries',
429 deps='LIBREPLACE_HOSTCC',
432 HEIMDAL_BINARY('rkpty', 'lib/roken/rkpty.c',
433 deps='roken',
434 install=False
437 if not bld.CONFIG_SET("USING_SYSTEM_KDC"):
438 HEIMDAL_ASN1('HEIMDAL_KX509_ASN1',
439 'lib/asn1/kx509.asn1',
440 directory='lib/asn1'
442 HEIMDAL_ASN1('HEIMDAL_DIGEST_ASN1',
443 'lib/asn1/digest.asn1',
444 directory='lib/asn1'
447 KDC_SOURCE='kdc/default_config.c kdc/kerberos5.c kdc/krb5tgs.c kdc/pkinit.c kdc/log.c kdc/misc.c kdc/digest.c kdc/process.c kdc/windc.c kdc/kx509.c'
449 HEIMDAL_LIBRARY('kdc', source=KDC_SOURCE,
450 includes='../heimdal/kdc',
451 deps='roken krb5 hdb asn1 HEIMDAL_DIGEST_ASN1 HEIMDAL_KX509_ASN1 heimntlm hcrypto com_err wind heimbase',
452 vnum='2.0.0',
453 version_script='kdc/version-script.map')
454 HEIMDAL_AUTOPROTO('kdc/kdc-protos.h', KDC_SOURCE)
455 HEIMDAL_AUTOPROTO_PRIVATE('kdc/kdc-private.h', KDC_SOURCE)
457 if not bld.CONFIG_SET("USING_SYSTEM_HEIMNTLM"):
458 HEIMDAL_ERRTABLE('HEIMNTLM_ET',
459 'lib/ntlm/ntlm_err.et')
461 HEIMNTLM_SOURCE = 'lib/ntlm/ntlm.c'
462 HEIMDAL_LIBRARY('heimntlm',
463 source=HEIMNTLM_SOURCE,
464 includes='../heimdal/lib/ntlm',
465 deps='roken hcrypto krb5',
466 vnum='1.0.1',
467 version_script='lib/ntlm/version-script.map',
469 HEIMDAL_AUTOPROTO('lib/ntlm/heimntlm-protos.h', HEIMNTLM_SOURCE)
471 if not bld.CONFIG_SET("USING_SYSTEM_HDB"):
472 HEIMDAL_ASN1('HEIMDAL_HDB_ASN1', 'lib/hdb/hdb.asn1',
473 directory='lib/asn1',
474 options="--sequence=HDB-Ext-KeySet --sequence=Keys",
475 includes='../heimdal/lib/asn1')
477 HEIMDAL_SUBSYSTEM('HEIMDAL_HDB_KEYS',
478 'lib/hdb/keys.c',
479 includes='../heimdal/lib/hdb',
480 deps='roken hcrypto krb5 HEIMDAL_HDB_ASN1'
483 HEIMDAL_ERRTABLE('HEIMDAL_HDB_ERR_ET', 'lib/hdb/hdb_err.et')
485 HDB_SOURCE = '''lib/hdb/db.c lib/hdb/dbinfo.c lib/hdb/hdb.c
486 lib/hdb/ext.c lib/hdb/keytab.c lib/hdb/hdb-keytab.c
487 lib/hdb/mkey.c lib/hdb/ndbm.c lib/hdb/hdb_err.c
488 ../heimdal_build/hdb-glue.c'''
490 HEIMDAL_LIBRARY('hdb',
491 version_script='lib/hdb/version-script.map',
492 source=HDB_SOURCE,
493 includes='../heimdal/lib/hdb',
494 deps='krb5 HEIMDAL_HDB_KEYS roken hcrypto com_err HEIMDAL_HDB_ASN1 wind',
495 vnum='11.0.2',
497 HEIMDAL_AUTOPROTO('lib/hdb/hdb-protos.h', HDB_SOURCE)
498 HEIMDAL_AUTOPROTO_PRIVATE('lib/hdb/hdb-private.h', HDB_SOURCE)
501 if not bld.CONFIG_SET("USING_SYSTEM_GSSAPI"):
502 HEIMDAL_ERRTABLE('HEIMDAL_GKRB5_ERR_ET', 'lib/gssapi/krb5/gkrb5_err.et')
504 HEIMDAL_ASN1('HEIMDAL_GSSAPI_ASN1',
505 'lib/gssapi/mech/gssapi.asn1',
506 includes='../heimdal/lib/asn1',
507 directory='lib/gssapi'
510 HEIMDAL_ASN1('HEIMDAL_SPNEGO_ASN1',
511 source='lib/gssapi/spnego/spnego.asn1',
512 options='--sequence=MechTypeList',
513 includes='../heimdal/lib/asn1',
514 directory='lib/gssapi'
517 HEIMDAL_GSSAPI_SPNEGO_SOURCE = '''
518 lib/gssapi/spnego/init_sec_context.c
519 lib/gssapi/spnego/external.c
520 lib/gssapi/spnego/compat.c
521 lib/gssapi/spnego/context_stubs.c
522 lib/gssapi/spnego/cred_stubs.c
523 lib/gssapi/spnego/accept_sec_context.c
526 HEIMDAL_AUTOPROTO_PRIVATE('lib/gssapi/spnego/spnego-private.h',
527 HEIMDAL_GSSAPI_SPNEGO_SOURCE)
529 HEIMDAL_GSSAPI_KRB5_SOURCE = '''
530 lib/gssapi/krb5/copy_ccache.c
531 lib/gssapi/krb5/delete_sec_context.c
532 lib/gssapi/krb5/init_sec_context.c
533 lib/gssapi/krb5/context_time.c
534 lib/gssapi/krb5/init.c
535 lib/gssapi/krb5/address_to_krb5addr.c
536 lib/gssapi/krb5/get_mic.c
537 lib/gssapi/krb5/inquire_context.c
538 lib/gssapi/krb5/add_cred.c
539 lib/gssapi/krb5/inquire_cred.c
540 lib/gssapi/krb5/inquire_cred_by_oid.c
541 lib/gssapi/krb5/inquire_cred_by_mech.c
542 lib/gssapi/krb5/inquire_mechs_for_name.c
543 lib/gssapi/krb5/inquire_names_for_mech.c
544 lib/gssapi/krb5/indicate_mechs.c
545 lib/gssapi/krb5/inquire_sec_context_by_oid.c
546 lib/gssapi/krb5/export_sec_context.c
547 lib/gssapi/krb5/import_sec_context.c
548 lib/gssapi/krb5/duplicate_name.c
549 lib/gssapi/krb5/import_name.c
550 lib/gssapi/krb5/compare_name.c
551 lib/gssapi/krb5/export_name.c
552 lib/gssapi/krb5/canonicalize_name.c
553 lib/gssapi/krb5/unwrap.c
554 lib/gssapi/krb5/wrap.c
555 lib/gssapi/krb5/release_name.c
556 lib/gssapi/krb5/cfx.c
557 lib/gssapi/krb5/8003.c
558 lib/gssapi/krb5/arcfour.c
559 lib/gssapi/krb5/encapsulate.c
560 lib/gssapi/krb5/display_name.c
561 lib/gssapi/krb5/sequence.c
562 lib/gssapi/krb5/display_status.c
563 lib/gssapi/krb5/release_buffer.c
564 lib/gssapi/krb5/external.c
565 lib/gssapi/krb5/compat.c
566 lib/gssapi/krb5/creds.c
567 lib/gssapi/krb5/acquire_cred.c
568 lib/gssapi/krb5/release_cred.c
569 lib/gssapi/krb5/store_cred.c
570 lib/gssapi/krb5/set_cred_option.c
571 lib/gssapi/krb5/decapsulate.c
572 lib/gssapi/krb5/verify_mic.c
573 lib/gssapi/krb5/accept_sec_context.c
574 lib/gssapi/krb5/set_sec_context_option.c
575 lib/gssapi/krb5/process_context_token.c
576 lib/gssapi/krb5/prf.c
577 lib/gssapi/krb5/aeap.c
578 lib/gssapi/krb5/pname_to_uid.c
579 lib/gssapi/krb5/authorize_localname.c
582 HEIMDAL_AUTOPROTO_PRIVATE('lib/gssapi/krb5/gsskrb5-private.h',
583 HEIMDAL_GSSAPI_KRB5_SOURCE)
585 HEIMDAL_LIBRARY('gssapi',
586 HEIMDAL_GSSAPI_SPNEGO_SOURCE + HEIMDAL_GSSAPI_KRB5_SOURCE + '''
587 lib/gssapi/mech/context.c lib/gssapi/mech/gss_krb5.c lib/gssapi/mech/gss_mech_switch.c
588 lib/gssapi/mech/gss_process_context_token.c lib/gssapi/mech/gss_buffer_set.c
589 lib/gssapi/mech/gss_aeap.c lib/gssapi/mech/gss_add_cred.c lib/gssapi/mech/gss_cred.c
590 lib/gssapi/mech/gss_add_oid_set_member.c lib/gssapi/mech/gss_compare_name.c lib/gssapi/mech/gss_release_oid_set.c
591 lib/gssapi/mech/gss_create_empty_oid_set.c lib/gssapi/mech/gss_decapsulate_token.c lib/gssapi/mech/gss_inquire_cred_by_oid.c
592 lib/gssapi/mech/gss_canonicalize_name.c lib/gssapi/mech/gss_inquire_sec_context_by_oid.c lib/gssapi/mech/gss_inquire_names_for_mech.c
593 lib/gssapi/mech/gss_inquire_mechs_for_name.c lib/gssapi/mech/gss_wrap_size_limit.c lib/gssapi/mech/gss_names.c
594 lib/gssapi/mech/gss_verify.c lib/gssapi/mech/gss_display_name.c
595 lib/gssapi/mech/gss_duplicate_oid.c lib/gssapi/mech/gss_display_status.c lib/gssapi/mech/gss_release_buffer.c
596 lib/gssapi/mech/gss_release_oid.c lib/gssapi/mech/gss_test_oid_set_member.c
597 lib/gssapi/mech/gss_release_cred.c
598 lib/gssapi/mech/gss_set_sec_context_option.c lib/gssapi/mech/gss_export_name.c lib/gssapi/mech/gss_seal.c
599 lib/gssapi/mech/gss_acquire_cred.c lib/gssapi/mech/gss_unseal.c lib/gssapi/mech/gss_verify_mic.c
600 lib/gssapi/mech/gss_accept_sec_context.c lib/gssapi/mech/gss_inquire_cred_by_mech.c lib/gssapi/mech/gss_indicate_mechs.c
601 lib/gssapi/mech/gss_delete_sec_context.c lib/gssapi/mech/gss_sign.c lib/gssapi/mech/gss_utils.c
602 lib/gssapi/mech/gss_init_sec_context.c lib/gssapi/mech/gss_oid_equal.c lib/gssapi/mech/gss_oid.c
603 lib/gssapi/mech/gss_oid_to_str.c lib/gssapi/mech/gss_mo.c
604 lib/gssapi/mech/gss_context_time.c lib/gssapi/mech/gss_encapsulate_token.c lib/gssapi/mech/gss_get_mic.c
605 lib/gssapi/mech/gss_import_sec_context.c lib/gssapi/mech/gss_inquire_cred.c lib/gssapi/mech/gss_wrap.c
606 lib/gssapi/mech/gss_import_name.c lib/gssapi/mech/gss_duplicate_name.c lib/gssapi/mech/gss_unwrap.c
607 lib/gssapi/mech/gss_export_sec_context.c lib/gssapi/mech/gss_inquire_context.c lib/gssapi/mech/gss_release_name.c
608 lib/gssapi/mech/gss_set_cred_option.c lib/gssapi/mech/gss_pseudo_random.c ../heimdal_build/gssapi-glue.c''',
609 includes='../heimdal/lib/gssapi ../heimdal/lib/gssapi/gssapi ../heimdal/lib/gssapi/spnego ../heimdal/lib/gssapi/krb5 ../heimdal/lib/gssapi/mech',
610 deps='hcrypto asn1 HEIMDAL_SPNEGO_ASN1 HEIMDAL_GSSAPI_ASN1 roken krb5 com_err wind',
611 vnum='2.0.0',
612 version_script='lib/gssapi/version-script.map',
615 if not bld.CONFIG_SET("USING_SYSTEM_KRB5"):
616 # expand_path.c needs some of the install paths
617 HEIMDAL_SUBSYSTEM('HEIMDAL_CONFIG',
618 'lib/krb5/expand_path.c lib/krb5/plugin.c lib/krb5/context.c',
619 includes='../heimdal/lib/krb5 ../heimdal/lib/asn1 ../heimdal/include',
620 cflags=bld.dynconfig_cflags('LIBDIR BINDIR LIBEXECDIR SBINDIR'),
621 deps='hcrypto heimbase wind hx509 com_err'
624 HEIMDAL_ERRTABLE('HEIMDAL_KRB5_ERR_ET', 'lib/krb5/krb5_err.et')
626 HEIMDAL_ERRTABLE('HEIMDAL_KRB_ERR_ET', 'lib/krb5/krb_err.et')
628 HEIMDAL_ERRTABLE('HEIMDAL_K524_ERR_ET', 'lib/krb5/k524_err.et')
630 HEIMDAL_ERRTABLE('HEIMDAL_HEIM_ERR_ET', 'lib/krb5/heim_err.et')
632 KRB5_SOURCE = [os.path.join('lib/krb5/', x) for x in to_list(
633 '''acache.c add_et_list.c
634 addr_families.c appdefault.c
635 asn1_glue.c auth_context.c
636 build_ap_req.c build_auth.c cache.c
637 changepw.c codec.c config_file.c
638 constants.c convert_creds.c
639 copy_host_realm.c crc.c creds.c
640 crypto.c crypto-aes.c crypto-algs.c
641 crypto-arcfour.c crypto-des3.c crypto-des.c
642 crypto-des-common.c crypto-evp.c
643 crypto-null.c crypto-pk.c crypto-rand.c
644 data.c eai_to_heim_errno.c
645 error_string.c expand_hostname.c
646 fcache.c free.c free_host_realm.c
647 generate_seq_number.c generate_subkey.c
648 get_addrs.c get_cred.c
649 get_default_principal.c
650 get_default_realm.c get_for_creds.c
651 get_host_realm.c get_in_tkt.c
652 get_port.c init_creds.c init_creds_pw.c
653 kcm.c keyblock.c keytab.c keytab_any.c
654 keytab_file.c keytab_memory.c
655 keytab_keyfile.c krbhst.c log.c
656 mcache.c misc.c mk_error.c mk_priv.c
657 mk_rep.c mk_req.c mk_req_ext.c
658 mit_glue.c n-fold.c padata.c pkinit.c
659 principal.c prog_setup.c pac.c
660 pcache.c prompter_posix.c rd_cred.c rd_error.c
661 rd_priv.c rd_rep.c rd_req.c replay.c
662 salt.c salt-aes.c salt-arcfour.c salt-des3.c salt-des.c
663 send_to_kdc.c set_default_realm.c
664 store.c store-int.c store_emem.c store_fd.c
665 store_mem.c ticket.c time.c transited.c
666 version.c warn.c krb5_err.c
667 aname_to_localname.c kuserok.c
668 heim_err.c k524_err.c krb_err.c''')] + ["../heimdal_build/krb5-glue.c"]
670 HEIMDAL_LIBRARY('krb5', KRB5_SOURCE,
671 version_script='lib/krb5/version-script.map',
672 includes='../heimdal/lib/krb5 ../heimdal/lib/asn1 ../heimdal/include',
673 deps='roken wind asn1 hx509 hcrypto intl com_err HEIMDAL_CONFIG heimbase execinfo',
674 vnum='26.0.0',
676 KRB5_PROTO_SOURCE = KRB5_SOURCE + ['lib/krb5/expand_path.c', 'lib/krb5/plugin.c', 'lib/krb5/context.c']
678 HEIMDAL_AUTOPROTO_PRIVATE('lib/krb5/krb5-private.h', KRB5_PROTO_SOURCE)
679 HEIMDAL_AUTOPROTO('lib/krb5/krb5-protos.h', KRB5_PROTO_SOURCE,
680 options='-E KRB5_LIB -q -P comment -o')
682 if not bld.CONFIG_SET("USING_SYSTEM_ASN1"):
683 HEIMDAL_HEIM_ASN1_DER_SOURCE = '''
684 lib/asn1/der_get.c
685 lib/asn1/der_put.c
686 lib/asn1/der_free.c
687 lib/asn1/der_format.c
688 lib/asn1/der_length.c
689 lib/asn1/der_copy.c
690 lib/asn1/der_cmp.c
693 HEIMDAL_AUTOPROTO('lib/asn1/der-protos.h',
694 HEIMDAL_HEIM_ASN1_DER_SOURCE,
695 group = 'compiler_prototypes',
696 options="-q -P comment -o")
699 HEIMDAL_AUTOPROTO('lib/asn1/der-private.h',
700 HEIMDAL_HEIM_ASN1_DER_SOURCE,
701 group = 'compiler_prototypes',
702 options="-q -P comment -p")
704 HEIMDAL_ERRTABLE('HEIMDAL_ASN1_ERR_ET', 'lib/asn1/asn1_err.et')
706 HEIMDAL_SUBSYSTEM('HEIMDAL_HEIM_ASN1',
707 HEIMDAL_HEIM_ASN1_DER_SOURCE + 'lib/asn1/extra.c lib/asn1/timegm.c lib/asn1/asn1_err.c',
708 includes='../heimdal/lib/asn1',
709 deps='roken com_err'
712 HEIMDAL_ASN1('HEIMDAL_RFC2459_ASN1',
713 'lib/asn1/rfc2459.asn1',
714 options='--preserve-binary=TBSCertificate --preserve-binary=TBSCRLCertList --preserve-binary=Name --sequence=GeneralNames --sequence=Extensions --sequence=CRLDistributionPoints',
715 directory='lib/asn1'
718 HEIMDAL_ASN1('HEIMDAL_KRB5_ASN1',
719 'lib/asn1/krb5.asn1',
720 option_file='lib/asn1/krb5.opt',
721 directory='lib/asn1'
724 HEIMDAL_ASN1('HEIMDAL_PKINIT_ASN1',
725 'lib/asn1/pkinit.asn1',
726 directory='lib/asn1'
729 HEIMDAL_ASN1('HEIMDAL_CMS_ASN1',
730 'lib/asn1/cms.asn1',
731 option_file='lib/asn1/cms.opt',
732 directory='lib/asn1'
735 HEIMDAL_LIBRARY('asn1',
736 version_script='lib/asn1/version-script.map',
737 deps="HEIMDAL_HEIM_ASN1 HEIMDAL_RFC2459_ASN1 HEIMDAL_KRB5_ASN1 HEIMDAL_PKINIT_ASN1 HEIMDAL_CMS_ASN1",
738 source='',
739 vnum='8.0.0')
741 if not bld.CONFIG_SET('USING_SYSTEM_HCRYPTO'):
742 if not bld.CONFIG_SET("USING_SYSTEM_TOMMATH"):
743 HEIMDAL_SUBSYSTEM('tommath',
744 'lib/hcrypto/libtommath/bncore.c lib/hcrypto/libtommath/bn_mp_init.c lib/hcrypto/libtommath/bn_mp_clear.c lib/hcrypto/libtommath/bn_mp_exch.c lib/hcrypto/libtommath/bn_mp_grow.c lib/hcrypto/libtommath/bn_mp_shrink.c lib/hcrypto/libtommath/bn_mp_clamp.c lib/hcrypto/libtommath/bn_mp_zero.c lib/hcrypto/libtommath/bn_mp_zero_multi.c lib/hcrypto/libtommath/bn_mp_set.c lib/hcrypto/libtommath/bn_mp_set_int.c lib/hcrypto/libtommath/bn_mp_init_size.c lib/hcrypto/libtommath/bn_mp_copy.c lib/hcrypto/libtommath/bn_mp_init_copy.c lib/hcrypto/libtommath/bn_mp_abs.c lib/hcrypto/libtommath/bn_mp_neg.c lib/hcrypto/libtommath/bn_mp_cmp_mag.c lib/hcrypto/libtommath/bn_mp_cmp.c lib/hcrypto/libtommath/bn_mp_cmp_d.c lib/hcrypto/libtommath/bn_mp_rshd.c lib/hcrypto/libtommath/bn_mp_lshd.c lib/hcrypto/libtommath/bn_mp_mod_2d.c lib/hcrypto/libtommath/bn_mp_div_2d.c lib/hcrypto/libtommath/bn_mp_mul_2d.c lib/hcrypto/libtommath/bn_mp_div_2.c lib/hcrypto/libtommath/bn_mp_mul_2.c lib/hcrypto/libtommath/bn_s_mp_add.c lib/hcrypto/libtommath/bn_s_mp_sub.c lib/hcrypto/libtommath/bn_fast_s_mp_mul_digs.c lib/hcrypto/libtommath/bn_s_mp_mul_digs.c lib/hcrypto/libtommath/bn_fast_s_mp_mul_high_digs.c lib/hcrypto/libtommath/bn_s_mp_mul_high_digs.c lib/hcrypto/libtommath/bn_fast_s_mp_sqr.c lib/hcrypto/libtommath/bn_s_mp_sqr.c lib/hcrypto/libtommath/bn_mp_add.c lib/hcrypto/libtommath/bn_mp_sub.c lib/hcrypto/libtommath/bn_mp_karatsuba_mul.c lib/hcrypto/libtommath/bn_mp_mul.c lib/hcrypto/libtommath/bn_mp_karatsuba_sqr.c lib/hcrypto/libtommath/bn_mp_sqr.c lib/hcrypto/libtommath/bn_mp_div.c lib/hcrypto/libtommath/bn_mp_mod.c lib/hcrypto/libtommath/bn_mp_add_d.c lib/hcrypto/libtommath/bn_mp_sub_d.c lib/hcrypto/libtommath/bn_mp_mul_d.c lib/hcrypto/libtommath/bn_mp_div_d.c lib/hcrypto/libtommath/bn_mp_mod_d.c lib/hcrypto/libtommath/bn_mp_expt_d.c lib/hcrypto/libtommath/bn_mp_addmod.c lib/hcrypto/libtommath/bn_mp_submod.c lib/hcrypto/libtommath/bn_mp_mulmod.c lib/hcrypto/libtommath/bn_mp_sqrmod.c lib/hcrypto/libtommath/bn_mp_gcd.c lib/hcrypto/libtommath/bn_mp_lcm.c lib/hcrypto/libtommath/bn_fast_mp_invmod.c lib/hcrypto/libtommath/bn_mp_invmod.c lib/hcrypto/libtommath/bn_mp_reduce.c lib/hcrypto/libtommath/bn_mp_montgomery_setup.c lib/hcrypto/libtommath/bn_fast_mp_montgomery_reduce.c lib/hcrypto/libtommath/bn_mp_montgomery_reduce.c lib/hcrypto/libtommath/bn_mp_exptmod_fast.c lib/hcrypto/libtommath/bn_mp_exptmod.c lib/hcrypto/libtommath/bn_mp_2expt.c lib/hcrypto/libtommath/bn_mp_n_root.c lib/hcrypto/libtommath/bn_mp_jacobi.c lib/hcrypto/libtommath/bn_reverse.c lib/hcrypto/libtommath/bn_mp_count_bits.c lib/hcrypto/libtommath/bn_mp_read_unsigned_bin.c lib/hcrypto/libtommath/bn_mp_read_signed_bin.c lib/hcrypto/libtommath/bn_mp_to_unsigned_bin.c lib/hcrypto/libtommath/bn_mp_to_signed_bin.c lib/hcrypto/libtommath/bn_mp_unsigned_bin_size.c lib/hcrypto/libtommath/bn_mp_signed_bin_size.c lib/hcrypto/libtommath/bn_mp_xor.c lib/hcrypto/libtommath/bn_mp_and.c lib/hcrypto/libtommath/bn_mp_or.c lib/hcrypto/libtommath/bn_mp_rand.c lib/hcrypto/libtommath/bn_mp_montgomery_calc_normalization.c lib/hcrypto/libtommath/bn_mp_prime_is_divisible.c lib/hcrypto/libtommath/bn_prime_tab.c lib/hcrypto/libtommath/bn_mp_prime_fermat.c lib/hcrypto/libtommath/bn_mp_prime_miller_rabin.c lib/hcrypto/libtommath/bn_mp_prime_is_prime.c lib/hcrypto/libtommath/bn_mp_prime_next_prime.c lib/hcrypto/libtommath/bn_mp_find_prime.c lib/hcrypto/libtommath/bn_mp_isprime.c lib/hcrypto/libtommath/bn_mp_dr_reduce.c lib/hcrypto/libtommath/bn_mp_dr_is_modulus.c lib/hcrypto/libtommath/bn_mp_dr_setup.c lib/hcrypto/libtommath/bn_mp_reduce_setup.c lib/hcrypto/libtommath/bn_mp_toom_mul.c lib/hcrypto/libtommath/bn_mp_toom_sqr.c lib/hcrypto/libtommath/bn_mp_div_3.c lib/hcrypto/libtommath/bn_s_mp_exptmod.c lib/hcrypto/libtommath/bn_mp_reduce_2k.c lib/hcrypto/libtommath/bn_mp_reduce_is_2k.c lib/hcrypto/libtommath/bn_mp_reduce_2k_setup.c lib/hcrypto/libtommath/bn_mp_reduce_2k_l.c lib/hcrypto/libtommath/bn_mp_reduce_is_2k_l.c lib/hcrypto/libtommath/bn_mp_reduce_2k_setup_l.c lib/hcrypto/libtommath/bn_mp_radix_smap.c lib/hcrypto/libtommath/bn_mp_read_radix.c lib/hcrypto/libtommath/bn_mp_toradix.c lib/hcrypto/libtommath/bn_mp_radix_size.c lib/hcrypto/libtommath/bn_mp_fread.c lib/hcrypto/libtommath/bn_mp_fwrite.c lib/hcrypto/libtommath/bn_mp_cnt_lsb.c lib/hcrypto/libtommath/bn_error.c lib/hcrypto/libtommath/bn_mp_init_multi.c lib/hcrypto/libtommath/bn_mp_clear_multi.c lib/hcrypto/libtommath/bn_mp_exteuclid.c lib/hcrypto/libtommath/bn_mp_toradix_n.c lib/hcrypto/libtommath/bn_mp_prime_random_ex.c lib/hcrypto/libtommath/bn_mp_get_int.c lib/hcrypto/libtommath/bn_mp_sqrt.c lib/hcrypto/libtommath/bn_mp_is_square.c lib/hcrypto/libtommath/bn_mp_init_set.c lib/hcrypto/libtommath/bn_mp_init_set_int.c lib/hcrypto/libtommath/bn_mp_invmod_slow.c lib/hcrypto/libtommath/bn_mp_prime_rabin_miller_trials.c lib/hcrypto/libtommath/bn_mp_to_signed_bin_n.c lib/hcrypto/libtommath/bn_mp_to_unsigned_bin_n.c',
745 includes='../heimdal/lib/hcrypto/libtommath'
748 HEIMDAL_LIBRARY('hcrypto',
749 'lib/hcrypto/aes.c lib/hcrypto/bn.c lib/hcrypto/dh.c lib/hcrypto/dh-ltm.c lib/hcrypto/des.c lib/hcrypto/dsa.c lib/hcrypto/engine.c lib/hcrypto/md2.c lib/hcrypto/md4.c lib/hcrypto/md5.c lib/hcrypto/rsa.c lib/hcrypto/rsa-ltm.c lib/hcrypto/rc2.c lib/hcrypto/rc4.c lib/hcrypto/rijndael-alg-fst.c lib/hcrypto/rnd_keys.c lib/hcrypto/sha.c lib/hcrypto/sha256.c lib/hcrypto/sha512.c lib/hcrypto/ui.c lib/hcrypto/evp.c lib/hcrypto/evp-hcrypto.c lib/hcrypto/pkcs5.c lib/hcrypto/pkcs12.c lib/hcrypto/rand.c lib/hcrypto/rand-egd.c lib/hcrypto/rand-unix.c lib/hcrypto/rand-fortuna.c lib/hcrypto/rand-timer.c lib/hcrypto/hmac.c lib/hcrypto/camellia.c lib/hcrypto/camellia-ntt.c lib/hcrypto/common.c lib/hcrypto/validate.c',
750 includes='../heimdal/lib/hcrypto ../heimdal/lib ../heimdal/include',
751 deps='roken asn1 tommath replace',
752 version_script='lib/hcrypto/version-script.map',
753 vnum='5.0.1',
756 if not bld.CONFIG_SET('USING_SYSTEM_HEIMBASE'):
757 HEIMDAL_LIBRARY('heimbase',
758 'base/array.c base/bool.c base/dict.c base/heimbase.c base/string.c base/number.c base/null.c',
759 includes='../heimdal/base ../heimdal/include',
760 deps='roken replace',
761 version_script='base/version-script.map',
762 vnum='1.0.0',
766 if not bld.CONFIG_SET("USING_SYSTEM_HX509"):
767 HEIMDAL_ASN1('HEIMDAL_OCSP_ASN1',
768 'lib/hx509/ocsp.asn1',
769 options='--preserve-binary=OCSPTBSRequest --preserve-binary=OCSPResponseData',
770 includes='../heimdal/lib/asn1',
771 directory='lib/hx509'
774 HEIMDAL_ASN1('HEIMDAL_PKCS8_ASN1',
775 'lib/asn1/pkcs8.asn1',
776 directory='lib/asn1'
780 HEIMDAL_ASN1('HEIMDAL_PKCS9_ASN1',
781 'lib/asn1/pkcs9.asn1',
782 directory='lib/asn1'
786 HEIMDAL_ASN1('HEIMDAL_PKCS12_ASN1',
787 'lib/asn1/pkcs12.asn1',
788 directory='lib/asn1'
791 HEIMDAL_ASN1('HEIMDAL_PKCS10_ASN1',
792 'lib/hx509/pkcs10.asn1',
793 options='--preserve-binary=CertificationRequestInfo',
794 includes='../heimdal/lib/asn1',
795 directory='lib/hx509'
798 HEIMDAL_ERRTABLE('HEIMDAL_HX509_ERR_ET',
799 'lib/hx509/hx509_err.et')
801 HEIMDAL_HX509_OBJH_SOURCE = '''
802 lib/hx509/ca.c
803 lib/hx509/cert.c
804 lib/hx509/cms.c
805 lib/hx509/collector.c
806 lib/hx509/crypto.c
807 lib/hx509/error.c
808 lib/hx509/env.c
809 lib/hx509/file.c
810 lib/hx509/keyset.c
811 lib/hx509/ks_dir.c
812 lib/hx509/ks_file.c
813 lib/hx509/ks_keychain.c
814 lib/hx509/ks_mem.c
815 lib/hx509/ks_null.c
816 lib/hx509/ks_p11.c
817 lib/hx509/ks_p12.c
818 lib/hx509/lock.c
819 lib/hx509/name.c
820 lib/hx509/peer.c
821 lib/hx509/print.c
822 lib/hx509/req.c
823 lib/hx509/revoke.c
824 lib/hx509/sel.c
825 lib/hx509/hx509_err.c
828 HEIMDAL_AUTOPROTO('lib/hx509/hx509-protos.h',
829 HEIMDAL_HX509_OBJH_SOURCE,
830 options="-R '^(_|^C)' -E HX509_LIB -q -P comment -o")
832 HEIMDAL_AUTOPROTO('lib/hx509/hx509-private.h',
833 HEIMDAL_HX509_OBJH_SOURCE,
834 options="-q -P comment -p")
836 HEIMDAL_LIBRARY('hx509',
837 'lib/hx509/ca.c lib/hx509/cert.c lib/hx509/cms.c lib/hx509/collector.c lib/hx509/crypto.c lib/hx509/error.c lib/hx509/env.c lib/hx509/file.c lib/hx509/keyset.c lib/hx509/ks_dir.c lib/hx509/ks_file.c lib/hx509/ks_keychain.c lib/hx509/ks_mem.c lib/hx509/ks_null.c lib/hx509/ks_p11.c lib/hx509/ks_p12.c lib/hx509/lock.c lib/hx509/name.c lib/hx509/peer.c lib/hx509/print.c lib/hx509/req.c lib/hx509/revoke.c lib/hx509/sel.c lib/hx509/hx509_err.c lib/hx509/sel-lex.c lib/hx509/sel-gram.c',
838 includes='../heimdal/lib/hx509',
839 deps='roken com_err asn1 hcrypto asn1 HEIMDAL_OCSP_ASN1 HEIMDAL_PKCS8_ASN1 HEIMDAL_PKCS9_ASN1 HEIMDAL_PKCS12_ASN1 HEIMDAL_PKCS10_ASN1 wind',
840 vnum='5.0.0',
841 version_script='lib/hx509/version-script.map',
844 if not bld.CONFIG_SET('USING_SYSTEM_WIND'):
845 HEIMDAL_ERRTABLE('WIND_ERR_ET',
846 'lib/wind/wind_err.et')
848 HEIMDAL_GENERATOR(
849 name="HEIMDAL_ERRORLIST",
850 rule="${PYTHON} '${SRC[0].abspath()}' '${SRC[1].abspath()}' '${SRC[1].parent.abspath(env)}'",
851 source = '../heimdal/lib/wind/gen-errorlist.py ../heimdal/lib/wind/rfc3454.txt ../heimdal/lib/wind/stringprep.py',
852 target = '../heimdal/lib/wind/errorlist_table.c ../heimdal/lib/wind/errorlist_table.h'
856 HEIMDAL_GENERATOR(
857 name = 'HEIMDAL_NORMALIZE_TABLE',
858 rule="${PYTHON} '${SRC[0].abspath()}' '${SRC[1].abspath()}' '${SRC[2].abspath()}' '${SRC[1].parent.abspath(env)}'",
859 source = '../heimdal/lib/wind/gen-normalize.py ../heimdal/lib/wind/UnicodeData.txt ../heimdal/lib/wind/CompositionExclusions-3.2.0.txt',
860 target = '../heimdal/lib/wind/normalize_table.h ../heimdal/lib/wind/normalize_table.c'
863 HEIMDAL_GENERATOR(
864 name = 'HEIMDAL_COMBINING_TABLE',
865 rule="${PYTHON} '${SRC[0].abspath()}' '${SRC[1].abspath()}' '${SRC[1].parent.abspath(env)}'",
866 source = '../heimdal/lib/wind/gen-combining.py ../heimdal/lib/wind/UnicodeData.txt',
867 target = '../heimdal/lib/wind/combining_table.h ../heimdal/lib/wind/combining_table.c'
870 HEIMDAL_GENERATOR(
871 name = 'HEIMDAL_BIDI_TABLE',
872 rule="${PYTHON} '${SRC[0].abspath()}' '${SRC[1].abspath()}' '${SRC[1].parent.abspath(env)}'",
873 source = '../heimdal/lib/wind/gen-bidi.py ../heimdal/lib/wind/rfc3454.txt',
874 target = '../heimdal/lib/wind/bidi_table.h ../heimdal/lib/wind/bidi_table.c'
878 HEIMDAL_GENERATOR(
879 name = 'HEIMDAL_MAP_TABLE',
880 rule="${PYTHON} '${SRC[0].abspath()}' '${SRC[2].abspath()}' '${SRC[2].parent.abspath(env)}'",
881 source = '../heimdal/lib/wind/gen-map.py ../heimdal/lib/wind/stringprep.py ../heimdal/lib/wind/rfc3454.txt',
882 target = '../heimdal/lib/wind/map_table.h ../heimdal/lib/wind/map_table.c'
885 HEIMDAL_LIBRARY('wind',
886 'lib/wind/wind_err.c lib/wind/stringprep.c lib/wind/errorlist.c lib/wind/errorlist_table.c lib/wind/normalize.c lib/wind/normalize_table.c lib/wind/combining.c lib/wind/combining_table.c lib/wind/utf8.c lib/wind/bidi.c lib/wind/bidi_table.c lib/wind/ldap.c lib/wind/map.c lib/wind/map_table.c',
887 includes='../heimdal/lib/wind',
888 deps='roken com_err',
889 vnum='0.0.0',
890 version_script='lib/wind/version-script.map',
893 if not bld.CONFIG_SET('USING_SYSTEM_COM_ERR'):
894 HEIMDAL_LIBRARY('com_err',
895 'lib/com_err/com_err.c lib/com_err/error.c',
896 includes='../heimdal/lib/com_err',
897 deps='roken intl',
898 vnum='0.25',
899 version_script='lib/com_err/version-script.map',
902 HEIMDAL_SUBSYSTEM('HEIMDAL_VERS_HOSTCC',
903 'lib/vers/print_version.c ../heimdal_build/version.c',
904 group='build_compilers',
905 deps='LIBREPLACE_HOSTCC ROKEN_HOSTCC',
906 use_global_deps=False,
907 use_hostcc=True)
909 HEIMDAL_SUBSYSTEM('HEIMDAL_VERS',
910 'lib/vers/print_version.c ../heimdal_build/version.c',
911 group='build_compilers',
912 deps='roken replace')
915 if not bld.CONFIG_SET('USING_SYSTEM_ASN1_COMPILE'):
916 # here is the asn1 compiler build rule
917 HEIMDAL_BINARY('asn1_compile',
918 'lib/asn1/main.c lib/asn1/gen.c lib/asn1/gen_copy.c lib/asn1/gen_decode.c lib/asn1/gen_encode.c lib/asn1/gen_free.c lib/asn1/gen_glue.c lib/asn1/gen_length.c lib/asn1/gen_seq.c lib/asn1/gen_template.c lib/asn1/hash.c lib/asn1/symbol.c lib/asn1/asn1parse.c lib/asn1/lex.c',
919 use_hostcc=True,
920 use_global_deps=False,
921 cflags='-DSOCKET_WRAPPER_DISABLE=1 -DNSS_WRAPPER_DISABLE=1 -D_SAMBA_HOSTCC_',
922 includes='../heimdal/lib/asn1',
923 group='build_compilers',
924 deps='ROKEN_HOSTCC LIBREPLACE_HOSTCC HEIMDAL_VERS_HOSTCC',
925 install=False
927 bld.env['ASN1_COMPILE'] = os.path.join(bld.env['BUILD_DIRECTORY'], 'asn1_compile')
930 if not bld.CONFIG_SET('USING_SYSTEM_COMPILE_ET'):
931 HEIMDAL_BINARY('compile_et',
932 'lib/com_err/parse.c lib/com_err/lex.c lib/com_err/compile_et.c',
933 use_hostcc=True,
934 use_global_deps=False,
935 includes='../heimdal/lib/com_err',
936 group='build_compilers',
937 cflags='-DSOCKET_WRAPPER_DISABLE=1 -DNSS_WRAPPER_DISABLE=1 -D_SAMBA_HOSTCC_',
938 deps='ROKEN_HOSTCC LIBREPLACE_HOSTCC HEIMDAL_VERS_HOSTCC',
939 install=False
941 bld.env['COMPILE_ET'] = os.path.join(bld.env['BUILD_DIRECTORY'], 'compile_et')
943 HEIMDAL_BINARY('samba4kinit',
944 'kuser/kinit.c',
945 deps='krb5 heimntlm roken HEIMDAL_VERS hcrypto',
946 install=False
949 HEIMDAL_BINARY('samba4kgetcred',
950 'kuser/kgetcred.c',
951 deps='krb5 heimntlm roken HEIMDAL_VERS hcrypto',
952 install=False
955 HEIMDAL_BINARY('samba4kpasswd',
956 'kpasswd/kpasswd.c',
957 deps='krb5 heimntlm roken HEIMDAL_VERS hcrypto',
958 install=False
961 # Alias subsystem to allow common kerberos code that will
962 # otherwise link against MIT's gssapi_krb5 and k5crypto
964 # Note: that we also need this if we use system heimdal libraries
965 HEIMDAL_SUBSYSTEM('gssapi_krb5', '', deps='gssapi')
966 HEIMDAL_SUBSYSTEM('k5crypto', '', deps='krb5')