-
Notifications
You must be signed in to change notification settings - Fork 31
/
Copy pathconfig.yml
359 lines (352 loc) · 11.3 KB
/
config.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
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
version: 2.0
jobs:
ure:
docker:
- image: $CIRCLE_PROJECT_USERNAME/opencog-deps
user: root
environment:
CCACHE_DIR: /ws/ccache
working_directory: /ws/ure
steps:
- attach_workspace:
at: /ws
- run:
name: Start restoring ccache
command: date +%d-%m-%Y > /tmp/date
- restore_cache:
keys:
- ccache-{{ checksum "/tmp/date" }}
- ccache-
- run:
name: Install CogUtil
command: |
git clone --depth 1 https://github.com/$CIRCLE_PROJECT_USERNAME/cogutil /ws/cogutil
mkdir -p /ws/cogutil/build
cd /ws/cogutil/build && cmake .. && make -j2 && make -j2 install
ldconfig
- run:
name: Checkout AtomSpace
command: git clone --depth 1 https://github.com/$CIRCLE_PROJECT_USERNAME/atomspace /ws/atomspace
- restore_cache:
name: Restore GHC Cache
keys:
- ghc-{{checksum "/ws/atomspace/opencog/haskell/stack.yaml"}}-{{ arch }}
- restore_cache:
name: Restore Haskell Deps Cache
keys:
- haskelldeps-{{checksum "/ws/atomspace/opencog/haskell/stack.yaml"}}-{{checksum "/ws/atomspace/opencog/haskell/opencog-atomspace.cabal"}}-{{ arch }}
- run:
name: Install AtomSpace
command: |
mkdir -p /ws/atomspace/build
cd /ws/atomspace/build && cmake .. && make -j2 && make -j2 install
ldconfig
- save_cache:
name: Save GHC Cache
key: ghc-{{checksum "/ws/atomspace/opencog/haskell/stack.yaml"}}-{{ arch }}
paths:
- /root/.stack
- save_cache:
name: Save Haskell Deps Cache
key: haskelldeps-{{checksum "/ws/atomspace/opencog/haskell/stack.yaml"}}-{{checksum "/ws/atomspace/opencog/haskell/opencog-atomspace.cabal"}}-{{ arch }}
paths:
- /ws/atomspace/opencog/haskell/.stack-work
- run:
name: Install Unify
command: |
git clone --depth 1 https://github.com/$CIRCLE_PROJECT_USERNAME/unify /ws/unify
mkdir -p /ws/unify/build
cd /ws/unify/build && cmake .. && make -j2 && make -j2 install
ldconfig
- checkout
- run:
name: CMake Configure
command: mkdir build && cd build && cmake ..
- run:
name: Build
command: cd build && make -j2
- run:
name: Build tests
command: cd build && make -j2 tests
- run:
name: Run tests
command: cd build && make -j2 check ARGS=-j2
- run:
name: Install URE
command: cd build && make -j2 install && ldconfig
- run:
name: Print test log
command: cat build/tests/Testing/Temporary/LastTest.log
when: always
- persist_to_workspace:
root: /ws/
paths:
- cogutil
- atomspace
- unify
- ure
- ccache
miner:
docker:
- image: $CIRCLE_PROJECT_USERNAME/opencog-deps
user: root
environment:
CCACHE_DIR: /ws/ccache
working_directory: /ws/miner
steps:
- attach_workspace:
at: /ws/
- restore_cache:
name: Restore GCH Cache
keys:
- ghc-{{checksum "/ws/atomspace/opencog/haskell/stack.yaml"}}-{{ arch }}
- restore_cache:
name: Restore Haskell Deps Cache
keys:
- haskelldeps-{{checksum "/ws/atomspace/opencog/haskell/stack.yaml"}}-{{checksum "/ws/atomspace/opencog/haskell/opencog-atomspace.cabal"}}-{{ arch }}
- run:
name: Install cogutil
command: cd /ws/cogutil/build && make -j2 install && ldconfig
- run:
name: Install AtomSpace
command: cd /ws/atomspace/build && make -j2 install && ldconfig
- run:
name: Install Unify
command: cd /ws/unify/build && make -j2 install && ldconfig
- run:
name: Install URE
command: cd /ws/ure/build && make -j2 install && ldconfig
- run:
name: Checkout Miner
command: git clone --depth 1 https://github.com/$CIRCLE_PROJECT_USERNAME/miner .
- run:
name: CMake Configure
command: mkdir build && cd build && cmake ..
- run:
name: Build
command: cd build && make -j2
- run:
name: Build tests
command: cd build && make -j2 tests
- run:
name: Run tests
command: cd build && make -j2 check ARGS=-j2
- run:
name: Print test log
command: cat build/tests/Testing/Temporary/LastTest.log
when: always
- persist_to_workspace:
root: /ws/
paths:
- miner
- ccache
spacetime:
docker:
- image: $CIRCLE_PROJECT_USERNAME/opencog-deps
user: root
environment:
CCACHE_DIR: /ws/ccache
working_directory: /ws/spacetime
steps:
- attach_workspace:
at: /ws/
- run:
name: Install CogUtil
command: cd /ws/cogutil/build && make -j2 install && ldconfig
- run:
name: Install AtomSpace
command: cd /ws/atomspace/build && make -j2 install && ldconfig
- run:
name: Checkout SpaceTime
command: git clone --depth 1 https://github.com/$CIRCLE_PROJECT_USERNAME/spacetime .
- run:
name: CMake Configure
command: mkdir build && cd build && cmake ..
- run:
name: Build
command: cd build && make -j2
- run:
name: Build tests
command: cd build && make -j2 tests
- run:
name: Run tests
command: cd build && make -j2 check ARGS=-j2
- run:
name: Install spacetime
command: cd build && make -j2 install && ldconfig
- run:
name: Print test log
command: cat build/tests/Testing/Temporary/LastTest.log
when: always
- persist_to_workspace:
root: /ws/
paths:
- spacetime
# See https://github.com/opencog/cogutil/commit/da53c4079c3972904857a365a7761ac5923e4e92
# - ccache
pln:
docker:
- image: $CIRCLE_PROJECT_USERNAME/opencog-deps
user: root
environment:
CCACHE_DIR: /ws/ccache
working_directory: /ws/pln
steps:
- attach_workspace:
at: /ws/
- restore_cache:
name: Restore GCH Cache
keys:
- ghc-{{checksum "/ws/atomspace/opencog/haskell/stack.yaml"}}-{{ arch }}
- restore_cache:
name: Restore Haskell Deps Cache
keys:
- haskelldeps-{{checksum "/ws/atomspace/opencog/haskell/stack.yaml"}}-{{checksum "/ws/atomspace/opencog/haskell/opencog-atomspace.cabal"}}-{{ arch }}
- run:
name: Install cogutil
command: cd /ws/cogutil/build && make -j2 install && ldconfig
- run:
name: Install AtomSpace
command: cd /ws/atomspace/build && make -j2 install && ldconfig
- run:
name: Install Unify
command: cd /ws/unify/build && make -j2 install && ldconfig
- run:
name: Install URE
command: cd /ws/ure/build && make -j2 install && ldconfig
- run:
name: Install SpaceTime
command: cd /ws/spacetime/build && make -j2 install && ldconfig
- run:
name: Checkout PLN
command: git clone --depth 1 https://github.com/$CIRCLE_PROJECT_USERNAME/pln .
- run:
name: CMake Configure
command: mkdir build && cd build && cmake ..
- run:
name: Build
command: cd build && make -j2
- run:
name: Build tests
command: cd build && make -j2 tests
- run:
name: Install PLN
command: cd build && make -j2 install && ldconfig
- run:
name: Run tests
command: cd build && make -j2 check ARGS=-j2
- run:
name: Print test log
command: cat build/tests/Testing/Temporary/LastTest.log
when: always
- persist_to_workspace:
root: /ws/
paths:
- pln
- ccache
opencog:
docker:
- image: $CIRCLE_PROJECT_USERNAME/opencog-deps
user: root
environment:
CCACHE_DIR: /ws/ccache
working_directory: /ws/opencog
steps:
- attach_workspace:
at: /ws/
- restore_cache:
name: Restore GCH Cache
keys:
- ghc-{{checksum "/ws/atomspace/opencog/haskell/stack.yaml"}}-{{ arch }}
- restore_cache:
name: Restore Haskell Deps Cache
keys:
- haskelldeps-{{checksum "/ws/atomspace/opencog/haskell/stack.yaml"}}-{{checksum "/ws/atomspace/opencog/haskell/opencog-atomspace.cabal"}}-{{ arch }}
- run:
name: Install cogutil
command: cd /ws/cogutil/build && make -j2 install && ldconfig
- run:
name: Install AtomSpace
command: cd /ws/atomspace/build && make -j2 install && ldconfig
- run:
name: Install Unify
command: cd /ws/unify/build && make -j2 install && ldconfig
- run:
name: Install URE
command: cd /ws/ure/build && make -j2 install && ldconfig
- run:
name: Checkout LG-Atomese
command: |
git clone --depth 1 https://github.com/$CIRCLE_PROJECT_USERNAME/lg-atomese /ws/lg-atomese
mkdir -p /ws/lg-atomese/build
cd /ws/lg-atomese/build && cmake .. && make -j2 && make -j2 install
ldconfig
- run:
name: Checkout OpenCog
command: git clone --depth 1 https://github.com/$CIRCLE_PROJECT_USERNAME/opencog .
- run:
name: CMake Configure
command: mkdir build && cd build && cmake ..
- run:
name: Build
command: cd build && make -j2
- run:
name: Build tests
command: cd build && make -j2 tests
- run:
name: Run tests
command: cd build && make -j2 check ARGS=-j2
- run:
name: Install OpenCog
command: cd build && make -j2 install && ldconfig
- run:
name: Print test log
command: cat build/tests/Testing/Temporary/LastTest.log
when: always
- persist_to_workspace:
root: /ws/
paths:
- opencog
- ccache
package: #Place holder
docker:
- image: $CIRCLE_PROJECT_USERNAME/opencog-deps
user: root
working_directory: /ws/ure
steps:
- attach_workspace:
at: /ws/
- run:
name: Start storing ccache
command: date +%d-%m-%Y > /tmp/date
- save_cache:
key: ccache-{{ checksum "/tmp/date" }}
paths:
- /ws/ccache
workflows:
version: 2
build-test-package:
jobs:
- ure
- miner:
requires:
- ure
- spacetime:
requires:
# spacetime does not actually depend on ure;
# we just fake it to get it built.
# - atomspace
- ure
- pln:
requires:
- ure
- spacetime
- opencog:
requires:
- ure
- package:
requires:
- opencog
filters:
branches:
only: master