aboutsummaryrefslogtreecommitdiffstats
path: root/.ci/templates/steps-build-uhd-ninja.yml
blob: 48b0a424d36fcbe51d657d4112f2890ec4eba2c8 (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
parameters:
- name: uhdSrcDir
  type: string
- name: uhdBuildDir
  type: string
- name: uhdAllowWarnings
  type: boolean
  default: false
- name: uhdCxxFlags
  type: string
  default: ""

steps:
- script: |
    mkdir -p ${{ parameters.uhdBuildDir }}
    cd ${{ parameters.uhdBuildDir }}
    if [[ "${{ parameters.uhdAllowWarnings }}" = "False" ]]; then
      echo "Warnings not allowed for this build."
      export CXXFLAGS="-Werror -Wno-error=maybe-uninitialized $CXXFLAGS"
    fi
    export CXXFLAGS="${{ parameters.uhdCxxFlags }} $CXXFLAGS"
    cmake -G Ninja ${{ parameters.uhdSrcDir }}/host
  displayName: cmake ninja UHD
- script: |
    cd ${{ parameters.uhdBuildDir }}
    ninja
  displayName: ninja UHD
- script: |
    cd ${{ parameters.uhdBuildDir }}
    ctest --no-compress-output --output-on-failure -T test
  continueOnError: true
  displayName: ctest ninja UHD