Skip to content

bsp:stm32:Add reminder for missing dependency packages #10247

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
May 12, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 19 additions & 0 deletions bsp/stm32/stm32f072-st-nucleo/SConstruct
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,25 @@ except:
print(RTT_ROOT)
exit(-1)

def bsp_pkg_check():
import subprocess

check_paths = [
os.path.join("packages", "CMSIS-Core-latest"),
os.path.join("packages", "stm32f0_cmsis_driver-latest"),
os.path.join("packages", "stm32f0_hal_driver-latest")
]

need_update = not all(os.path.exists(p) for p in check_paths)

if need_update:
print("\n==============================================================")
print("Dependency packages missing, please running 'pkgs --update'...")
print("==============================================================")
exit(1)

RegisterPreBuildingAction(bsp_pkg_check)

TARGET = 'rt-thread.' + rtconfig.TARGET_EXT

DefaultEnvironment(tools=[])
Expand Down
19 changes: 19 additions & 0 deletions bsp/stm32/stm32f091-st-nucleo/SConstruct
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,25 @@ except:
print('Cannot found RT-Thread root directory, please check RTT_ROOT')
print(RTT_ROOT)
exit(-1)

def bsp_pkg_check():
import subprocess

check_paths = [
os.path.join("packages", "CMSIS-Core-latest"),
os.path.join("packages", "stm32f0_cmsis_driver-latest"),
os.path.join("packages", "stm32f0_hal_driver-latest")
]

need_update = not all(os.path.exists(p) for p in check_paths)

if need_update:
print("\n==============================================================")
print("Dependency packages missing, please running 'pkgs --update'...")
print("==============================================================")
exit(1)

RegisterPreBuildingAction(bsp_pkg_check)

TARGET = 'rt-thread.' + rtconfig.TARGET_EXT

Expand Down
19 changes: 19 additions & 0 deletions bsp/stm32/stm32f103-100ask-mini/SConstruct
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,25 @@ except:
print(RTT_ROOT)
exit(-1)

def bsp_pkg_check():
import subprocess

check_paths = [
os.path.join("packages", "CMSIS-Core-latest"),
os.path.join("packages", "stm32f1_cmsis_driver-latest"),
os.path.join("packages", "stm32f1_hal_driver-latest")
]

need_update = not all(os.path.exists(p) for p in check_paths)

if need_update:
print("\n==============================================================")
print("Dependency packages missing, please running 'pkgs --update'...")
print("==============================================================")
exit(1)

RegisterPreBuildingAction(bsp_pkg_check)

TARGET = 'rt-thread.' + rtconfig.TARGET_EXT

DefaultEnvironment(tools=[])
Expand Down
19 changes: 19 additions & 0 deletions bsp/stm32/stm32f103-100ask-pro/SConstruct
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,25 @@ except:
print(RTT_ROOT)
exit(-1)

def bsp_pkg_check():
import subprocess

check_paths = [
os.path.join("packages", "CMSIS-Core-latest"),
os.path.join("packages", "stm32f1_cmsis_driver-latest"),
os.path.join("packages", "stm32f1_hal_driver-latest")
]

need_update = not all(os.path.exists(p) for p in check_paths)

if need_update:
print("\n==============================================================")
print("Dependency packages missing, please running 'pkgs --update'...")
print("==============================================================")
exit(1)

RegisterPreBuildingAction(bsp_pkg_check)

TARGET = 'rt-thread.' + rtconfig.TARGET_EXT

DefaultEnvironment(tools=[])
Expand Down
19 changes: 19 additions & 0 deletions bsp/stm32/stm32f103-atk-nano/SConstruct
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,25 @@ except:
print(RTT_ROOT)
exit(-1)

def bsp_pkg_check():
import subprocess

check_paths = [
os.path.join("packages", "CMSIS-Core-latest"),
os.path.join("packages", "stm32f1_cmsis_driver-latest"),
os.path.join("packages", "stm32f1_hal_driver-latest")
]

need_update = not all(os.path.exists(p) for p in check_paths)

if need_update:
print("\n==============================================================")
print("Dependency packages missing, please running 'pkgs --update'...")
print("==============================================================")
exit(1)

RegisterPreBuildingAction(bsp_pkg_check)

TARGET = 'rt-thread.' + rtconfig.TARGET_EXT

