fix: change vcpkg triplet for Windows from debug to static release in… #39
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: Build and Test (Linux/macOS/Windows) | |
on: | |
push: | |
branches: [ "main" ] | |
pull_request: | |
branches: [ "main" ] | |
workflow_dispatch: | |
jobs: | |
multi-platform-build: | |
runs-on: ${{matrix.config.os}} | |
strategy: | |
matrix: | |
config: | |
- os: ubuntu-latest | |
vcpkg_triplet: x64-linux-release | |
- os: macos-latest | |
vcpkg_triplet: arm64-osx-release | |
- os: windows-latest | |
vcpkg_triplet: x64-windows-static-release | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Install gnuplot (Linux) | |
run: | | |
sudo apt install gnuplot | |
if: matrix.os == 'ubuntu-latest' | |
- name: Install gnuplot (Windows) | |
run: | | |
choco install gnuplot | |
if: matrix.os == 'windows-latest' | |
- name: Install gnuplot (macOS) | |
run: | | |
brew install gnuplot | |
if: matrix.os == 'macos-latest' | |
- name: vcpkg build | |
uses: johnwason/vcpkg-action@v6 | |
id: vcpkg | |
with: | |
pkgs: catch2 | |
triplet: ${{ matrix.config.vcpkg_triplet }} | |
cache-key: ${{ matrix.config.os }} | |
revision: master | |
token: ${{ github.token }} | |
github-binarycache: true | |
- name: Configure with CMake | |
run: | | |
cmake ${{ steps.vcpkg.outputs.vcpkg-cmake-config }} -S ${{ github.workspace }} -B build | |
- name: Build | |
run: cmake --build build | |
- name: Test (Linux and macOS) | |
working-directory: ${{github.workspace}}/build | |
run: ctest --output-on-failure | |
if: matrix.os == 'ubuntu-latest' || matrix.os == 'macos-latest' | |
- name: Test (Windows) | |
working-directory: ${{github.workspace}}/build | |
run: ctest --output-on-failure | |
env: | |
G3P_GNUPLOT_PATH: "C:/Program Files/gnuplot/bin/gnuplot.exe" | |
if: matrix.os == 'windows-latest' |