Mobile/Fennec/Android: Difference between revisions

No edit summary
Line 219: Line 219:


=== Multilocale builds ===
=== Multilocale builds ===
<p><b>NOTE: These instructions are still in development. They do not work yet
* Create a directory, clone mozharness, copy the config file for easy editing/usage:
</b></p><p>Pull the locale you want to build. For this, I'm pulling the ar locale, but you could do this for multiple different locales if you want:
<pre>
</p>
mkdir multilocale
<pre class="_fck_mw_lspace"> hg clone http://hg.mozilla.org/l10n-central/ar
cd multilocale
</pre>
hg clone http://hg.mozilla.org/build/mozharness
<p>You'll need to specify the location of your l10n directory in your mozconfig with
cp mozharness/configs/multi_locale/standalone_mozilla-central.py myconfig.py
</p>
<pre class="_fck_mw_lspace"> ac_add_options --with-l10n-base=&quot;ABS_PATH_TO_L10N_CENTRAL&quot;
</pre>
<p>You'll also need to install the &lt;a _fcknotitle="true" href="Compare-locales"&gt;Compare-locales&lt;/a&gt; scripts. Its easiest to just use easy_install on Ubuntu:
</p>
<pre class="_fck_mw_lspace"> sudo apt-get install python-setuptools
sudo easy_install -U compare-locales
</pre>
<p>Merge it with the english locales (to fill in missing strings)
</p>
<pre class="_fck_mw_lspace"> compare-locales OBJ_DIR/mobile/android/locales/l10n.ini ar
// This should do the same, but doesn't work for me...
//make -C OBJ_DIR/mobile/android/locales/ merge-ar LOCALE_MERGEDIR=ABS_PATH_TO_L10N_CENTRAL/mobile/android/locales/merge-ar
</pre>
<p>build
</p>
<pre class="_fck_mw_lspace"> export MOZ_CHROME_MULTILOCALE=&quot;ar en-US&quot;
make -C OBJ_DIR package AB_CD=multi
</pre>
</pre>
* Edit myconfig.py
** currently will check out m-c into a directory named 'mozilla-central' in this directory
** currently assumes your mozconfig is in this directory and named 'mozconfig'
** currently assumes your mozconfig sets your objdir name to 'objdir-droid'
* pull mozilla-central
mozharness/scripts/multil10n.py --cfg myconfig.py --pull-build-source
# Alternately, you can hg clone http://hg.mozilla.org/mozilla-central
* Run the script, which will create a multilocale apk
mozharness/scripts/multil10n.py --cfg myconfig.py
And you're done.
* If you want to recompile or re-run the script, restore your objdir to en-US first!
mozharness/scripts/multil10n.py --cfg myconfig.py --restore-objdir
Also see [http://escapewindow.dreamwidth.org/234671.html this blog post] for more information.


== Testing  ==
== Testing  ==
Confirmed users
4,971

edits