From c08b1692a6c789b39d789b6202b30a141c7458db Mon Sep 17 00:00:00 2001 From: Jorge Aparicio Date: Fri, 3 Feb 2017 20:00:24 -0500 Subject: [PATCH] add rebuild logic to compiler-rt-cdylib fixes #136 --- compiler-rt/compiler-rt-cdylib/build.rs | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/compiler-rt/compiler-rt-cdylib/build.rs b/compiler-rt/compiler-rt-cdylib/build.rs index 4eb7638..a4d53cc 100644 --- a/compiler-rt/compiler-rt-cdylib/build.rs +++ b/compiler-rt/compiler-rt-cdylib/build.rs @@ -62,9 +62,16 @@ fn main() { "powisf2.c", ]); + let builtins_dir = Path::new("compiler-rt/lib/builtins"); for src in sources.files.iter() { - cfg.file(Path::new("compiler-rt/lib/builtins").join(src)); + cfg.file(builtins_dir.join(src)); } cfg.compile("libcompiler-rt.a"); + + println!("cargo:rerun-if-changed=build.rs"); + + for source in sources.files.iter() { + println!("cargo:rerun-if-changed={}", builtins_dir.join(source).display()); + } }