Skip to content

Commit 3a31a5f

Browse files
committed
Auto merge of #2138 - JohnTitor:rerun-if-changed, r=Amanieu
Specify `cargo:rerun-if-changed=build.rs` to avoid re-building Fixes #1978 r? `@Amanieu`
2 parents 5114daa + 45e1681 commit 3a31a5f

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

build.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,9 @@ use std::process::Command;
33
use std::str;
44

55
fn main() {
6+
// Avoid unnecessary re-building.
7+
println!("cargo:rerun-if-changed=build.rs");
8+
69
let (rustc_minor_ver, is_nightly) =
710
rustc_minor_nightly().expect("Failed to get rustc version");
811
let rustc_dep_of_std = env::var("CARGO_FEATURE_RUSTC_DEP_OF_STD").is_ok();

0 commit comments

Comments
 (0)