-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathMakefile
More file actions
76 lines (52 loc) · 2.53 KB
/
Copy pathMakefile
File metadata and controls
76 lines (52 loc) · 2.53 KB
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
.PHONY: all rust cpp zig go clean test bench
# ─── FLOWLAB unified build ─────────────────────────────────────────
all: rust cpp zig go
# ─── Rust ──────────────────────────────────────────────────────────
rust:
cargo build --release
rust-debug:
cargo build
test-rust:
cargo test --workspace
# ─── C++ Hotpath ───────────────────────────────────────────────────
cpp:
cmake -S hotpath -B hotpath/build -DCMAKE_BUILD_TYPE=Release
cmake --build hotpath/build
cpp-debug:
cmake -S hotpath -B hotpath/build -DCMAKE_BUILD_TYPE=Debug
cmake --build hotpath/build
# ─── Zig Feed Parser ──────────────────────────────────────────────
zig:
cd feed-parser && zig build -Doptimize=ReleaseFast
zig-debug:
cd feed-parser && zig build
test-zig:
cd feed-parser && zig build test
# ─── Go Services ──────────────────────────────────────────────────
go:
cd ingest && go build -o ../target/flowlab-ingest ./cmd/ingest
cd api && go build -o ../target/flowlab-api ./cmd/api
test-go:
cd ingest && go test ./...
cd api && go test ./...
# ─── Test All ─────────────────────────────────────────────────────
test: test-rust test-zig test-go
# ─── Benchmarks ───────────────────────────────────────────────────
bench:
cargo bench
bench-replay:
cargo bench --bench replay
# ─── Clean ────────────────────────────────────────────────────────
ifeq ($(OS),Windows_NT)
RM_RF = powershell -NoProfile -Command "Remove-Item -Recurse -Force"
RM_F = powershell -NoProfile -Command "Remove-Item -Force -ErrorAction SilentlyContinue"
else
RM_RF = rm -rf
RM_F = rm -f
endif
clean:
cargo clean
-$(RM_RF) hotpath/build
-$(RM_RF) feed-parser/zig-out
-$(RM_RF) feed-parser/zig-cache
-$(RM_F) target/flowlab-ingest target/flowlab-api