2013-01-08 22:40:58 +08:00
|
|
|
from building import *
|
|
|
|
|
|
|
|
# The set of source files associated with this SConscript file.
|
2017-10-15 22:44:53 +08:00
|
|
|
src = Split('''
|
|
|
|
src/dfs.c
|
|
|
|
src/dfs_file.c
|
|
|
|
src/dfs_fs.c
|
|
|
|
src/dfs_posix.c
|
|
|
|
''')
|
2015-04-03 22:26:18 +08:00
|
|
|
cwd = GetCurrentDir()
|
|
|
|
CPPPATH = [cwd + "/include"]
|
|
|
|
|
2017-10-17 22:27:06 +08:00
|
|
|
if GetDepend('RT_USING_POSIX'):
|
2021-09-11 23:25:43 +08:00
|
|
|
src += ['src/dfs_poll.c', 'src/dfs_select.c']
|
2017-10-15 22:44:53 +08:00
|
|
|
|
2015-04-03 22:26:18 +08:00
|
|
|
group = DefineGroup('Filesystem', src, depend = ['RT_USING_DFS'], CPPPATH = CPPPATH)
|
|
|
|
|
|
|
|
if GetDepend('RT_USING_DFS'):
|
|
|
|
# search in the file system implementation
|
|
|
|
list = os.listdir(cwd)
|
2017-10-15 22:44:53 +08:00
|
|
|
|
2015-04-03 22:26:18 +08:00
|
|
|
for item in list:
|
|
|
|
if os.path.isfile(os.path.join(cwd, item, 'SConscript')):
|
|
|
|
group = group + SConscript(os.path.join(item, 'SConscript'))
|
2013-01-08 22:40:58 +08:00
|
|
|
|
|
|
|
Return('group')
|