mirror of
https://github.com/RT-Thread/rt-thread.git
synced 2026-10-02 14:23:19 +08:00
同步 Renesas BSP 的 MDK5 工程生成方式,移除对 RASC gpdsc/build hook 的依赖,并更新由 scons 生成的 Keil 工程。 已保留存在实际 via 文件的 BSP 配置,仅移除缺失 via 文件的引用。
27 lines
642 B
Python
27 lines
642 B
Python
# for module compiling
|
|
import os
|
|
Import('RTT_ROOT')
|
|
Import('rtconfig')
|
|
from building import *
|
|
|
|
cwd = GetCurrentDir()
|
|
src = []
|
|
CPPPATH = []
|
|
list = os.listdir(cwd)
|
|
|
|
if rtconfig.PLATFORM in ['iccarm']:
|
|
print("\nThe current project does not support IAR build\n")
|
|
Return('group')
|
|
elif rtconfig.PLATFORM in ['gcc', 'armclang']:
|
|
CPPPATH = [cwd]
|
|
src = Glob('./src/*.c')
|
|
|
|
group = DefineGroup('Applications', src, depend = [''], CPPPATH = CPPPATH)
|
|
|
|
for d in list:
|
|
path = os.path.join(cwd, d)
|
|
if os.path.isfile(os.path.join(path, 'SConscript')):
|
|
group = group + SConscript(os.path.join(d, 'SConscript'))
|
|
|
|
Return('group')
|