File tree Expand file tree Collapse file tree 4 files changed +15
-10
lines changed
Expand file tree Collapse file tree 4 files changed +15
-10
lines changed Original file line number Diff line number Diff line change 6868 mingw-w64-x86_64-nsis \
6969 mingw-w64-x86_64-dfu-util \
7070 mingw-w64-x86_64-openssl
71- python -m pip install clang jinja2
71+ python -m pip install --break-system-packages clang jinja2
7272
7373 - name : Check out the repo
7474 uses : actions/checkout@v4
Original file line number Diff line number Diff line change @@ -50,10 +50,14 @@ include(Macros)
5050git_id(GIT_STR)
5151
5252# Python check
53- find_package (PythonInterp 3 REQUIRED)
54- if (PYTHONINTERP_FOUND)
55- message (STATUS "Python found, version: ${PYTHON_VERSION_STRING} " )
56- get_filename_component (PYTHON_DIRECTORY ${PYTHON_EXECUTABLE} DIRECTORY )
53+ set (Python3_FIND_VIRTUALENV FIRST)
54+ set (Python3_FIND_STRATEGY LOCATION )
55+
56+ find_package (Python3 REQUIRED COMPONENTS Interpreter)
57+
58+ if (Python3_Interpreter_FOUND)
59+ message (STATUS "Python found, version: ${Python3_VERSION} " )
60+ cmake_path(NATIVE_PATH Python3_EXECUTABLE PYTHON_EXECUTABLE)
5761else ()
5862 message (WARNING "Python not found! Most firmware and simu flavors not buildable." )
5963 set (LUA NO )
Original file line number Diff line number Diff line change @@ -145,10 +145,11 @@ set(HWDEFS_QRC "${CMAKE_CURRENT_BINARY_DIR}/hwdefs.qrc")
145145set (HWDEFS_CMD "${COMPANION_SRC_DIRECTORY} /../util/generate_hwdefs_qrc.py" )
146146
147147add_custom_command (OUTPUT ${HWDEFS_QRC}
148- COMMAND ${HWDEFS_CMD} -d ${HWDEFS_DIR}
149- -t ${HWDEFS_TMPL}
150- -p ${HWDEFS_PHDR}
151- -o ${HWDEFS_QRC}
148+ COMMAND ${PYTHON_EXECUTABLE} ${HWDEFS_CMD}
149+ -d ${HWDEFS_DIR}
150+ -t ${HWDEFS_TMPL}
151+ -p ${HWDEFS_PHDR}
152+ -o ${HWDEFS_QRC}
152153 DEPENDS ${HWDEFS_TMPL}
153154)
154155
Original file line number Diff line number Diff line change @@ -102,7 +102,7 @@ add_custom_command(
102102 COMMAND ${CMAKE_OBJCOPY} -O binary bootloader.elf ${CMAKE_BINARY_DIR} /bootloader.bin
103103)
104104
105- if (PYTHONINTERP_FOUND )
105+ if (Python3_FOUND )
106106 add_custom_command (
107107 TARGET bootloader POST_BUILD
108108 COMMAND ${PYTHON_EXECUTABLE} ${RADIO_DIRECTORY} /util/bin2lbm.py ${CMAKE_BINARY_DIR} /bootloader.bin bootloader.lbm
You can’t perform that action at this time.
0 commit comments