summaryrefslogtreecommitdiff
path: root/SConstruct
diff options
context:
space:
mode:
authorGabe Black <gabeblack@google.com>2017-05-01 19:50:30 -0700
committerGabe Black <gabeblack@google.com>2017-05-08 22:11:13 +0000
commitc31b4ae223b9dbdfa22adaf877e602d6c88e42cf (patch)
tree6a8ea46de59061b444a5fe66b3422d8e3467bbfb /SConstruct
parenta17c9a9936a53a4cb6f60c983891dc1d797619e2 (diff)
downloadgem5-c31b4ae223b9dbdfa22adaf877e602d6c88e42cf.tar.xz
scons: Get rid of the PHONY_BASE construction variable.
The value of that variable can be computed more directly and more locally to where it's consumed. Change-Id: I5ca1f732a34e22d4dae2aeb6ee7fc8adebe1caa0 Reviewed-on: https://gem5-review.googlesource.com/2981 Maintainer: Jason Lowe-Power <jason@lowepower.com> Reviewed-by: Curtis Dunham <curtis.dunham@arm.com> Reviewed-by: Jason Lowe-Power <jason@lowepower.com>
Diffstat (limited to 'SConstruct')
-rwxr-xr-xSConstruct6
1 files changed, 5 insertions, 1 deletions
diff --git a/SConstruct b/SConstruct
index d252865db..f56c23df7 100755
--- a/SConstruct
+++ b/SConstruct
@@ -1357,7 +1357,6 @@ def make_switching_dir(dname, switch_headers, env):
env.Command(hdr, [], switch_hdr_action)
isa_target = Dir('.').up().name.lower().replace('_', '-')
- env['PHONY_BASE'] = '#'+isa_target
all_isa_deps[isa_target] = None
Export('make_switching_dir')
@@ -1421,6 +1420,11 @@ BUILD_TARGETS[:] = ['#all-targets']
#
###################################################
+def variant_name(path):
+ return os.path.basename(path).lower().replace('_', '-')
+main['variant_name'] = variant_name
+main['VARIANT_NAME'] = '${variant_name(BUILDDIR)}'
+
for variant_path in variant_paths:
if not GetOption('silent'):
print "Building in", variant_path