I have managed to build clang on Windows 7 using Visual Studio 210 and now I like to use it with the codeblocks IDE. So I copied the clang executables into the mingw bin\\ folde
UPDATE
MSYS2 packages are available for clang on 32-bit and 64-bit, and from what limited testing I did it seems to work quite well. The compiler can be used from outside the MSYS2 environment.
On how to install MSYS2, see here. Then just run
pacman -Sy mingw-w64-x86_64-clang
or
pacman -Sy mingw-w64-i686-clang
after updating MSYS2 to install Clang.
The patches used in that package (if you want to build LLVM/Clang yourself) are located here.
old reply follows, slightly out of date
If you want to use Clang on Windows for C++, your only option currently is to use (or build yourself) Clang with/for MinGW(-w64).
Lucky for you, I provide packages:
Unzip both to the same directory and add mingw32-dw2/bin
to PATH
, or point Codeblocks to it. You will be limited to GCC 4.6's libstdc++. Clang 3.2's C++11 language support is fully functional though.
Note that Clang expects GCC style options, so I suggest modifying the Codeblocks GCC build process and replacing g++
with clang++
and gcc
with clang
.