[PATCH] D63743: [llvm-shlib] Do not use version script when building with MinGW and LLD

Pirama Arumuga Nainar via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Jun 24 22:40:49 PDT 2019


pirama added a comment.

In D63743#1556912 <https://reviews.llvm.org/D63743#1556912>, @mstorsjo wrote:

> I'd suggest skipping the lld condition, the version script adds no value here.
>
> For ELF, version scripts do two things, select what symbols to export using glob pattetns, and set symbol versions on them.
>
> As COFF doesn't have symbol versions, all it does on mingw with GNU ld, is filtering symbols, to export *. So it adds no value there.


I thought so - that -version-script is not needed for Windows but wanted to leave it just in case GNU ld did something with it.  I'll skip this option altogether for MinGW unless someone suggests otherwise.

> (I don't remember if cmake even knows the linker is lld in my mingw setups.)

It does know - LINKER_IS_LLD_LINK is set at the top of llvm/cmake/modules/HandleLLVMOptions.cmake.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D63743/new/

https://reviews.llvm.org/D63743





More information about the llvm-commits mailing list