if conf.CHECK_FUNCS_IN('ber_flush ldap_open ldap_initialize', 'lber ldap', headers='lber.h ldap.h'):
conf.env.ENABLE_LDAP_BACKEND = True
- conf.DEFINE('LDB_VERSION', VERSION, quote=True)
-
conf.DEFINE('HAVE_CONFIG_H', 1, add_to_cflags=True)
# we don't want any libraries or modules to rely on runtime
abi_directory = 'ABI',
abi_match = abi_match)
+ # generate a include/ldb_version.h
+ t = bld.SAMBA_GENERATOR('ldb_version.h',
+ rule='echo "#define LDB_VERSION \\"${LDB_VERSION}\\"" > ${TGT}',
+ target='include/ldb_version.h',
+ public_headers='include/ldb_version.h')
+ t.env.LDB_VERSION = VERSION
+ bld.add_manual_dependency(bld.path.find_or_declare('include/ldb_version.h'), VERSION)
+
+
bld.SAMBA_PYTHON('pyldb', 'pyldb.c',
deps='ldb pyldb-util',