[cfe-dev] Clang 3.5 Release Pre-Pre-Pre-Announcement

Hans Wennborg hans at chromium.org
Tue Jun 3 11:00:42 PDT 2014


Hi Kim,

On Mon, Jun 2, 2014 at 10:28 PM, Kim Gräsman <kim.grasman at gmail.com> wrote:
> On Fri, May 23, 2014 at 1:09 AM, Hans Wennborg <hans at chromium.org> wrote:
>> On Sat, May 17, 2014 at 6:16 PM, Richard <legalize at xmission.com> wrote:
>>>
>>> In article <CAB8jPhdE5mE8v=OVw3A4N2cxLNNhZTdisbTnaMUkxD+erizs+Q at mail.gmail.com>,
>>>     Hans Wennborg <hans at chromium.org> writes:
>>>
>>>> OK, maybe we should try shipping without LLVM_INSTALL_TOOLCHAIN_ONLY.
>>>> It grows the installer from 25 MB to 115 MB, but Reid pointed out that
>>>> the release on Linux is actually even larger, so maybe it's ok.
>>>
>>> I bought a copy of "Mastering CMake" and read it so I could understand
>>> clang/llvm's build.  I understand it enough that I think I could try
>>> creating an "SDK" installer that would be for developers using either
>>> libclang or the C++ API.
>>>
>>>> If we think this is what we want to do, I can build next week's
>>>> snapshot this way, and maybe Richard can try it out and see if
>>>> building a tool with that works?
>>>
>>> I'm very willing to test that.
>>
>> Sorry for the delay. Here's a snapshot that was built without
>> LLVM_INSTALL_TOOLCHAIN_ONLY:
>> http://llvm.org/builds/downloads/LLVM-3.5.r209120-win32.exe
>>
>> Please let me know if that works.
>
> I just downloaded this yesterday to try an out-of-tree build of a
> Clang tool on Windows. I ran into two surprises:

Thanks for trying it out!

> - All LLVM/Clang libraries seem to be statically linked to the
> Microsoft CRT (i.e. /MT instead of the default /MD), so I had to
> modify my standalone CMakeLists.txt to also set /MT.

Yes, we do this to avoid shipping the redistributable with the
toolchain. Can you set USE_CRT_RELEASE =MT in your standalone build?
That's what I use to build with /MT.

> - The default target triple for the resulting tool turned out to be
> "i686-pc-windows-gnu" instead of "i686-pc-windows-msvc" that I get
> when I build in-tree with Ninja+MSVC. I'm assuming this is because the
> posted LLVM binaries are built under MinGW.

No, the snapshots are built with VS2012, but we made MinGW the default
target because it had the most complete support. Note that clang-cl
always targets windows-msvc.

> Unfortunately, this
> shortcircuits all default include paths. Is there a way for me to
> override the default triple from the build system?

Does setting LLVM_DEFAULT_TARGET_TRIPLE=i686-pc-mingw32 work?

Thanks,
Hans




More information about the cfe-dev mailing list