compiler-rt with MSVC?

I’m trying to figure out how to build compiler-rt 3.5.0 with Visual Studio 2013. In an autotools build or cmake on Linux, I believe putting the compiler-rt sources under llvm/projects is enough to build them automatically. Do I need to do anything specific to get the same with MSVC? I've tried setting -DLLVM_BUILD_EXTERNAL_COMPILER_RT either ON or OFF, but can't find any evidence of compiler-rt getting built. If I build compiler-rt separately, pointing it to an installed LLVM build with -DLLVM_CONFIG_PATH, the only thing that ends up in the install result is the sanitizer headers. Should this be working, or is it still under construction? When I tried with LLVM 3.3 I was getting a bunch of syntax errors from MSVC in compiler-rt, so presumably it wasn't yet MSVC-compatible at that time. Has the MSVC build just been disabled somewhere to avoid this?

Thanks,
Tony

Please pardon the top posting (mobile devices make this hard).

This should work for x86 targets theoretically. There is an outstanding patch that I need to tweak for windows support via make and clang. It uses the MSVC environment for the x86 targets and the Itanium environment for ARM (due to assembly).

Creating a custom VS solution should allow you to do this I believe.

I know we build at least lib/sanitizer_common and lib/asan. I don’t know about lib/builtins.

Thanks Reid and Saleem.

Creating a custom VS solution should allow you to do this I believe.

I’d prefer to limit my interactions with Visual Studio to cmake and the command line if at all possible. The difference in LLVM's build time was striking, going through the GUI vs not.

I know we build at least lib/sanitizer_common and lib/asan. I don't know about lib/builtins.

I think builtins should have what I'm looking for here. I was able to get Julia to a working REPL with an MSVC build, but some uses of int128 intrinsics are crapping out.

-Tony

If this is your preference, then I strongly recommend using ninja to build:
http://martine.github.io/ninja/

To select the CMake ninja generator, pass -GNinja to cmake.