2010-03-24 13:16:28 +08:00
|
|
|
Import('RTT_ROOT')
|
2010-11-20 20:31:00 +08:00
|
|
|
Import('rtconfig')
|
|
|
|
from building import *
|
2010-03-24 13:16:28 +08:00
|
|
|
|
|
|
|
comm = rtconfig.ARCH + '/common'
|
|
|
|
path = rtconfig.ARCH + '/' + rtconfig.CPU
|
2018-06-04 14:18:31 +08:00
|
|
|
AFLAGS = ''
|
2010-03-24 13:16:28 +08:00
|
|
|
|
|
|
|
# The set of source files associated with this SConscript file.
|
|
|
|
if rtconfig.PLATFORM == 'armcc':
|
2010-11-20 20:31:00 +08:00
|
|
|
src = Glob(path + '/*.c') + Glob(path + '/*_rvds.S') + Glob(comm + '/*.c')
|
2010-03-24 13:16:28 +08:00
|
|
|
|
|
|
|
if rtconfig.PLATFORM == 'gcc':
|
2010-11-20 20:31:00 +08:00
|
|
|
src = Glob(path + '/*.c') + Glob(path + '/*_gcc.S') + Glob(comm + '/*.c') + Glob(path + '/*_init.S')
|
2010-03-24 13:16:28 +08:00
|
|
|
|
|
|
|
if rtconfig.PLATFORM == 'iar':
|
2010-11-20 20:31:00 +08:00
|
|
|
src = Glob(path + '/*.c') + Glob(path + '/*_iar.S') + Glob(comm + '/*.c')
|
2010-04-19 06:16:50 +08:00
|
|
|
|
2012-10-21 12:42:49 +08:00
|
|
|
if rtconfig.PLATFORM == 'cl':
|
|
|
|
src = Glob(path + '/*.c')
|
|
|
|
|
2013-02-26 16:03:08 +08:00
|
|
|
if rtconfig.PLATFORM == 'mingw':
|
|
|
|
src = Glob(path + '/*.c')
|
|
|
|
|
2018-06-04 14:18:31 +08:00
|
|
|
if rtconfig.PLATFORM == 'armcc' and rtconfig.ARCH == 'arm' and rtconfig.CPU == 'arm926':
|
|
|
|
ASFLAGS = ' --cpreproc'
|
|
|
|
|
2010-11-20 20:31:00 +08:00
|
|
|
CPPPATH = [RTT_ROOT + '/libcpu/' + rtconfig.ARCH + '/' + rtconfig.CPU, RTT_ROOT + '/libcpu/' + rtconfig.ARCH + '/common']
|
2018-06-04 14:18:31 +08:00
|
|
|
group = DefineGroup(rtconfig.CPU.upper(), src, depend = [''], CPPPATH = CPPPATH, ASFLAGS = ASFLAGS)
|
2010-03-24 13:16:28 +08:00
|
|
|
|
2010-11-20 20:31:00 +08:00
|
|
|
Return('group')
|