Hello,
for some time I didn't have to work on my project that uses nRF Connect SDK but recently I had to work on it again and noticed that I am not able to build my before working configurations anymore.
This is my build log:
-- west build: generating a build system Loading Zephyr default modules (Zephyr base). -- Application: <path-to-project> -- Found Python3: C:/ncs/toolchains/v2.0.2/opt/bin/python.exe (found suitable exact version "3.8.2") found components: Interpreter -- Cache files will be written to: C:/ncs/v2.0.2/zephyr/.cache -- Zephyr version: 3.0.99 (C:/ncs/v2.0.2/zephyr) -- Found west (found suitable version "0.13.1", minimum required is "0.7.1") -- Board: nrf52840dk_nrf52840 -- Found host-tools: zephyr 0.14.1 (C:/ncs/toolchains/v2.0.2/opt/zephyr-sdk) -- Found dtc: C:/ncs/toolchains/v2.0.2/opt/bin/dtc.exe (found suitable version "1.4.7", minimum required is "1.4.6") -- Found toolchain: zephyr 0.14.1 (C:/ncs/toolchains/v2.0.2/opt/zephyr-sdk) -- Found BOARD.dts: C:/ncs/v2.0.2/zephyr/boards/arm/nrf52840dk_nrf52840/nrf52840dk_nrf52840.dts -- Found devicetree overlay: <path-to-project>/configuration/nrf52840dk_nrf52840/app.overlay -- Generated zephyr.dts: <path-to-project>/build/zephyr/zephyr.dts -- Generated devicetree_unfixed.h: <path-to-project>/build/zephyr/include/generated/devicetree_unfixed.h -- Generated device_extern.h: <path-to-project>/build/zephyr/include/generated/device_extern.h -- Including generated dts.cmake file: <path-to-project>/build/zephyr/dts.cmake CMake Error at C:/ncs/v2.0.2/zephyr/cmake/modules/kconfig.cmake:226 (message): File not found: <path-to-project>/configuration/nrf52840dk_nrf52840/configuration/nrf52840dk_nrf52840/prj.conf Call Stack (most recent call first): C:/ncs/v2.0.2/zephyr/cmake/modules/zephyr_default.cmake:121 (include) C:/ncs/v2.0.2/zephyr/share/zephyr-package/cmake/ZephyrConfig.cmake:51 (include) C:/ncs/v2.0.2/zephyr/share/zephyr-package/cmake/ZephyrConfig.cmake:76 (include_boilerplate) CMakeLists.txt:22 (find_package)
And this is the build command:
west build --build-dir <path-to-project>/build <path-to-project> --pristine --board nrf52840dk_nrf52840 --cmake-only -- -DNCS_TOOLCHAIN_VERSION=NONE -DCONF_FILE=configuration/nrf52840dk_nrf52840/prj.conf -DBOARD_ROOT=<path-to-project>
The error says it doesn't find the configuration file and this is correct because it is looking in the wrong path. It is looking under <path-to-project>/configuration/nrf52840dk_nrf52840/configuration/nrf52840dk_nrf52840/prj.conf but the actual path should be just <path-to-project>/configuration/nrf52840dk_nrf52840/prj.conf.
This seems like a bug to me or am I missing something?
OS: Windows 11 24H2
VS Code: 1.102.2
nRF Connect for VS Code: 2025.5.152
Edit:
When adjusting the build command like below and run it manually it works.
west build --build-dir <path-to-project>/build <path-to-project> --pristine --board nrf52840dk_nrf52840 --cmake-only -- -DNCS_TOOLCHAIN_VERSION=NONE -DCONF_FILE=prj.conf -DBOARD_ROOT=<path-to-project>
