From 4ea992428bbfea18b261ce28417228be730ffbc8 Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Sat, 1 Jan 2011 01:54:35 +0100 Subject: [PATCH] heimdal_build: Allow using system heimntlm. --- source4/heimdal_build/wscript_build | 26 +++++++++++++------------ source4/heimdal_build/wscript_configure | 2 ++ 2 files changed, 16 insertions(+), 12 deletions(-) diff --git a/source4/heimdal_build/wscript_build b/source4/heimdal_build/wscript_build index c71e22494bb..217eb227470 100644 --- a/source4/heimdal_build/wscript_build +++ b/source4/heimdal_build/wscript_build @@ -493,18 +493,20 @@ HEIMDAL_LIBRARY('kdc', source=KDC_SOURCE, HEIMDAL_AUTOPROTO('kdc/kdc-protos.h', KDC_SOURCE) HEIMDAL_AUTOPROTO_PRIVATE('kdc/kdc-private.h', KDC_SOURCE) -HEIMDAL_ERRTABLE('HEIMNTLM_ET', - 'lib/ntlm/ntlm_err.et') - -HEIMNTLM_SOURCE = 'lib/ntlm/ntlm.c' -HEIMDAL_LIBRARY('heimntlm', - source=HEIMNTLM_SOURCE, - includes='../heimdal/lib/ntlm', - deps='roken hcrypto krb5', - vnum='1.0.1', - version_script='lib/ntlm/version-script.map', - ) -HEIMDAL_AUTOPROTO('lib/ntlm/heimntlm-protos.h', HEIMNTLM_SOURCE) + +if not bld.CONFIG_SET("USING_SYSTEM_HEIMNTLM"): + HEIMDAL_ERRTABLE('HEIMNTLM_ET', + 'lib/ntlm/ntlm_err.et') + + HEIMNTLM_SOURCE = 'lib/ntlm/ntlm.c' + HEIMDAL_LIBRARY('heimntlm', + source=HEIMNTLM_SOURCE, + includes='../heimdal/lib/ntlm', + deps='roken hcrypto krb5', + vnum='1.0.1', + version_script='lib/ntlm/version-script.map', + ) + HEIMDAL_AUTOPROTO('lib/ntlm/heimntlm-protos.h', HEIMNTLM_SOURCE) HEIMDAL_SUBSYSTEM('HEIMDAL_HDB_KEYS', diff --git a/source4/heimdal_build/wscript_configure b/source4/heimdal_build/wscript_configure index 63be7b701ca..5090df9d8ea 100644 --- a/source4/heimdal_build/wscript_configure +++ b/source4/heimdal_build/wscript_configure @@ -104,6 +104,8 @@ check_system_heimdal_lib("asn1", "initialize_asn1_error_table", "asn1_err.h", on check_system_heimdal_lib("heimbase", "heim_cmp", "heimbase.h", onlyif="roken") check_system_heimdal_lib("hcrypto", "MD4_Init", "hcrypto/md4.h", onlyif="asn1 roken com_err") +check_system_heimdal_lib("heimntlm", "heim_ntlm_ntlmv2_key", "heimntlm.h", + onlyif="roken hcrypto krb5") # With the proper checks in place we should be able to build against the system libtommath. # conf.CHECK_BUNDLED_SYSTEM('tommath', checkfunctions='mp_init', headers='tommath.h') -- 2.34.1