Skip to content

feat: refactor and expand StUartProgrammer #707

feat: refactor and expand StUartProgrammer

feat: refactor and expand StUartProgrammer #707

Workflow file for this run

---
name: Continuous Integration
on:
push:
branches: [main]
pull_request:
types: [opened, synchronize, reopened]
permissions:
contents: read
jobs:
host_build_test_ubuntu:
name: Host Build & Test (ubuntu-latest)
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.0.0
with:
persist-credentials: false
- uses: hendrikmuhs/ccache-action@6d1841ec156c39a52b1b23a810da917ab98da1f4 # v1.2.10
with:
key: ${{ github.job }}-ubuntu-latest
variant: sccache
- uses: seanmiddleditch/gha-setup-ninja@8b297075da4cd2a5f1fd21fe011b499edf06e9d2 # v4
- uses: lukka/run-cmake@c2b72aff009141774c5a5fabe74ea46c8c04d9c4 # v10.6
with:
configurePreset: "host"
buildPreset: "host-Debug" #-WithPackage"
#testPreset: "host"
configurePresetAdditionalArgs: "['-DCMAKE_C_COMPILER_LAUNCHER=sccache', '-DCMAKE_CXX_COMPILER_LAUNCHER=sccache']"
#- uses: actions/upload-artifact@0b7f8abb1508181956e8e162db84b466c27e18ce # v3.1.2
# with:
# name: halst
# path: build/host/halst-*-Linux.tar.gz
# if-no-files-found: error
#- name: Upload test logs
# if: ${{ failure() }}
# uses: actions/upload-artifact@0b7f8abb1508181956e8e162db84b466c27e18ce # v3.1.2
# with:
# name: test-logs
# path: build/host/Testing/Temporary/
host_build_test:
name: Host Build & Test
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [windows-latest, windows-2019, macos-latest]
steps:
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.0.0
with:
persist-credentials: false
- uses: hendrikmuhs/ccache-action@6d1841ec156c39a52b1b23a810da917ab98da1f4 # v1.2.10
with:
key: ${{ github.job }}-${{ matrix.os }}
variant: sccache
- uses: lukka/run-cmake@c2b72aff009141774c5a5fabe74ea46c8c04d9c4 # v10.6
with:
configurePreset: "host-single-Debug"
buildPreset: "host-single-Debug"
#testPreset: "host-single-Debug"
configurePresetAdditionalArgs: "['-DCMAKE_C_COMPILER_LAUNCHER=sccache', '-DCMAKE_CXX_COMPILER_LAUNCHER=sccache']"
#- name: Upload test logs
# if: ${{ failure() }}
# uses: actions/upload-artifact@0b7f8abb1508181956e8e162db84b466c27e18ce # v3.1.2
# with:
# name: test-logs
# path: build/host/Testing/Temporary/
embedded_build:
name: Embedded Build
runs-on: ubuntu-latest
strategy:
matrix:
configuration: ["RelWithDebInfo"]
gcc: [ "10.3-2021.10" ]
target: ["stm32wb55", "stm32g070", "stm32g431", "stm32f407", "stm32f429", "stm32f746", "stm32f767"]
include:
- gcc: "7-2018-q2"
configuration: "RelWithDebInfo"
target: "stm32f767"
- gcc: "8-2019-q3"
configuration: "RelWithDebInfo"
target: "stm32f767"
- gcc: "9-2020-q2"
configuration: "RelWithDebInfo"
target: "stm32f767"
steps:
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
- name: Install GNU Arm Embedded Toolchain ${{ matrix.gcc }}
uses: carlosperate/arm-none-eabi-gcc-action@e9cd61b92edb079b14b2d0449b21f8a517121fe8 # v1.8.0
with:
release: ${{ matrix.gcc }}
- uses: hendrikmuhs/ccache-action@6d1841ec156c39a52b1b23a810da917ab98da1f4 # v1.2.10
with:
key: ${{ matrix.gcc }}-${{ matrix.configuration }}-${{ matrix.target }}
- run: |
sudo apt-get update && sudo apt-get install --no-install-recommends ninja-build xsltproc
echo "::add-matcher::.github/matchers/gcc-problem-matcher.json"
cmake --preset host -DCMAKE_CXX_COMPILER_LAUNCHER=ccache
cmake --build --preset host-${{ matrix.configuration }}
cmake --preset ${{ matrix.target }} -DCMAKE_CXX_COMPILER_LAUNCHER=ccache
cmake --build --preset ${{ matrix.target }}-${{ matrix.configuration }}