1import rtconfig 2Import('RTT_ROOT') 3from building import * 4 5# get current directory 6cwd = GetCurrentDir() 7 8# The set of source files associated with this SConscript file. 9src = [] 10 11src += Glob('ES32F36xx_ALD_StdPeriph_Driver/Source/*.c') 12 13#add for startup script 14if rtconfig.PLATFORM in ['gcc']: 15 src = src + ['CMSIS/Device/EastSoft/ES32F36xx/Startup/gcc/startup_es32f36xx.S'] 16elif rtconfig.PLATFORM in ['armcc', 'armclang']: 17 src = src + ['CMSIS/Device/EastSoft/ES32F36xx/Startup/keil/startup_es32f36xx.s'] 18elif rtconfig.PLATFORM in ['iccarm']: 19 src = src + ['CMSIS/Device/EastSoft/ES32F36xx/Startup/iar/startup_es32f36xx.s'] 20 21path = [cwd + '/CMSIS/Device/EastSoft/ES32F36xx/Include', 22 cwd + '/CMSIS/Include', 23 cwd + '/ES32F36xx_ALD_StdPeriph_Driver/Include'] 24 25group = DefineGroup('Libraries', src, depend = [''], CPPPATH = path, CPPDEFINES = ['ES32F36xx']) 26 27Return('group') 28