summaryrefslogtreecommitdiff
path: root/source4/heimdal_build/wscript_configure
diff options
context:
space:
mode:
authorJelmer Vernooij <jelmer@samba.org>2011-01-01 01:25:10 +0100
committerJelmer Vernooij <jelmer@samba.org>2011-01-01 04:00:03 +0100
commit3febaed9ba9e02ba43259023c4e8255e53c0ad85 (patch)
tree546152e558b5d93e054cab36ec0617ebfe3f01dd /source4/heimdal_build/wscript_configure
parent5792fa90ace06f736661d9924ec9a75c3a0a9771 (diff)
downloadsamba-3febaed9ba9e02ba43259023c4e8255e53c0ad85.tar.gz
samba-3febaed9ba9e02ba43259023c4e8255e53c0ad85.tar.bz2
samba-3febaed9ba9e02ba43259023c4e8255e53c0ad85.zip
heimdal_build: Look for asn1_compile (but by default, don't use it).
Diffstat (limited to 'source4/heimdal_build/wscript_configure')
-rw-r--r--source4/heimdal_build/wscript_configure26
1 files changed, 20 insertions, 6 deletions
diff --git a/source4/heimdal_build/wscript_configure b/source4/heimdal_build/wscript_configure
index 5936b0441b..63be7b701c 100644
--- a/source4/heimdal_build/wscript_configure
+++ b/source4/heimdal_build/wscript_configure
@@ -1,4 +1,12 @@
#!/usr/bin/env python
+# Waf build script for Samba 4's bundled Heimdal.
+
+# Unless explicitly requested by the user (e.g.
+# "./configure --bundled-libraries=!asn1_compile") this will always use the
+# bundled Heimdal, even if a system heimdal was found. The reason
+# for this is that our checks for the system heimdal are not accurate
+# enough yet to know if it is usable (some bug fix might be missing,
+# compile_et might not generate the expected code, etc).
import Logs, sys
@@ -66,7 +74,8 @@ if conf.CHECK_BUNDLED_SYSTEM('com_err', checkfunctions='com_right_r com_err', he
conf.define('USING_SYSTEM_COM_ERR', 1)
def check_system_heimdal_lib(name, functions='', headers='', onlyif=None):
- # Only use system library if the user requested the bundled one not be used.
+ # Only use system library if the user requested the bundled one not be
+ # used.
if conf.LIB_MAY_BE_BUNDLED(name):
return False
setattr(conf.env, "CPPPATH_%s" % name.upper(), ["/usr/include/heimdal"])
@@ -76,6 +85,14 @@ def check_system_heimdal_lib(name, functions='', headers='', onlyif=None):
conf.define('USING_SYSTEM_%s' % name.upper(), 1)
return True
+def check_system_heimdal_binary(name):
+ if conf.LIB_MAY_BE_BUNDLED(name):
+ return False
+ if not conf.find_program(name, var=name.upper()):
+ return False
+ conf.define('USING_SYSTEM_%s' % name.upper(), 1)
+ return True
+
if check_system_heimdal_lib("roken", "rk_socket_set_reuseaddr", "roken.h"):
conf.env.CPPPATH_ROKEN_HOSTCC = conf.env.CPPPATH_ROKEN
conf.env.LIBPATH_ROKEN_HOSTCC = conf.env.LIBPATH_ROKEN
@@ -92,8 +109,5 @@ check_system_heimdal_lib("hcrypto", "MD4_Init", "hcrypto/md4.h",
# conf.CHECK_BUNDLED_SYSTEM('tommath', checkfunctions='mp_init', headers='tommath.h')
# conf.define('USING_SYSTEM_TOMMATH', 1)
-# disable trying to use an external compile_et until we have a configure
-# test that checks that the system one actually works. On some systems it
-# results in missing symbols (eg. OpenSUSE 10.2 'opi' in the build farm)
-#if conf.find_program('compile_et', var='COMPILE_ET'):
-# conf.define('USING_SYSTEM_COMPILE_ET', 1)
+check_system_heimdal_binary("compile_et")
+check_system_heimdal_binary("asn1_compile")