SConscript 1.0 KB

123456789101112131415161718192021222324252627
  1. import rtconfig
  2. from building import *
  3. cwd = GetCurrentDir()
  4. # add the general drivers.
  5. src = Glob('board.c')
  6. src += Glob('CubeMX_Config/Src/stm32f7xx_hal_msp.c')
  7. path = [cwd]
  8. path += [cwd + '/CubeMX_Config/Inc']
  9. if rtconfig.CROSS_TOOL == 'gcc':
  10. src += [cwd + '/../../libraries/STM32F7xx_HAL/CMSIS/Device/ST/STM32F7xx/Source/Templates/gcc/startup_stm32f746xx.s']
  11. elif rtconfig.CROSS_TOOL == 'keil':
  12. src += [cwd + '/../../libraries/STM32F7xx_HAL/CMSIS/Device/ST/STM32F7xx/Source/Templates/arm/startup_stm32f746xx.s']
  13. elif rtconfig.CROSS_TOOL == 'iar':
  14. src += [cwd + '/../../libraries/STM32F7xx_HAL/CMSIS/Device/ST/STM32F7xx/Source/Templates/iar/startup_stm32f746xx.s']
  15. # STM32F756xx || STM32F746xx || STM32F745xx || STM32F767xx ||
  16. # STM32F769xx || STM32F777xx || STM32F779xx || STM32F722xx ||
  17. # STM32F723xx || STM32F732xx || STM32F733xx || STM32F730xx || STM32F750xx
  18. # You can select chips from the list above
  19. CPPDEFINES = ['STM32F746xx']
  20. group = DefineGroup('Drivers', src, depend = [''], CPPPATH = path, CPPDEFINES = CPPDEFINES)
  21. Return('group')