IAR Arm Toolchain
Download and install a release v9.70 or newer of IAR Arm Toolchain on your host (IAR Embedded Workbench or IAR Build Tools, perpetual or subscription licensing)
Make sure you have Zephyr SDK installed on your host.
Set these environment variables:
Set
ZEPHYR_TOOLCHAIN_VARIANTtoiar.Set
IAR_TOOLCHAIN_PATHto the toolchain installation directory.
The cloud licensed variant of the IAR Toolchain needs the
IAR_LMS_BEARER_TOKENenvironment variable to be set to a validlicense bearer token(subscription licensing).
For example:
# Linux (default installation path):
export IAR_TOOLCHAIN_PATH=/opt/iar/cxarm-<version>/arm
export ZEPHYR_TOOLCHAIN_VARIANT=iar
export IAR_LMS_BEARER_TOKEN="<BEARER-TOKEN>"
# Windows:
set IAR_TOOLCHAIN_PATH=c:\<path>\cxarm-<version>\arm
set ZEPHYR_TOOLCHAIN_VARIANT=iar
set IAR_LMS_BEARER_TOKEN="<BEARER-TOKEN>"
Note
Known limitations:
The IAR Toolchain uses
ilinkfor linking and depends on Zephyr’s CMAKE_LINKER_GENERATOR.ilinkis incompatible with Zephyr’s linker script template, which works with GNU ld.The GNU Assembler distributed with the Zephyr SDK is used for
.S-files.C library support for
Minimal libconly. C++ is not supported.Some Zephyr subsystems or modules may contain C or assembly code that relies on GNU intrinsics and have not yet been updated to work fully with
iar.TrustedFirmware is not supported