[[PageOutline]] = Building WebKitGTK+ = {{{ #!div style="border: 1pt dotted; margin: 1em; background: PeachPuff" **These instructions are meant for use with the source code repository and are generally not suitable for building a release tarball.** }}} == Getting the source == To get the [wiki:WebKitGTK WebKitGTK+] source, please follow the instructions on the [http://webkit.org/building/checkout.html WebKit page]. Many WebKit developer also use git to interact with the repository and the WebKit developer tools have strong support for git. [http://trac.webkit.org/wiki/UsingGitWithWebKit] contains tips for using git with WebKit. == Dependencies == 1. '''Install the base WebKitGTK+ dependencies:''' {{{ #!sh $ Tools/gtk/install-dependencies }}} 2. '''Download and build all jhbuild modules:''' {{{ #!sh $ Tools/Scripts/update-webkitgtk-libs }}} == Building == {{{ #!sh $ Tools/Scripts/build-webkit --gtk }}} === Notes === * You can pass parameters to the make command with the ''--makeargs'' argument. * For example, you can pass ''--makeargs="-jXX"'', where XX is an integer, to set the number of threads make will use. The default is one per logical CPU detected, but you might want fewer if it's bogging down your system. * JHBuild configuration and module files are stored as `Tools/gtk/jhbuildrc` and `Tools/gtk/jhbuild.modules`. * If everything builds properly tests should typically pass on your system. Please file a bug if they do not. * If you get build errors saying a library could not be found but you have the appropriate packages installed make sure you have up-to-date multiarch-support and binutils (or binutils-gold) packages. * You can also [wiki:WebKitGtkExtendingJHBuild add more modules to the default WebKit JHBuild]. * Wayland support has been under working. If you're interested in hacking on it, just use ./Tools/gtk/wayland-dependencies.modules. You can simply set up the dependencies by exporting WEBKIT_EXTRA_MODULESETS. {{{ WEBKIT_EXTRA_MODULESETS=file:///webkit/directory/Tools/gtk/wayland-dependencies.modules }}} == OS X == The code on Mac OS X should built like any Linux distribution, as long as you install the above build dependencies (in addition to an "ordinary build environment" that includes XCode Tools 2.3 or newer). [http://www.macports.org/ MacPorts] users can get the dependencies via: {{{ #!sh $ sudo port install webkit-gtk }}} If you get an error about libjpeg when the build does the configuration step, you may find the following fixes it: {{{ $ export CPPFLAGS="-I/opt/local/include" $ export LDFLAGS="-L/opt/local/lib" }}}