open(IN, $smbd_build_options) or die("Unable to run $smbd_build_options: $!");
while (<IN>) {
- if (/WITH_ADS/) {
+ if (/HAVE_ADS/) {
$found_ads = 1;
}
}
#include <valgrind.h>
#endif
-/* we support ADS if we want it and have krb5 and ldap libs */
-#if defined(WITH_ADS) && defined(HAVE_KRB5) && defined(HAVE_LDAP)
-#define HAVE_ADS
-#endif
-
/*
* Define additional missing types
*/
ndr_print_struct(ndr, name, "saslwrap");
ndr->depth++;
ndr_print_uint16(ndr, "wrap_type", r->wrap_type);
-#ifdef HAVE_LDAP_SASL_WRAPPING
+#ifdef HAVE_ADS
ndr_print_ptr(ndr, "sbiod", r->sbiod);
-#endif /* HAVE_LDAP_SASL_WRAPPING */
+#endif /* HAVE_ADS */
ndr_print_ptr(ndr, "mem_ctx", r->mem_ctx);
ndr_print_ptr(ndr, "wrap_ops", r->wrap_ops);
ndr_print_ptr(ndr, "wrap_private_data", r->wrap_private_data);
ndr->depth--;
}
-#ifdef HAVE_LDAP_SASL_WRAPPING
+#ifdef HAVE_ADS
static int ads_saslwrap_setup(Sockbuf_IO_Desc *sbiod, void *arg)
{
{
return ADS_ERROR_NT(NT_STATUS_NOT_SUPPORTED);
}
-#endif /* HAVE_LDAP_SASL_WRAPPING */
+#endif /* HAVE_ADS */
typedef [nopull,nopush] struct {
ads_saslwrap_type wrap_type;
[ignore] ads_saslwrap_ops *wrap_ops;
-#ifdef HAVE_LDAP_SASL_WRAPPING
+#ifdef HAVE_ADS
[ignore] struct sockbuf_io_desc *sbiod; /* lowlevel state for LDAP wrapping */
-#endif /* HAVE_LDAP_SASL_WRAPPING */
+#endif /* HAVE_ADS */
[ignore] TALLOC_CTX *mem_ctx;
[ignore] void *wrap_private_data;
ads_ldap_buf_in in;
/* info derived from the servers config */
ads_config config;
-#ifdef HAVE_LDAP
+#ifdef HAVE_ADS
ads_saslwrap ldap_wrap_data;
/* info about the current LDAP connection */
ads_ldap ldap;
-#endif /* HAVE_LDAP */
+#endif /* HAVE_ADS */
} ads_struct;
}
conf.undefine('HAVE_GSSAPI_GSSAPI_H')
use_ads = False
- if not conf.CONFIG_SET('HAVE_LDAP'):
+ if not conf.CONFIG_SET('HAVE_LDAP_TRANSPORT_WRAPPING'):
+ Logs.warn("need ber_sockbuf_add_io() and LDAP_OPT_SOCKBUF for SASL and TLS support")
use_ads = False
use_ads_ldap = False
if use_ads:
- conf.DEFINE('WITH_ADS', '1')
- conf.env['HAVE_ADS'] = '1'
+ conf.DEFINE('HAVE_ADS', '1')
Logs.info("Building with Active Directory support.")
# these have broken dependencies
forced_shared_modules.extend(['idmap_ad', 'idmap_rfc2307'])
'gen_output.py',
'samba_downgrade_db']:
bld.SAMBA_SCRIPT(script, pattern=script, installdir='.')
-if bld.CONFIG_SET('WITH_ADS'):
+if bld.CONFIG_SET('HAVE_ADS'):
bld.SAMBA_SCRIPT('samba-tool', pattern='samba-tool', installdir='.')
bld.SAMBA_SCRIPT('samba-gpupdate', pattern='samba-gpupdate', installdir='.')
if 'XSLTPROC_MANPAGES' in bld.env and bld.env['XSLTPROC_MANPAGES']:
bld.MANPAGES(man_files, True)
-if bld.CONFIG_SET('WITH_ADS'):
+if bld.CONFIG_SET('HAVE_ADS'):
bld.INSTALL_FILES('${BINDIR}',
'bin/samba-tool',
chmod=MODE_755, python_fixup=True, flat=True)
# SASL wrapping hooks
if conf.CONFIG_SET('HAVE_BER_SOCKBUF_ADD_IO') and \
conf.CONFIG_SET('HAVE_LDAP_OPT_SOCKBUF'):
- conf.DEFINE('HAVE_LDAP_SASL_WRAPPING', '1')
+ conf.DEFINE('HAVE_LDAP_TRANSPORT_WRAPPING', 1)
conf.env.ENABLE_LDAP_BACKEND = True
else:
conf.fatal("LDAP support not found. "