Building a single GNOME module using jhbuild
I often see new contributors (and even seasoned hackers) wanting to hack on a GNOME module, say Empathy, trying to build it using:
jhbuild build empathy
This is obviously correct but asks jhbuild to build not only Empathy but also all its dependencies (62 modules) so you'll end up building most of the GNOME stack. While building a full GNOME stack may sometimes be useful that's generally not needed and definitely not the easiest and fastest way to proceed.
Here is what I usually do.
First I make sure to have installed all the dependencies of the module using your distribution packaging system. This is done on Fedora using:
sudo yum-builddep empathy
or on Ubuntu/Debian:
sudo apt-get build-dep empathy
If you are using a recent distribution, there are good chances that most of these dependencies are still recent enough to build the module you want to hack on. Of course, as you are trying to build the master branch of the project some dependencies may have been bumped to one of the latest developement releases. But first let's try to build just Empathy.
jhbuild buildone empathy
There are good chances that some dependencies are missing or are too old, you'll then see this kind of error message:
No package 'libsecret-1' found Requested 'telepathy-glib >= 0.19.9' but version of Telepathy-GLib is 0.18.2
That means you'll have to build these two libraries in your jhbuild as well. Just check the list of depencies of the module to find the exact name of the module:
jhbuild list empathy | grep secret jhbuild list empathy | grep telepathy
In this example you'll see you have to build the libsecret and telepathy-glib modules:
jhbuild buildone libsecret telepathy-glib
Of course these modules may have some extra depencies on their own so you may have to do some iteration of this process before being able to actually build the module you care about. But, from my experience, if you are using a recent distribution (like the latest Fedora release) the whole process will still be much faster than building the full stack. Furthermore, it will save you to have to deal with build errors from potentially 62 modules.