name = "compiler_builtins"
version = "0.0.0"
dependencies = [
+ "build_helper 0.1.0",
"core 0.0.0",
"gcc 0.3.43 (registry+https://github.com/rust-lang/crates.io-index)",
]
use build_helper::{run, rerun_if_changed_anything_in_dir, up_to_date};
fn main() {
- println!("cargo:rerun-if-changed=build.rs");
-
// FIXME: This is a hack to support building targets that don't
// support jemalloc alongside hosts that do. The jemalloc build is
// controlled by a feature of the std crate, and if that feature
core = { path = "../libcore" }
[build-dependencies]
+build_helper = { path = "../build_helper" }
gcc = "0.3.27"
//! error (if any) and then we just add it to the list. Overall, that cost is
//! far far less than working with compiler-rt's build system over time.
+extern crate build_helper;
extern crate gcc;
use std::collections::BTreeMap;
cfg.file(Path::new("../compiler-rt/lib/builtins").join(src));
}
+ // Can't reuse `sources` list becuse it doesn't contain header files.
+ build_helper::rerun_if_changed_anything_in_dir(Path::new("../compiler-rt"));
+
cfg.compile("libcompiler-rt.a");
}
extern crate gcc;
fn main() {
+ println!("cargo:rerun-if-changed=../rt/miniz.c");
gcc::Config::new()
.file("../rt/miniz.c")
.compile("libminiz.a");
.unwrap())
.join("../compiler-rt"));
}
-
- println!("cargo:rerun-if-changed=build.rs");
}
cfg.flag("-DLLVM_RUSTLLVM");
}
- println!("cargo:rerun-if-changed=../rustllvm/PassWrapper.cpp");
- println!("cargo:rerun-if-changed=../rustllvm/RustWrapper.cpp");
- println!("cargo:rerun-if-changed=../rustllvm/ArchiveWrapper.cpp");
+ build_helper::rerun_if_changed_anything_in_dir(Path::new("../rustllvm"));
cfg.file("../rustllvm/PassWrapper.cpp")
.file("../rustllvm/RustWrapper.cpp")
.file("../rustllvm/ArchiveWrapper.cpp")
.unwrap())
.join("../compiler-rt"));
}
-
- println!("cargo:rerun-if-changed=build.rs");
}
.unwrap())
.join("../compiler-rt"));
}
-
- println!("cargo:rerun-if-changed=build.rs");
}
.unwrap())
.join("../compiler-rt"));
}
-
- println!("cargo:rerun-if-changed=build.rs");
}
// option. This file may not be copied, modified, or distributed
// except according to those terms.
+extern crate build_helper;
extern crate gcc;
fn main() {
+ let src_dir = std::path::Path::new("../rt/hoedown/src");
+ build_helper::rerun_if_changed_anything_in_dir(src_dir);
let mut cfg = gcc::Config::new();
cfg.file("../rt/hoedown/src/autolink.c")
.file("../rt/hoedown/src/buffer.c")
.file("../rt/hoedown/src/html_smartypants.c")
.file("../rt/hoedown/src/stack.c")
.file("../rt/hoedown/src/version.c")
- .include("../rt/hoedown/src")
+ .include(src_dir)
.compile("libhoedown.a");
}
use build_helper::{run, rerun_if_changed_anything_in_dir, up_to_date};
fn main() {
- println!("cargo:rerun-if-changed=build.rs");
-
let target = env::var("TARGET").expect("TARGET was not set");
let host = env::var("HOST").expect("HOST was not set");
if cfg!(feature = "backtrace") && !target.contains("apple") && !target.contains("msvc") &&
use std::env;
fn main() {
+ println!("cargo:rerun-if-changed=build.rs");
let target = env::var("TARGET").expect("TARGET was not set");
if target.contains("linux") {