mirror of
https://github.com/RT-Thread/rt-thread.git
synced 2026-05-28 01:51:00 +08:00
[bsp][hpm]:fix scons --dist
This commit is contained in:
@@ -15,6 +15,23 @@ except:
|
|||||||
print(RTT_ROOT)
|
print(RTT_ROOT)
|
||||||
exit(-1)
|
exit(-1)
|
||||||
|
|
||||||
|
def bsp_pkg_check():
|
||||||
|
import subprocess
|
||||||
|
|
||||||
|
need_update = True
|
||||||
|
for p in os.listdir("packages"):
|
||||||
|
if p.startswith("hpm_sdk-"):
|
||||||
|
need_update = False
|
||||||
|
break
|
||||||
|
if need_update:
|
||||||
|
print("\n===============================================================================")
|
||||||
|
print("Dependency packages missing, please running 'pkgs --update'...")
|
||||||
|
print("If no packages are fetched, run 'pkgs --upgrade' first, then 'pkgs --update'...")
|
||||||
|
print("===============================================================================")
|
||||||
|
exit(1)
|
||||||
|
|
||||||
|
RegisterPreBuildingAction(bsp_pkg_check)
|
||||||
|
|
||||||
TARGET = 'rtthread.' + rtconfig.TARGET_EXT
|
TARGET = 'rtthread.' + rtconfig.TARGET_EXT
|
||||||
|
|
||||||
AddOption('--run',
|
AddOption('--run',
|
||||||
@@ -56,7 +73,6 @@ GDB = rtconfig.GDB
|
|||||||
objs = PrepareBuilding(env, RTT_ROOT, has_libcpu=False)
|
objs = PrepareBuilding(env, RTT_ROOT, has_libcpu=False)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
# includes rtt drivers
|
# includes rtt drivers
|
||||||
objs.extend(SConscript(os.path.join(libraries_path_prefix, 'drivers', 'SConscript')))
|
objs.extend(SConscript(os.path.join(libraries_path_prefix, 'drivers', 'SConscript')))
|
||||||
|
|
||||||
|
|||||||
@@ -12,29 +12,6 @@ else:
|
|||||||
RTT_ROOT = os.path.normpath(os.getcwd() + '/../../..')
|
RTT_ROOT = os.path.normpath(os.getcwd() + '/../../..')
|
||||||
|
|
||||||
sys.path = sys.path + [os.path.join(RTT_ROOT, 'tools')]
|
sys.path = sys.path + [os.path.join(RTT_ROOT, 'tools')]
|
||||||
try:
|
|
||||||
from building import *
|
|
||||||
except:
|
|
||||||
print('Cannot found RT-Thread root directory, please check RTT_ROOT')
|
|
||||||
print(RTT_ROOT)
|
|
||||||
exit(-1)
|
|
||||||
|
|
||||||
def bsp_pkg_check():
|
|
||||||
import subprocess
|
|
||||||
|
|
||||||
need_update = True
|
|
||||||
for p in os.listdir("packages"):
|
|
||||||
if p.startswith("hpm_sdk-"):
|
|
||||||
need_update = False
|
|
||||||
break
|
|
||||||
if need_update:
|
|
||||||
print("\n===============================================================================")
|
|
||||||
print("Dependency packages missing, please running 'pkgs --update'...")
|
|
||||||
print("If no packages are fetched, run 'pkgs --upgrade' first, then 'pkgs --update'...")
|
|
||||||
print("===============================================================================")
|
|
||||||
exit(1)
|
|
||||||
|
|
||||||
RegisterPreBuildingAction(bsp_pkg_check)
|
|
||||||
|
|
||||||
|
|
||||||
# toolchains options
|
# toolchains options
|
||||||
|
|||||||
@@ -15,6 +15,23 @@ except:
|
|||||||
print(RTT_ROOT)
|
print(RTT_ROOT)
|
||||||
exit(-1)
|
exit(-1)
|
||||||
|
|
||||||
|
def bsp_pkg_check():
|
||||||
|
import subprocess
|
||||||
|
|
||||||
|
need_update = True
|
||||||
|
for p in os.listdir("packages"):
|
||||||
|
if p.startswith("hpm_sdk-"):
|
||||||
|
need_update = False
|
||||||
|
break
|
||||||
|
if need_update:
|
||||||
|
print("\n===============================================================================")
|
||||||
|
print("Dependency packages missing, please running 'pkgs --update'...")
|
||||||
|
print("If no packages are fetched, run 'pkgs --upgrade' first, then 'pkgs --update'...")
|
||||||
|
print("===============================================================================")
|
||||||
|
exit(1)
|
||||||
|
|
||||||
|
RegisterPreBuildingAction(bsp_pkg_check)
|
||||||
|
|
||||||
TARGET = 'rtthread.' + rtconfig.TARGET_EXT
|
TARGET = 'rtthread.' + rtconfig.TARGET_EXT
|
||||||
|
|
||||||
AddOption('--run',
|
AddOption('--run',
|
||||||
|
|||||||
@@ -12,30 +12,6 @@ else:
|
|||||||
RTT_ROOT = os.path.normpath(os.getcwd() + '/../../..')
|
RTT_ROOT = os.path.normpath(os.getcwd() + '/../../..')
|
||||||
|
|
||||||
sys.path = sys.path + [os.path.join(RTT_ROOT, 'tools')]
|
sys.path = sys.path + [os.path.join(RTT_ROOT, 'tools')]
|
||||||
try:
|
|
||||||
from building import *
|
|
||||||
except:
|
|
||||||
print('Cannot found RT-Thread root directory, please check RTT_ROOT')
|
|
||||||
print(RTT_ROOT)
|
|
||||||
exit(-1)
|
|
||||||
|
|
||||||
def bsp_pkg_check():
|
|
||||||
import subprocess
|
|
||||||
|
|
||||||
need_update = True
|
|
||||||
for p in os.listdir("packages"):
|
|
||||||
if p.startswith("hpm_sdk-"):
|
|
||||||
need_update = False
|
|
||||||
break
|
|
||||||
if need_update:
|
|
||||||
print("\n===============================================================================")
|
|
||||||
print("Dependency packages missing, please running 'pkgs --update'...")
|
|
||||||
print("If no packages are fetched, run 'pkgs --upgrade' first, then 'pkgs --update'...")
|
|
||||||
print("===============================================================================")
|
|
||||||
exit(1)
|
|
||||||
|
|
||||||
RegisterPreBuildingAction(bsp_pkg_check)
|
|
||||||
|
|
||||||
|
|
||||||
# toolchains options
|
# toolchains options
|
||||||
ARCH='risc-v'
|
ARCH='risc-v'
|
||||||
|
|||||||
@@ -15,6 +15,23 @@ except:
|
|||||||
print(RTT_ROOT)
|
print(RTT_ROOT)
|
||||||
exit(-1)
|
exit(-1)
|
||||||
|
|
||||||
|
def bsp_pkg_check():
|
||||||
|
import subprocess
|
||||||
|
|
||||||
|
need_update = True
|
||||||
|
for p in os.listdir("packages"):
|
||||||
|
if p.startswith("hpm_sdk-"):
|
||||||
|
need_update = False
|
||||||
|
break
|
||||||
|
if need_update:
|
||||||
|
print("\n===============================================================================")
|
||||||
|
print("Dependency packages missing, please running 'pkgs --update'...")
|
||||||
|
print("If no packages are fetched, run 'pkgs --upgrade' first, then 'pkgs --update'...")
|
||||||
|
print("===============================================================================")
|
||||||
|
exit(1)
|
||||||
|
|
||||||
|
RegisterPreBuildingAction(bsp_pkg_check)
|
||||||
|
|
||||||
TARGET = 'rtthread.' + rtconfig.TARGET_EXT
|
TARGET = 'rtthread.' + rtconfig.TARGET_EXT
|
||||||
|
|
||||||
AddOption('--run',
|
AddOption('--run',
|
||||||
|
|||||||
@@ -12,30 +12,6 @@ else:
|
|||||||
RTT_ROOT = os.path.normpath(os.getcwd() + '/../../..')
|
RTT_ROOT = os.path.normpath(os.getcwd() + '/../../..')
|
||||||
|
|
||||||
sys.path = sys.path + [os.path.join(RTT_ROOT, 'tools')]
|
sys.path = sys.path + [os.path.join(RTT_ROOT, 'tools')]
|
||||||
try:
|
|
||||||
from building import *
|
|
||||||
except:
|
|
||||||
print('Cannot found RT-Thread root directory, please check RTT_ROOT')
|
|
||||||
print(RTT_ROOT)
|
|
||||||
exit(-1)
|
|
||||||
|
|
||||||
def bsp_pkg_check():
|
|
||||||
import subprocess
|
|
||||||
|
|
||||||
need_update = True
|
|
||||||
for p in os.listdir("packages"):
|
|
||||||
if p.startswith("hpm_sdk-"):
|
|
||||||
need_update = False
|
|
||||||
break
|
|
||||||
if need_update:
|
|
||||||
print("\n===============================================================================")
|
|
||||||
print("Dependency packages missing, please running 'pkgs --update'...")
|
|
||||||
print("If no packages are fetched, run 'pkgs --upgrade' first, then 'pkgs --update'...")
|
|
||||||
print("===============================================================================")
|
|
||||||
exit(1)
|
|
||||||
|
|
||||||
RegisterPreBuildingAction(bsp_pkg_check)
|
|
||||||
|
|
||||||
|
|
||||||
# toolchains options
|
# toolchains options
|
||||||
ARCH='risc-v'
|
ARCH='risc-v'
|
||||||
|
|||||||
@@ -15,6 +15,23 @@ except:
|
|||||||
print(RTT_ROOT)
|
print(RTT_ROOT)
|
||||||
exit(-1)
|
exit(-1)
|
||||||
|
|
||||||
|
def bsp_pkg_check():
|
||||||
|
import subprocess
|
||||||
|
|
||||||
|
need_update = True
|
||||||
|
for p in os.listdir("packages"):
|
||||||
|
if p.startswith("hpm_sdk-"):
|
||||||
|
need_update = False
|
||||||
|
break
|
||||||
|
if need_update:
|
||||||
|
print("\n===============================================================================")
|
||||||
|
print("Dependency packages missing, please running 'pkgs --update'...")
|
||||||
|
print("If no packages are fetched, run 'pkgs --upgrade' first, then 'pkgs --update'...")
|
||||||
|
print("===============================================================================")
|
||||||
|
exit(1)
|
||||||
|
|
||||||
|
RegisterPreBuildingAction(bsp_pkg_check)
|
||||||
|
|
||||||
TARGET = 'rtthread.' + rtconfig.TARGET_EXT
|
TARGET = 'rtthread.' + rtconfig.TARGET_EXT
|
||||||
|
|
||||||
AddOption('--run',
|
AddOption('--run',
|
||||||
|
|||||||
@@ -12,30 +12,6 @@ else:
|
|||||||
RTT_ROOT = os.path.normpath(os.getcwd() + '/../../..')
|
RTT_ROOT = os.path.normpath(os.getcwd() + '/../../..')
|
||||||
|
|
||||||
sys.path = sys.path + [os.path.join(RTT_ROOT, 'tools')]
|
sys.path = sys.path + [os.path.join(RTT_ROOT, 'tools')]
|
||||||
try:
|
|
||||||
from building import *
|
|
||||||
except:
|
|
||||||
print('Cannot found RT-Thread root directory, please check RTT_ROOT')
|
|
||||||
print(RTT_ROOT)
|
|
||||||
exit(-1)
|
|
||||||
|
|
||||||
def bsp_pkg_check():
|
|
||||||
import subprocess
|
|
||||||
|
|
||||||
need_update = True
|
|
||||||
for p in os.listdir("packages"):
|
|
||||||
if p.startswith("hpm_sdk-"):
|
|
||||||
need_update = False
|
|
||||||
break
|
|
||||||
if need_update:
|
|
||||||
print("\n===============================================================================")
|
|
||||||
print("Dependency packages missing, please running 'pkgs --update'...")
|
|
||||||
print("If no packages are fetched, run 'pkgs --upgrade' first, then 'pkgs --update'...")
|
|
||||||
print("===============================================================================")
|
|
||||||
exit(1)
|
|
||||||
|
|
||||||
RegisterPreBuildingAction(bsp_pkg_check)
|
|
||||||
|
|
||||||
|
|
||||||
# toolchains options
|
# toolchains options
|
||||||
ARCH='risc-v'
|
ARCH='risc-v'
|
||||||
|
|||||||
@@ -15,6 +15,23 @@ except:
|
|||||||
print(RTT_ROOT)
|
print(RTT_ROOT)
|
||||||
exit(-1)
|
exit(-1)
|
||||||
|
|
||||||
|
def bsp_pkg_check():
|
||||||
|
import subprocess
|
||||||
|
|
||||||
|
need_update = True
|
||||||
|
for p in os.listdir("packages"):
|
||||||
|
if p.startswith("hpm_sdk-"):
|
||||||
|
need_update = False
|
||||||
|
break
|
||||||
|
if need_update:
|
||||||
|
print("\n===============================================================================")
|
||||||
|
print("Dependency packages missing, please running 'pkgs --update'...")
|
||||||
|
print("If no packages are fetched, run 'pkgs --upgrade' first, then 'pkgs --update'...")
|
||||||
|
print("===============================================================================")
|
||||||
|
exit(1)
|
||||||
|
|
||||||
|
RegisterPreBuildingAction(bsp_pkg_check)
|
||||||
|
|
||||||
TARGET = 'rtthread.' + rtconfig.TARGET_EXT
|
TARGET = 'rtthread.' + rtconfig.TARGET_EXT
|
||||||
|
|
||||||
AddOption('--run',
|
AddOption('--run',
|
||||||
|
|||||||
@@ -12,30 +12,6 @@ else:
|
|||||||
RTT_ROOT = os.path.normpath(os.getcwd() + '/../../..')
|
RTT_ROOT = os.path.normpath(os.getcwd() + '/../../..')
|
||||||
|
|
||||||
sys.path = sys.path + [os.path.join(RTT_ROOT, 'tools')]
|
sys.path = sys.path + [os.path.join(RTT_ROOT, 'tools')]
|
||||||
try:
|
|
||||||
from building import *
|
|
||||||
except:
|
|
||||||
print('Cannot found RT-Thread root directory, please check RTT_ROOT')
|
|
||||||
print(RTT_ROOT)
|
|
||||||
exit(-1)
|
|
||||||
|
|
||||||
def bsp_pkg_check():
|
|
||||||
import subprocess
|
|
||||||
|
|
||||||
need_update = True
|
|
||||||
for p in os.listdir("packages"):
|
|
||||||
if p.startswith("hpm_sdk-"):
|
|
||||||
need_update = False
|
|
||||||
break
|
|
||||||
if need_update:
|
|
||||||
print("\n===============================================================================")
|
|
||||||
print("Dependency packages missing, please running 'pkgs --update'...")
|
|
||||||
print("If no packages are fetched, run 'pkgs --upgrade' first, then 'pkgs --update'...")
|
|
||||||
print("===============================================================================")
|
|
||||||
exit(1)
|
|
||||||
|
|
||||||
RegisterPreBuildingAction(bsp_pkg_check)
|
|
||||||
|
|
||||||
|
|
||||||
# toolchains options
|
# toolchains options
|
||||||
ARCH='risc-v'
|
ARCH='risc-v'
|
||||||
|
|||||||
@@ -15,6 +15,23 @@ except:
|
|||||||
print(RTT_ROOT)
|
print(RTT_ROOT)
|
||||||
exit(-1)
|
exit(-1)
|
||||||
|
|
||||||
|
def bsp_pkg_check():
|
||||||
|
import subprocess
|
||||||
|
|
||||||
|
need_update = True
|
||||||
|
for p in os.listdir("packages"):
|
||||||
|
if p.startswith("hpm_sdk-"):
|
||||||
|
need_update = False
|
||||||
|
break
|
||||||
|
if need_update:
|
||||||
|
print("\n===============================================================================")
|
||||||
|
print("Dependency packages missing, please running 'pkgs --update'...")
|
||||||
|
print("If no packages are fetched, run 'pkgs --upgrade' first, then 'pkgs --update'...")
|
||||||
|
print("===============================================================================")
|
||||||
|
exit(1)
|
||||||
|
|
||||||
|
RegisterPreBuildingAction(bsp_pkg_check)
|
||||||
|
|
||||||
TARGET = 'rtthread.' + rtconfig.TARGET_EXT
|
TARGET = 'rtthread.' + rtconfig.TARGET_EXT
|
||||||
|
|
||||||
AddOption('--run',
|
AddOption('--run',
|
||||||
|
|||||||
@@ -12,30 +12,6 @@ else:
|
|||||||
RTT_ROOT = os.path.normpath(os.getcwd() + '/../../..')
|
RTT_ROOT = os.path.normpath(os.getcwd() + '/../../..')
|
||||||
|
|
||||||
sys.path = sys.path + [os.path.join(RTT_ROOT, 'tools')]
|
sys.path = sys.path + [os.path.join(RTT_ROOT, 'tools')]
|
||||||
try:
|
|
||||||
from building import *
|
|
||||||
except:
|
|
||||||
print('Cannot found RT-Thread root directory, please check RTT_ROOT')
|
|
||||||
print(RTT_ROOT)
|
|
||||||
exit(-1)
|
|
||||||
|
|
||||||
def bsp_pkg_check():
|
|
||||||
import subprocess
|
|
||||||
|
|
||||||
need_update = True
|
|
||||||
for p in os.listdir("packages"):
|
|
||||||
if p.startswith("hpm_sdk-"):
|
|
||||||
need_update = False
|
|
||||||
break
|
|
||||||
if need_update:
|
|
||||||
print("\n===============================================================================")
|
|
||||||
print("Dependency packages missing, please running 'pkgs --update'...")
|
|
||||||
print("If no packages are fetched, run 'pkgs --upgrade' first, then 'pkgs --update'...")
|
|
||||||
print("===============================================================================")
|
|
||||||
exit(1)
|
|
||||||
|
|
||||||
RegisterPreBuildingAction(bsp_pkg_check)
|
|
||||||
|
|
||||||
|
|
||||||
# toolchains options
|
# toolchains options
|
||||||
ARCH='risc-v'
|
ARCH='risc-v'
|
||||||
|
|||||||
@@ -15,6 +15,23 @@ except:
|
|||||||
print(RTT_ROOT)
|
print(RTT_ROOT)
|
||||||
exit(-1)
|
exit(-1)
|
||||||
|
|
||||||
|
def bsp_pkg_check():
|
||||||
|
import subprocess
|
||||||
|
|
||||||
|
need_update = True
|
||||||
|
for p in os.listdir("packages"):
|
||||||
|
if p.startswith("hpm_sdk-"):
|
||||||
|
need_update = False
|
||||||
|
break
|
||||||
|
if need_update:
|
||||||
|
print("\n===============================================================================")
|
||||||
|
print("Dependency packages missing, please running 'pkgs --update'...")
|
||||||
|
print("If no packages are fetched, run 'pkgs --upgrade' first, then 'pkgs --update'...")
|
||||||
|
print("===============================================================================")
|
||||||
|
exit(1)
|
||||||
|
|
||||||
|
RegisterPreBuildingAction(bsp_pkg_check)
|
||||||
|
|
||||||
TARGET = 'rtthread.' + rtconfig.TARGET_EXT
|
TARGET = 'rtthread.' + rtconfig.TARGET_EXT
|
||||||
|
|
||||||
AddOption('--run',
|
AddOption('--run',
|
||||||
|
|||||||
@@ -12,30 +12,6 @@ else:
|
|||||||
RTT_ROOT = os.path.normpath(os.getcwd() + '/../../..')
|
RTT_ROOT = os.path.normpath(os.getcwd() + '/../../..')
|
||||||
|
|
||||||
sys.path = sys.path + [os.path.join(RTT_ROOT, 'tools')]
|
sys.path = sys.path + [os.path.join(RTT_ROOT, 'tools')]
|
||||||
try:
|
|
||||||
from building import *
|
|
||||||
except:
|
|
||||||
print('Cannot found RT-Thread root directory, please check RTT_ROOT')
|
|
||||||
print(RTT_ROOT)
|
|
||||||
exit(-1)
|
|
||||||
|
|
||||||
def bsp_pkg_check():
|
|
||||||
import subprocess
|
|
||||||
|
|
||||||
need_update = True
|
|
||||||
for p in os.listdir("packages"):
|
|
||||||
if p.startswith("hpm_sdk-"):
|
|
||||||
need_update = False
|
|
||||||
break
|
|
||||||
if need_update:
|
|
||||||
print("\n===============================================================================")
|
|
||||||
print("Dependency packages missing, please running 'pkgs --update'...")
|
|
||||||
print("If no packages are fetched, run 'pkgs --upgrade' first, then 'pkgs --update'...")
|
|
||||||
print("===============================================================================")
|
|
||||||
exit(1)
|
|
||||||
|
|
||||||
RegisterPreBuildingAction(bsp_pkg_check)
|
|
||||||
|
|
||||||
|
|
||||||
# toolchains options
|
# toolchains options
|
||||||
ARCH='risc-v'
|
ARCH='risc-v'
|
||||||
|
|||||||
@@ -15,6 +15,23 @@ except:
|
|||||||
print(RTT_ROOT)
|
print(RTT_ROOT)
|
||||||
exit(-1)
|
exit(-1)
|
||||||
|
|
||||||
|
def bsp_pkg_check():
|
||||||
|
import subprocess
|
||||||
|
|
||||||
|
need_update = True
|
||||||
|
for p in os.listdir("packages"):
|
||||||
|
if p.startswith("hpm_sdk-"):
|
||||||
|
need_update = False
|
||||||
|
break
|
||||||
|
if need_update:
|
||||||
|
print("\n===============================================================================")
|
||||||
|
print("Dependency packages missing, please running 'pkgs --update'...")
|
||||||
|
print("If no packages are fetched, run 'pkgs --upgrade' first, then 'pkgs --update'...")
|
||||||
|
print("===============================================================================")
|
||||||
|
exit(1)
|
||||||
|
|
||||||
|
RegisterPreBuildingAction(bsp_pkg_check)
|
||||||
|
|
||||||
TARGET = 'rtthread.' + rtconfig.TARGET_EXT
|
TARGET = 'rtthread.' + rtconfig.TARGET_EXT
|
||||||
|
|
||||||
AddOption('--run',
|
AddOption('--run',
|
||||||
|
|||||||
@@ -12,30 +12,6 @@ else:
|
|||||||
RTT_ROOT = os.path.normpath(os.getcwd() + '/../../..')
|
RTT_ROOT = os.path.normpath(os.getcwd() + '/../../..')
|
||||||
|
|
||||||
sys.path = sys.path + [os.path.join(RTT_ROOT, 'tools')]
|
sys.path = sys.path + [os.path.join(RTT_ROOT, 'tools')]
|
||||||
try:
|
|
||||||
from building import *
|
|
||||||
except:
|
|
||||||
print('Cannot found RT-Thread root directory, please check RTT_ROOT')
|
|
||||||
print(RTT_ROOT)
|
|
||||||
exit(-1)
|
|
||||||
|
|
||||||
def bsp_pkg_check():
|
|
||||||
import subprocess
|
|
||||||
|
|
||||||
need_update = True
|
|
||||||
for p in os.listdir("packages"):
|
|
||||||
if p.startswith("hpm_sdk-"):
|
|
||||||
need_update = False
|
|
||||||
break
|
|
||||||
if need_update:
|
|
||||||
print("\n===============================================================================")
|
|
||||||
print("Dependency packages missing, please running 'pkgs --update'...")
|
|
||||||
print("If no packages are fetched, run 'pkgs --upgrade' first, then 'pkgs --update'...")
|
|
||||||
print("===============================================================================")
|
|
||||||
exit(1)
|
|
||||||
|
|
||||||
RegisterPreBuildingAction(bsp_pkg_check)
|
|
||||||
|
|
||||||
|
|
||||||
# toolchains options
|
# toolchains options
|
||||||
ARCH='risc-v'
|
ARCH='risc-v'
|
||||||
|
|||||||
@@ -15,6 +15,23 @@ except:
|
|||||||
print(RTT_ROOT)
|
print(RTT_ROOT)
|
||||||
exit(-1)
|
exit(-1)
|
||||||
|
|
||||||
|
def bsp_pkg_check():
|
||||||
|
import subprocess
|
||||||
|
|
||||||
|
need_update = True
|
||||||
|
for p in os.listdir("packages"):
|
||||||
|
if p.startswith("hpm_sdk-"):
|
||||||
|
need_update = False
|
||||||
|
break
|
||||||
|
if need_update:
|
||||||
|
print("\n===============================================================================")
|
||||||
|
print("Dependency packages missing, please running 'pkgs --update'...")
|
||||||
|
print("If no packages are fetched, run 'pkgs --upgrade' first, then 'pkgs --update'...")
|
||||||
|
print("===============================================================================")
|
||||||
|
exit(1)
|
||||||
|
|
||||||
|
RegisterPreBuildingAction(bsp_pkg_check)
|
||||||
|
|
||||||
TARGET = 'rtthread.' + rtconfig.TARGET_EXT
|
TARGET = 'rtthread.' + rtconfig.TARGET_EXT
|
||||||
|
|
||||||
AddOption('--run',
|
AddOption('--run',
|
||||||
|
|||||||
@@ -12,30 +12,6 @@ else:
|
|||||||
RTT_ROOT = os.path.normpath(os.getcwd() + '/../../..')
|
RTT_ROOT = os.path.normpath(os.getcwd() + '/../../..')
|
||||||
|
|
||||||
sys.path = sys.path + [os.path.join(RTT_ROOT, 'tools')]
|
sys.path = sys.path + [os.path.join(RTT_ROOT, 'tools')]
|
||||||
try:
|
|
||||||
from building import *
|
|
||||||
except:
|
|
||||||
print('Cannot found RT-Thread root directory, please check RTT_ROOT')
|
|
||||||
print(RTT_ROOT)
|
|
||||||
exit(-1)
|
|
||||||
|
|
||||||
def bsp_pkg_check():
|
|
||||||
import subprocess
|
|
||||||
|
|
||||||
need_update = True
|
|
||||||
for p in os.listdir("packages"):
|
|
||||||
if p.startswith("hpm_sdk-"):
|
|
||||||
need_update = False
|
|
||||||
break
|
|
||||||
if need_update:
|
|
||||||
print("\n===============================================================================")
|
|
||||||
print("Dependency packages missing, please running 'pkgs --update'...")
|
|
||||||
print("If no packages are fetched, run 'pkgs --upgrade' first, then 'pkgs --update'...")
|
|
||||||
print("===============================================================================")
|
|
||||||
exit(1)
|
|
||||||
|
|
||||||
RegisterPreBuildingAction(bsp_pkg_check)
|
|
||||||
|
|
||||||
|
|
||||||
# toolchains options
|
# toolchains options
|
||||||
ARCH='risc-v'
|
ARCH='risc-v'
|
||||||
|
|||||||
@@ -15,6 +15,23 @@ except:
|
|||||||
print(RTT_ROOT)
|
print(RTT_ROOT)
|
||||||
exit(-1)
|
exit(-1)
|
||||||
|
|
||||||
|
def bsp_pkg_check():
|
||||||
|
import subprocess
|
||||||
|
|
||||||
|
need_update = True
|
||||||
|
for p in os.listdir("packages"):
|
||||||
|
if p.startswith("hpm_sdk-"):
|
||||||
|
need_update = False
|
||||||
|
break
|
||||||
|
if need_update:
|
||||||
|
print("\n===============================================================================")
|
||||||
|
print("Dependency packages missing, please running 'pkgs --update'...")
|
||||||
|
print("If no packages are fetched, run 'pkgs --upgrade' first, then 'pkgs --update'...")
|
||||||
|
print("===============================================================================")
|
||||||
|
exit(1)
|
||||||
|
|
||||||
|
RegisterPreBuildingAction(bsp_pkg_check)
|
||||||
|
|
||||||
TARGET = 'rtthread.' + rtconfig.TARGET_EXT
|
TARGET = 'rtthread.' + rtconfig.TARGET_EXT
|
||||||
|
|
||||||
AddOption('--run',
|
AddOption('--run',
|
||||||
|
|||||||
@@ -12,30 +12,6 @@ else:
|
|||||||
RTT_ROOT = os.path.normpath(os.getcwd() + '/../../..')
|
RTT_ROOT = os.path.normpath(os.getcwd() + '/../../..')
|
||||||
|
|
||||||
sys.path = sys.path + [os.path.join(RTT_ROOT, 'tools')]
|
sys.path = sys.path + [os.path.join(RTT_ROOT, 'tools')]
|
||||||
try:
|
|
||||||
from building import *
|
|
||||||
except:
|
|
||||||
print('Cannot found RT-Thread root directory, please check RTT_ROOT')
|
|
||||||
print(RTT_ROOT)
|
|
||||||
exit(-1)
|
|
||||||
|
|
||||||
def bsp_pkg_check():
|
|
||||||
import subprocess
|
|
||||||
|
|
||||||
need_update = True
|
|
||||||
for p in os.listdir("packages"):
|
|
||||||
if p.startswith("hpm_sdk-"):
|
|
||||||
need_update = False
|
|
||||||
break
|
|
||||||
if need_update:
|
|
||||||
print("\n===============================================================================")
|
|
||||||
print("Dependency packages missing, please running 'pkgs --update'...")
|
|
||||||
print("If no packages are fetched, run 'pkgs --upgrade' first, then 'pkgs --update'...")
|
|
||||||
print("===============================================================================")
|
|
||||||
exit(1)
|
|
||||||
|
|
||||||
RegisterPreBuildingAction(bsp_pkg_check)
|
|
||||||
|
|
||||||
|
|
||||||
# toolchains options
|
# toolchains options
|
||||||
ARCH='risc-v'
|
ARCH='risc-v'
|
||||||
|
|||||||
@@ -1,14 +0,0 @@
|
|||||||
import os
|
|
||||||
import rtconfig
|
|
||||||
from building import *
|
|
||||||
|
|
||||||
|
|
||||||
objs = []
|
|
||||||
cwd = GetCurrentDir()
|
|
||||||
list = os.listdir(cwd)
|
|
||||||
|
|
||||||
for item in list:
|
|
||||||
if os.path.isfile(os.path.join(cwd, item, 'SConscript')):
|
|
||||||
objs = objs + SConscript(os.path.join(item, 'SConscript'))
|
|
||||||
|
|
||||||
Return('objs')
|
|
||||||
Reference in New Issue
Block a user