summaryrefslogtreecommitdiff
path: root/build/SConstruct
diff options
context:
space:
mode:
Diffstat (limited to 'build/SConstruct')
-rw-r--r--build/SConstruct23
1 files changed, 17 insertions, 6 deletions
diff --git a/build/SConstruct b/build/SConstruct
index 306d3a9dc..28940fc5a 100644
--- a/build/SConstruct
+++ b/build/SConstruct
@@ -231,6 +231,11 @@ sticky_opts = Options(args=ARGUMENTS)
sticky_opts.AddOptions(
EnumOption('TARGET_ISA', 'Target ISA', 'alpha', env['ALL_ISA_LIST']),
BoolOption('FULL_SYSTEM', 'Full-system support', False),
+ # There's a bug in scons 0.96.1 that causes ListOptions with list
+ # values (more than one value) not to be able to be restored from
+ # a saved option file. If this causes trouble then upgrade to
+ # scons 0.96.90 or later.
+ ListOption('CPU_MODELS', 'CPU models', 'all', env['ALL_CPU_LIST']),
BoolOption('ALPHA_TLASER',
'Model Alpha TurboLaser platform (vs. Tsunami)', False),
BoolOption('NO_FAST_ALLOC', 'Disable fast object allocator', False),
@@ -254,12 +259,6 @@ sticky_opts.AddOptions(
# Non-sticky options only apply to the current build.
nonsticky_opts = Options(args=ARGUMENTS)
nonsticky_opts.AddOptions(
- # This really should be a sticky option, but there's a bug in
- # scons 0.96.1 that causes ListOptions not to be able to be
- # restored from a saved option file. It looks like this is fixed
- # in 0.96.9, but there's a different bug in that version that means we
- # can't just upgrade.
- ListOption('CPU_MODELS', 'CPU models', 'all', env['ALL_CPU_LIST']),
BoolOption('update_ref', 'Update test reference outputs', False)
)
@@ -329,6 +328,11 @@ env.Append(BUILDERS = { 'ConfigFile' : config_builder })
# rename base env
base_env = env
+help_text = '''
+Usage: scons [scons options] [build options] [target(s)]
+
+'''
+
for build_dir in build_dirs:
# Make a copy of the default environment to use for this config.
env = base_env.Copy()
@@ -362,6 +366,11 @@ for build_dir in build_dirs:
sticky_opts.Update(env)
nonsticky_opts.Update(env)
+ help_text += "Sticky options for %s:\n" % build_dir \
+ + sticky_opts.GenerateHelpText(env) \
+ + "\nNon-sticky options for %s:\n" % build_dir \
+ + nonsticky_opts.GenerateHelpText(env)
+
# Process option settings.
if not have_fenv and env['USE_FENV']:
@@ -410,6 +419,8 @@ for build_dir in build_dirs:
build_dir = os.path.join(build_dir, 'test', e.Label),
exports = { 'env' : e }, duplicate = False)
+Help(help_text)
+
###################################################
#
# Let SCons do its thing. At this point SCons will use the defined