forked from black-parrot-sdk/black-parrot-sdk
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.gitlab-ci.yml
172 lines (154 loc) · 3.11 KB
/
.gitlab-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
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
variables:
GIT_STRATEGY: fetch
GIT_SUBMODULE_STRATEGY: recursive
GIT_SUBMODULE_UPDATE_FLAGS: --jobs ${CI_NUM_CORES}
stages:
- checkout
- tools
- linker
- perch
- prog
- zip
- publish
.job_template: &job_definition
only:
- pushes
artifacts:
when: always
paths:
- "*.log"
- include/
- lib/
- linker/
- install/
- prog/
- bedrock/
expire_in: "1 day"
checkout:
<<: *job_definition
stage: checkout
script:
- make bleach_all
- make checkout -j ${CI_NUM_CORES} | tee checkout.log
build_bedrock:
<<: *job_definition
stage: tools
script:
- make bedrock -j1 | tee bedrock.log
dependencies:
- checkout
build_dromajo:
<<: *job_definition
stage: tools
script:
- make dromajo -j ${CI_NUM_CORES} | tee dromajo.log
dependencies:
- checkout
build_gnu:
<<: *job_definition
stage: tools
script:
- make gnudramfs -j ${CI_NUM_CORES} | tee gnudramfs.log
- make gnulinux -j ${CI_NUM_CORES} | tee gnulinux.log
dependencies:
- checkout
build_linker:
<<: *job_definition
stage: linker
script:
- make linker -j1 | tee linker.log
dependencies:
- build_bedrock
- build_dromajo
- build_gnu
build_perch:
<<: *job_definition
stage: perch
script:
- make perch -j1 | tee perch.log
dependencies:
- build_linker
build_bootrom:
<<: *job_definition
stage: prog
script:
- make bootrom -j1 | tee bootrom.log
dependencies:
- build_perch
build_bp-demos:
<<: *job_definition
stage: prog
script:
- make bp-demos -j1 | tee bp-demos.log
dependencies:
- build_perch
build_bp-tests:
<<: *job_definition
stage: prog
script:
- make bp-tests -j1 | tee bp-tests.log
dependencies:
- build_perch
build_riscv-tests:
<<: *job_definition
stage: prog
script:
- make riscv-tests -j1 | tee riscv-tests.log
dependencies:
- build_perch
build_coremark:
<<: *job_definition
stage: prog
script:
- make coremark -j1 | tee coremark.log
dependencies:
- build_perch
build_beebs:
<<: *job_definition
stage: prog
script:
- make beebs -j1 | tee beebs.log
dependencies:
- build_perch
zip_tools:
stage: zip
script:
- tar -czvf tools.tar.gz install/ | tee zip_tools.log
artifacts:
when: on_success
paths:
- "*.log"
- tools.tar.gz
expire_in: "1 day"
dependencies:
- build_bedrock
- build_dromajo
- build_gnu
zip_prog:
stage: zip
script:
- tar -czvf prog.tar.gz prog/ linker/ bedrock/ | tee zip_prog.log
artifacts:
when: on_success
paths:
- "*.log"
- prog.tar.gz
dependencies:
- build_perch
- build_linker
- build_bootrom
- build_bp-demos
- build_bp-tests
- build_riscv-tests
- build_coremark
- build_beebs
publish_tag:
stage: publish
when: manual
script:
- gh config set prompt disabled
- if [ "$CI_RELEASE_TAG" == "" ]; then echo "Please set CI_RELEASE_TAG"; exit 1; fi
- gh release create ${CI_RELEASE_TAG} tools.tar.gz prog.tar.gz --repo black-parrot-sdk/black-parrot-sdk
dependencies:
- zip_tools
- zip_prog