aboutsummaryrefslogtreecommitdiffhomepage
path: root/externals/biscuit/.github/workflows/build-and-test.yml
blob: 3fa8c40fe66d728a5e50411148a29f5f9110e11d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
name: Build and Test

on: [push, pull_request]

env:
  BUILD_TYPE: Release

jobs:
  build:
    strategy:
      matrix:
        os: [ubuntu-latest, macos-latest]
        cpu_detection: [0, 1]
      fail-fast: false

    runs-on: ${{matrix.os}}

    steps:

    - name: Install build dependencies
      if: ${{matrix.os == 'ubuntu-latest'}}
      run: sudo apt-get install llvm ninja-build

    - name: Install build dependencies
      if: ${{matrix.os == 'macos-latest'}}
      run: |
        brew install llvm ninja
        echo "/usr/local/opt/llvm/bin" >> $GITHUB_PATH

    - name: Checkout biscuit repo
      uses: actions/checkout@v2

    - name: Configure CMake
      run: >
        cmake 
        -B ${{github.workspace}}/build
        -G Ninja

    - name: Build
      working-directory: ${{github.workspace}}/build
      run: ninja

    - name: Test
      working-directory: ${{github.workspace}}/build
      run: ctest --extra-verbose -C ${{env.BUILD_TYPE}}