C++程序没有使用Clang和Visual Studio 2010 Express进行编译

Sou*_*jee 6 c++ visual-studio-2010 windows-7-x64 llvm-clang

我正在尝试使用visual c ++ 2010 express编译本教程中描述的源代码. http://kevinaboos.wordpress.com/2013/07/23/clang-tutorial-part-ii-libtooling-example/

完整的源代码就在这里. https://github.com/kevinaboos/LibToolingExample

我已使用此链接中提供的可执行文件来安装LLVM.由于格式问题,我无法发布完整的错误消息.但我会尽量提供尽可能多的信息.当我尝试构建解决方案时,我收到以下错误: -

argument unused during compilation warnings.
C:\Program Files (x86)\LLVM\include\llvm/Support/Compiler.h(57,1): error : LLVM requires at least MSVC 2012.
C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\include\xlocnum(228,53): error : definition of dllimport static field not allowed
C:\Program Files (x86)\LLVM\include\llvm/ADT/IntrusiveRefCntPtr.h(26,9): fatal error : 'atomic' file not found

我正在使用Windows-7 64位.我通过更改项目属性链接了头文件和库.我是构建c ++应用程序的新手.请帮忙.

sam*_*sam 10

对于MSVC 2012构建错误,请在此处找到解决方案

根据Clang文档,尚不支持例外和SEH.你必须禁用它.

要在Visual Studio中禁用异常,请打开Project Properties并转到C/C++,预处理器,然后将_HAS_EXCEPTIONS = 0添加到预处理器定义.