mirror of https://github.com/aya-rs/aya
Feature-gate `no_std` and `no_main`
The `no_std` and `no_main` attributes are only needed when we compile the eBPF kernels for the "bpf" architecture. By feature-gating them on the target architecture, we ensure the kernels compile just fine on a host-architecture like x64. They won't be able to do anything meaningfully but it is useful within the context of the larger workspace they are embedded in as it allows `cargo build --workspace` and `cargo test --workspace` to just work.reviewable/pr1229/r2
parent
c005ad30ed
commit
267796f1f5
@ -1,3 +1,3 @@
|
||||
#![no_std]
|
||||
#![cfg_attr(target_arch = "bpf", no_std)]
|
||||
|
||||
// This file exists to enable the library target.
|
||||
|
Loading…
Reference in New Issue