-
Notifications
You must be signed in to change notification settings - Fork 1
89 lines (74 loc) · 2.63 KB
/
ubuntu.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
name: CI Pipeline [Ubuntu]
on: [push, pull_request]
env:
LIBIOTRACE_BUILD_TYPE: Release
LIBIOTRACE_BASE_PATH: '${{github.workspace}}/libiotrace'
LIBIOTRACE_BUILD_PATH: '${{github.workspace}}/libiotrace/build'
IOTRACEANALYZE_BASE_PATH: '${{github.workspace}}/IOTrace_Analyze'
jobs:
# --- libiotrace ---
libiotrace:
name: libiotrace
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
# Required for CUnit tests --> doesn't work ?
# with:
# submodules: recursive
# >> WORKAROUND <<
- name: Checkout submodules
shell: bash
run: |
cd $LIBIOTRACE_BASE_PATH
git rm --cached test/ext/cunit
rm -rf test/ext/cunit
git submodule add --force https://gitlab.com/cunity/cunit.git test/ext/cunit
# - Clean (unnecessary ??) + Build -
- name: Cleanup
shell: bash
run: rm -rf $LIBIOTRACE_BUILD_PATH
- name: Create Build Environment
shell: bash
run: cmake -E make_directory $LIBIOTRACE_BUILD_PATH
- name: Configure CMake
shell: bash
run: cmake -B $LIBIOTRACE_BUILD_PATH -S $LIBIOTRACE_BASE_PATH -DCMAKE_BUILD_TYPE=$LIBIOTRACE_BUILD_TYPE
- name: Build w/ CMake
shell: bash
run: make -C $LIBIOTRACE_BUILD_PATH -j
# - Test -
- name: Test (CUnit)
shell: bash
# Executes only tests w/ 'test_' prefix
run: make -C $LIBIOTRACE_BUILD_PATH -j test ARGS="-R '^test_'"
# >> WORKAROUND <<: Not feasible w/ cmake (see 'libiotrace/test/cunit/CMakeLists.txt')
env:
CTEST_OUTPUT_ON_FAILURE: 1
# # - Release -
# - uses: marvinpinto/action-automatic-releases@latest
# with:
# repo_token: "${{secrets.GITHUB_TOKEN}}"
# prerelease: true
# automatic_release_tag: "latest"
# title: "libiotrace-#${{github.run_number}}"
# files: |
# ${{env.LIBIOTRACE_BUILD_PATH}}/src/libiotrace_control.so
# ${{env.LIBIOTRACE_BUILD_PATH}}/src/libiotrace.so
# ${{env.LIBIOTRACE_BUILD_PATH}}/src/libiotrace.a
# ${{env.LIBIOTRACE_BASE_PATH}}/include/libiotrace.h
# name: Create Release
# --- IOTrace_Analyze ---
iotraceanalyze:
name: IOTrace_Analyze
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Set up JDK 11
uses: actions/setup-java@v2
with:
java-version: '11'
distribution: 'adopt'
# - Build + Test -
- name: Build + Test w/ Maven
shell: bash
run: mvn -f $IOTRACEANALYZE_BASE_PATH --batch-mode --update-snapshots verify