Allow static linking LLVM with ThinLTO
This commit is contained in:
parent
f06f9bbd3a
commit
c9af192690
1 changed files with 4 additions and 9 deletions
|
@ -824,15 +824,10 @@ impl Config {
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
if config.llvm_thin_lto {
|
if config.llvm_thin_lto && llvm.link_shared.is_none() {
|
||||||
// If we're building with ThinLTO on, we want to link to LLVM
|
// If we're building with ThinLTO on, by default we want to link
|
||||||
// shared, to avoid re-doing ThinLTO (which happens in the link
|
// to LLVM shared, to avoid re-doing ThinLTO (which happens in
|
||||||
// step) with each stage.
|
// the link step) with each stage.
|
||||||
assert_ne!(
|
|
||||||
llvm.link_shared,
|
|
||||||
Some(false),
|
|
||||||
"setting link-shared=false is incompatible with thin-lto=true"
|
|
||||||
);
|
|
||||||
config.llvm_link_shared = true;
|
config.llvm_link_shared = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue