Skip to content

Commit

Permalink
link vcruntime statically
Browse files Browse the repository at this point in the history
  • Loading branch information
vadimcn committed Jul 28, 2016
1 parent f2e59cc commit 32a8269
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
1 change: 1 addition & 0 deletions configure
Original file line number Diff line number Diff line change
Expand Up @@ -1730,6 +1730,7 @@ do
fi
# FIXME: What about LDFLAGS?
fi
CMAKE_ARGS="$CMAKE_ARGS '-DCMAKE_C_FLAGS=-D_VCRTIMP=' '-DCMAKE_CXX_FLAGS=-D_VCRTIMP='"

if [ -n "$CFG_DISABLE_OPTIMIZE_LLVM" ]; then
CMAKE_ARGS="$CMAKE_ARGS -DCMAKE_BUILD_TYPE=Debug"
Expand Down
2 changes: 2 additions & 0 deletions src/librustc_trans/back/linker.rs
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,8 @@ impl<'a, 'tcx> LinkerInfo {
cmd: &'a mut Command,
sess: &'a Session) -> Box<Linker+'a> {
if sess.target.target.options.is_like_msvc {
cmd.arg("/NODEFAULTLIB:vcruntime.lib");
cmd.arg("libvcruntime.lib");
Box::new(MsvcLinker {
cmd: cmd,
sess: sess,
Expand Down

0 comments on commit 32a8269

Please sign in to comment.