Skip to content

Updated README.

Updated README. #124

name: Compile Lib (Arm Cortex-M0,3,4)
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
env:
# Customize the CMake build type here (Release, Debug, RelWithDebInfo, etc.)
BUILD_TYPE: Release
jobs:
build:
strategy:
matrix:
include:
- name: "Configure CMake (Board: STM32F0DISCOVERY, CPU: Arm Cortex-M0)"
cmake_flags: -DVENDOR_STM32=ON -DTARGET_CORTEX_M0=ON -DTARGET_CPU_FAMILY=STM32F051x8
- name: "Configure CMake (Board: NUCLEOF103RB, CPU: Arm Cortex-M3)"
cmake_flags: -DVENDOR_STM32=ON -DTARGET_CORTEX_M3=ON -DTARGET_CPU_FAMILY=STM32F103xB
- name: "Configure CMake (Board: STM32F407DISC1, CPU: Arm Cortex-M4)"
cmake_flags: -DVENDOR_STM32=ON -DTARGET_CORTEX_M4=ON -DTARGET_CPU_FAMILY=STM32F407xx
# The CMake configure and build commands are platform agnostic and should work equally well on Windows or Mac.
# You can convert this to a matrix build if you need cross-platform coverage.
# See: https://docs.github.com/en/free-pro-team@latest/actions/learn-github-actions/managing-complex-workflows#using-a-build-matrix
runs-on: ubuntu-latest
steps:
- name: Install GCC arm-none-eabi
uses: carlosperate/arm-none-eabi-gcc-action@v1
- name: GCC version
run: arm-none-eabi-gcc --version
- name: Checkout
uses: actions/checkout@v3
- name: ${{matrix.name}}
run: cmake -G "Unix Makefiles" -B ${{github.workspace}}/build -DCMAKE_TOOLCHAIN_FILE=build/cmake/toolchain/arm-none-eabi-gcc.cmake -DVENDOR_STM32=ON ${{matrix.cmake_flags}} -DBUILD_LIB=ON
- name: Build
run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}} --parallel 4