mirror of
https://github.com/RT-Thread/rt-thread.git
synced 2026-02-08 03:03:07 +08:00
Some checks failed
ToolsCI / Tools (push) Has been cancelled
RT-Thread BSP Static Build Check / 🔍 Summary of Git Diff Changes (push) Has been cancelled
doc_doxygen / doxygen_doc generate (push) Has been cancelled
pkgs_test / change (push) Has been cancelled
utest_auto_run / A9 :components/dfs.cfg (push) Has been cancelled
utest_auto_run / A9 :components/lwip.cfg (push) Has been cancelled
utest_auto_run / A9 :components/netdev.cfg (push) Has been cancelled
utest_auto_run / A9 :components/sal.cfg (push) Has been cancelled
utest_auto_run / A9 :cpp11/cpp11.cfg (push) Has been cancelled
utest_auto_run / AARCH64-rtsmart :default.cfg (push) Has been cancelled
utest_auto_run / A9-rtsmart :default.cfg (push) Has been cancelled
utest_auto_run / RISCV-rtsmart :default.cfg (push) Has been cancelled
utest_auto_run / XUANTIE-rtsmart :default.cfg (push) Has been cancelled
utest_auto_run / AARCH64 :default.cfg (push) Has been cancelled
utest_auto_run / A9 :default.cfg (push) Has been cancelled
utest_auto_run / A9-smp :default.cfg (push) Has been cancelled
utest_auto_run / RISCV :default.cfg (push) Has been cancelled
utest_auto_run / A9 :kernel/atomic_c11.cfg (push) Has been cancelled
utest_auto_run / RISCV :kernel/atomic_c11.cfg (push) Has been cancelled
utest_auto_run / A9 :kernel/ipc.cfg (push) Has been cancelled
utest_auto_run / A9 :kernel/kernel_basic.cfg (push) Has been cancelled
utest_auto_run / A9 :kernel/mem.cfg (push) Has been cancelled
RT-Thread BSP Static Build Check / ${{ matrix.legs.RTT_BSP }} (push) Has been cancelled
RT-Thread BSP Static Build Check / collect-artifacts (push) Has been cancelled
doc_doxygen / deploy (push) Has been cancelled
Weekly CI Scheduler / Trigger and Monitor CIs (push) Has been cancelled
Weekly CI Scheduler / Create Discussion Report (push) Has been cancelled
41 lines
931 B
Python
41 lines
931 B
Python
# RT-Thread building script for component
|
|
|
|
from building import *
|
|
|
|
Import('rtconfig')
|
|
|
|
cwd = GetCurrentDir()
|
|
src = Glob('*.c') + Glob('*.cpp') + Glob('*.S')
|
|
CPPPATH = [cwd, cwd + '/include']
|
|
|
|
if GetDepend('RT_USING_SMP'):
|
|
core_model = 'mp'
|
|
else:
|
|
core_model = 'up'
|
|
|
|
src += Glob(core_model + '/*.S')
|
|
|
|
if GetDepend('RT_USING_OFW') == False:
|
|
SrcRemove(src, ['setup.c', 'cpu_psci.c', 'psci.c'])
|
|
|
|
if GetDepend('RT_USING_PIC') == True:
|
|
SrcRemove(src, ['gicv3.c', 'gic.c', 'gtimer.c', 'interrupt.c'])
|
|
|
|
if GetDepend('RT_HWTIMER_ARM_ARCH') == True:
|
|
SrcRemove(src, ['gtimer.c'])
|
|
|
|
group = DefineGroup('CPU', src, depend = [''], CPPPATH = CPPPATH)
|
|
|
|
# build for sub-directory
|
|
list = os.listdir(cwd)
|
|
objs = []
|
|
|
|
for d in list:
|
|
path = os.path.join(cwd, d)
|
|
if os.path.isfile(os.path.join(path, 'SConscript')):
|
|
objs = objs + SConscript(os.path.join(d, 'SConscript'))
|
|
group = group + objs
|
|
|
|
|
|
Return('group')
|