From 5ed5f56f0cc905ef1eacef833a74e781b396c3b2 Mon Sep 17 00:00:00 2001 From: Edouard Oger Date: Wed, 13 May 2020 09:49:28 -0400 Subject: [PATCH] Redirect probe compile errors to /dev/null --- build.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/build.rs b/build.rs index 056164d..d20b072 100644 --- a/build.rs +++ b/build.rs @@ -1,7 +1,7 @@ use std::env; use std::fs; use std::path::Path; -use std::process::{Command, ExitStatus}; +use std::process::{Command, ExitStatus, Stdio}; // This code exercises the surface area that we expect of the std Backtrace // type. If the current toolchain is able to compile it, we go ahead and use @@ -50,6 +50,7 @@ fn compile_probe() -> Option { let probefile = Path::new(&out_dir).join("probe.rs"); fs::write(&probefile, PROBE).ok()?; Command::new(rustc) + .stderr(Stdio::null()) .arg("--edition=2018") .arg("--crate-name=anyhow_build") .arg("--crate-type=lib")