Skip to content

Commit

Permalink
SConscript: Use GetDepend() to gather device driver assets instead
Browse files Browse the repository at this point in the history
  • Loading branch information
ramangopalan committed Oct 21, 2023
1 parent b1fd636 commit ba0e3b6
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion bsp/avr32uc3b0/SConscript
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,16 @@ import rtconfig
Import('RTT_ROOT')
from building import *

src_bsp = ['application.c', 'startup.c', 'board.c', 'drv_uart.c', 'drv_gpio.c']
src_bsp = ['application.c', 'startup.c', 'board.c']

if GetDepend(['RT_USING_PIN']):
src_bsp += ['drv_gpio.c']

if GetDepend(['RT_USING_SERIAL']):
if GetDepend(['RT_USING_SERIAL_V2']):
src_bsp += ['drv_uart_v2.c']
else:
src_bsp += ['drv_uart.c']

src = File(src_bsp)
CPPPATH = [RTT_ROOT + '/bsp/avr32uc3b0']
Expand Down

0 comments on commit ba0e3b6

Please sign in to comment.