Windows 上的 Clang 静态分析器
有人在 Windows 上成功运行 clang 静态分析器吗?
我已经成功构建了 llvm 和 clang (使用 VS 2008)。运行 scan-build 会导致以下错误:
The getpwuid function is unimplemented at scan-build line 35.
一些研究表明 Windows 平台不支持 getpwuid。
Does anybody have any success running clang static analyzer on Windows?
I have successfully built llvm and clang (using VS 2008). Running scan-build results in the following error:
The getpwuid function is unimplemented at scan-build line 35.
Some research shows that getpwuid is not supported on Windows platforms.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
将调用更改为...
scan-build 是一个 perl 脚本,因此需要一些方便的修复才能在 Windows 上执行 scan build.. 这些是
->指向那些变量来查看绝对物理路径
请记住,我的 $Cmd ;我的 $CmdCXX 是 ccc-analyzer 和 c++-analyzer 的路径...它们也是 perl 脚本,因此请在绝对路径字符串前面放置一个 perl -w ..
并在声明后立即禁用变量检查...
! -x $blaBla 在 Windows 上有问题...
此外您还需要这些更改
-->令人
惊讶的
是,扫描构建正在 Windows 上运行..:)
change the call to ...
scan-build is a perl script, so will need some handy fixes to execute scan build on windows.. these are
-> point those variables to look at the absolute physical path
please remember, that my $Cmd ; and my $CmdCXX is path of ccc-analyzer and c++-analyzer ... which are also perl scripts, so please place a perl -w in front of absolute path string..
and also disable the variable check right after declaration...
! -x $blaBla is problematic on windows...
beside you will also need these changes
--> CHANGE
to
surprise, scan-build is working on windows.. :)