Skip to content

Commit

Permalink
Merge branch 'main' into clippy_cast_lossless
Browse files Browse the repository at this point in the history
  • Loading branch information
Jonathan Woollett-Light authored Oct 28, 2022
2 parents 33cd99e + c5d76c7 commit 78f6458
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 10 deletions.
1 change: 0 additions & 1 deletion .cargo/config
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
[build]
target = "x86_64-unknown-linux-musl"
target-dir = "build/cargo_target"

[net]
Expand Down
1 change: 1 addition & 0 deletions docs/devctr-image.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ registry. The Firecracker CI suite must also be updated to use the new image.
you've ever built Firecracker from source.
1. Access to both an `x86_64` and `aarch64` machines to build the container
images.
1. Ensure `aws --version` is >=1.17.10.

## Steps

Expand Down
12 changes: 3 additions & 9 deletions src/vmm/build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -46,26 +46,20 @@ fn main() {
// Run seccompiler-bin, getting the default, advanced filter.
let mut bpf_out_path = PathBuf::from(&out_dir);
bpf_out_path.push(ADVANCED_BINARY_FILTER_FILE_NAME);
run_seccompiler_bin(
&target,
json_path,
bpf_out_path.to_str().expect("Invalid bytes."),
);
run_seccompiler_bin(json_path, bpf_out_path.to_str().expect("Invalid bytes."));
}

// Run seccompiler with the given arguments.
fn run_seccompiler_bin(cargo_target: &str, json_path: &str, out_path: &str) {
fn run_seccompiler_bin(json_path: &str, out_path: &str) {
let target_arch = env::var("CARGO_CFG_TARGET_ARCH").expect("Missing target arch.");

// Command for running seccompiler-bin
let mut command = Command::new("cargo");
command.args(&[
command.args([
"run",
"-p",
"seccompiler",
"--verbose",
"--target",
cargo_target,
// We need to specify a separate build directory for seccompiler-bin. Otherwise, cargo will
// deadlock waiting to acquire a lock on the build folder that the parent cargo process is
// holding.
Expand Down

0 comments on commit 78f6458

Please sign in to comment.