mirror of https://github.com/RT-Thread/rt-thread
[smart] rename the Group name to 'lwProcess' and optimize the error handling for vDSO building.
This commit is contained in:
parent
492e33dd3c
commit
172676e115
|
@ -52,7 +52,7 @@ CPPPATH += ['./terminal/']
|
||||||
if not GetDepend(['LWP_USING_RUNTIME']):
|
if not GetDepend(['LWP_USING_RUNTIME']):
|
||||||
SrcRemove(src, 'lwp_runtime.c')
|
SrcRemove(src, 'lwp_runtime.c')
|
||||||
|
|
||||||
group = DefineGroup('lwP', src, depend = ['RT_USING_SMART'], CPPPATH = CPPPATH)
|
group = DefineGroup('lwProcess', src, depend = ['RT_USING_SMART'], CPPPATH = CPPPATH)
|
||||||
|
|
||||||
group = group + SConscript(os.path.join('vdso', 'SConscript'))
|
group = group + SConscript(os.path.join('vdso', 'SConscript'))
|
||||||
Return('group')
|
Return('group')
|
||||||
|
|
|
@ -1,11 +0,0 @@
|
||||||
# RT-Thread building script for component
|
|
||||||
|
|
||||||
from building import *
|
|
||||||
|
|
||||||
cwd = GetCurrentDir()
|
|
||||||
src = Glob('*.c') + Glob('*.S')
|
|
||||||
CPPPATH = [cwd]
|
|
||||||
|
|
||||||
group = DefineGroup('lwp-riscv', src, depend = ['RT_USING_SMART'], CPPPATH = CPPPATH)
|
|
||||||
|
|
||||||
Return('group')
|
|
|
@ -1,11 +0,0 @@
|
||||||
# RT-Thread building script for component
|
|
||||||
|
|
||||||
from building import *
|
|
||||||
|
|
||||||
cwd = GetCurrentDir()
|
|
||||||
src = Glob('*.c') + Glob('*.S')
|
|
||||||
CPPPATH = [cwd]
|
|
||||||
|
|
||||||
group = DefineGroup('lwp-x86-i386', src, depend = ['RT_USING_SMART'], CPPPATH = CPPPATH)
|
|
||||||
|
|
||||||
Return('group')
|
|
|
@ -35,12 +35,15 @@ else:
|
||||||
process_env['RTT_DEVICE'] = rtconfig.DEVICE
|
process_env['RTT_DEVICE'] = rtconfig.DEVICE
|
||||||
|
|
||||||
command = ["scons", "-C", vdso_arch]
|
command = ["scons", "-C", vdso_arch]
|
||||||
clean_command = ["scons", "-C", vdso_arch, "--clean"]
|
if GetOption('clean'):
|
||||||
|
command = ["scons", "-C", vdso_arch, "--clean"]
|
||||||
|
|
||||||
if not GetOption('clean'):
|
try:
|
||||||
result = subprocess.run(command, env=process_env, check=True)
|
result = subprocess.run(command, env=process_env, check=True)
|
||||||
else:
|
# generic error handle
|
||||||
result = subprocess.run(clean_command, env=process_env, check=True)
|
except :
|
||||||
|
print('exec command: "%s" failed.' % ' '.join(command))
|
||||||
|
exit(1)
|
||||||
|
|
||||||
if result.returncode == 0:
|
if result.returncode == 0:
|
||||||
print("Command executed successfully")
|
print("Command executed successfully")
|
||||||
|
@ -48,5 +51,5 @@ else:
|
||||||
print("Command failed with exit code:", result.returncode)
|
print("Command failed with exit code:", result.returncode)
|
||||||
exit(1)
|
exit(1)
|
||||||
|
|
||||||
group = DefineGroup('vDSO', src, depend = ['RT_USING_SMART','RT_USING_VDSO'], CPPPATH = CPPPATH)
|
group = DefineGroup('lwProcess', src, depend = ['RT_USING_SMART','RT_USING_VDSO'], CPPPATH = CPPPATH)
|
||||||
Return('group')
|
Return('group')
|
||||||
|
|
Loading…
Reference in New Issue