DefaultEnvironment(tools=[])
Expand Down
19 changes: 19 additions & 0 deletions bsp/stm32/stm32f103-atk-warshipv3/SConstruct
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,25 @@ except:
print(RTT_ROOT)
exit(-1)

def bsp_pkg_check():
import subprocess

check_paths = [
os.path.join("packages", "CMSIS-Core-latest"),
os.path.join("packages", "stm32f1_cmsis_driver-latest"),
os.path.join("packages", "stm32f1_hal_driver-latest")
]

need_update = not all(os.path.exists(p) for p in check_paths)

if need_update:
print("\n==============================================================")
print("Dependency packages missing, please running 'pkgs --update'...")
print("==============================================================")
exit(1)

RegisterPreBuildingAction(bsp_pkg_check)

TARGET = 'rt-thread.' + rtconfig.TARGET_EXT

DefaultEnvironment(tools=[])
Expand Down
19 changes: 19 additions & 0 deletions bsp/stm32/stm32f103-blue-pill/SConstruct
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,25 @@ except:
print(RTT_ROOT)
exit(-1)

def bsp_pkg_check():
import subprocess

check_paths = [
os.path.join("packages", "CMSIS-Core-latest"),
os.path.join("packages", "stm32f1_cmsis_driver-latest"),
os.path.join("packages", "stm32f1_hal_driver-latest")
]

need_update = not all(os.path.exists(p) for p in check_paths)

if need_update:
print("\n==============================================================")
print("Dependency packages missing, please running 'pkgs --update'...")
print("==============================================================")
exit(1)

RegisterPreBuildingAction(bsp_pkg_check)

TARGET = 'rt-thread.' + rtconfig.TARGET_EXT

DefaultEnvironment(tools=[])
Expand Down
19 changes: 19 additions & 0 deletions bsp/stm32/stm32f103-dofly-M3S/SConstruct
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,25 @@ except:
print(RTT_ROOT)
exit(-1)

def bsp_pkg_check():
import subprocess

check_paths = [
os.path.join("packages", "CMSIS-Core-latest"),
os.path.join("packages", "stm32f1_cmsis_driver-latest"),
os.path.join("packages", "stm32f1_hal_driver-latest")
]

need_update = not all(os.path.exists(p) for p in check_paths)

if need_update:
print("\n==============================================================")
print("Dependency packages missing, please running 'pkgs --update'...")
print("==============================================================")
exit(1)

RegisterPreBuildingAction(bsp_pkg_check)

TARGET = 'rt-thread.' + rtconfig.TARGET_EXT

DefaultEnvironment(tools=[])
Expand Down
19 changes: 19 additions & 0 deletions bsp/stm32/stm32f103-dofly-lyc8/SConstruct
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,25 @@ except:
print(RTT_ROOT)
exit(-1)

def bsp_pkg_check():
import subprocess

check_paths = [
os.path.join("packages", "CMSIS-Core-latest"),
os.path.join("packages", "stm32f1_cmsis_driver-latest"),
os.path.join("packages", "stm32f1_hal_driver-latest")
]

need_update = not all(os.path.exists(p) for p in check_paths)

if need_update:
print("\n==============================================================")
print("Dependency packages missing, please running 'pkgs --update'...")
print("==============================================================")
exit(1)

RegisterPreBuildingAction(bsp_pkg_check)

TARGET = 'rt-thread.' + rtconfig.TARGET_EXT

DefaultEnvironment(tools=[])
Expand Down
19 changes: 19 additions & 0 deletions bsp/stm32/stm32f103-fire-arbitrary/SConstruct
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,25 @@ except:
print(RTT_ROOT)
exit(-1)

def bsp_pkg_check():
import subprocess

check_paths = [
os.path.join("packages", "CMSIS-Core-latest"),
os.path.join("packages", "stm32f1_cmsis_driver-latest"),
os.path.join("packages", "stm32f1_hal_driver-latest")
]

need_update = not all(os.path.exists(p) for p in check_paths)

if need_update:
print("\n==============================================================")
print("Dependency packages missing, please running 'pkgs --update'...")
print("==============================================================")
exit(1)

RegisterPreBuildingAction(bsp_pkg_check)

TARGET = 'rt-thread.' + rtconfig.TARGET_EXT

