SConscript 720 B

1234567891011121314151617181920212223242526
  1. from building import *
  2. cwd = GetCurrentDir()
  3. src = ['device.c']
  4. CPPPATH = [cwd + '/../include']
  5. if GetDepend(['RT_USING_DEV_BUS']) or GetDepend(['RT_USING_DM']):
  6. src = src + ['bus.c']
  7. if GetDepend(['RT_USING_DM']):
  8. src = src + ['dm.c', 'driver.c', 'numa.c', 'platform.c', 'power.c', 'power_domain.c']
  9. if GetDepend(['RT_USING_DFS']):
  10. src += ['mnt.c'];
  11. if GetDepend(['RT_USING_OFW']):
  12. src += ['platform_ofw.c']
  13. group = DefineGroup('DeviceDrivers', src, depend = ['RT_USING_DEVICE'], CPPPATH = CPPPATH)
  14. list = os.listdir(cwd)
  15. for item in list:
  16. if os.path.isfile(os.path.join(cwd, item, 'SConscript')):
  17. group = group + SConscript(os.path.join(item, 'SConscript'))
  18. Return('group')