rustc_llvm: use cc::Build::define

This commit is contained in:
Tamir Duberstein 2017-11-26 16:25:49 -05:00
parent 658ea389fd
commit 9067d9735a
No known key found for this signature in database
GPG Key ID: 1C1E98CC8E17BB89

View File

@ -154,13 +154,13 @@ fn main() {
}
for component in &components {
let mut flag = String::from("-DLLVM_COMPONENT_");
let mut flag = String::from("LLVM_COMPONENT_");
flag.push_str(&component.to_uppercase());
cfg.flag(&flag);
cfg.define(&flag, None);
}
if env::var_os("LLVM_RUSTLLVM").is_some() {
cfg.flag("-DLLVM_RUSTLLVM");
cfg.define("LLVM_RUSTLLVM", None);
}
build_helper::rerun_if_changed_anything_in_dir(Path::new("../rustllvm"));