4
0
mirror of https://github.com/RT-Thread/rt-thread.git synced 2025-01-16 00:49:31 +08:00
2016-09-22 12:31:38 +08:00

28 lines
499 B
Python

Import('RTT_ROOT')
Import('rtconfig')
from building import *
cwd = os.path.join(str(Dir('#')), 'drivers')
# add the general drivers.
src = Split("""
board.c
stm32l0xx_it.c
usart.c
""")
# add gpio drivers.
if GetDepend('RT_USING_PIN'):
src += ['gpio.c']
# add spi drivers.
if GetDepend('RT_USING_SPI'):
src += ['drv_spi.c']
CPPPATH = [cwd,
cwd + '../Drivers/CMSIS/Device/ST/STM32L0xx/Include']
group = DefineGroup('Drivers', src, depend = [''], CPPPATH = CPPPATH)
Return('group')