1
0

SConscript 534 B

1234567891011121314151617181920212223
  1. from building import *
  2. cwd = GetCurrentDir()
  3. src = Glob('*.c')
  4. list = os.listdir(cwd)
  5. CPPPATH = [cwd]
  6. objs = []
  7. if not GetDepend('BSP_DRV_EMAC'):
  8. SrcRemove(src, ['drv_smc911x.c'])
  9. if not GetDepend('BSP_DRV_CLCD'):
  10. SrcRemove(src, ['drv_clcd.c'])
  11. group = DefineGroup('Drivers', src, depend = [''], CPPPATH = CPPPATH)
  12. for d in list:
  13. path = os.path.join(cwd, d)
  14. if os.path.isfile(os.path.join(path, 'SConscript')):
  15. objs = objs + SConscript(os.path.join(d, 'SConscript'))
  16. objs = objs + group
  17. Return('objs')