ActiveState Community

Mozilla build from tarball?

Posted by jtatum on 2009-09-17 11:48

I'm getting started on Ubuntu packaging for Open Komodo. One item that's going to be an issue right away is Mozilla. The way the build system downloads Mozilla sources and applies patches is neat, but Debian/Ubuntu packages have to have all sources available at build time. I noticed a tarball option for mozilla/build.py which could probably work. Any hints on where to get this tarball? I noticed Mozilla provides tarballs of source releases but I don't know which might apply here. Any guidance is appreciated.

toddw | Mon, 2009-09-21 11:21

It should be possible to build Komodo from a mozilla tarball by providing the "--moz-src" option of the Komodo/Mozilla build.py configuring.

Komodo 5.2.0 was built using Firefox 3.0.11, but you should be able to use latest Firefox 3.0.x release just as well. The latest release is 3.0.14:
http://releases.mozilla.org/pub/mozilla.org/firefox/releases/3.0.14/sour...

The official build options we use to configure Mozilla and Komodo are:

python build.py configure -k 5.2 --moz-src=cvs:FIREFOX_3_0_11_RELEASE \
                --release --blessed --no-strip --moz-objdir=ko-5.2.x-release \
                --src-tree-name=cvs-ff-3.0.11
python build.py all
python build.py configure -k 5.2 --moz-src=cvs:FIREFOX_3_0_11_RELEASE \
                --release --blessed --no-strip --moz-objdir=ko-5.2.x-release \
                --src-tree-name=cvs-ff-3.0.11
python build.py all

If you download the above tarball, then change the configure to use this tarball as:

python build.py configure -k 5.2 \
                --release --blessed --no-strip --moz-objdir=ko-5.2.x-release \
                --src-tree-name=cvs-ff-3.0.11 \
                --no-mar \
                --moz-src=./firefox-3.0.14-source.tar.bz2
python build.py all
python build.py configure -k 5.2 \
                --release --blessed --no-strip --moz-objdir=ko-5.2.x-release \
                --src-tree-name=cvs-ff-3.0.11 \
                --no-mar \
                --moz-src=./firefox-3.0.14-source.tar.bz2
python build.py all

I added the "--no-mar" to above configure line to disable the building of the mar tool - as you likely won't the "auto-update" facility with the Ubuntu repository.

Then the official command line Komodo configuration is done as:

python util/black/bk.py configure --product-type=edit --full --moz-src=blessed
python util/black/bk.py build
python util/black/bk.py image
python util/black/bk.py package
python util/black/bk.py configure --product-type=edit --full --moz-src=blessed
python util/black/bk.py build
python util/black/bk.py image
python util/black/bk.py package

You may run into problems in the Komodo package part - due to the "mar" not existing.

Cheers,
Todd