DefaultEnvironment(tools=[])
Expand Down
19 changes: 19 additions & 0 deletions bsp/stm32/stm32f103-gizwits-gokitv21/SConstruct
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,25 @@ except:
print(RTT_ROOT)
exit(-1)

def bsp_pkg_check():
import subprocess

check_paths = [
os.path.join("packages", "CMSIS-Core-latest"),
os.path.join("packages", "stm32f1_cmsis_driver-latest"),
os.path.join("packages", "stm32f1_hal_driver-latest")
]

need_update = not all(os.path.exists(p) for p in check_paths)

if need_update:
print("\n==============================================================")
print("Dependency packages missing, please running 'pkgs --update'...")
print("==============================================================")
exit(1)

RegisterPreBuildingAction(bsp_pkg_check)

TARGET = 'rt-thread.' + rtconfig.TARGET_EXT

DefaultEnvironment(tools=[])
Expand Down
19 changes: 19 additions & 0 deletions bsp/stm32/stm32f103-hw100k-ibox/SConstruct
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,25 @@ except:
print(RTT_ROOT)
exit(-1)

def bsp_pkg_check():
import subprocess

check_paths = [
os.path.join("packages", "CMSIS-Core-latest"),
os.path.join("packages", "stm32f1_cmsis_driver-latest"),
os.path.join("packages", "stm32f1_hal_driver-latest")
]

need_update = not all(os.path.exists(p) for p in check_paths)

if need_update:
print("\n==============================================================")
print("Dependency packages missing, please running 'pkgs --update'...")
print("==============================================================")
exit(1)

RegisterPreBuildingAction(bsp_pkg_check)

TARGET = 'rt-thread.' + rtconfig.TARGET_EXT

DefaultEnvironment(tools=[])
Expand Down
19 changes: 19 additions & 0 deletions bsp/stm32/stm32f103-onenet-nbiot/SConstruct
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,25 @@ except:
print(RTT_ROOT)
exit(-1)

def bsp_pkg_check():
import subprocess

check_paths = [
os.path.join("packages", "CMSIS-Core-latest"),
os.path.join("packages", "stm32f1_cmsis_driver-latest"),
os.path.join("packages", "stm32f1_hal_driver-latest")
]

need_update = not all(os.path.exists(p) for p in check_paths)

if need_update:
print("\n==============================================================")
print("Dependency packages missing, please running 'pkgs --update'...")
print("==============================================================")
exit(1)

RegisterPreBuildingAction(bsp_pkg_check)

TARGET = 'rt-thread.' + rtconfig.TARGET_EXT

DefaultEnvironment(tools=[])
Expand Down
19 changes: 19 additions & 0 deletions bsp/stm32/stm32f103-yf-ufun/SConstruct
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,25 @@ except:
print(RTT_ROOT)
exit(-1)

def bsp_pkg_check():
import subprocess

check_paths = [
os.path.join("packages", "CMSIS-Core-latest"),
os.path.join("packages", "stm32f1_cmsis_driver-latest"),
os.path.join("packages", "stm32f1_hal_driver-latest")
]

need_update = not all(os.path.exists(p) for p in check_paths)

if need_update:
print("\n==============================================================")
print("Dependency packages missing, please running 'pkgs --update'...")
print("==============================================================")
exit(1)

RegisterPreBuildingAction(bsp_pkg_check)

TARGET = 'rt-thread.' + rtconfig.TARGET_EXT

DefaultEnvironment(tools=[])
Expand Down
19 changes: 19 additions & 0 deletions bsp/stm32/stm32f103-ys-f1pro/SConstruct
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,25 @@ except:
print(RTT_ROOT)
exit(-1)

def bsp_pkg_check():
import subprocess

check_paths = [
os.path.join("packages", "CMSIS-Core-latest"),
os.path.join("packages", "stm32f1_cmsis_driver-latest"),
os.path.join("packages", "stm32f1_hal_driver-latest")
]

need_update = not all(os.path.exists(p) for p in check_paths)

if need_update:
print("\n==============================================================")
print("Dependency packages missing, please running 'pkgs --update'...")
print("==============================================================")
exit(1)

RegisterPreBuildingAction(bsp_pkg_check)

TARGET = 'rt-thread.' + rtconfig.TARGET_EXT

DefaultEnvironment(tools=[])
Expand Down
Loading
Loading