File tree Expand file tree Collapse file tree 2 files changed +6
-13
lines changed Expand file tree Collapse file tree 2 files changed +6
-13
lines changed Original file line number Diff line number Diff line change 11
11
1 . bpf-linker: ` cargo install bpf-linker ` (` --no-default-features ` on macOS)
12
12
13
13
14
- ## Build & Run
15
-
16
- Use ` cargo build ` , ` cargo check ` , etc. as normal. Run your program with ` xtask run ` .
17
-
18
- Cargo build scripts are used to automatically build the eBPF correctly and include it in the
19
- program. When not using ` xtask run ` , eBPF code generation is skipped for a faster developer
20
- experience; this compromise necessitates the use of ` xtask ` to actually build the eBPF.
21
-
22
- Compiling project:
14
+ ## Build
23
15
24
16
``` shell
25
17
$ AYA_BUILD_EBPF=true cargo build --release
@@ -44,16 +36,16 @@ AYA_BUILD_EBPF=true CC=${ARCH}-linux-musl-gcc cargo build --package rust-memleak
44
36
The cross-compiled program ` target/${ARCH}-unknown-linux-musl/release/rust-memleak ` can be
45
37
copied to a Linux server or VM and run there.
46
38
47
- ## Notice
48
39
49
- 1 . ` aya v0.13.0 ` requires rustc 1.80.0 or newer.
40
+ ## Notice
50
41
51
- 2 . The target Rust application needs to enable stack frame compilation:
42
+ The target Rust application needs to enable stack frame compilation:
52
43
53
44
```
54
45
$ RUSTFLAGS="-C force-frame-pointers=yes" cargo build
55
46
```
56
47
48
+
57
49
## Usage
58
50
59
51
``` shell
@@ -68,6 +60,7 @@ Options:
68
60
-h, --help Print help
69
61
```
70
62
63
+
71
64
### Example:
72
65
73
66
``` shell
@@ -82,7 +75,7 @@ Generating flame graphs:
82
75
83
76
Flame graph:
84
77
85
- ![ flamegraph] ( img /1.svg)
78
+ ![ flamegraph] ( images /1.svg)
86
79
87
80
88
81
## Reference
File renamed without changes.
You can’t perform that action at this time.
0 commit comments