SConscript (6286:40b142645016) | SConscript (6287:d60118c43d60) |
---|---|
1# -*- mode:python -*- 2 3# Copyright (c) 2009 The Hewlett-Packard Development Company 4# All rights reserved. 5# 6# Redistribution and use in source and binary forms, with or without 7# modification, are permitted provided that the following conditions are 8# met: redistributions of source code must retain the above copyright --- 59 unchanged lines hidden (view full) --- 68 return cmdline 69 70slicc_builder = Builder(generator=slicc_generator) 71 72protocol = env['PROTOCOL'] 73sources = [ protocol_dir.File("RubySlicc_interfaces.slicc"), 74 protocol_dir.File("%s.slicc" % protocol) ] 75 | 1# -*- mode:python -*- 2 3# Copyright (c) 2009 The Hewlett-Packard Development Company 4# All rights reserved. 5# 6# Redistribution and use in source and binary forms, with or without 7# modification, are permitted provided that the following conditions are 8# met: redistributions of source code must retain the above copyright --- 59 unchanged lines hidden (view full) --- 68 return cmdline 69 70slicc_builder = Builder(generator=slicc_generator) 71 72protocol = env['PROTOCOL'] 73sources = [ protocol_dir.File("RubySlicc_interfaces.slicc"), 74 protocol_dir.File("%s.slicc" % protocol) ] 75 |
76sm_files = [] 77for s in sources: 78 for sm_file in file(File(s).srcnode().abspath, "r"): 79 sm_file = sm_file.strip() 80 if not sm_file: 81 continue 82 if sm_file.startswith("#"): 83 continue 84 sm_file = protocol_dir.File(sm_file) 85 sm_file.srcnode().abspath 86 sm_files.append(sm_file) 87 | |
88sys.path[0:0] = [env['ENV']['M5_PLY']] 89execfile(slicc_dir.File('parser/parser.py').srcnode().abspath) 90 | 76sys.path[0:0] = [env['ENV']['M5_PLY']] 77execfile(slicc_dir.File('parser/parser.py').srcnode().abspath) 78 |
79sm_files = read_slicc([s.srcnode().abspath for s in sources]) 80sm_files = [ protocol_dir.File(f) for f in sm_files ] 81 |
|
91hh, cc = scan([s.srcnode().abspath for s in sm_files]) 92hh = [ protocol_dir.File(f) for f in hh ] 93cc = [ protocol_dir.File(f) for f in cc ] 94 95slicc_bin = slicc_dir.File("slicc") 96 97env.Append(BUILDERS={'SLICC' : slicc_builder}) 98env.SLICC(hh + cc, [ slicc_bin, Value(protocol) ] + sm_files) 99 100for f in cc: 101 Source(f) | 82hh, cc = scan([s.srcnode().abspath for s in sm_files]) 83hh = [ protocol_dir.File(f) for f in hh ] 84cc = [ protocol_dir.File(f) for f in cc ] 85 86slicc_bin = slicc_dir.File("slicc") 87 88env.Append(BUILDERS={'SLICC' : slicc_builder}) 89env.SLICC(hh + cc, [ slicc_bin, Value(protocol) ] + sm_files) 90 91for f in cc: 92 Source(f) |