Skip to content

Commit

Permalink
Add back bpf/.cargo/config.toml
Browse files Browse the repository at this point in the history
So to build/check things using the bpf target one can:

    cd bpf && cargo check && cargo build

without having to manually pass --target=bpfel-unknown-none -Z
build-std=core.

It also fixes cargo xtask docs, since the command relies on bpf docs
being built with the bpfel-unknown-none target.
  • Loading branch information
alessandrod committed Jul 13, 2023
1 parent 242d8c3 commit c64d8e2
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions bpf/.cargo/config.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# We have this so that one doesn't need to manually pass
# --target=bpfel-unknown-none -Z build-std=core when running cargo
# check/build/doc etc.
#
# NB: this file gets loaded only if you run cargo from this directory, it's
# ignored if you run from the workspace root. See
# https://doc.rust-lang.org/cargo/reference/config.html#hierarchical-structure
#
# NB-2: cargo xtask docs currently relies on this file existing.
[build]
target = "bpfel-unknown-none"

[unstable]
build-std = ["core"]

0 comments on commit c64d8e2

Please sign in to comment.