build: need to mark disabled libraries as DISABLED
authorAndrew Tridgell <tridge@samba.org>
Wed, 24 Mar 2010 05:25:37 +0000 (16:25 +1100)
committerAndrew Tridgell <tridge@samba.org>
Tue, 6 Apr 2010 10:27:05 +0000 (20:27 +1000)
buildtools/wafsamba/samba_utils.py
source4/lib/tls/wscript

index fe290a33e17bed22b722c5c0efe53ed4ff56480c..59003d8212632f0c1670d8df9f4e1fc64af79b9e 100644 (file)
@@ -23,6 +23,7 @@ def NEW_NODE(node, name):
 #############################################################
 # set a value in a local cache
 # return False if it's already set
+@conf
 def SET_TARGET_TYPE(ctx, target, value):
     cache = LOCAL_CACHE(ctx, 'TARGET_TYPE')
     if target in cache:
index 6f517de48d94e576959e3bf440d0c165455352bb..c8427c781fe296a18118c58d886529b79b5eeb3a 100644 (file)
@@ -12,6 +12,9 @@ def set_options(opt):
 def configure(conf):
     conf.env.enable_gnutls = Options.options.enable_gnutls
     if not conf.env.enable_gnutls:
+        conf.SET_TARGET_TYPE('gnutls', 'DISABLED')
+        conf.SET_TARGET_TYPE('gcrypt', 'DISABLED')
+        conf.SET_TARGET_TYPE('gpg-error', 'DISABLED')
         return
 
     conf.check_cfg(package='gnutls',
@@ -44,6 +47,5 @@ def configure(conf):
 def build(bld):
     bld.SAMBA_SUBSYSTEM('LIBTLS',
                         source='tls.c tlscert.c',
-                        public_deps='talloc gnutls gcrypt LIBSAMBA-HOSTCONFIG samba_socket',
-                        enabled = bld.env.enable_gnutls
+                        public_deps='talloc gnutls gcrypt LIBSAMBA-HOSTCONFIG samba_socket'
                         )