File tree Expand file tree Collapse file tree 2 files changed +10
-0
lines changed Expand file tree Collapse file tree 2 files changed +10
-0
lines changed Original file line number Diff line number Diff line change @@ -310,6 +310,10 @@ impl<'a> CargoProcess<'a> {
310
310
// we want to wrap rustc.
311
311
if let Some ( ( ref mut processor, ..) ) = self . processor_etc {
312
312
let profiler = processor. profiler ( self . build_kind ) . name ( ) ;
313
+ // If we're using a processor, we expect that only the crate
314
+ // we're interested in benchmarking will be built, not any
315
+ // dependencies.
316
+ cmd. env ( "EXPECT_ONLY_WRAPPED_RUSTC" , "1" ) ;
313
317
cmd. arg ( "--wrap-rustc-with" ) ;
314
318
cmd. arg ( profiler) ;
315
319
cmd. args ( & self . rustc_args ) ;
Original file line number Diff line number Diff line change @@ -215,6 +215,12 @@ fn main() {
215
215
}
216
216
}
217
217
} else {
218
+ if env:: var_os ( "EXPECT_ONLY_WRAPPED_RUSTC" ) . is_some ( ) {
219
+ eprintln ! ( "{:?} {:?}" , tool, args) ;
220
+ eprintln ! ( "exiting -- non-wrapped rustc" ) ;
221
+ std:: process:: exit ( 1 ) ;
222
+ }
223
+
218
224
let mut cmd = Command :: new ( & tool) ;
219
225
cmd. args ( & args) ;
220
226
exec ( & mut cmd) ;
You can’t perform that action at this time.
0 commit comments