[cfe-dev] How to use clang static code analysis without building a project

Sz. G. semyazz at gmail.com
Fri Feb 8 07:27:15 PST 2013


I'm new to Objective-C and whole iOS platform, but I'd know if there is a
possibility to use Clang without building whole project.

I'm doing security assessments and sometimes they include code review. I'd
like to write some scripts that would use clang and analyze code before
I'll read it manually. The main problem is that, I'm not always able to
compile code. Sometimes I get only source code without external
dependencies and I can't build and run it, so my main question is:

Is Clang able to analyze code without building it? Is there any clang API
to use it outside the XCode, in some scripts that will run it, and get
clang's results? I just read that there is console runner, but when I
briefly read the docs, I saw that that console tool builds project.

Thx in advance
Sz. G.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20130208/f112eaf2/attachment.html>

More information about the cfe-dev mailing list