Toolchain installation location

nRF Util

tags
nRF Util

The toolchain-manager has its own, dedicated installation directory for downloading and installing toolchains: toolchains. When you install a toolchain, its bundle is placed inside this toolchains directory, in a separate directory whose name is (most commonly) the SHA of the toolchain bundle.

The following command prints the information about where the toolchain bundles are installed:

nrfutil toolchain-manager config --show

The location of the toolchains directory varies depending on your operating system:

  • Windows - the toolchains directory is located by default at C:\\ncs, which can be configured to a different location.
  • Linux - the toolchains directory is located by default at $HOME/ncs, commonly written as ~/ncs, which can be configured to a different location.
  • macOS - the toolchains directory is located at /opt/nordic/ncs, and no other directory can be used. This is because of a requirement from Python and the dynamic loader to have a deterministic path for the toolchain.

    This limitation means that a fixed, absolute path must be used, which is why /opt/nordic/ncs was chosen (instead of something like $HOME/ncs). This, in turn, requires root access for creating the directory: You will be prompted to grant the program admin rights for the creation of the folder on their first install. The folder will be created with some access rights to the user, so subsequent installs do not require root access. It is not recommended to run the toolchain-manager as root (for example, using sudo), as this will cause the directory to only grant access to root, meaning subsequent installs also need root access.