cl.exe and link.exe require `ninja -t msvc` processes to set up some env vars.
clang-cl and lld-link mostly don't need these. We already don't use these processes for compiles with clang-cl, and we don't use it for links with lld-link in cross builds.
But when using lld-link on a Windows host (the most common case), we currently still need a -t msvc process to set PATH because lld-link needs to shell out to mt.exe.
We should instead make lld-link not depend on mt.exe on Windows and instead make it do manifest merging itself, like it does on non-Win. This requires parsing xml, and on non-win we can use libxml. On Windows, we should probably use msxml instead. https://reviews.llvm.org/D42910 is some unfinished work I did on this. We should finish this at some point.
Comment 1 by thakis@chromium.org
, Sep 17