Skip to content

Commit

Permalink
Make sure that -lole32 ends up *after* LLVM libs on the linker comman…
Browse files Browse the repository at this point in the history
…d line.
  • Loading branch information
vadimcn committed Mar 30, 2017
1 parent 3b1ba01 commit 0f87203
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 7 deletions.
6 changes: 6 additions & 0 deletions src/librustc_llvm/build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -259,4 +259,10 @@ fn main() {
println!("cargo:rustc-link-lib={}", stdcppname);
}
}

// LLVM requires symbols from this library, but apparently they're not printeds
// during llvm-config?
if target.contains("windows") {
println!("cargo:rustc-link-lib=ole32");
}
}
7 changes: 0 additions & 7 deletions src/librustc_llvm/ffi.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1662,10 +1662,3 @@ extern "C" {
pub fn LLVMRustUnsetComdat(V: ValueRef);
pub fn LLVMRustSetModulePIELevel(M: ModuleRef);
}


// LLVM requires symbols from this library, but apparently they're not printed
// during llvm-config?
#[cfg(windows)]
#[link(name = "ole32")]
extern "C" {}

0 comments on commit 0f87203

Please sign in to comment.