summaryrefslogtreecommitdiff
path: root/lib/replace/wscript
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2010-04-04 13:08:05 +1000
committerAndrew Tridgell <tridge@samba.org>2010-04-06 20:27:25 +1000
commit553324bc1022635e05a683c4bec5135d845f6fea (patch)
tree7d8aa296c7e433793e47bf1227310973a4aed7e9 /lib/replace/wscript
parent8dc8d31f4adf84f35bce34339e13e9d70c4b8a66 (diff)
downloadsamba-553324bc1022635e05a683c4bec5135d845f6fea.tar.gz
samba-553324bc1022635e05a683c4bec5135d845f6fea.tar.bz2
samba-553324bc1022635e05a683c4bec5135d845f6fea.zip
s4-waf: move to a universal method of recursing into subdirs
This works with both standalone lib builds and bundled builds
Diffstat (limited to 'lib/replace/wscript')
-rw-r--r--lib/replace/wscript18
1 files changed, 8 insertions, 10 deletions
diff --git a/lib/replace/wscript b/lib/replace/wscript
index af70c47a24..70475c4f29 100644
--- a/lib/replace/wscript
+++ b/lib/replace/wscript
@@ -8,12 +8,10 @@ blddir = 'bin'
import sys, os, Utils
# 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 '.'
-
-sys.path.insert(0, buildtools + "/wafsamba")
+srcdir = '.'
+while not os.path.exists(srcdir+'/buildtools') and len(srcdir.split('/')) < 5:
+ srcdir = '../' + srcdir
+sys.path.insert(0, srcdir + '/buildtools/wafsamba')
import wafsamba, samba_dist
import Options, os, preproc
@@ -23,11 +21,11 @@ samba_dist.DIST_DIRS('lib/replace buildtools:buildtools')
def set_options(opt):
opt.BUILTIN_DEFAULT('NONE')
opt.BUNDLED_EXTENSION_DEFAULT('')
- opt.recurse('../../buildtools/wafsamba')
+ opt.RECURSE('buildtools/wafsamba')
@wafsamba.runonce
def configure(conf):
- conf.sub_config('../../buildtools/wafsamba')
+ conf.RECURSE('buildtools/wafsamba')
conf.DEFINE('LIBREPLACE_NETWORK_CHECKS', 1)
@@ -290,12 +288,12 @@ def configure(conf):
define='REPLACE_GETPASS',
cflags='-DNO_CONFIG_H')
- conf.sub_config('system')
+ conf.RECURSE('system')
conf.SAMBA_CONFIG_H()
def build(bld):
- bld.BUILD_SUBDIR('../../buildtools/wafsamba')
+ bld.RECURSE('buildtools/wafsamba')
REPLACE_SOURCE = 'replace.c snprintf.c'