将LLVM Clang 4.x.x/5.x.x/6.x.x集成到Visual Studio 2017中 [英] Integrate LLVM Clang 4.x.x / 5.x.x / 6.x.x into Visual Studio 2017

查看:111
本文介绍了将LLVM Clang 4.x.x/5.x.x/6.x.x集成到Visual Studio 2017中的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

用于Windows的官方LLVM 4.0版本与Visual Studio集成到Visual Studio 2015.不支持Visual Studio 2017.

The official LLVM 4.0 build for Windows integrates with Visual Studio up to Visual Studio 2015. Unfortunately it still doesn't support Visual Studio 2017.

当您尝试将项目的 Platform Toolset 设置为LLVM-vs2014时,它会弹出错误.

When you try to set the Platform Toolset of a project to LLVM-vs2014, it pops up an error.

您知道使它起作用的任何方法吗?

Do you know any way to make it work?

更新

在2018年,LLVM 6.0正式仍然不支持与Visual Studio 2017(版本15.X.X)集成,仅支持与Visual Studio 2015(版本14.X.X)工具集成.

In 2018, LLVM 6.0 officially still doesn't support integration with Visual Studio 2017 (version 15.X.X), only with the Visual Studio 2015 (version 14.X.X) toolset.

推荐答案

最后,我找到了

Finally, I found a brilliant GitHub repo with the required MSBuild platform toolsets which integrates LLVM clang 5.0.0 into Visual Studio 2017. After following the instructions of the README file, you will have two new platform toolsets LLVM-vs2017 and LLVM-vs2017_xp. Problem solved.

更新

我制作了 叉子 LLVM 6.0.0,并通过提供LLVM/clang的包含和库路径来提供更好的集成.

I made a fork which is updated for LLVM 6.0.0 and provides better integration by providing include and library paths of LLVM/clang.

感谢 Royi ,他意识到原始的.prop文件是经过明确定制的对于LLVM 5.0,它会丢失添加正确的lib( $(LLVMInstallDir)\lib)和include($(LLVMInstallDir)\lib\clang\6.0.0\include)文件夹的可能性.

Thanks to Royi, who realized that the original .prop files are explicitly tailored for LLVM 5.0 and it misses adding the proper lib ( $(LLVMInstallDir)\lib) and include ($(LLVMInstallDir)\lib\clang\6.0.0\include) folders.

这篇关于将LLVM Clang 4.x.x/5.x.x/6.x.x集成到Visual Studio 2017中的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