-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathTaskfile.yml
68 lines (58 loc) · 1.74 KB
/
Taskfile.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
version: '3'
vars:
NAME: fractal-generator
RELEASE_BUILD: "true"
RELEASE_PRESET: "ci-macos"
tasks:
deps:
dir: .
cmds:
- conan install . -s build_type=Debug -b missing -pr cpp23 -pr:b cpp23
- conan install . -s build_type=Release -b missing -pr cpp23 -pr:b cpp23
init:
dir: .
preconditions:
- test -f CMakeUserPresets.json
cmds:
- cmake --preset=dev
- cmake --preset={{.RELEASE_PRESET}} -DCMAKE_BUILD_TYPE=Release
build:
dir: .
vars:
CMAKE_SUFFIX: '{{if eq .RELEASE_BUILD "true"}}build --config Release{{else}}--preset=dev{{end}}'
preconditions:
- test -f CMakeUserPresets.json
cmds:
- cmake --build {{.CMAKE_SUFFIX}} -j
run:
dir: .
vars:
PATH: '{{if eq .RELEASE_BUILD "true"}}build/{{.NAME}}{{else}}build/dev/{{.NAME}}{{end}}'
cmds:
- task: build
- ./{{ .PATH }}
run-perf:
dir: .
vars:
PATH: '{{if eq .RELEASE_BUILD "true"}}build/{{.NAME}}{{else}}build/dev/{{.NAME}}{{end}}'
cmds:
- task: build
- perf record -g ./{{ .PATH }}
test:
dir: '{{if eq .RELEASE_BUILD "true"}}./build{{else}}.{{end}}'
vars:
DEV_TEST_FLAGS: '--preset=dev --timeout 1'
RELEASE_TEST_FLAGS: '--output-on-failure --no-tests=error -C Release --timeout 2'
TEST_FLAGS: '{{if eq .RELEASE_BUILD "true"}}{{.RELEASE_TEST_FLAGS}}{{else}}{{.DEV_TEST_FLAGS}}{{end}}'
cmds:
- task: build
- ctest {{.TEST_FLAGS}}
bench:
dir: .
cmds:
- task: build
- sudo chrt --fifo 99 taskset 3 ./build/benchmark/fractal_benchmarks --benchmark_repetitions=5 --benchmark_min_warmup_time=0.5 --benchmark_report_aggregates_only=true
fmt:
dir: .
cmds:
- cmake -D FIX=YES -P cmake/lint.cmake