blob: d1a162e418640ffd675d923a0f19a5c881fc07a8 [file] [log] [blame]
<?php
$title = "Building WebKit";
include("../header.inc");
?>
<h2>Building WebKit</h2>
Building WebKit requires that you have the proper <a href="tools.html">developer tools
installed</a> and that you have a copy of the <a href="checkout.html">WebKit source tree</a>.
<div class="windows-instructions">
<h4>Windows</h4>
<ol>
<li><p>Open a Cygwin Shell (if not already open from checking out sources)</p>
<p>Double-click the Cygwin icon on your Desktop to launch a new shell.
</ol>
</div>
<ol>
<li><p>Run the <code>build-webkit</code> <a href="/coding/scripts.html">script</a>
to build WebKit.</p>
<p>Use the <code>--debug</code> option for a debug build, which includes
debugging symbols and assertions:</p>
<p class="code">build-webkit --debug</p>
</li>
</ol>
<p>By default, <code>build-webkit</code> places build products in <code>WebKitBuild</code>. You can specify a different build
location on Mac in your Xcode preferences. On other platforms, the <code>WEBKIT_OUTPUTDIR</code> environment variable can be used to
set a different build products location. If you have set up a custom build location, then <code>build-webkit</code> will
place the build products there.</p>
<div class="windows-instructions">
<h4>Windows</h4>
<p>A common source of build errors on Windows is Visual C++ Express forgetting the Platform SDK paths. If you have trouble building WebKit,
double check that the paths you set during <a href="http://msdn.microsoft.com/en-us/library/ms235626(VS.80).aspx">step 2 of the Platform SDK Installation</a>
are still there and add them again if necessary.</p>
<p>Building on Windows requires a few more steps, you should look at: http://trac.webkit.org/wiki/BuildingOnWindows</p>
<p>Don't forget that if you have any questions or problems building WebKit, feel free to <a href="/contact.html">get in touch!</a></p>
</div>
<p>Once your build has finished, you can <a href="run.html">run it inside
Safari.</a></p>
<h2>Building WebKit from Xcode</h2>
<p>To build from within Xcode, you can use the WebKit workspace. Ensure that the Products and Intermediates locations for the workspace match those used by <code>build-webkit</code> by choosing File > Workspace Settings and clicking the Advanced button, selecting Custom, Relative to Workspace, and entering WebKitBuild both for Products and for Intermediates. Note that if you have specified a custom build location in Xcode preferences, then you don&rsquo;t need to do this.</p>
<h2>Setting a Default Configuration</h2>
<ol>
<li><p>To set a default build configuration for <code>build-webkit</code> and
other <a href="/coding/scripts.html">scripts</a>, use the
<code>set-webkit-configuration</code> script:</p>
<p class="code">set-webkit-configuration --debug</p>
<p class="code">set-webkit-configuration --release</p>
</li>
</ol>
<?php
include("../footer.inc");
?>