Thursday, September 20, 2007

Session 3 - setting up the mozconfig files

Session 3
Before I continue with the Armenian localization process, I have to build Firefox in debug mode for the DPS909 course I'm taking.
Therefore I'm going to read about how to build different things from the same source code.

Finally, it seems that I know what I'm doing:
http://developer.mozilla.org/en/docs/Configuring_Build_Options#Using_multiple_mozconfig_files
- I have set 2 mozconfig files:
- one to build firefox in debug mode
- the other to build firefox hy-AM (in Armenian)

- Aside of creating two specific files, I had to create a common one that will pull the whole source code for the browser
(Check the source code of the them at the bottom)

To checkout, run the following commands:
> export MOZCONFIG=/d/MozillaffSource/mozilla/mozconfig-common
> make -f client.mk checkout //It started 19:26pm and 15 mins later is here

To build Firefox with debug, run the following commands:
> export MOZCONFIG=/d/MozillaffSource/mozilla/mozconfig-firefox-debug
> make -f client.mk build

To build Firefox's Armenian localization, run the following commands:
> export MOZCONFIG=/d/MozillaffSource/mozilla/mozconfig-firefox-hyAM
> make -f client.mk build

mozconfig-common
mk_add_options MOZ_CO_PROJECT=browser

mozconfig-firefox-debug
# include the common mozconfig
. ./mozconfig-common

# Build Firefox
mk_add_options MOZ_OBJDIR=@TOPSRCDIR@/../build-firefox-debug
ac_add_options --enable-application=browser
ac_add_options --disable-optimize
ac_add_options --enable-debug

mozconfigfirefox-hyAM
# include the common mozconfig
. ./mozconfig-common

# remove the next comment when you are about to build (as I said before)
#. $topsrcdir/browser/config/mozconfig
# this is to set where you want the binaries to be built
mk_add_options MOZ_OBJDIR=@TOPSRCDIR@/../build-hyAM
# this is to pull the code related to the Armenian language
mk_add_options MOZ_CO_LOCALES=hy-AM
# for translations in the incubator (term used by Axel), we use HEAD
mk_add_options LOCALES_CO_TAG=HEAD

Next session, I will actually try to build it


No comments:

Post a Comment

Post a Comment