SConscript 799 B

1234567891011121314151617181920212223242526272829
  1. import os
  2. import rtconfig
  3. from building import *
  4. Import('SDK_LIB')
  5. cwd = GetCurrentDir()
  6. # add general drivers
  7. src = Split('''
  8. board.c
  9. ''')
  10. path = [cwd]
  11. startup_path_prefix = SDK_LIB
  12. if rtconfig.PLATFORM in ['gcc']:
  13. src += [startup_path_prefix + '/FT32F0xx/CMSIS/FT32F0xx/source/gcc/startup_ft32f072xb.s']
  14. elif rtconfig.PLATFORM in ['armcc', 'armclang']:
  15. src += [startup_path_prefix + '/FT32F0xx/CMSIS/FT32F0xx/source/arm/startup_ft32f072xb.s']
  16. elif rtconfig.PLATFORM in ['iccarm']:
  17. src += [startup_path_prefix + '/FT32F0xx/CMSIS/FT32F0xx/source/iar/startup_ft32f072xb.s']
  18. # FT32F072x8 || FT32F072xB
  19. # You can select chips from the list above
  20. CPPDEFINES = ['FT32F072xB']
  21. group = DefineGroup('Drivers', src, depend = [''], CPPPATH = path, CPPDEFINES = CPPDEFINES)
  22. Return('group')