I picked up a project that was last worked on several months ago, updated all the tools, and can't get past this:
[18:25] jwr-macbook-pro:/opt/nordic/ncs/v2.1.0/nrf/samples/peripheral/lpuart>west build -b nrf52840_mdk
-- west build: generating a build system
Loading Zephyr default modules (Zephyr base (cached)).
-- Application: /opt/nordic/ncs/v2.1.0/nrf/samples/peripheral/lpuart
-- Using NCS Toolchain 2.1.0 for building. (/opt/nordic/ncs/toolchains/v2.1.0/cmake)
-- Cache files will be written to: /Users/jwr/Library/Caches/zephyr
-- Zephyr version: 3.1.99 (/opt/nordic/ncs/v2.1.0/zephyr)
-- Found west (found suitable version "0.14.0", minimum required is "0.7.1")
-- Board: nrf52840_mdk
CMake Error at /opt/nordic/ncs/v2.1.0/zephyr/cmake/modules/verify-toolchain.cmake:84 (find_package):
Could not find a package configuration file provided by "Zephyr-sdk"
(requested version 0.13.1) with any of the following names:
Zephyr-sdkConfig.cmake
zephyr-sdk-config.cmake
Add the installation prefix of "Zephyr-sdk" to CMAKE_PREFIX_PATH or set
"Zephyr-sdk_DIR" to a directory containing one of the above files. If
"Zephyr-sdk" provides a separate development package or SDK, be sure it has
been installed.
Call Stack (most recent call first):
/opt/nordic/ncs/v2.1.0/zephyr/cmake/modules/zephyr_default.cmake:121 (include)
/opt/nordic/ncs/v2.1.0/zephyr/share/zephyr-package/cmake/ZephyrConfig.cmake:66 (include)
/opt/nordic/ncs/v2.1.0/zephyr/share/zephyr-package/cmake/ZephyrConfig.cmake:97 (include_boilerplate)
CMakeLists.txt:9 (find_package)
-- Configuring incomplete, errors occurred!
FATAL ERROR: command exited with status 1: /opt/homebrew/bin/cmake -DWEST_PYTHON=/opt/homebrew/opt/[email protected]/bin/python3.10 -B/opt/nordic/ncs/v2.1.0/nrf/samples/peripheral/lpuart/build -GNinja -S/opt/nordic/ncs/v2.1.0/nrf/samples/peripheral/lpuart
I normally use my own checkout of nRF Connect SDK, but this time I even tried using the SDK installed with the toolchain (see above), same results.
I have no idea why this started happening, I never had to point to Zephyr-sdkConfig.cmake. A file with that name does exist in /opt/nordic/ncs/toolchains/v2.1.0/opt/zephyr-sdk/cmake/Zephyr-sdkConfig.cmake, but I have no idea why west is unable to find it.
I have ZEPHYR_BASE=/opt/nordic/ncs/v2.1.0/zephyr and ZEPHYR_TOOLCHAIN_VARIANT=gnuarmemb and GNUARMEMB_TOOLCHAIN_PATH=/opt/nordic/ncs/toolchains/v2.1.0.
This is on an Apple Silicon (M1) Mac under Mac OS 12.6.
Any pointers would be appreciated, as I'm completely stuck on this unexpected problem!