Zephyr was unable to find the toolchain.

-- west build: generating a build system
-- Found Python3: /home/ivob/connectedhomeip/.environment/pigweed-venv/bin/python3.10 (found version "3.10.6") found components: Interpreter 
Loading Zephyr default modules (Zephyr base).
-- Application: /home/ivob/connectedhomeip/examples/lock-app/nrfconnect
-- Found Python3: /home/ivob/connectedhomeip/.environment/pigweed-venv/bin/python3.10 (found suitable exact version "3.10.6") found components: Interpreter 
-- Cache files will be written to: /home/ivob/.cache/zephyr
-- Zephyr version: 3.2.99 (/home/ivob/tools/ncs/zephyr)
-- Found west (found suitable version "1.0.0", minimum required is "0.7.1")
-- Board: nrf52840dk_nrf52840
-- Found toolchain: gnuarmemb (/home/ivob/zephyr-sdk-0.15.2/)
CMake Error at /home/ivob/tools/ncs/zephyr/cmake/compiler/gcc/generic.cmake:9 (message):
  Zephyr was unable to find the toolchain.  Is the environment misconfigured?

  User-configuration:

  ZEPHYR_TOOLCHAIN_VARIANT: gnuarmemb

  Internal variables:

  CROSS_COMPILE: /home/ivob/zephyr-sdk-0.15.2//bin/arm-none-eabi-

  TOOLCHAIN_HOME: /home/ivob/zephyr-sdk-0.15.2/

Call Stack (most recent call first):
  /home/ivob/tools/ncs/zephyr/cmake/modules/FindHostTools.cmake:107 (include)
  /home/ivob/tools/ncs/zephyr/cmake/modules/dts.cmake:8 (find_package)
  /home/ivob/tools/ncs/zephyr/cmake/modules/zephyr_default.cmake:108 (include)
  /home/ivob/tools/ncs/zephyr/share/zephyr-package/cmake/ZephyrConfig.cmake:66 (include)
  /home/ivob/tools/ncs/zephyr/share/zephyr-package/cmake/ZephyrConfig.cmake:92 (include_boilerplate)
  CMakeLists.txt:34 (find_package)


-- Configuring incomplete, errors occurred!
FATAL ERROR: command exited with status 1: /usr/bin/cmake -DWEST_PYTHON=/home/ivob/connectedhomeip/.environment/pigweed-venv/bin/python -B/home/ivob/connectedhomeip/examples/lock-app/nrfconnect/build -GNinja -DBOARD=nrf52840dk_nrf52840 -S/home/ivob/connectedhomeip/examples/lock-app/nrfconnect

Hi,

I am following all the steps on this page: https://developer.nordicsemi.com/nRF_Connect_SDK/doc/latest/nrf/getting_started/installing.html to manually install the nRF Connect SDK on my ubuntu based laptop. The details of my system are as follows:

uname -a

Linux laptop 5.19.0-35-generic #36~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Fri Feb 17 15:17:25 UTC 2 x86_64 x86_64 x86_64 GNU/Linux

I have extracted the file zephyr-sdk-0.15.2_linux-x86_64.tar.gz to my home directory. I have run the setup script and I have set the environment variables:

export ZEPHYR_TOOLCHAIN_VARIANT=gnuarmemb

export GNUARMEMB_TOOLCHAIN_PATH=~/zephyr-sdk-0.15.2


I then try to build my target using the nrfconnect sample matter app in the connected home over ip repo: https://github.com/project-chip/connectedhomeip/blob/master/examples/lock-app/nrfconnect/README.md

I first remove the build directory as I have found that previous environment variables are set there and then I run the west build -b build_target

rm -rf build/

west build -b nrf52840dk_nrf52840

Unfortunately the build fails with the error "Zephyr was unable to find the toolchain.". I have followed the step carefully (and several times) so I suspect that the problem is because of the toolchain path that I am using.

Can someone help me and suggest the proper full path for the toolchain. Within the ~/zephyr-sdk-0.15.2 directory I have many sub directories that look to be platform specific e.g.

aarch64-zephyr-elf, arc64-zephyr-elf, arc-zephyr-elf, x86_64-zephyr-elf, etc. I have attached my directory structure

What should I use for export GNUARMEMB_TOOLCHAIN_PATH?

Many thanks

Ivo

8883.directorystructure.txt

Parents Reply Children
Related