2023-02-06 14:16:37 -05:00
|
|
|
name: cmake_find_package
|
|
|
|
on:
|
|
|
|
push:
|
|
|
|
branches: [ main ]
|
|
|
|
pull_request:
|
|
|
|
branches: [ main ]
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
cmake-find-package:
|
|
|
|
name: Build ${{ matrix.os }}
|
|
|
|
runs-on: ${{ matrix.os }}
|
|
|
|
strategy:
|
|
|
|
matrix:
|
|
|
|
os: [ ubuntu-latest, macos-latest ]
|
|
|
|
steps:
|
2024-01-17 18:25:32 -05:00
|
|
|
- uses: actions/checkout@v4
|
2023-02-06 14:16:37 -05:00
|
|
|
- uses: lukka/get-cmake@latest
|
|
|
|
with:
|
|
|
|
cmakeVersion: 3.14.0
|
|
|
|
- name: Configure GSL
|
|
|
|
run: cmake -S . -B build -G "Ninja" -D GSL_TEST=OFF -D CMAKE_INSTALL_PREFIX=${GITHUB_WORKSPACE}/build/install
|
|
|
|
- name: Install GSL
|
|
|
|
run: cmake --build build --target install
|
|
|
|
- name: Test GSL find_package support
|
|
|
|
run: cmake -S tests/ -B build/tests_find_package -G "Ninja" -D CMAKE_PREFIX_PATH=${GITHUB_WORKSPACE}/build/install -D CMAKE_BUILD_TYPE=Release
|