Skip to content

Commit 42bf37e

Browse files
committed
Update workflows and build scripts
1 parent 0e65378 commit 42bf37e

File tree

4 files changed

+47
-12
lines changed

4 files changed

+47
-12
lines changed

.github/workflows/core.yml

Lines changed: 23 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,9 @@ concurrency:
1414
group: ${{ github.workflow }}-${{ github.ref }}
1515
cancel-in-progress: true
1616

17+
env:
18+
IAR_VERSION: '9.40.2'
19+
1720
jobs:
1821
lit:
1922
runs-on: ubuntu-latest
@@ -36,7 +39,7 @@ jobs:
3639
- name: Cache vcpkg
3740
uses: actions/cache@v3
3841
with:
39-
key: vcpkg-${{ runner.os }}-${{ runner.arch }}-${{ github.run_id }}-${{ matrix.compiler }}
42+
key: vcpkg-${{ runner.os }}-${{ runner.arch }}-${{ github.run_id }}
4043
restore-keys: |
4144
vcpkg-${{ runner.os }}-${{ runner.arch }}-
4245
path: /home/runner/.vcpkg
@@ -54,7 +57,25 @@ jobs:
5457
. <(curl https://aka.ms/vcpkg-init.sh -L)
5558
vcpkg x-update-registry --all
5659
vcpkg activate
57-
60+
61+
- name: Cache IAR Toolchain
62+
uses: actions/cache@v3
63+
with:
64+
key: bxarm-${{env.IAR_VERSION}}-${{ runner.os }}-${{ runner.arch }}-${{ github.run_id }}
65+
restore-keys: |
66+
bxarm-${{env.IAR_VERSION}}-${{ runner.os }}-${{ runner.arch }}-
67+
path: bxarm-${{env.IAR_VERSION}}.deb
68+
69+
- name: Install IAR Toolchain
70+
run: |
71+
if [ ! -f bxarm-${{env.IAR_VERSION}}.deb ] then
72+
curl -LO http://files.iar.com/ftp/pub/box/bxarm-${{env.IAR_VERSION}}.deb
73+
fi
74+
dpkg -i bxarm-${{env.IAR_VERSION}}.deb
75+
echo "/opt/iarsystems/bxarm/arm/bin" >> "$GITHUB_PATH"
76+
echo "IAR_TOOLCHAIN_${IAR_VERSION//./_}=/opt/iarsystems/bxarm/arm/bin" >> "$GITHUB_ENV"
77+
# TODO: activate license
78+
5879
- name: Activate Arm tool license
5980
working-directory: ./CMSIS/Core/Test
6081
run: |

.github/workflows/corevalidation.yml

Lines changed: 24 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,13 +15,16 @@ concurrency:
1515
group: ${{ github.workflow }}-${{ github.ref }}
1616
cancel-in-progress: true
1717

18+
env:
19+
IAR_VERSION: '9.40.2'
20+
1821
jobs:
1922
build-and-run:
2023

2124
strategy:
2225
fail-fast: true
2326
matrix:
24-
compiler: [AC6, GCC, Clang]
27+
compiler: [AC6, GCC, Clang, IAR]
2528

2629
runs-on: ubuntu-latest
2730

@@ -78,6 +81,26 @@ jobs:
7881
vcpkg x-update-registry --all
7982
vcpkg activate
8083
84+
- name: Cache IAR Toolchain
85+
uses: actions/cache@v3
86+
if: matrix.compiler == 'IAR'
87+
with:
88+
key: bxarm-${{env.IAR_VERSION}}-${{ runner.os }}-${{ runner.arch }}-${{ github.run_id }}
89+
restore-keys: |
90+
bxarm-${{env.IAR_VERSION}}-${{ runner.os }}-${{ runner.arch }}-
91+
path: bxarm-${{env.IAR_VERSION}}.deb
92+
93+
- name: Install IAR Toolchain
94+
if: matrix.compiler == 'IAR'
95+
run: |
96+
if [ ! -f bxarm-${{env.IAR_VERSION}}.deb ] then
97+
curl -LO http://files.iar.com/ftp/pub/box/bxarm-${{env.IAR_VERSION}}.deb
98+
fi
99+
dpkg -i bxarm-${{env.IAR_VERSION}}.deb
100+
echo "/opt/iarsystems/bxarm/arm/bin" >> "$GITHUB_PATH"
101+
echo "IAR_TOOLCHAIN_${IAR_VERSION//./_}=/opt/iarsystems/bxarm/arm/bin" >> "$GITHUB_ENV"
102+
# TODO: activate license
103+
81104
- name: Activate Arm tool license
82105
working-directory: ./CMSIS/CoreValidation/Project
83106
run: |

CMSIS/Core/Test/build.py

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -73,10 +73,6 @@ def run_lit(toolchain, device, optimize, extra_args = None):
7373
extra_args = ["."]
7474
return ["lit", "--xunit-xml-output", f"lit-{toolchain}-{optimize}-{device}.xunit", "-D", f"toolchain={toolchain}", "-D", f"device={device}", "-D", f"optimize={optimize}"]+extra_args
7575

76-
# @matrix_filter
77-
# def filter_iar(config):
78-
# return config.compiler == CompilerAxis.IAR
79-
8076
@matrix_filter
8177
def filter_gcc_cm85(config):
8278
return config.compiler == CompilerAxis.GCC and config.device.match('CM85*')

CMSIS/CoreValidation/Project/build.py

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -253,11 +253,6 @@ def model_exec(config):
253253
return cmdline
254254

255255

256-
# @matrix_filter
257-
# def filter_iar(config):
258-
# return config.compiler == CompilerAxis.IAR
259-
260-
261256
@matrix_filter
262257
def filter_gcc_cm85(config):
263258
return config.compiler == CompilerAxis.GCC and config.device.match('CM85*')

0 commit comments

Comments
 (0)