Sunday, March 20, 2011

Compiling Firefox 4 RC

Mozilla Firefox 4 is almost here! Out of curiosity I compiled the source using Debian Sid in Virtualbox.
See some former posts : http://debian-bits-and-snips.blogspot.com/2011/01/firefox-40b8en-uslinux-x8664tarbz2.html and http://debian-bits-and-snips.blogspot.com/2010/12/error-enable-applicationapp-was-not.html.

.mozconfig ( added to folder mozilla-2.0 after extracting source ) :
.$topsrcdir/browser/config/mozconfig
mk_add_options MOZ_OBJDIR=@TOPSRCDIR@/ff-release
ac_add_options --disable-debug
ac_add_options --disable-tests
ac_add_options --enable-optimize
ac_add_options --enable-official-branding
ac_add_options --enable-system-cairo
ac_add_options --enable-application=browser
mk_add_options MOZ_CO_PROJECT=browser


In mozilla-2.0 open a terminal and enter make -f client.mk. Once the compile is done, the binaries will be in ../mozilla-2.0/ff-release/dist/bin/. After that cd mozilla-2.0/ff-release && make package. Package will be in : mozilla-2.0/ff-release/dist/ (tar.bz2). In my case : firefox-4.0.en-US.linux-x86_64.tar.bz2.

Extracting firefox-4.0.en-US.linux-x86_64.tar.bz2 will yield a folder firefox which I renamed firefox-4.0rc2 and moved into my home directory. To test I opened a terminal inside this folder and I got this error after the command ./firefox -P ( to create a new profile ) : ./firefox-bin : /usr/lib/libstdc++.so.6 : version `GLIBCXX_3.4.14` not found ( required by ./libxul.so ).

Solution : add testing repository to your sources.list, update and in synaptic search for package libstdc++6. In synaptic : Package > Force Version...
libstdc++6 (4.4.5-8) will be upgraded to 4.5.2-4 and package gcc-4.5-base (4.5.2-4) will be installed. After that remove testing from your sources.list.

Add an entry in your menu and you're done....

No comments:

Post a Comment

Note: Only a member of this blog may post a comment.