summaryrefslogtreecommitdiff
path: root/source4/lib/ldb/wscript
diff options
context:
space:
mode:
authorRusty Russell <rusty@rustcorp.com.au>2011-06-20 18:40:25 +0930
committerRusty Russell <rusty@rustcorp.com.au>2011-06-20 11:18:34 +0200
commit0e4c358e2710580d5aeb439d767c87aaf4c0f2f3 (patch)
treeaeca32c597485b907e017e7dd580c9603af14ee2 /source4/lib/ldb/wscript
parent61bf43f5d17c9ac3fc9a36cab74a81f26ac97ccb (diff)
downloadsamba-0e4c358e2710580d5aeb439d767c87aaf4c0f2f3.tar.gz
samba-0e4c358e2710580d5aeb439d767c87aaf4c0f2f3.tar.bz2
samba-0e4c358e2710580d5aeb439d767c87aaf4c0f2f3.zip
tdb_compat.h: divert every tdb build and includes to tdb_compat
We change all the headers and wscript files to use tdb_compat; this means we have one place to decide whether to use TDB1 or TDB2. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Diffstat (limited to 'source4/lib/ldb/wscript')
-rwxr-xr-xsource4/lib/ldb/wscript17
1 files changed, 11 insertions, 6 deletions
diff --git a/source4/lib/ldb/wscript b/source4/lib/ldb/wscript
index b59e782e45..393f99f630 100755
--- a/source4/lib/ldb/wscript
+++ b/source4/lib/ldb/wscript
@@ -16,29 +16,33 @@ sys.path.insert(0, srcdir + '/buildtools/wafsamba')
import wafsamba, samba_dist, Options
samba_dist.DIST_DIRS('''source4/lib/ldb:. lib/replace:lib/replace lib/talloc:lib/talloc
- lib/tdb:lib/tdb lib/tevent:lib/tevent lib/popt:lib/popt
+ lib/tdb:lib/tdb lib/tdb_compat:lib/tdb_compat lib/ccan:lib/ccan lib/tevent:lib/tevent lib/popt:lib/popt
buildtools:buildtools''')
def set_options(opt):
opt.BUILTIN_DEFAULT('replace')
opt.PRIVATE_EXTENSION_DEFAULT('ldb', noextension='ldb')
- opt.RECURSE('lib/tdb')
+ opt.RECURSE('lib/tdb_compat')
opt.RECURSE('lib/tevent')
opt.RECURSE('lib/replace')
opt.tool_options('python') # options for disabling pyc or pyo compilation
def configure(conf):
- conf.RECURSE('lib/tdb')
+ conf.RECURSE('lib/tdb_compat')
conf.RECURSE('lib/tevent')
conf.RECURSE('lib/popt')
conf.RECURSE('lib/replace')
+ conf.RECURSE('lib/tdb_compat')
conf.find_program('python', var='PYTHON')
conf.find_program('xsltproc', var='XSLTPROC')
conf.check_tool('python')
conf.check_python_version((2,4,2))
conf.SAMBA_CHECK_PYTHON_HEADERS(mandatory=True)
+ # This make #include <ccan/...> work.
+ conf.ADD_EXTRA_INCLUDES('''#lib''')
+
# where does the default LIBDIR end up? in conf.env somewhere?
#
conf.CONFIG_PATH('LDB_MODULESDIR', conf.SUBST_ENV_VAR('MODULESDIR') + '/ldb')
@@ -72,10 +76,11 @@ def configure(conf):
conf.SAMBA_CONFIG_H()
def build(bld):
- bld.RECURSE('lib/tdb')
+ bld.RECURSE('lib/tdb_compat')
bld.RECURSE('lib/tevent')
bld.RECURSE('lib/popt')
bld.RECURSE('lib/replace')
+ bld.RECURSE('lib/tdb_compat')
if bld.env.standalone_ldb:
private_library = False
@@ -233,14 +238,14 @@ def build(bld):
init_function='ldb_tdb_init',
module_init_name='ldb_init_module',
internal_module=False,
- deps='tdb ldb',
+ deps='tdb_compat ldb',
subsystem='ldb')
# have a separate subsystem for common/ldb.c, so it can rebuild
# for install with a different -DLDB_MODULESDIR=
bld.SAMBA_SUBSYSTEM('LIBLDB_MAIN',
'common/ldb.c',
- deps='tevent',
+ deps='tevent tdb_compat',
includes='include',
cflags=['-DLDB_MODULESDIR=\"%s\"' % modules_dir])