Add GitHub Actions CI for Windows #25
This file contains 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: CMake build | |
on: | |
push: | |
paths: | |
- '.github/**/*.yml' | |
- 'CMakeLists.txt' | |
- 'cmake/**' | |
- '**.cc' | |
- '**.h' | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.head_ref || github.ref }} | |
cancel-in-progress: true | |
jobs: | |
cmake-linux-x86_64: | |
runs-on: ubuntu-20.04 | |
timeout-minutes: 15 | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Update apt | |
run: sudo apt update | |
- name: Install ninja | |
run: sudo apt install ninja-build | |
- name: Configure | |
run: cmake -Bbuild -S. -G Ninja -DCMAKE_BUILD_TYPE=Release -DFP16_BUILD_COMPARATIVE_BENCHMARKS=ON | |
- name: Build | |
run: cmake --build build --parallel | |
- name: Test | |
run: ctest --test-dir build --parallel | |
cmake-macos-x86_64: | |
runs-on: macos-12 | |
timeout-minutes: 15 | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Configure | |
run: cmake -Bbuild -S. -G Xcode -DCMAKE_OSX_ARCHITECTURES=x86_64 -DCMAKE_CONFIGURATION_TYPES=Release -DHAVE_STD_REGEX=TRUE -DFP16_BUILD_COMPARATIVE_BENCHMARKS=ON | |
- name: Build | |
run: cmake --build build --config Release --parallel -- -quiet | |
- name: Test | |
run: ctest --test-dir build --parallel | |
cmake-macos-arm64: | |
runs-on: macos-14 | |
timeout-minutes: 15 | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Configure | |
run: cmake -Bbuild -S. -G Xcode -DCMAKE_OSX_ARCHITECTURES=arm64 -DCMAKE_CONFIGURATION_TYPES=Release -DHAVE_STD_REGEX=TRUE -DFP16_BUILD_COMPARATIVE_BENCHMARKS=ON | |
- name: Build | |
run: cmake --build build --config Release --parallel -- -quiet | |
- name: Test | |
run: ctest --test-dir build --parallel | |
cmake-windows-x86: | |
runs-on: windows-2019 | |
timeout-minutes: 15 | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Configure | |
run: cmake -Bbuild -S. -G "Visual Studio 16 2019" -A Win32 -DFP16_BUILD_COMPARATIVE_BENCHMARKS=ON | |
- name: Build | |
run: cmake --build build --parallel --config Release | |
- name: Test | |
run: ctest --test-dir build --parallel | |
cmake-windows-x64: | |
runs-on: windows-2019 | |
timeout-minutes: 15 | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Configure | |
run: cmake -Bbuild -S. -G "Visual Studio 16 2019" -A x64 -DFP16_BUILD_COMPARATIVE_BENCHMARKS=ON | |
- name: Build | |
run: cmake --build build --parallel --config Release | |
- name: Test | |
run: ctest --test-dir build --parallel | |
cmake-windows-arm64: | |
runs-on: windows-2019 | |
timeout-minutes: 15 | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Configure | |
run: cmake -Bbuild -S. -G "Visual Studio 16 2019" -A ARM64 -DFP16_BUILD_COMPARATIVE_BENCHMARKS=ON | |
- name: Build | |
run: cmake --build build --parallel --config Release |