Dec 062012
 

As I mentioned last week, we’ve been working hard to get multilocale B2G builds going. This morning we flipped the switch and turned on multilocale Gaia across the board. The existing desktop and device builds on TBPL will now include a Gaia profile with Arabic, English, Spanish, French, Brazilian Portuguese, and Mandarin Chinese (zh-TW).

Additionally, we now have new desktop builds with all of the locales listed in this file available — meaning that most people localizing B2G can now test their translations in-app. These are available for Linux, Mac, and Windows in the “localizer” packages in this directory.

A few notes:

  • Linux users who have run a B2G desktop build in the past may need to rm -rf ~/.mozilla/b2g before these new builds will function correctly.
  • Gecko is still en-US only. Expect network errors and other such things to be in en-US for now. Multilocale gecko for B2G work is being tracked in bug 817197 and the bugs that it blocks.
  • All of the desktop builds will be updated on a nightly basis. However, there are no automatic updates for them – you must download by hand whenever you want to test newer code or translations.
Jan 302009
 

Someone I know recently expressed interest in translating Firefox into her native language, Tagalog. Being a build guy, I decided to spare her the pain of getting everything setup and let her focus on the translation. Much to my dismay I discovered that the Create a New Localization page hasn’t been fully updated for Firefox 3.1 yet. By mashing together information on a couple of pages and a lot of help from #l10n I managed to get an environment up and running that allowed her to dive in.

Here’s how to do it. (Note: This has been tested on Mac and Windows. On Windows, this depends on MozillaBuild 1.3; on both it depends on Python setuptools.)

  1. Install compare-locales
  2. wget http://pypi.python.org/packages/2.5/c/compare-locales/compare_locales-0.6.1-py2.5.egg#md5=0b939a22d87427d80f5286dc5eb1eab2
    easy_install compare_locales-0.6.1-py2.5.egg

  3. Clone mozilla-1.9.1
  4. hg clone http://hg.mozilla.org/releases/mozilla-1.9.1

  5. Create the barebones localization
  6. mkdir -p tl/browser/installer tl/browser/profile/chrome tl/browser/searchplugins tl/browser/updater tl/toolkit
    cp mozilla-1.9.1/browser/locales/en-US/defines.inc tl/browser
    cp mozilla-1.9.1/browser/locales/en-US/profile/chrome/userC* tl/browser/profile/chrome
    cp mozilla-1.9.1/browser/locales/en-US/firefox-l10n.js tl/browser
    cp mozilla-1.9.1/browser/locales/en-US/README.txt tl/browser
    cp mozilla-1.9.1/browser/locales/en-US/searchplugins/list.txt tl/browser/searchplugins
    cp mozilla-1.9.1/browser/locales/en-US/updater/updater.ini tl/browser/updater/updater.ini
    cp mozilla-1.9.1/toolkit/locales/en-US/defines.inc tl/toolkit

  7. Create a mozconfig file, setup your object directory
  8. cd mozilla-1.9.1
    echo “mk_add_options MOZ_OBJDIR=@TOPSRCDIR@/../fx-tl” > .mozconfig
    echo “ac_add_options –with-l10n-base=../” >> .mozconfig
    echo “ac_add_options –disable-compile-environment” >> .mozconfig
    echo “ac_add_options –enable-application=browser” >> .mozconfig
    make -f client.mk configure

  9. Test merge-ab-CD and langpack-ab-CD targets
  10. cd ../fx-tl
    make -C browser/locales merge-tl LOCALE_MERGEDIR=`pwd`/../merge
    make -C browser/locales langpack-tl LOCALE_MERGEDIR=`pwd`/../merge LANGPACK_FILE=`pwd`/../firefox-tl.xpi

If everything went well, you should be ready to translate now!