summaryrefslogtreecommitdiff
path: root/source4/lib
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2010-04-04 13:16:49 +1000
committerAndrew Tridgell <tridge@samba.org>2010-04-06 20:27:25 +1000
commitc8835f440a7e07f385f5759bae6b4e53c1927e82 (patch)
tree7cc1500da172b98371c03217f9061196fad25994 /source4/lib
parent553324bc1022635e05a683c4bec5135d845f6fea (diff)
downloadsamba-c8835f440a7e07f385f5759bae6b4e53c1927e82.tar.gz
samba-c8835f440a7e07f385f5759bae6b4e53c1927e82.tar.bz2
samba-c8835f440a7e07f385f5759bae6b4e53c1927e82.zip
s4-waf: use a common pattern for finding buildtools and libs
Diffstat (limited to 'source4/lib')
-rw-r--r--source4/lib/ldb/wscript31
1 files changed, 14 insertions, 17 deletions
diff --git a/source4/lib/ldb/wscript b/source4/lib/ldb/wscript
index 9d3eddfc99..da83b7c26f 100644
--- a/source4/lib/ldb/wscript
+++ b/source4/lib/ldb/wscript
@@ -6,33 +6,30 @@ VERSION = '0.9.10'
blddir = 'bin'
import sys, os
+
# find the buildtools directory
-buildtools = 'buildtools'
-while not os.path.exists(buildtools) and len(buildtools.split('/')) < 5:
- buildtools = '../' + buildtools
-srcdir = os.path.dirname(buildtools) or '.'
+srcdir = '.'
+while not os.path.exists(srcdir+'/buildtools') and len(srcdir.split('/')) < 5:
+ srcdir = '../' + srcdir
+sys.path.insert(0, srcdir + '/buildtools/wafsamba')
-sys.path.insert(0, buildtools + "/wafsamba")
import wafsamba, samba_dist
samba_dist.DIST_DIRS('''lib/ldb:. lib/replace:lib/replace lib/talloc:lib/talloc
lib/tdb:lib/tdb lib/tevent:lib/tevent buildtools:buildtools''')
-LIBTDB_DIR= '../../../lib/tdb'
-LIBTEVENT_DIR= '../../../lib/tevent'
-LIBPOPT_DIR= '../../../lib/popt'
-
def set_options(opt):
opt.BUILTIN_DEFAULT('replace')
opt.BUNDLED_EXTENSION_DEFAULT('ldb', noextenion='ldb')
- opt.RECURSE(LIBTDB_DIR)
- opt.RECURSE(LIBTEVENT_DIR)
+ opt.RECURSE('lib/tdb')
+ opt.RECURSE('lib/tevent')
def configure(conf):
- conf.RECURSE(LIBTDB_DIR)
- conf.RECURSE(LIBTEVENT_DIR)
- conf.RECURSE(LIBPOPT_DIR)
+ conf.RECURSE('lib/tdb')
+ conf.RECURSE('lib/tevent')
+ conf.RECURSE('lib/popt')
+
# where does the default LIBDIR end up? in conf.env somewhere?
#
conf.CONFIG_PATH('LDB_MODULESDIR', conf.SUBST_ENV_VAR('MODULESDIR') + '/ldb')
@@ -53,9 +50,9 @@ def configure(conf):
conf.SAMBA_CONFIG_H()
def build(bld):
- bld.RECURSE(LIBTDB_DIR)
- bld.RECURSE(LIBTEVENT_DIR)
- bld.RECURSE(LIBPOPT_DIR)
+ bld.RECURSE('lib/tdb')
+ bld.RECURSE('lib/tevent')
+ bld.RECURSE('lib/popt')
# in Samba4 we build some extra modules, and add extra
# capabilities to the ldb cmdline tools