Zephyr cmake 错误`字符串子命令 REGEX,模式 MATCH 总共需要至少 5 个参数才能命令。`
Zephyr cmake error `string sub-command REGEX, mode MATCH needs at least 5 arguments total to command.`
嗨,我正在尝试 运行 getting started guide,但我遇到了问题,我目前在 zephyr 目录中,我想 运行 这个例子,所以我尝试 west build -p auto -b qemu_x86 samples/basic/blinky
但它给出了
-- west build: generating a build system
Including boilerplate (Zephyr base (cached)): /content/zephyrproject/zephyr/cmake/app/boilerplate.cmake
-- Application: /content/zephyrproject/zephyr/samples/basic/blinky
-- Zephyr version: 2.3.99 (/content/zephyrproject/zephyr)
-- Board: qemu_x86
-- Found toolchain: zephyr (/usr/zephyr-sdk-0.11.3)
-- Found west: /root/.local/bin/west (found suitable version "0.7.2", minimum required is "0.7.1")
/usr/zephyr-sdk-0.11.3/sysroots/x86_64-pokysdk-linux/usr/bin/dtc: error while loading shared libraries: libunwind.so.8: cannot open shared object file: No such file or directory
CMake Error at /content/zephyrproject/zephyr/cmake/host-tools.cmake:63 (string):
string sub-command REGEX, mode MATCH needs at least 5 arguments total to
command.
Call Stack (most recent call first):
/content/zephyrproject/zephyr/cmake/app/boilerplate.cmake:490 (include)
/content/zephyrproject/zephyr/share/zephyr-package/cmake/ZephyrConfig.cmake:24 (include)
/content/zephyrproject/zephyr/share/zephyr-package/cmake/ZephyrConfig.cmake:40 (include_boilerplate)
CMakeLists.txt:4 (find_package)
CMake Error at /content/zephyrproject/zephyr/cmake/host-tools.cmake:68 (if):
if given arguments:
"VERSION_GREATER" "1.4.6"
Unknown arguments specified
Call Stack (most recent call first):
/content/zephyrproject/zephyr/cmake/app/boilerplate.cmake:490 (include)
/content/zephyrproject/zephyr/share/zephyr-package/cmake/ZephyrConfig.cmake:24 (include)
/content/zephyrproject/zephyr/share/zephyr-package/cmake/ZephyrConfig.cmake:40 (include_boilerplate)
CMakeLists.txt:4 (find_package)
-- Configuring incomplete, errors occurred!
FATAL ERROR: command exited with status 1: /usr/local/bin/cmake -B/content/zephyrproject/zephyr/build -S/content/zephyrproject/zephyr/samples/basic/blinky -GNinja -DBOARD=qemu_x86
有人 google colab 试图重现该问题。
该错误是由过时的 DTC 版本引起的。更新或使用 SDK 安装中的那个:
ln -s <zephyr-install-dir>/sysroots/x86_64-pokysdk-linux/usr/bin/dtc ~/.local/bin/dtc
并确保您的 .local/bin 在 /usr/bin
之前位于 $PATH 中
您可以通过以下方式查看版本:
dtc --version
它应该大于 1.4.6。
Ubuntu 18.0.4 有版本 1.4.5
嗨,我正在尝试 运行 getting started guide,但我遇到了问题,我目前在 zephyr 目录中,我想 运行 这个例子,所以我尝试 west build -p auto -b qemu_x86 samples/basic/blinky
但它给出了
-- west build: generating a build system
Including boilerplate (Zephyr base (cached)): /content/zephyrproject/zephyr/cmake/app/boilerplate.cmake
-- Application: /content/zephyrproject/zephyr/samples/basic/blinky
-- Zephyr version: 2.3.99 (/content/zephyrproject/zephyr)
-- Board: qemu_x86
-- Found toolchain: zephyr (/usr/zephyr-sdk-0.11.3)
-- Found west: /root/.local/bin/west (found suitable version "0.7.2", minimum required is "0.7.1")
/usr/zephyr-sdk-0.11.3/sysroots/x86_64-pokysdk-linux/usr/bin/dtc: error while loading shared libraries: libunwind.so.8: cannot open shared object file: No such file or directory
CMake Error at /content/zephyrproject/zephyr/cmake/host-tools.cmake:63 (string):
string sub-command REGEX, mode MATCH needs at least 5 arguments total to
command.
Call Stack (most recent call first):
/content/zephyrproject/zephyr/cmake/app/boilerplate.cmake:490 (include)
/content/zephyrproject/zephyr/share/zephyr-package/cmake/ZephyrConfig.cmake:24 (include)
/content/zephyrproject/zephyr/share/zephyr-package/cmake/ZephyrConfig.cmake:40 (include_boilerplate)
CMakeLists.txt:4 (find_package)
CMake Error at /content/zephyrproject/zephyr/cmake/host-tools.cmake:68 (if):
if given arguments:
"VERSION_GREATER" "1.4.6"
Unknown arguments specified
Call Stack (most recent call first):
/content/zephyrproject/zephyr/cmake/app/boilerplate.cmake:490 (include)
/content/zephyrproject/zephyr/share/zephyr-package/cmake/ZephyrConfig.cmake:24 (include)
/content/zephyrproject/zephyr/share/zephyr-package/cmake/ZephyrConfig.cmake:40 (include_boilerplate)
CMakeLists.txt:4 (find_package)
-- Configuring incomplete, errors occurred!
FATAL ERROR: command exited with status 1: /usr/local/bin/cmake -B/content/zephyrproject/zephyr/build -S/content/zephyrproject/zephyr/samples/basic/blinky -GNinja -DBOARD=qemu_x86
有人 google colab 试图重现该问题。
该错误是由过时的 DTC 版本引起的。更新或使用 SDK 安装中的那个:
ln -s <zephyr-install-dir>/sysroots/x86_64-pokysdk-linux/usr/bin/dtc ~/.local/bin/dtc
并确保您的 .local/bin 在 /usr/bin
之前位于 $PATH 中您可以通过以下方式查看版本:
dtc --version
它应该大于 1.4.6。
Ubuntu 18.0.4 有版本 1.4.5