Closed Bug 1482060 Opened 6 years ago Closed 6 years ago

FTL files aren't packaged in locales.xpi

Categories

(Thunderbird :: Installer, defect)

defect
Not set
normal

Tracking

(Not tracked)

VERIFIED FIXED
Thunderbird 63.0

People

(Reporter: Paenglab, Unassigned)

Details

The FTL files are missing in the locales XPI. Actually there should be in the root directory a directory named "localiztion" and then below the locale name. Below this there should be the different directories like "crashreporter", "devtools", "messenger" and "toolkit". But they don't exist.

Actually not all locales have translated the our fonts.ftl. In es-ES it exists, so at least this should include it.

Axel proposed:

DIST_SUBDIR wants to be `messenger`, it's set to browser in Firefox.

Probably https://dxr.mozilla.org/comm-central/source/mail/installer/Makefile.in#6 needs to be fixed.

This could IMO fix the messenger part, but why are "crashreporter", "devtools" and "toolkit" from m-c missing?
This seems not to be the right approach. Axel, do you know which script creates the XPI? In normal localized builds the files are at the correct place, so it must be a problem with the XPI packager script.
Flags: needinfo?(l10n)
https://searchfox.org/mozilla-central/source/toolkit/locales/l10n.mk#215 is the code that packages the xpi.

No idea why thunderbird breaks when doing what firefox does on the packager. It doesn't even mention "messenger" in the code log near to the failure.
Flags: needinfo?(l10n)
Should be a job for Rob.
Flags: needinfo?(rob)
As indicated in comment 3, l10n.mk#215 seems to be where the issue manifests. 

$(call py_action,zip,-C $(DIST)/xpi-stage/locale-$(AB_CD) -x **/*.manifest -x **/*.js -x **/*.ini $(LANGPACK_FILE) $(PKG_ZIP_DIRS) manifest.json)

Specifically, $(PKG_ZIP_DIRS) is wrong:

python -m mozbuild.action.zip -C ../../../dist/xpi-stage/locale-uk -x **/*.manifest -x **/*.js -x **/*.ini /home/rob/moz/mozilla-central/obj-x86_64-pc-linux-gnu/dist/linux-x86_64/xpi/thunderbird-63.0a1.uk.langpack.xpi chrome manifest.json

It's apparently set to "chrome", but should include "messenger".

PKG_ZIP_DIRS = chrome $(or $(DIST_SUBDIRS),$(DIST_SUBDIR))

... neither $(DIST_SUBDIRS) nor $(DIST_SUBDIR) are defined.

So the original suggestion of fixing Makefile.in makes the most sense to me. 

This looks interesting...
https://hg.mozilla.org/mozilla-central/file/tip/config/rules.mk#l1258

Short version, if DIST_SUBDIR is defined, use "defaults/preferences" for $(PREF_DIR). When I did define $(DIST_SUBDIR) the error was in regard to missing files under a "preferences" directory.

0:12.59 Error: /home/rob/moz/mozilla-central/comm/mail/installer/package-manifest.in:303: Missing file(s): bin/defaults/preferences/debugger.js

The files it complains about are in a "prefs" directory though.

So I tried defining $(DIST_SUBDIRS) instead, but that didn't work for some reason I've yet to figure out.
(In reply to Rob Lemley [:rjl] from comment #5)
> As indicated in comment 3, l10n.mk#215 seems to be where the issue
> manifests. 
> 
> $(call py_action,zip,-C $(DIST)/xpi-stage/locale-$(AB_CD) -x **/*.manifest
> -x **/*.js -x **/*.ini $(LANGPACK_FILE) $(PKG_ZIP_DIRS) manifest.json)
> 
> Specifically, $(PKG_ZIP_DIRS) is wrong:
> 
> python -m mozbuild.action.zip -C ../../../dist/xpi-stage/locale-uk -x
> **/*.manifest -x **/*.js -x **/*.ini
> /home/rob/moz/mozilla-central/obj-x86_64-pc-linux-gnu/dist/linux-x86_64/xpi/
> thunderbird-63.0a1.uk.langpack.xpi chrome manifest.json
> 
> It's apparently set to "chrome", but should include "messenger".
>

You'll need both, chrome for properties/dtds (chrome://) and messenger for ftl (resource:// for l10n registry)
Are somewhere also Firefox Nightly XPI language packs?
(In reply to Richard Marti (:Paenglab) from comment #7)
> Are somewhere also Firefox Nightly XPI language packs?

http://archive.mozilla.org/pub/firefox/nightly/latest-mozilla-central-l10n/linux-x86_64/xpi/
(In reply to Francesco Lodolo [:flod] from comment #8)
> http://archive.mozilla.org/pub/firefox/nightly/latest-mozilla-central-l10n/
> linux-x86_64/xpi/

They are also not complete. The "crashreporter" and the "toolkit" directories with their FTLs are missing. Only the browser and devtools FTLs are added.
(In reply to Richard Marti (:Paenglab) from comment #9)
> (In reply to Francesco Lodolo [:flod] from comment #8)
> > http://archive.mozilla.org/pub/firefox/nightly/latest-mozilla-central-l10n/
> > linux-x86_64/xpi/
> 
> They are also not complete. The "crashreporter" and the "toolkit"
> directories with their FTLs are missing. Only the browser and devtools FTLs
> are added.

Indeed. 

Localized builds are OK, but language packs are missing FTL files for toolkit (filed bug 1482695)
Apparently fixed by bug 1482695.
Status: NEW → RESOLVED
Closed: 6 years ago
Flags: needinfo?(rob)
Resolution: --- → FIXED
Target Milestone: --- → Thunderbird 63.0
You need to log in before you can comment on or make changes to this bug.