Skip to content

update

update #120

Workflow file for this run

name: Build
on: [ push, workflow_dispatch ]
jobs:
cmake-on-linux:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ ubuntu-20.04 ]
build_type: [ Debug, Release ]
steps:
- uses: actions/checkout@v3
- name: Install prerequisites
run: |
sudo apt install libtbb-dev
- name: Restore artifacts, or run vcpkg, build (and cache artifacts as post step)
uses: lukka/run-vcpkg@v10
id: runvcpkg
with:
vcpkgDirectory: '${{ github.workspace }}/vcpkg'
vcpkgGitCommitId: '63366443439398a62afc9a63b34b9a3ba63b1cae'
vcpkgJsonGlob: 'vcpkg.json'
appendedCacheKey: vcpkginstall
- name: Configure and build
run: |
cmake . -B build -DCMAKE_TOOLCHAIN_FILE="${{ github.workspace }}/vcpkg/scripts/buildsystems/vcpkg.cmake" -DECOS_BUILD_EXAMPLES=ON -DECOS_BUILD_TESTS=ON -DCMAKE_BUILD_TYPE=${{ matrix.build_type }}
cmake --build build
- name: Test
run: |
cd build/tests
ctest --output-on-failure
- uses: actions/upload-artifact@v3
if: matrix.build_type == 'Release'
with:
name: ecos
path: build/bin/ecos*
cmake-on-windows:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ windows-2019 ]
build_type: [ Debug, Release ]
steps:
- uses: actions/checkout@v3
- name: Restore artifacts, or run vcpkg, build (and cache artifacts as post step)
uses: lukka/run-vcpkg@v10
id: runvcpkg
with:
vcpkgDirectory: '${{ github.workspace }}/vcpkg'
vcpkgGitCommitId: '63366443439398a62afc9a63b34b9a3ba63b1cae'
vcpkgJsonGlob: 'vcpkg.json'
appendedCacheKey: vcpkginstall
- name: Configure and build
run: |
cmake . -A x64 -B build -DCMAKE_TOOLCHAIN_FILE="${{ github.workspace }}/vcpkg/scripts/buildsystems/vcpkg.cmake" -DECOS_BUILD_EXAMPLES=ON -DECOS_BUILD_TESTS=ON -DCMAKE_BUILD_TYPE=${{ matrix.build_type }}
cmake --build build --config ${{ matrix.build_type }}
- name: Test
run: |
cd build/tests
ctest -C ${{ matrix.build_type }} --output-on-failure
- uses: actions/upload-artifact@v3
if: matrix.build_type == 'Release'
with:
name: ecos
path: build/bin/ecos*