Skip to content

Commit

Permalink
Fixed continously building build.rs
Browse files Browse the repository at this point in the history
  • Loading branch information
syrusakbary committed Jun 25, 2020
1 parent c473985 commit b4e15ff
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 2 deletions.
10 changes: 10 additions & 0 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@ members = [

[build-dependencies]
test-generator = { path = "tests/lib/test-generator" }
build-deps = "0.1.4"
anyhow = "1.0"
glob = "0.3"
rustc_version = "0.2"
Expand Down
8 changes: 6 additions & 2 deletions build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,12 @@ use test_generator::{

fn main() -> anyhow::Result<()> {
println!("cargo:rerun-if-changed=tests/ignores.txt");
println!("cargo:rerun-if-changed=tests/wasi-wast/wasi/unstable/*");
println!("cargo:rerun-if-changed=tests/wasi-wast/wasi/snapshot1/*");
// As rerun-if-changed doesn't support globs, we use another crate
// to check changes in directories.
build_deps::rerun_if_changed_paths("tests/wasi-wast/wasi/unstable/*")
.expect("Can't get directory");
build_deps::rerun_if_changed_paths("tests/wasi-wast/wasi/snapshot1/*")
.expect("Can't get directory");

let out_dir = PathBuf::from(
env::var_os("OUT_DIR").expect("The OUT_DIR environment variable must be set"),
Expand Down

0 comments on commit b4e15ff

Please sign in to comment.