[PATCH] D72372: [CMake] Force static linking for registered plugins on Windows.

Michael Kruse via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Jan 9 10:05:05 PST 2020


Meinersbur added a comment.

In D72372#1811384 <https://reviews.llvm.org/D72372#1811384>, @serge-sans-paille wrote:

> 1. I'm unsure it's fine to have a different default for different platform (but that's arguable)


IMHO it is worse if the default settings don't even work. We also have such different default already, e.g. for LLVM_ENABLE_MODULE_DEBUGGING (enabled by default only on MacOS) and LLVM_ENABLE_PLUGINS.

> 2. This would link the *example* Bye plugin statically, which is not something we want (and that's critical).

I agree. Ideally, we find a common solution for all example/tutorial code.

> One workaround would be to warn the user if the setting is set to OFF on Windows

The OFF setting yields a broken build and as a consequence could even not used. It happens that the dll still builds/links but I wouldn't rely on that.

> , or disable the test on Windows?

I dislike disabling tests/examples even though they are supposed to work.

Currently, loadable module give a warning "LLVMHello ignored -- Loadable modules not supported on this platform." We could do the same here with the message explaining how to enable it.
(Actually enabling LLVMHello on Windows requires setting more flags such as LLVM_ENABLE_PLUGINS and LLVM_EXPORT_SYMBOLS_FOR_PLUGINS)

On the other side, I would also like to see -DLLVM_ENABLE_PROJECT=polly to just work. Any ideas?


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

https://reviews.llvm.org/D72372





More information about the llvm-commits mailing list