add rebuild logic to compiler-rt-cdylib

fixes #136
This commit is contained in:
Jorge Aparicio 2017-02-03 20:00:24 -05:00
parent 631b5687b2
commit c08b1692a6

View File

@ -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());
}
}