-
Notifications
You must be signed in to change notification settings - Fork 1.1k
137 lines (115 loc) · 3.45 KB
/
CI.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
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
# CI jobs
name: CI
# Controls when the action will run. Triggers the workflow on push or pull request
# events but only for the master branch
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
schedule:
# Weekly build to make sure dependencies are OK
- cron: '30 16 * * 1'
permissions:
contents: read
jobs:
read_targets_from_file:
uses: bitcraze/workflows/.github/workflows/read_build_targets.yml@dfbc8c23a8ec6d4925d01deb20277839ad1235f1
with:
target_file: './build_targets.json'
basic_build:
needs: read_targets_from_file
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
${{fromJson(needs.read_targets_from_file.outputs.platforms)}}
steps:
- name: Checkout Repo
uses: actions/checkout@v3
with:
submodules: true
- name: build
run: docker run --rm -v ${PWD}:/module bitcraze/builder bash -c "make ${{ matrix.platform }}_defconfig && ./tools/build/build UNIT_TEST_STYLE=min"
- name: Upload Build Artifact
uses: actions/upload-artifact@v3
with:
name: ${{ matrix.platform }}-${{ github.sha }}
path: |
${{ matrix.platform }}.bin
${{ matrix.platform }}.elf
features:
runs-on: ubuntu-latest
needs: basic_build
strategy:
fail-fast: false
matrix:
features:
# Build cf2 with bosch sensors
- bosch.conf
# Build cf2 with TDMA
- loco_tdma.conf
# Build cf2 with TDOA2 positioning mode
- loco_tdoa2.conf
#- LPS_TDOA_ENABLE=1
# Build cf2 with TDOA3 positioning mode
- loco_tdoa3.conf
#- LPS_TDOA3_ENABLE=1
# Build cf2 with TDOA3 and all config options
- loco_tdoa3_all.conf
# Build Bigquad deck with all config options
- bigquad.conf
# Build API test app layer app
- app_api.conf
env:
CONF: ${{ matrix.features }}
steps:
- name: Checkout Repo
uses: actions/checkout@v3
with:
submodules: true
- name: build
run: docker run --rm -v ${PWD}:/module bitcraze/builder bash -c "./scripts/kconfig/merge_config.sh configs/${CONF} configs/defconfig && ./tools/build/build UNIT_TEST_STYLE=min"
apps:
runs-on: ubuntu-latest
needs: basic_build
strategy:
fail-fast: false
matrix:
example:
- examples/app_hello_world
- examples/app_hello_world-cpp
- examples/app_hello_file_tree
- examples/app_peer_to_peer
- examples/app_p2p_DTR
- examples/demos/app_push_demo
- examples/demos/swarm_demo
- examples/demos/app_wall_following_demo
env:
EXAMPLE: ${{ matrix.example }}
steps:
- name: Checkout Repo
uses: actions/checkout@v3
with:
submodules: true
- name: build
run: docker run --rm -v ${PWD}:/module bitcraze/builder bash -c "./tools/build/make_app ${EXAMPLE}"
kbuild-targets:
runs-on: ubuntu-latest
needs: basic_build
strategy:
fail-fast: false
matrix:
target:
- allyesconfig
- allnoconfig
- randconfig
env:
TARGET: ${{ matrix.target }}
steps:
- name: Checkout Repo
uses: actions/checkout@v3
with:
submodules: true
- name: build
run: docker run --rm -v ${PWD}:/module bitcraze/builder bash -c "KCONFIG_ALLCONFIG=configs/all.config make ${TARGET} && ./tools/build/build UNIT_TEST_STYLE=min"