chore: add arm64 to cmake-multi-platform workflow

This commit is contained in:
2025-06-22 13:52:32 +02:00
parent 1c41293832
commit bb6cb08f06

View File

@@ -23,19 +23,28 @@ jobs:
# #
# To add more build types (Release, Debug, RelWithDebInfo, etc.) customize the build_type list. # To add more build types (Release, Debug, RelWithDebInfo, etc.) customize the build_type list.
matrix: matrix:
os: [ubuntu-latest, windows-latest] os: [ubuntu-latest, windows-latest, ubuntu-24.04-arm, windows-11-arm]
build_type: [Release] build_type: [Release]
c_compiler: [gcc, clang, cl] c_compiler: [gcc, clang, cl]
include: include:
- os: windows-latest
c_compiler: cl
cpp_compiler: cl
- os: ubuntu-latest - os: ubuntu-latest
c_compiler: gcc c_compiler: gcc
cpp_compiler: g++ cpp_compiler: g++
- os: ubuntu-latest arch: x86_64
c_compiler: clang - os: ubuntu-24.04-arm
cpp_compiler: clang++ c_compiler: gcc
cpp_compiler: g++
arch: arm64
- os: windows-latest
c_compiler: cl
cpp_compiler: cl
arch: x86_64
vs_arch: x64
- os: windows-11-arm
c_compiler: cl
cpp_compiler: cl
arch: arm64
vs_arch: ARM64
exclude: exclude:
- os: windows-latest - os: windows-latest
c_compiler: gcc c_compiler: gcc
@@ -57,12 +66,18 @@ jobs:
- name: Configure CMake - name: Configure CMake
# Configure CMake in a 'build' subdirectory. `CMAKE_BUILD_TYPE` is only required if you are using a single-configuration generator such as make. # Configure CMake in a 'build' subdirectory. `CMAKE_BUILD_TYPE` is only required if you are using a single-configuration generator such as make.
# See https://cmake.org/cmake/help/latest/variable/CMAKE_BUILD_TYPE.html?highlight=cmake_build_type # See https://cmake.org/cmake/help/latest/variable/CMAKE_BUILD_TYPE.html?highlight=cmake_build_type
run: > run: |
cmake -B ${{ steps.strings.outputs.build-output-dir }} GEN=""
-DCMAKE_CXX_COMPILER=${{ matrix.cpp_compiler }} if [[ "${{ runner.os }}" == "Windows" ]]; then
-DCMAKE_C_COMPILER=${{ matrix.c_compiler }} GEN="-A ${{ matrix.vs_arch }}"
-DCMAKE_BUILD_TYPE=${{ matrix.build_type }} fi
-S ${{ github.workspace }}
cmake -B "${{ steps.strings.outputs.build-output-dir }}" \
-DCMAKE_CXX_COMPILER=${{ matrix.cpp_compiler }} \
-DCMAKE_C_COMPILER=${{ matrix.c_compiler }} \
-DCMAKE_BUILD_TYPE=${{ matrix.build_type }} \
$GEN \
-S "${{ github.workspace }}"
- name: Build - name: Build
# Build your program with the given configuration. Note that --config is needed because the default Windows generator is a multi-config generator (Visual Studio generator). # Build your program with the given configuration. Note that --config is needed because the default Windows generator is a multi-config generator (Visual Studio generator).