@ -3,13 +3,23 @@ The tests in this directory are for the CMake Modules for the IAR Toolchains (e.
The `run-tests.sh` script will...
- build one executable for each supported language (`C`, `CXX` and `ASM`) using...
- the the default CMake build configurations (`Debug`, `Release`, `DebWithRelInfo` and `MinSizeRel`).
- the default CMake build configurations (`Debug`, `Release`, `DebWithRelInfo` and `MinSizeRel`).
## Environment
The following GNU Bash environments were used:
The script was used with the following environments providing GNU Bash:
- Cygwin (https://cygwin.com)
- IAR Embedded Workbench
- CMake for Windows
- Ninja for Windows
- MINGW64 (https://msys2.org)
- WSL2/Ubuntu 20.04 (IAR Build Tools for Linux)
- CYGWIN64 (https://cygwin.com)
- IAR Embedded Workbench
- CMake for Windows
- Ninja for Windows
- Ubuntu 20.04 (/WSL2)
- IAR Build Tools for Linux
- Cmake for Linux
- Ninja for Linux
## Environment variables
### IAR_TOOL_ROOT
@ -23,17 +33,19 @@ Export the `$IAR_TOOL_ROOT` environment variable, pointing to the top-level loca
| `/c/IAR_Systems/EW/ARM/9.30.1` | Perform tests only using "Embedded Workbench 9.30.1". |
### IAR_LMS2_SERVER_IP (optional)
Export the `IAR_LMS2_SERVER_IP` environment pointing to the license server, if the client's 1st-time license setup is required. Applies to the `-GL` and `-NW` products. (Default: not set)
Export the `IAR_LMS2_SERVER_IP` environment variable pointing to the license server, if the client's 1st-time license setup is required. Applies to the `-GL` and `-NW` products. (Default: not set)
### CMAKE_MAKE_PROGRAM (optional)
Export the `CMAKE_MAKE_PROGRAM` to specify which generator to use. (Default: `Ninja`)
Export the `CMAKE_MAKE_PROGRAM`environment variable to specify which generator to use. (Default: `Ninja`)
### MSYSTEM
This variable is automatically set by MSYS2, MINGW64 and MINGW32. CygWin users must set this environment variable manually.
This environment variable is automatically set by MSYS2, MINGW64 and MINGW32. Cygwin users must set it manually.
Example: `export MSYSTEM=CYGWIN`
## Procedure example using __MINGW64__
## Examples
### Using __MINGW64__
The example below will test every tool found in `C:\IAR_Systems\EW` using MINGW64:
```bash
export IAR_TOOL_ROOT=/c/IAR_Systems/EW
@ -44,7 +56,7 @@ cd ~/cmake-tutorial/tests
./run-tests.sh
```
## Procedure example using __Ubuntu on WSL2__
### Using __Ubuntu (/WSL2)__
The example below will test every tool found in `/opt/iarsystems` using Ubuntu (WSL2):