4
0
mirror of https://github.com/RT-Thread/rt-thread.git synced 2025-01-19 18:23:32 +08:00
Man, Jianting (Meco) a0f8d43744
[gcc][armcc][armclang] rtconfig.CROSS_TOOL->rtconfig.PLATFORM (#5802)
* [gcc][armcc][armclang] rtconfig.CROSS_TOOL->rtconfig.PLATFORM
2022-04-20 09:56:04 +08:00

27 lines
734 B
Python

Import('RTT_ROOT')
Import('rtconfig')
from building import *
# The set of source files associated with this SConscript file.
cwd = GetCurrentDir()
src = Glob('driverlib/*.c')
SrcRemove(src, 'onewire.c')
CFLAGS = ''
# add for startup script
if rtconfig.PLATFORM == 'gcc':
src += ['startup/startup_gcc.c']
elif rtconfig.PLATFORM in ['armcc', 'armclang']:
src += ['startup/startup_rvmdk.S']
elif rtconfig.CROSS_TOOL == 'iar':
src += ['startup/startup_ewarm.c']
CFLAGS += ' --diag_suppress=pe177'
CPPPATH = [cwd, cwd + '/inc', cwd + '/driverlib']
CPPDEFINES = [rtconfig.PART_TYPE]
group = DefineGroup('Libraries', src, depend = [''], CPPPATH = CPPPATH, CPPDEFINES = CPPDEFINES, CFLAGS = CFLAGS)
Return('group')