diff options
author | Stefan Metzmacher <metze@samba.org> | 2014-10-22 10:08:17 +0200 |
---|---|---|
committer | Michael Adam <obnox@samba.org> | 2014-10-30 20:25:03 +0100 |
commit | 331f9805ea6743ab130af719733cf51b3ddf12fb (patch) | |
tree | 383ae3bf8a1dd94f199c57f5148c5c142efba3b3 /selftest/wscript | |
parent | 35356499769b0913855d79acbb805581673909a9 (diff) | |
download | samba-331f9805ea6743ab130af719733cf51b3ddf12fb.tar.gz samba-331f9805ea6743ab130af719733cf51b3ddf12fb.tar.xz samba-331f9805ea6743ab130af719733cf51b3ddf12fb.zip |
selftest: only use Options.options.SELFTEST_PREFIX if it's not the default
The --with-selftest-prefix option is typically specified as argument
to './configure' ! Overwriting it for 'waf testonly' should only
happen with an explicit 'waf testonly --with-selftest-prefix=/some/path'.
This fixes a regression introduced by
commit edc1cedf932de2bc068da9a5db844ac4c48f4324
(selftest: Actually honor --with-selftest-prefix).
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Diffstat (limited to 'selftest/wscript')
-rw-r--r-- | selftest/wscript | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/selftest/wscript b/selftest/wscript index e5df412d9d..3e6dffcc35 100644 --- a/selftest/wscript +++ b/selftest/wscript @@ -8,6 +8,8 @@ from samba_utils import * from samba_autoconf import * import types +DEFAULT_SELFTEST_PREFIX="./st" + def set_options(opt): opt.add_option('--enable-selftest', @@ -19,8 +21,8 @@ def set_options(opt): action="store_true", dest='enable_coverage', default=False) opt.add_option('--with-selftest-prefix', help=("specify location of selftest directory " - "(default=./st)"), - action="store", dest='SELFTEST_PREFIX', default='./st') + "(default=%s)" % DEFAULT_SELFTEST_PREFIX), + action="store", dest='SELFTEST_PREFIX', default=DEFAULT_SELFTEST_PREFIX) opt.ADD_COMMAND('test', cmd_test) opt.ADD_COMMAND('testonly', cmd_testonly) @@ -94,7 +96,8 @@ def cmd_testonly(opt): env = LOAD_ENVIRONMENT() opt.env = env - env.SELFTEST_PREFIX = Options.options.SELFTEST_PREFIX + if Options.options.SELFTEST_PREFIX != DEFAULT_SELFTEST_PREFIX: + env.SELFTEST_PREFIX = Options.options.SELFTEST_PREFIX if (not CONFIG_SET(opt, 'NSS_WRAPPER') or not CONFIG_SET(opt, 'UID_WRAPPER') or |