build: neater way to find libreplace and start on tevent waf build
[ira/wip.git] / lib / tdb / wscript
1 VERSION='1.2.1'
2
3 srcdir = '.'
4 blddir = 'build'
5
6 LIBREPLACE_DIR='../replace'
7
8 def set_options(opt):
9     opt.recurse(LIBREPLACE_DIR)
10
11 def configure(conf):
12     conf.sub_config(LIBREPLACE_DIR)
13     conf.SAMBA_CONFIG_H()
14
15 def build(bld):
16     bld.add_subdirs(LIBREPLACE_DIR)
17
18     COMMON_SRC = bld.SUBDIR('common',
19                             '''check.c error.c tdb.c traverse.c
20                             freelistcheck.c lock.c dump.c freelist.c
21                             io.c open.c transaction.c''')
22
23     bld.SAMBA_LIBRARY('tdb',
24                       COMMON_SRC,
25                       libdeps='replace talloc',
26                       include_list='include',
27                       vnum=VERSION)
28
29     bld.SAMBA_BINARY('tdbtorture',
30                      'tools/tdbtorture.c',
31                      'tdb')
32
33     bld.SAMBA_BINARY('tdbdump',
34                      'tools/tdbdump.c',
35                      'tdb')
36
37     bld.SAMBA_BINARY('tdbbackup',
38                      'tools/tdbbackup.c',
39                      'tdb')
40
41     bld.SAMBA_BINARY('tdbtool',
42                      'tools/tdbtool.c',
43                      'tdb')