forked from sogno-platform/dpsim
-
Notifications
You must be signed in to change notification settings - Fork 0
117 lines (98 loc) · 3 KB
/
build_test_linux_rocky.yaml
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
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
name: Build & Test RockyLinux
on:
push:
## Build ##
jobs:
linux-rocky:
name: Build on Rocky Linux
runs-on: ubuntu-latest
container: sogno/dpsim:dev-rocky
steps:
- name: Checkout
uses: actions/checkout@v3
with:
submodules: recursive
- name: Create Build Environment
run: mkdir build
- name: Configure CMake
shell: bash
working-directory: ${{ github.workspace }}/build
run: cmake $GITHUB_WORKSPACE -DFETCH_SPDLOG=ON
- name: Build every target
shell: bash
working-directory: ${{ github.workspace }}/build
run: cmake --build .
env:
MAKEFLAGS: "-j2"
- name: Cache build directory
uses: actions/cache@v3
with:
path: ${{ github.workspace }}/build
key: build-cache-rocky-${{ github.sha }}
linux-rocky-clang:
name: Build on Rocky Linux using Clang
runs-on: ubuntu-latest
container: sogno/dpsim:dev-rocky
steps:
- name: Checkout
uses: actions/checkout@v3
with:
submodules: recursive
- name: Create Build Environment
run: mkdir build
- name: Configure CMake
shell: bash
working-directory: ${{ github.workspace }}/build
run: cmake $GITHUB_WORKSPACE -DFETCH_SPDLOG=ON -DCMAKE_CXX_COMPILER=clang++ -DCMAKE_C_COMPILER=clang -DWITH_PYBIND=OFF
- name: Build every target
shell: bash
working-directory: ${{ github.workspace }}/build
run: cmake --build .
env:
MAKEFLAGS: "-j2"
- name: Cache build directory
uses: actions/cache@v3
with:
path: ${{ github.workspace }}/build
key: build-cache-rocky-${{ github.sha }}
profiling:
name: Build with Profiling options
runs-on: ubuntu-latest
container: sogno/dpsim:dev-rocky
steps:
- name: Checkout
uses: actions/checkout@v3
with:
submodules: recursive
- name: Create Build Environment
run: mkdir build
- name: Configure CMake
shell: bash
working-directory: ${{ github.workspace }}/build
run: cmake $GITHUB_WORKSPACE -DWITH_PROFILING=ON -DWITH_ASAN=ON -DWITH_CUDA=OFF -DFETCH_SPDLOG=ON
- name: Build every target
shell: bash
working-directory: ${{ github.workspace }}/build
run: cmake --build .
env:
MAKEFLAGS: "-j2"
- name: Cache build directory
uses: actions/cache@v3
with:
path: ${{ github.workspace }}/build
key: build-cache-rocky-profiling-${{ github.sha }}
## Tests ##
test-examples-1:
name: Test Examples 1/2
needs: [profiling]
uses: sogno-platform/dpsim/.github/workflows/run_and_profile_example.yaml@master
with:
path: ./build/dpsim/examples/cxx/WSCC_9bus_mult_decoupled
name: WSCC_9bus_mult_decoupled
test-examples-2:
name: Test Examples 2/2
needs: [profiling]
uses: sogno-platform/dpsim/.github/workflows/run_and_profile_example.yaml@master
with:
path: ./build/dpsim/examples/cxx/WSCC_9bus_mult_coupled
name: WSCC_9bus_mult_coupled