CYFS 1 месяц назад
Родитель
Сommit
5c20c4f8db

+ 17 - 1
bsp/hpmicro/hpm5300evk/SConstruct

@@ -15,6 +15,23 @@ except:
     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)
+
 TARGET = 'rtthread.' + rtconfig.TARGET_EXT
 
 AddOption('--run',
@@ -56,7 +73,6 @@ GDB = rtconfig.GDB
 objs = PrepareBuilding(env, RTT_ROOT, has_libcpu=False)
 
 
-
 # includes rtt drivers
 objs.extend(SConscript(os.path.join(libraries_path_prefix, 'drivers',  'SConscript')))
 

+ 0 - 23
bsp/hpmicro/hpm5300evk/rtconfig.py

@@ -12,29 +12,6 @@ else:
     RTT_ROOT = os.path.normpath(os.getcwd() + '/../../..')
 
 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

+ 17 - 0
bsp/hpmicro/hpm5301evklite/SConstruct

@@ -15,6 +15,23 @@ except:
     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)
+
 TARGET = 'rtthread.' + rtconfig.TARGET_EXT
 
 AddOption('--run',

+ 0 - 24
bsp/hpmicro/hpm5301evklite/rtconfig.py

@@ -12,30 +12,6 @@ else:
     RTT_ROOT = os.path.normpath(os.getcwd() + '/../../..')
 
 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
 ARCH='risc-v'

+ 17 - 0
bsp/hpmicro/hpm5e00evk/SConstruct

@@ -15,6 +15,23 @@ except:
     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)
+
 TARGET = 'rtthread.' + rtconfig.TARGET_EXT
 
 AddOption('--run',

+ 0 - 24
bsp/hpmicro/hpm5e00evk/rtconfig.py

@@ -12,30 +12,6 @@ else:
     RTT_ROOT = os.path.normpath(os.getcwd() + '/../../..')
 
 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
 ARCH='risc-v'

+ 17 - 0
bsp/hpmicro/hpm6200evk/SConstruct

@@ -15,6 +15,23 @@ except:
     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)
+
 TARGET = 'rtthread.' + rtconfig.TARGET_EXT
 
 AddOption('--run',

+ 0 - 24
bsp/hpmicro/hpm6200evk/rtconfig.py

@@ -12,30 +12,6 @@ else:
     RTT_ROOT = os.path.normpath(os.getcwd() + '/../../..')
 
 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
 ARCH='risc-v'

+ 17 - 0
bsp/hpmicro/hpm6300evk/SConstruct

@@ -15,6 +15,23 @@ except:
     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)
+
 TARGET = 'rtthread.' + rtconfig.TARGET_EXT
 
 AddOption('--run',

+ 0 - 24
bsp/hpmicro/hpm6300evk/rtconfig.py

@@ -12,30 +12,6 @@ else:
     RTT_ROOT = os.path.normpath(os.getcwd() + '/../../..')
 
 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
 ARCH='risc-v'

+ 17 - 0
bsp/hpmicro/hpm6750evk/SConstruct

@@ -15,6 +15,23 @@ except:
     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)
+
 TARGET = 'rtthread.' + rtconfig.TARGET_EXT
 
 AddOption('--run',

+ 0 - 24
bsp/hpmicro/hpm6750evk/rtconfig.py

@@ -12,30 +12,6 @@ else:
     RTT_ROOT = os.path.normpath(os.getcwd() + '/../../..')
 
 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
 ARCH='risc-v'

+ 17 - 0
bsp/hpmicro/hpm6750evk2/SConstruct

@@ -15,6 +15,23 @@ except:
     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)
+
 TARGET = 'rtthread.' + rtconfig.TARGET_EXT
 
 AddOption('--run',

+ 0 - 24
bsp/hpmicro/hpm6750evk2/rtconfig.py

@@ -12,30 +12,6 @@ else:
     RTT_ROOT = os.path.normpath(os.getcwd() + '/../../..')
 
 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
 ARCH='risc-v'

+ 17 - 0
bsp/hpmicro/hpm6750evkmini/SConstruct

@@ -15,6 +15,23 @@ except:
     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)
+
 TARGET = 'rtthread.' + rtconfig.TARGET_EXT
 
 AddOption('--run',

+ 0 - 24
bsp/hpmicro/hpm6750evkmini/rtconfig.py

@@ -12,30 +12,6 @@ else:
     RTT_ROOT = os.path.normpath(os.getcwd() + '/../../..')
 
 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
 ARCH='risc-v'

+ 17 - 0
bsp/hpmicro/hpm6800evk/SConstruct

@@ -15,6 +15,23 @@ except:
     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)
+
 TARGET = 'rtthread.' + rtconfig.TARGET_EXT
 
 AddOption('--run',

+ 0 - 24
bsp/hpmicro/hpm6800evk/rtconfig.py

@@ -12,30 +12,6 @@ else:
     RTT_ROOT = os.path.normpath(os.getcwd() + '/../../..')
 
 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
 ARCH='risc-v'

+ 17 - 0
bsp/hpmicro/hpm6p00evk/SConstruct

@@ -15,6 +15,23 @@ except:
     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)
+
 TARGET = 'rtthread.' + rtconfig.TARGET_EXT
 
 AddOption('--run',

+ 0 - 24
bsp/hpmicro/hpm6p00evk/rtconfig.py

@@ -12,30 +12,6 @@ else:
     RTT_ROOT = os.path.normpath(os.getcwd() + '/../../..')
 
 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
 ARCH='risc-v'

+ 0 - 14
bsp/hpmicro/libraries/SConscript

@@ -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')