Add "cargo:rerun-if-changed=build.rs" to some build.rs files.
Add "cargo:rerun-if-changed=build.rs" in some build.rs files to tell cargo that it doesn't need to scan the whole package. See the [Cargo docs] for more info. [Cargo docs]: https://doc.rust-lang.org/cargo/reference/build-scripts.html#rerun-if-changed
This commit is contained in:
@@ -3,4 +3,5 @@ fn main() {
|
||||
"cargo:rustc-env=TARGET={}",
|
||||
std::env::var("TARGET").unwrap()
|
||||
);
|
||||
println!("cargo:rerun-if-changed=build.rs");
|
||||
}
|
||||
|
||||
@@ -7,4 +7,6 @@ fn main() {
|
||||
println!("cargo:wasi={}", wasi.display());
|
||||
// and available to our own crate as WASI_ROOT:
|
||||
println!("cargo:rustc-env=WASI_ROOT={}", wasi.display());
|
||||
// and this build.rs script doesn't depend on any files.
|
||||
println!("cargo:rerun-if-changed=build.rs");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user