I'm not using Iceweasel, but always downloaded the latest stable version of Firefox from their site.
Now with using patched libfreetype6, libcairo2 and libxft2 I had the problem that the Firefox binary from Mozilla is statically linked. The solution is to rebuild them to be dynamically linked against your system libraries (particularly Cairo).
The first thing you need to do is get the source code. Move it to a directory e.g "src" on your Desktop.
tar xf firefox-3.5.5.source.tar.bz2 will extract it. You will get a directory "/src/ mozilla-1.9.1/ ".
You need to patch the source file ’cause it has a bug when you compile with the ‘–enable-system-cairo’ . Get the patch from here: https://bugzilla.mozilla.org/show_bug.cgi?id=466250 .
Save the patch file in your ‘mozilla-1.9.1′ directory. Patch the source: patch -p1 < patch-filename.
Before we go any further you need to install a lot of building dependencies, sudo apt-get build-dep iceweasel .
When building you will get errors, take a note of them and see what else you need.
Next step will be to make a textfile .mozconfig in your "/src/ mozilla-1.9.1/ ".
Put the following inside the .mozconfig file:
ac_add_options --enable-optimize --disable-debug
ac_add_options --enable-default-toolkit=cairo-gtk2 --enable-system-cairo
For the make script to be able to find your .mozconfig do :
Now in your "/src/ mozilla-1.9.1/ " directory, start a terminal and issue the build command:
make -f client.mk build
Now be patient, this is taking some time !
When its is all done, cd into the directory ‘mozilla-1.9.1/ff-opt/dist/bin’ and run the executable ‘firefox’.
cd mozilla-1.9.1/ff-opt/dist/bin and start your brandnew firefox :
./firefox -P -no-remote
-P will start the profilemanager, -no-remote will let you run firefox with a new choosen profile even when other firefox windows are already open.
To package the build:
The new package will be located in ‘ff-opt/dist/’
Move your firefox folder in e.g your home directory, and make a link on your Desktop, taskbar, menu : /home/username/firefox/firefox -P "profile-name" -no-remote
Already built packages :
firefox-3.5.5.en-US.langpack.xpi ( save link as )
Type in " about:buildconfig " in the adress bar :