From 59d0627d72cd5ac2a7c5b60132775eb7c178967a Mon Sep 17 00:00:00 2001 From: miniduikboot Date: Tue, 29 Apr 2025 23:23:57 +0200 Subject: [PATCH] Rename output of -ebpf crate This makes it possible to run `cargo doc --workspace` and get both the eBPF and normal crate and their dependencies in the output docs. Fixes: https://github.com/aya-rs/aya/issues/1260 --- {{project-name}}-ebpf/Cargo.toml | 2 +- {{project-name}}/src/main.rs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/{{project-name}}-ebpf/Cargo.toml b/{{project-name}}-ebpf/Cargo.toml index 370ea43..aec62c5 100644 --- a/{{project-name}}-ebpf/Cargo.toml +++ b/{{project-name}}-ebpf/Cargo.toml @@ -13,5 +13,5 @@ aya-log-ebpf = { workspace = true } which = { workspace = true } [[bin]] -name = "{{ project-name }}" +name = "{{ project-name }}_ebpf" path = "src/main.rs" diff --git a/{{project-name}}/src/main.rs b/{{project-name}}/src/main.rs index b558ec8..c40b800 100644 --- a/{{project-name}}/src/main.rs +++ b/{{project-name}}/src/main.rs @@ -94,7 +94,7 @@ async fn main() -> anyhow::Result<()> { // reach for `Bpf::load_file` instead. let mut ebpf = aya::Ebpf::load(aya::include_bytes_aligned!(concat!( env!("OUT_DIR"), - "/{{project-name}}" + "/{{project-name}}_ebpf" )))?; match aya_log::EbpfLogger::init(&mut ebpf) { Err(e) => {