Closed
Bug 1413240
Opened 7 years ago
Closed 7 years ago
Support webext language packs in Fennec
Categories
(Core :: Internationalization, enhancement, P3)
Core
Internationalization
Tracking
()
RESOLVED
FIXED
mozilla59
Tracking | Status | |
---|---|---|
firefox59 | --- | fixed |
People
(Reporter: zbraniecki, Assigned: cnevinchen)
References
Details
(Whiteboard: [FNC][SPT59.3][INT])
Attachments
(1 file)
In bug 1395363 we switched Firefox to use webextension based language packs. They also seem to work in Thunderbird and Seamonkey.
Next step is to make them work in Fennec.
The steps to build a German language pack on desktop:
1) ./mach build
2) ./mach build langpack-de
3) The result file is in `objdir/dist/platform/xpi/`
Installing:
1) Select the file (drag&drop or File>Open)
2) Install the langpack
3) In browser console type `Services.locale.setRequestedLocales(['de']);`
From that moment every new window will use German string.
I don't know where this breaks on Fennec and how far are we from this working on Fennec.
Reporter | ||
Comment 1•7 years ago
|
||
Nevin, this is I believe the first step.
If you don't get to play with it, I'll look into this over the next weeks.
I believe that once we figure that out, next steps will be to build code to install langpacks into Fennec on demand, and then hook it into the language picker in Fennec.
Flags: needinfo?(cnevinchen)
Assignee | ||
Comment 2•7 years ago
|
||
I got below message and the build stops.
nechen@nechen-30058:~/Desktop/mozilla-central$ ./mach build langpack-de
0:00.25 /usr/bin/make -C /Users/nechen/Desktop/mozilla-central/objdir-frontend -j8 -s backend
0:00.40 /usr/bin/make -j8 -s langpack-de
0:00.48 make: *** No rule to make target `langpack-de'. Stop.
Not sure if it related to artifact build. I'll use full build tomorrow.
Comment 3•7 years ago
|
||
Yes, artifact builds are not supported by l10n repacks, that's tracked in bug 1387485.
Assignee | ||
Comment 4•7 years ago
|
||
I got some build error and trying it fix it bug 1416058
Assignee: nobody → cnevinchen
Assignee | ||
Comment 5•7 years ago
|
||
I can now do full build. But I got this error
0:00.34 /usr/bin/make -C /Users/nechen/Desktop/mozilla-central/objdir-full-b04669e98 -j8 -s backend
0:00.48 /usr/bin/make -j8 -s langpack-de
0:00.57 make: *** No rule to make target `langpack-de'. Stop.
After I look at the code, I found this
https://hg.mozilla.org/mozilla-central/annotate/0ef6d21da190/mobile/android/build.mk#l54 with bug 1412983
May I know how can I help to make langpack-% work on Fennec?
Flags: needinfo?(nfroyd)
Reporter | ||
Comment 6•7 years ago
|
||
Nick, you know more about mobile build system. Can you help us figure out what we need to make langpack-de work for mobile?
Flags: needinfo?(nalexander)
Comment 8•7 years ago
|
||
(In reply to Zibi Braniecki [:gandalf][:zibi] from comment #6)
> Nick, you know more about mobile build system. Can you help us figure out
> what we need to make langpack-de work for mobile?
I can try to help, but I can't commit to any schedule since I'm technically on leave until January. I think you want to start by understanding https://searchfox.org/mozilla-central/source/mobile/android/build.mk#59, and in particular what happens if you make that look like https://searchfox.org/mozilla-central/source/browser/build.mk#43.
But I haven't tried this myself, so I don't know where the rabbit hole leads. In principle, there's nothing exciting happening in Android land that should make this challenging. In reality, I expect there to be crufty Desktop l10n code that needs to be extracted into toolkit/ or similar.
Flags: needinfo?(nalexander)
Comment hidden (mozreview-request) |
Reporter | ||
Comment 10•7 years ago
|
||
Thank you Nick!
I opened bug 1425689 to move the searchplugins resource entry out of locale package (same as we did for browser in bug 1393848), and will test it on my android setup over the next days, but visually the patch looks great :)
Reporter | ||
Comment 11•7 years ago
|
||
mozreview-review |
Comment on attachment 8937215 [details]
Bug 1413240 - Build webext langpack for mobile/android.
https://reviewboard.mozilla.org/r/207934/#review213836
Verified that it produces a langpack that can be then installed into Fennec and gives the localized (Gecko) UI! :)
I'm slightly surprised that in the result .xpi file we have the ./chrome/ab_CD/locale/ab_CD/browser/* directories and files - I expected the ./browser resources not to be loaded here, but maybe they're needed?
Attachment #8937215 -
Flags: review?(gandalf) → review+
Reporter | ||
Comment 12•7 years ago
|
||
mozreview-review |
Comment on attachment 8937215 [details]
Bug 1413240 - Build webext langpack for mobile/android.
https://reviewboard.mozilla.org/r/207934/#review214068
::: python/mozbuild/mozbuild/action/langpack_manifest.py:25
(Diff revision 1)
> import mozversioncontrol
> import mozpack.path as mozpath
> from mozpack.chrome.manifest import (
> Manifest,
> ManifestLocale,
> + ManifestResource,
I believe you can now remove that part :)
Comment hidden (mozreview-request) |
Comment 14•7 years ago
|
||
mozreview-review-reply |
Comment on attachment 8937215 [details]
Bug 1413240 - Build webext langpack for mobile/android.
https://reviewboard.mozilla.org/r/207934/#review214068
> I believe you can now remove that part :)
Done :)
Comment 15•7 years ago
|
||
Pushed by nalexander@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/d2c11314f956
Build webext langpack for mobile/android. r=gandalf
Comment 16•7 years ago
|
||
bugherder |
Status: NEW → RESOLVED
Closed: 7 years ago
status-firefox59:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla59
Updated•7 years ago
|
Whiteboard: [FNC][SPT59.3][INT]
You need to log in
before you can comment on or make changes to this bug.
Description
•