Skip to content

Commit

Permalink
statically link the tools to libstdc++
Browse files Browse the repository at this point in the history
  • Loading branch information
japaric committed Jun 3, 2018
1 parent a1ef529 commit 8e67307
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/bootstrap/native.rs
Expand Up @@ -174,6 +174,11 @@ impl Step for Llvm {
cfg.define("LLVM_LINK_LLVM_DYLIB", "ON");
}

// For distribution we want the LLVM tools to be *statically* linked to libstdc++
if builder.config.ship_llvm_tools {
cfg.define("CMAKE_EXE_LINKER_FLAGS", "-Wl,-Bsymbolic -static-libstdc++");
}

if target.contains("msvc") {
cfg.define("LLVM_USE_CRT_DEBUG", "MT");
cfg.define("LLVM_USE_CRT_RELEASE", "MT");
Expand Down

0 comments on commit 8e67307

Please sign in to comment.