Lines Matching +full:xcode +full:- +full:version
1 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
5 <title>Running the analyzer within Xcode</title>
13 <!--#include virtual="menu.html.incl"-->
16 <h1>Running the analyzer within Xcode</h1>
18 <table style="margin-top:0px" width="100%" border="0" cellpadding="0px" cellspacing="0">
23 <p>Since Xcode 3.2, users have been able to run the Clang Static Analyzer
25 …apple.com/library/ios/recipes/xcode_help-source_editor/chapters/Analyze.html#//apple_ref/doc/uid/T…
26 within Xcode</a>.</p>
28 <p>It integrates directly with the Xcode build system and
29 presents analysis results directly within Xcode's editor.</p>
31 <h3>Can I use the open source analyzer builds with Xcode?</h3>
36 <td style="padding-left:10px; text-align:center">
37 …analyzer_xcode.png"><img src="images/analyzer_xcode.png" width="620px" alt="analyzer in xcode"></a>
38 <br><b>Viewing static analyzer results in Xcode</b>
43 <li><b>Integrated workflow:</b> Results are integrated within Xcode. There is
46 <li><b>Transparency:</b> Works effortlessly with Xcode projects (including iPhone projects).
47 <li><b>Cons:</b> Doesn't work well with non-Xcode projects. For those,
48 consider using <a href="scan-build.html"><b>scan-build</b></a>.
54 <p>Xcode is available as a free download from Apple on the <a
55 href="https://itunes.apple.com/us/app/xcode/id497799835?mt=12">Mac
57 …apple.com/library/ios/recipes/xcode_help-source_editor/chapters/Analyze.html#//apple_ref/doc/uid/T…
60 <h2>Using open source analyzer builds with Xcode</h2>
62 <p>By default, Xcode uses the version of <tt>clang</tt> that came bundled with
63 it to analyze your code. It is possible to change Xcode's behavior to use an
64 alternate version of <tt>clang</tt> for this purpose while continuing to use
65 the <tt>clang</tt> that came with Xcode for compiling projects.</p>
70 is that they are often newer than the analyzer provided with Xcode, and thus can
75 (for any version of the analyzer) where they encounter false positives or other
78 <h3>set-xcode-analyzer</h3>
80 <p>Starting with analyzer build checker-234, analyzer builds contain a command
81 line utility called <tt>set-xcode-analyzer</tt> that allows users to change what
82 copy of <tt>clang</tt> that Xcode uses for analysis:</p>
85 $ <b>set-xcode-analyzer -h</b>
86 Usage: set-xcode-analyzer [options]
89 -h, --help show this help message and exit
90 --use-checker-build=PATH
92 e.g. /Users/foo/checker-1
93 --use-xcode-clang Use the Clang bundled with Xcode
96 <p>Operationally, <b>set-xcode-analyzer</b> edits Xcode's configuration files
97 to point it to use the version of <tt>clang</tt> you specify for static
101 …<li><b>--use-xcode-clang</b>: Switch Xcode (back) to using the <tt>clang</tt> that came bundled wi…
102 …<li><b>--use-checker-build</b>: Switch Xcode to using the <tt>clang</tt> provided by the specified…
108 …<li>You should quit Xcode prior to running <tt>set-xcode-analyzer</tt>.</li> <li>You will need …
109 <b><tt>sudo</tt></b> in order to have write privileges to modify the Xcode
115 <p><b>Example 1</b>: Telling Xcode to use checker-235:</p>
120 $ tar xjf checker-235.tar.bz2
121 $ sudo checker-235/set-xcode-analyzer --use-checker-build=/tmp/checker-235
125 the point of this example is that <tt>set-xcode-analyzer</tt> just wants a full
128 <p><b>Example 2</b>: Telling Xcode to use a very specific version of <tt>clang</tt>:</p>
131 $ sudo set-xcode-analyzer --use-checker-build=~/mycrazyclangbuild/bin/clang
134 <p><b>Example 3</b>: Resetting Xcode to its default behavior:</p>
137 $ sudo set-xcode-analyzer --use-xcode-clang