diff --git a/src/bootstrap/src/core/build_steps/clippy.rs b/src/bootstrap/src/core/build_steps/clippy.rs index 190ea1752d8..21ac6c505c3 100644 --- a/src/bootstrap/src/core/build_steps/clippy.rs +++ b/src/bootstrap/src/core/build_steps/clippy.rs @@ -5,6 +5,7 @@ use crate::builder::ShouldRun; use crate::core::builder; use crate::core::builder::crate_description; use crate::core::builder::Alias; +use crate::core::builder::Kind; use crate::core::builder::RunConfig; use crate::core::builder::Step; use crate::Mode; @@ -233,7 +234,7 @@ impl Step for Rustc { macro_rules! lint_any { ($( - $name:ident, $path:expr, $tool_name:expr + $name:ident, $path:expr, $readable_name:expr $(,is_external_tool = $external:expr)* $(,is_unstable_tool = $unstable:expr)* $(,allow_features = $allow_features:expr)? @@ -276,6 +277,15 @@ macro_rules! lint_any { &[], ); + let _guard = builder.msg_tool( + Kind::Clippy, + Mode::ToolRustc, + $readable_name, + compiler.stage, + &compiler.host, + &target, + ); + run_cargo( builder, cargo, diff --git a/src/bootstrap/src/core/build_steps/tool.rs b/src/bootstrap/src/core/build_steps/tool.rs index 8d1ff2fcb24..45b1d5a05f3 100644 --- a/src/bootstrap/src/core/build_steps/tool.rs +++ b/src/bootstrap/src/core/build_steps/tool.rs @@ -36,8 +36,9 @@ struct ToolBuild { impl Builder<'_> { #[track_caller] - fn msg_tool( + pub(crate) fn msg_tool( &self, + kind: Kind, mode: Mode, tool: &str, build_stage: u32, @@ -47,7 +48,7 @@ impl Builder<'_> { match mode { // depends on compiler stage, different to host compiler Mode::ToolRustc => self.msg_sysroot_tool( - Kind::Build, + kind, build_stage, format_args!("tool {tool}"), *host, @@ -100,6 +101,7 @@ impl Step for ToolBuild { cargo.allow_features(self.allow_features); } let _guard = builder.msg_tool( + Kind::Build, self.mode, self.tool, self.compiler.stage, @@ -481,6 +483,7 @@ impl Step for Rustdoc { ); let _guard = builder.msg_tool( + Kind::Build, Mode::ToolRustc, "rustdoc", build_compiler.stage,