<div dir="ltr">The Visual Studio installer has an option to install Clang tools for Windows or you can build from source. I believe all the tools are not included in the prebuilt package because of size. </div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Thu, Jul 23, 2020 at 11:32 AM Dimitry Andric via llvm-dev <<a href="mailto:llvm-dev@lists.llvm.org">llvm-dev@lists.llvm.org</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-style:solid;border-left-color:rgb(204,204,204);padding-left:1ex">On 23 Jul 2020, at 20:00, Alex Denisov via llvm-dev <<a href="mailto:llvm-dev@lists.llvm.org" target="_blank">llvm-dev@lists.llvm.org</a>> wrote:<br>
> <br>
> I’m trying to port some code built on top of LLVM/Clang to Windows,<br>
> however I just discovered that the precompiled versions from <a href="http://releases.llvm.org" rel="noreferrer" target="_blank">releases.llvm.org</a><br>
> are missing all the libLLVM* and libclang* dlls.<br>
<br>
This is controlled by the following CMake settings (see <a href="https://llvm.org/docs/CMake.html#llvm-specific-variables" rel="noreferrer" target="_blank">https://llvm.org/docs/CMake.html#llvm-specific-variables</a>):<br>
<br>
LLVM_BUILD_LLVM_DYLIB:BOOL<br>
<br>
If enabled, the target for building the libLLVM shared library is added. This library contains all of LLVM’s components in a single shared library. Defaults to OFF. This cannot be used in conjunction with BUILD_SHARED_LIBS. Tools will only be linked to the libLLVM shared library if LLVM_LINK_LLVM_DYLIB is also ON. The components in the library can be customised by setting LLVM_DYLIB_COMPONENTS to a list of the desired components. This option is not available on Windows.<br>
<br>
LLVM_LINK_LLVM_DYLIB:BOOL<br>
<br>
If enabled, tools will be linked with the libLLVM shared library. Defaults to OFF. Setting LLVM_LINK_LLVM_DYLIB to ON also sets LLVM_BUILD_LLVM_DYLIB to ON. This option is not available on Windows.<br>
<br>
E.g. these options are off by default (probably because it saves build time, but I'm just guessing here), and are not available on Windows (for reasons unknown to me).<br>
<br>
<br>
> Also, some tools (e.g. opt) are missing on Windows as well.<br>
<br>
I don't know about that, but maybe Hans Wennborg has more information.<br>
<br>
<br>
> I’m curious whether it’s a technical limitation (i.e. certain things don’t work on Windows),<br>
> or something else?<br>
> <br>
> For the others out there building cross-platform tools based on LLVM:<br>
> how do you deal with this issue? Am I supposed to build LLVM myself there?<br>
<br>
Either you can link against distro-provided LLVM dynamic libraries, like those shipped by Debian and Ubuntu, or you can link against the static libraries in the release tarballs.<br>
<br>
But obviously, you could always build them yourself, and ship them with your tools. This would give you the most flexibility.<br>
<br>
-Dimitry<br>
<br>
_______________________________________________<br>
LLVM Developers mailing list<br>
<a href="mailto:llvm-dev@lists.llvm.org" target="_blank">llvm-dev@lists.llvm.org</a><br>
<a href="https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev" rel="noreferrer" target="_blank">https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev</a><br>
</blockquote></div>