Build and Execution Test Ubuntu 24.04 on ARM64 #21
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Build and Execution Test Ubuntu 24.04 on ARM64 | |
| on: | |
| workflow_dispatch: | |
| pull_request: | |
| branches: [main] | |
| push: | |
| branches: [main] | |
| schedule: | |
| - cron: '0 6 * * 1' | |
| env: | |
| GIT_CURL_VERBOSE: True | |
| GIT_TRACE: True | |
| GIT_SSH_COMMAND: ssh -vvv | |
| jobs: | |
| install_build_execute: | |
| runs-on: ubuntu-24.04-arm | |
| strategy: | |
| matrix: | |
| compiler: [ | |
| {name: AC6, ext: axf}, | |
| {name: GCC, ext: elf} | |
| ] | |
| target: [ | |
| {type: CM0, model: FVP_MPS2_Cortex-M0, uart: fvp_mps2.UART0}, | |
| {type: CM0plus, model: FVP_MPS2_Cortex-M0plus, uart: fvp_mps2.UART0}, | |
| {type: CM3, model: FVP_MPS2_Cortex-M3, uart: fvp_mps2.UART0}, | |
| {type: CM4, model: FVP_MPS2_Cortex-M4, uart: fvp_mps2.UART0}, | |
| {type: CM4_FP, model: FVP_MPS2_Cortex-M4, uart: fvp_mps2.UART0}, | |
| {type: CM7, model: FVP_MPS2_Cortex-M7, uart: fvp_mps2.UART0}, | |
| {type: CM7_SP, model: FVP_MPS2_Cortex-M7, uart: fvp_mps2.UART0}, | |
| {type: CM7_DP, model: FVP_MPS2_Cortex-M7, uart: fvp_mps2.UART0}, | |
| {type: CM23, model: FVP_MPS2_Cortex-M23, uart: fvp_mps2.UART0}, | |
| {type: CM33, model: FVP_MPS2_Cortex-M33, uart: fvp_mps2.UART0}, | |
| {type: CM33_FP, model: FVP_MPS2_Cortex-M33, uart: fvp_mps2.UART0}, | |
| {type: CS300, model: FVP_Corstone_SSE-300, uart: mps3_board.uart0}, | |
| {type: CS310, model: FVP_Corstone_SSE-310, uart: mps3_board.uart0}, | |
| {type: CS315, model: FVP_Corstone_SSE-315, uart: mps4_board.uart0}, | |
| {type: CS320, model: FVP_Corstone_SSE-320, uart: mps4_board.uart0} | |
| ] | |
| build: [ | |
| {type: Release}, | |
| {type: Debug} | |
| ] | |
| steps: | |
| - name: Checkout repo | |
| uses: actions/checkout@v4 | |
| - name: Install tools | |
| uses: ARM-software/cmsis-actions/vcpkg@v1 | |
| - name: Activate Arm tool license | |
| uses: ARM-software/cmsis-actions/armlm@v1 | |
| - name: Cache packs | |
| uses: actions/cache@v4 | |
| with: | |
| key: cmsis-packs | |
| path: /home/runner/.cache/arm/packs | |
| - name: Build context Hello.${{ matrix.build.type }}+${{ matrix.target.type }} with ${{ matrix.compiler.name }} | |
| working-directory: ./ | |
| run: | | |
| cbuild Hello.csolution.yml --packs \ | |
| --context Hello.${{ matrix.build.type }}+${{ matrix.target.type }} \ | |
| --toolchain ${{ matrix.compiler.name }} --rebuild | |
| - name: Execute context Hello.${{ matrix.build.type }}+${{ matrix.target.type }} with ${{ matrix.compiler.name }} | |
| working-directory: ./ | |
| run: | | |
| ${{ matrix.target.model }} \ | |
| -a ./out/Hello/${{ matrix.target.type }}/${{ matrix.build.type }}/${{ matrix.compiler.name }}/Hello.${{ matrix.compiler.ext }} \ | |
| -f ./FVP/${{ matrix.target.model }}/fvp_config.txt \ | |
| -C ${{ matrix.target.uart }}.out_file=./out/Hello/${{ matrix.target.type }}/${{ matrix.build.type }}/${{ matrix.compiler.name }}/fvp_stdout.log \ | |
| --simlimit 60 --stat | |
| echo " Show simulation UART output" | |
| cat ./out/Hello/${{ matrix.target.type }}/${{ matrix.build.type }}/${{ matrix.compiler.name }}/fvp_stdout.log | |
| echo "Checking simulation UART output" | |
| if [ "$(grep -c "Hello World 100" ./out/Hello/${{ matrix.target.type }}/${{ matrix.build.type }}/${{ matrix.compiler.name }}/fvp_stdout.log)" -eq 1 ] | |
| then | |
| exit 0 | |
| else | |
| exit 1 | |
| fi |