summaryrefslogtreecommitdiff
path: root/src/mem/protocol
diff options
context:
space:
mode:
authorNathan Binkert <nate@binkert.org>2009-07-06 15:49:47 -0700
committerNathan Binkert <nate@binkert.org>2009-07-06 15:49:47 -0700
commit1f6933503d3e0fb088345175cc1cae9610b98ce2 (patch)
treedfd80aadce2687280c8a145ce536898e927b2f04 /src/mem/protocol
parent92de70b69aaf3f399a855057b556ed198139e5d8 (diff)
downloadgem5-1f6933503d3e0fb088345175cc1cae9610b98ce2.tar.xz
scons: update SCons files for changes in ruby.
Diffstat (limited to 'src/mem/protocol')
-rw-r--r--src/mem/protocol/SConscript10
-rw-r--r--src/mem/protocol/SConsopts2
2 files changed, 8 insertions, 4 deletions
diff --git a/src/mem/protocol/SConscript b/src/mem/protocol/SConscript
index 17701e403..f7f7afdcd 100644
--- a/src/mem/protocol/SConscript
+++ b/src/mem/protocol/SConscript
@@ -50,7 +50,7 @@ html_dir = Dir('html')
#
# Use SLICC
#
-def slicc_action(target, source, env):
+def slicc_generator(target, source, env, for_signature):
slicc_bin = str(source[0])
protocol = source[1].get_contents()
pdir = str(protocol_dir)
@@ -65,7 +65,9 @@ def slicc_action(target, source, env):
cmdline = [ slicc_bin, pdir, hdir, protocol, do_html ]
cmdline += [ str(s) for s in source[2:] ]
cmdline = ' '.join(cmdline)
- os.system(cmdline)
+ return cmdline
+
+slicc_builder = Builder(generator=slicc_generator)
protocol = env['PROTOCOL']
sources = [ protocol_dir.File("RubySlicc_interfaces.slicc"),
@@ -91,7 +93,9 @@ hh = [ protocol_dir.File(f) for f in hh ]
cc = [ protocol_dir.File(f) for f in cc ]
slicc_bin = slicc_dir.File("slicc")
-env.Command(hh + cc, [ slicc_bin, Value(protocol) ] + sm_files, slicc_action)
+
+env.Append(BUILDERS={'SLICC' : slicc_builder})
+env.SLICC(hh + cc, [ slicc_bin, Value(protocol) ] + sm_files)
for f in cc:
Source(f)
diff --git a/src/mem/protocol/SConsopts b/src/mem/protocol/SConsopts
index 6ca93ca06..ded0814d2 100644
--- a/src/mem/protocol/SConsopts
+++ b/src/mem/protocol/SConsopts
@@ -49,7 +49,7 @@ all_protocols = [
'MSI_MOSI_CMP_directory',
]
-opt = EnumVariable('PROTOCOL', 'Coherence Protocol for Ruby', 'MOSI_SMP_bcast',
+opt = EnumVariable('PROTOCOL', 'Coherence Protocol for Ruby', 'MI_example',
all_protocols)
sticky_vars.AddVariables(opt)