forked from acados/acados
-
Notifications
You must be signed in to change notification settings - Fork 0
95 lines (80 loc) · 3.39 KB
/
c_test_blasfeo_reference.yml
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
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
name: Test Build and C tests with BLASFEO REFERENCE
on:
push:
branches-ignore:
- 'doc*'
- 'wip*'
pull_request:
branches:
- '*'
env:
# Customize the CMake build type here (Release, Debug, RelWithDebInfo, etc.)
BUILD_TYPE: Release
ACADOS_UNIT_TESTS: ON
ACADOS_PYTHON: OFF
ACADOS_OCTAVE: OFF
ACADOS_WITH_OSQP: ON
ACADOS_WITH_QPOASES: ON
ACADOS_WITH_DAQP: ON
ACADOS_WITH_QPDUNES: ON
ACADOS_ON_CI: ON
jobs:
full_build:
# The CMake configure and build commands are platform agnostic and should work equally
# well on Windows or Mac. You can convert this to a matrix build if you need
# cross-platform coverage.
# See: https://docs.github.com/en/free-pro-team@latest/actions/learn-github-actions/managing-complex-workflows#using-a-build-matrix
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v2
with:
submodules: 'recursive'
# To get checks on Pull requests, see https://github.com/LouisBrunner/checks-action
# - uses: LouisBrunner/checks-action@v1.1.1
# if: always()
# with:
# token: ${{ secrets.GITHUB_TOKEN }}
# name: Test Full Build
# conclusion: ${{ job.status }}
# # output: |
# # {"summary":${{ steps.test.outputs.summary }}}
- name: Create Build Environment
# Some projects don't allow in-source building, so create a separate build directory
# We'll use this as our working directory for all subsequent commands
working-directory: ${{runner.workspace}}
run: cmake -E make_directory ${{runner.workspace}}/build
- name: Install Eigen (C test dependency)
working-directory: ${{runner.workspace}}/acados
shell: bash
# TODO: cache
run: ./ci/shared/install_eigen.sh
- name: Configure CMake
# Use a bash shell so we can use the same syntax for environment variable
# access regardless of the host operating system
shell: bash
working-directory: ${{runner.workspace}}/build
# Note the current convention is to use the -S and -B options here to specify source
# and build directories, but this is only available with CMake 3.13 and higher.
# The CMake binaries on the Github Actions machines are (as of this writing) 3.12
run: cmake $GITHUB_WORKSPACE -DCMAKE_BUILD_TYPE=$BUILD_TYPE -DACADOS_WITH_QPOASES=$ACADOS_WITH_QPOASES -DACADOS_WITH_DAQP=$ACADOS_WITH_DAQP -DACADOS_WITH_QPDUNES=$ACADOS_WITH_QPDUNES -DACADOS_WITH_OSQP=$ACADOS_WITH_OSQP -DACADOS_PYTHON=$ACADOS_PYTHON -DACADOS_UNIT_TESTS=$ACADOS_UNIT_TESTS -DACADOS_OCTAVE=$ACADOS_OCTAVE -DLA=REFERENCE
- name: Build & Install
working-directory: ${{runner.workspace}}/build
shell: bash
run: |
cmake --build . --config $BUILD_TYPE
make install -j4
- name: Export Paths Lib
working-directory: ${{runner.workspace}}/acados
shell: bash
run: |
echo "ACADOS_SOURCE_DIR=$(pwd)" >> $GITHUB_ENV
echo "ACADOS_INSTALL_DIR=$(pwd)" >> $GITHUB_ENV
echo "LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$(pwd)/lib" >> $GITHUB_ENV
- name: Run CMake tests (ctest)
working-directory: ${{runner.workspace}}/build
shell: bash
# Execute tests defined by the CMake configuration.
# See https://cmake.org/cmake/help/latest/manual/ctest.1.html for more detail
run: |
echo "LD_LIBRARY_PATH=$LD_LIBRARY_PATH"
./../acados/.github/linux/run_tests.sh