From 9a96876d2d1f8e2a4ca066f132c4b6ddec1b94ff Mon Sep 17 00:00:00 2001 From: Jorge Aparicio Date: Wed, 20 Jun 2018 17:48:04 -0500 Subject: [PATCH] no -Bsymbolic for mac; no static-libstdc++ for windows --- src/bootstrap/native.rs | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/bootstrap/native.rs b/src/bootstrap/native.rs index c3f84378adf..7dcdbe9c931 100644 --- a/src/bootstrap/native.rs +++ b/src/bootstrap/native.rs @@ -176,7 +176,13 @@ impl Step for Llvm { // For distribution we want the LLVM tools to be *statically* linked to libstdc++ if builder.config.llvm_tools_enabled { - cfg.define("CMAKE_EXE_LINKER_FLAGS", "-Wl,-Bsymbolic -static-libstdc++"); + if !target.contains("windows") { + if target.contains("apple") { + cfg.define("CMAKE_EXE_LINKER_FLAGS", "-static-libstdc++"); + } else { + cfg.define("CMAKE_EXE_LINKER_FLAGS", "-Wl,-Bsymbolic -static-libstdc++"); + } + } } if target.contains("msvc") {