diff options
author | Andrew Tridgell <tridge@samba.org> | 2010-04-04 13:08:05 +1000 |
---|---|---|
committer | Andrew Tridgell <tridge@samba.org> | 2010-04-06 20:27:25 +1000 |
commit | 553324bc1022635e05a683c4bec5135d845f6fea (patch) | |
tree | 7d8aa296c7e433793e47bf1227310973a4aed7e9 /lib | |
parent | 8dc8d31f4adf84f35bce34339e13e9d70c4b8a66 (diff) | |
download | samba-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')
-rw-r--r-- | lib/replace/wscript | 18 | ||||
-rw-r--r-- | lib/talloc/wscript | 6 | ||||
-rw-r--r-- | lib/tdb/wscript | 6 | ||||
-rw-r--r-- | lib/tevent/wscript | 12 |
4 files changed, 20 insertions, 22 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' diff --git a/lib/talloc/wscript b/lib/talloc/wscript index e577643595..9c6316289e 100644 --- a/lib/talloc/wscript +++ b/lib/talloc/wscript @@ -29,10 +29,10 @@ samba_dist.DIST_DIRS('lib/talloc:. lib/replace:lib/replace buildtools:buildtools def set_options(opt): opt.BUILTIN_DEFAULT('replace') opt.BUNDLED_EXTENSION_DEFAULT('talloc', noextenion='talloc') - opt.recurse(LIBREPLACE_DIR) + opt.RECURSE(LIBREPLACE_DIR) def configure(conf): - conf.sub_config(LIBREPLACE_DIR) + conf.RECURSE(LIBREPLACE_DIR) if conf.CHECK_BUNDLED_SYSTEM('talloc', minversion=VERSION, implied_deps='replace'): @@ -45,7 +45,7 @@ def configure(conf): def build(bld): - bld.BUILD_SUBDIR(LIBREPLACE_DIR) + bld.RECURSE(LIBREPLACE_DIR) if not bld.CONFIG_SET('USING_SYSTEM_TALLOC'): bld.SAMBA_LIBRARY('talloc', diff --git a/lib/tdb/wscript b/lib/tdb/wscript index 8c941948c8..a11832f985 100644 --- a/lib/tdb/wscript +++ b/lib/tdb/wscript @@ -24,10 +24,10 @@ LIBREPLACE_DIR= '../replace' def set_options(opt): opt.BUILTIN_DEFAULT('replace') opt.BUNDLED_EXTENSION_DEFAULT('tdb', noextenion='tdb') - opt.recurse(LIBREPLACE_DIR) + opt.RECURSE(LIBREPLACE_DIR) def configure(conf): - conf.sub_config(LIBREPLACE_DIR) + conf.RECURSE(LIBREPLACE_DIR) if conf.CHECK_BUNDLED_SYSTEM('tdb', minversion=VERSION, implied_deps='replace'): @@ -36,7 +36,7 @@ def configure(conf): conf.SAMBA_CONFIG_H() def build(bld): - bld.BUILD_SUBDIR(LIBREPLACE_DIR) + bld.RECURSE(LIBREPLACE_DIR) COMMON_SRC = bld.SUBDIR('common', '''check.c error.c tdb.c traverse.c diff --git a/lib/tevent/wscript b/lib/tevent/wscript index cc139ccee5..569740e8d0 100644 --- a/lib/tevent/wscript +++ b/lib/tevent/wscript @@ -25,12 +25,12 @@ LIBTALLOC_DIR= '../talloc' def set_options(opt): opt.BUILTIN_DEFAULT('replace') opt.BUNDLED_EXTENSION_DEFAULT('tevent', noextenion='tevent') - opt.recurse(LIBREPLACE_DIR) - opt.recurse(LIBTALLOC_DIR) + opt.RECURSE(LIBREPLACE_DIR) + opt.RECURSE(LIBTALLOC_DIR) def configure(conf): - conf.sub_config(LIBREPLACE_DIR) - conf.sub_config(LIBTALLOC_DIR) + conf.RECURSE(LIBREPLACE_DIR) + conf.RECURSE(LIBTALLOC_DIR) if conf.CHECK_BUNDLED_SYSTEM('tevent', minversion=VERSION, onlyif='talloc', implied_deps='replace talloc'): @@ -42,8 +42,8 @@ def configure(conf): conf.SAMBA_CONFIG_H() def build(bld): - bld.BUILD_SUBDIR(LIBREPLACE_DIR) - bld.BUILD_SUBDIR(LIBTALLOC_DIR) + bld.RECURSE(LIBREPLACE_DIR) + bld.RECURSE(LIBTALLOC_DIR) SRC = '''tevent.c tevent_debug.c tevent_fd.c tevent_immediate.c tevent_queue.c tevent_req.c tevent_select.c |