-
Notifications
You must be signed in to change notification settings - Fork 7
Expand file tree
/
Copy pathjustfile
More file actions
53 lines (41 loc) · 1.29 KB
/
Copy pathjustfile
File metadata and controls
53 lines (41 loc) · 1.29 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
bump level:
cargo release version --no-confirm -x {{level}}
book:
mdbook serve
update-readme:
#!/usr/bin/env ruby
readme = File.read "README.template.md"
tracexec = "cargo run -- "
helps = {
:general => `#{tracexec} --help`,
:tui => `#{tracexec} tui --help`,
:log => `#{tracexec} log --help`,
:collect => `#{tracexec} collect --help`,
:ebpf => `#{tracexec} ebpf --help`
}
File.write("README.md", readme % helps)
test-normal:
cargo test --workspace
test-root:
#!/usr/bin/env bash
set -euo pipefail
triple="$(rustc -vV | sed -n 's/^host: //p' | tr '[:lower:]-' '[:upper:]_')"
export "CARGO_TARGET_${triple}_RUNNER=sudo -E"
cargo test --workspace -- --ignored
test-all: test-normal test-root
arch-family := if arch() == "x86_64" {
"x86"
} else if arch() == "aarch64" {
"arm64"
} else if arch() == "riscv64" {
"riscv"
} else {
error("Unsupported architecture")
}
bpf-disasm debug:
clang -I crates/tracexec-backend-ebpf/include \
-D TRACEXEC_TARGET_{{uppercase(arch())}} -DMAX_CPUS=64 {{ if debug == "debug" { "-DEBPF_DEBUG" } else { "" } }} \
-I crates/tracexec-backend-ebpf/src/bpf/src -fno-stack-protector \
-D__TARGET_ARCH_{{arch-family}} -g -O2 -target bpf \
crates/tracexec-backend-ebpf/src/bpf/tracexec_system.bpf.c \
-S -o /dev/stdout