summaryrefslogtreecommitdiff
path: root/bsp/stm32f7-disco/Libraries/SConscript
blob: 1bd5e934bf9a484c21b107746008a8431e309927 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
import rtconfig
from building import *

# get current directory
cwd = GetCurrentDir()

# The set of source files associated with this SConscript file.

src = Glob('STM32F7xx_HAL_Driver/Src/*.c')
src += Split('''
CMSIS/Device/ST/STM32F7xx/Source/Templates/system_stm32f7xx.c
''')

#add for startup script
if rtconfig.CROSS_TOOL == 'gcc':
     src = src + ['CMSIS/Device/ST/STM32F7xx/Source/Templates/gcc/startup_stm32f769xx.s']
elif rtconfig.CROSS_TOOL == 'keil':
     src = src + ['CMSIS/Device/ST/STM32F7xx/Source/Templates/arm/startup_stm32f769xx.s']
elif rtconfig.CROSS_TOOL == 'iar':
    src = src + ['CMSIS/Device/ST/STM32F7xx/Source/Templates/iar/startup_stm32f769xx.s']

path = [cwd + '/STM32F7xx_HAL_Driver/Inc',
    cwd + '/CMSIS/Device/ST/STM32F7xx/Include',
    cwd + '/CMSIS/Include']

CPPDEFINES = ['STM32F769xx', 'USE_HAL_DRIVER']

group = DefineGroup('STM32_HAL', src, depend = [''], CPPPATH = path, CPPDEFINES = CPPDEFINES)

Return('group')