Overview
In general, the steps are:
- Pull the Songbird-modified XULRunner source code from the Songbird vendor repository
- Pull the Songbird vendor-binaries for your platform
- (If you want to build Songbird after this),
At this point I suggest you go read the Mozilla build documentation for your platform of choice. Then come back here and peruse the section for that platform below for specifics to building for Songbird. Mozilla build documentation.
Machine Requirements
A recent clean install of Ubuntu (Gutsy 7.10) required the following additional packages be installed in order to build XULRunner. All other packages were either installed by default or added as part of building Songbird already.
cvs
curl (for crashreporter)
libcurl4-openssl-dev (for curl.h)
libidl-dev
libxt-dev
Installing on Fedora 9 required the following additional packages be installed in order to build XULRunner.
cvs
curl
libXt-devel
libIDL-devel
libcurl-devel
Step Detail
- Check out the vendor source code: the easiest way to do this is to get the entire vendor tree for the branch you're interested in building, but if you don't want to check all that out, you'll minimally need the files in the root of the tree and the xulrunner directory:
# For the following examples, we assume you're checking out into /builds/sb-vendor/
# To grab everything
svn co http://publicsvn.songbirdnest.com/vendor/trunk
# To grab just xulrunner
svn co -N http://publicsvn.songbirdnest.com/vendor/trunk/
cd trunk
svn up xulrunner
- Checkout the vendor binaries for your platform; see the Get the Songbird source code instructions for details on how to do this. Check them out into a directory called "checkout" (required for the vendor build system):
cd /builds/sb-vendor/
mkdir checkout && cd checkout
svn co http://publicsvn.songbirdnest.com/vendor-binaries/trunk/$myPlatform
- Set SB_VENDOR_BUILD_ROOT to the root directory of your vendor build area; in our case, that will be /builds/sb-vendor:
export SB_VENDOR_BUILD_ROOT=/builds/sb-vendor
- If you want to make any changes to your mozconfigs, they will be copied from the xulrunner/mozconfig directory; modify them there, as they get deleted upon each build (so modifying them in the build tree won't maintain your custom changes).
- Build xulrunner; the following will build both debug and release xulrunners:
cd /builds/sb-vendor
mkdir build
mkdir $platformString
cd trunk/xulrunner
# If you're NOT building trunk, do the following: export SB_BRANCH="$branchName", e.g. Songbird1.5
make -f Makefile.songbird
If this is not what you want, you can customize what you want to build by specifying a specific target.
Targets
- xr-build-debug - Perform a debug xulrunner build
- xr-build-release - Perform a release xulrunner build
- xr-packaging - Package up any available xulrunners
- xr-symbols - Generate symbol packages for any release xulrunners (will fail if no release xulrunners have been built)
- xr-clean - Remove all generated xulrunner builds
- xr-all - default target; perform a debug build followed by a release build, followed by symbol generation and packaging for both
Environment Variables
- SB_VENDOR_AUTOCLEAN_OBJDIRS - Define if you want the build system to remove the object directories after each successful build; this can be useful if you don't need to keep the object directories around and want to reclaim some space.
- XR_DISABLE_SYMBOLS - Define if you want to always disable symbol generation (e.g. you want to use xr-all to build, but don't want to waste time on generating symbol packages)
Wrap Up
At this point you will have a completely built XULRunner tree capable of running XUL applications, like Songbird.
Now on to Packaging XULRunner for Songbird.