SConscript revision 6993
12139SN/A# -*- mode:python -*-
22139SN/A
32139SN/A# Copyright (c) 2007-2008 The Florida State University
42139SN/A# Copyright (c) 2009 ARM Limited
52139SN/A# All rights reserved.
62139SN/A#
72139SN/A# Redistribution and use in source and binary forms, with or without
82139SN/A# modification, are permitted provided that the following conditions are
92139SN/A# met: redistributions of source code must retain the above copyright
102139SN/A# notice, this list of conditions and the following disclaimer;
112139SN/A# redistributions in binary form must reproduce the above copyright
122139SN/A# notice, this list of conditions and the following disclaimer in the
132139SN/A# documentation and/or other materials provided with the distribution;
142139SN/A# neither the name of the copyright holders nor the names of its
152139SN/A# contributors may be used to endorse or promote products derived from
162139SN/A# this software without specific prior written permission.
172139SN/A#
182139SN/A# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
192139SN/A# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
202139SN/A# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
212139SN/A# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
222139SN/A# OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
232139SN/A# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
242139SN/A# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
252139SN/A# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
262139SN/A# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
272139SN/A# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
282665Ssaidi@eecs.umich.edu# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
292665Ssaidi@eecs.umich.edu#
302139SN/A# Authors: Stephen Hines
314202Sbinkertn@umich.edu#          Ali Saidi
322139SN/A
334202Sbinkertn@umich.eduImport('*')
342152SN/A
352152SN/Aif env['TARGET_ISA'] == 'arm':
362139SN/A# Workaround for bug in SCons version > 0.97d20071212
372139SN/A# Scons bug id: 2006 M5 Bug id: 308 
382139SN/A    Dir('isa/formats')
392139SN/A    Source('faults.cc')
402139SN/A    Source('insts/branch.cc')
412152SN/A    Source('insts/mem.cc')
422152SN/A    Source('insts/pred_inst.cc')
432139SN/A    Source('insts/static_inst.cc')
442139SN/A    Source('nativetrace.cc')
452139SN/A    Source('pagetable.cc')
464781Snate@binkert.org    Source('tlb.cc')
474781Snate@binkert.org    Source('vtophys.cc')
487799Sgblack@eecs.umich.edu    Source('utility.cc')
494781Snate@binkert.org
504781Snate@binkert.org    SimObject('ArmNativeTrace.py')
513170Sstever@eecs.umich.edu    SimObject('ArmTLB.py')
525664Sgblack@eecs.umich.edu
538105Sgblack@eecs.umich.edu    TraceFlag('Arm')
546179Sksewell@umich.edu    TraceFlag('Faults', "Trace Exceptions, interrupts, svc/swi")
554781Snate@binkert.org    if env['FULL_SYSTEM']:
564781Snate@binkert.org        Source('interrupts.cc')
576329Sgblack@eecs.umich.edu        Source('stacktrace.cc')
584781Snate@binkert.org        Source('system.cc')
594781Snate@binkert.org        
604781Snate@binkert.org        SimObject('ArmInterrupts.py')
614781Snate@binkert.org        SimObject('ArmSystem.py')
624781Snate@binkert.org    else:
634781Snate@binkert.org        Source('process.cc')
642139SN/A        Source('linux/linux.cc')
652139SN/A        Source('linux/process.cc')
663546Sgblack@eecs.umich.edu
674202Sbinkertn@umich.edu    # Add in files generated by the ISA description.
682152SN/A    isa_desc_files = env.ISADesc('isa/main.isa')
692152SN/A    # Only non-header files need to be compiled.
702152SN/A    for f in isa_desc_files:
712152SN/A        if not f.path.endswith('.hh'):
722152SN/A            Source(f)
732152SN/A
742152SN/A