rt-thread/bsp/ft32/libraries/FT32F0xx/SConscript

56 lines
1.5 KiB
Python

import rtconfig
Import('RTT_ROOT')
from building import *
# get current directory
cwd = GetCurrentDir()
# The set of source files associated with this SConscript file.
src = Split("""
CMSIS/FT32F0xx/source/system_ft32f0xx.c
FT32F0xx_Driver/Src/ft32f0xx_comp.c
FT32F0xx_Driver/Src/ft32f0xx_crc.c
FT32F0xx_Driver/Src/ft32f0xx_crs.c
FT32F0xx_Driver/Src/ft32f0xx_debug.c
FT32F0xx_Driver/Src/ft32f0xx_div.c
FT32F0xx_Driver/Src/ft32f0xx_dma.c
FT32F0xx_Driver/Src/ft32f0xx_exti.c
FT32F0xx_Driver/Src/ft32f0xx_gpio.c
FT32F0xx_Driver/Src/ft32f0xx_iwdg.c
FT32F0xx_Driver/Src/ft32f0xx_misc.c
FT32F0xx_Driver/Src/ft32f0xx_opa.c
FT32F0xx_Driver/Src/ft32f0xx_pwr.c
FT32F0xx_Driver/Src/ft32f0xx_rcc.c
FT32F0xx_Driver/Src/ft32f0xx_syscfg.c
FT32F0xx_Driver/Src/ft32f0xx_tim.c
""")
if GetDepend(['RT_USING_SERIAL']):
src += ['FT32F0xx_Driver/Src/ft32f0xx_usart.c']
if GetDepend(['RT_USING_I2C']):
src += ['FT32F0xx_Driver/Src/ft32f0xx_i2c.c']
if GetDepend(['RT_USING_SPI']):
src += ['FT32F0xx_Driver/Src/ft32f0xx_spi.c']
if GetDepend(['RT_USING_ADC']):
src += ['FT32F0xx_Driver/Src/ft32f0xx_adc.c']
if GetDepend(['RT_USING_RTC']):
src += ['FT32F0xx_Driver/Src/ft32f0xx_rtc.c']
if GetDepend(['RT_USING_WDT']):
src += ['FT32F0xx_Driver/Src/ft32f0xx_wwdg.c']
if GetDepend(['BSP_USING_ON_CHIP_FLASH']):
src += ['FT32F0xx_Driver/Src/ft32f0xx_flash.c']
path = [cwd + '/CMSIS/FT32F0xx/Include',
cwd + '/FT32F0xx_Driver/Inc',
cwd + '/FT32F0xx_Driver/templates/Inc']
group = DefineGroup('Libraries', src, depend = [''], CPPPATH = path)
Return('group')