Closed Bug 523856 Opened 12 years ago Closed 11 years ago

Localized builds on WinCE


(Firefox Build System :: General, defect, P2)

3.6 Branch
Windows CE


(status1.9.2 final-fixed)

Tracking Status
status1.9.2 --- final-fixed


(Reporter: vlad, Assigned: Dolske)



(Whiteboard: [l10n][nv])


(2 files, 1 obsolete file)

What's involved in creating localized builds for WinCE?  We had a request come in for an Indonesian build (id), and I'm just looking for a rough time schedule.
Whiteboard: [l10n]
If I was to start today I would say a couple of weeks if the "make installers-locale" stuff is already in place and working properly.
We don't have Makefile logic to repack cab's.

For fennec, folks are not really fond of cabs anyway, so it really depends on:

What's a Firefox build on WinCE?

If it's cabs, doing cab will require someone that knows cabs to do it, basically, nobody in the l10n nor in the releng team have the background knowledge on that.
Creating a CAB file is not an issue; if we can get zip files created, we can turn those into CABs as needed.  The same bits end up on the disk, so updates are not affected.
If it's just for testing purposes, the langpacks on ftp should work fine.
Component: Release Engineering → Release Engineering: Future
Any update on this?

Armen, what do I need to do to test and see whether the current code works correctly?  Just run make installers-locale?  Do I need to check out the locales anywhere?
Vlad this script should give you an idea more or less of what is needed:
It might be slightly out-of-date but it pretty much works like that.

If you don't use --disable-compile-environment you will have make few more things. Let me know.

make installers-locale is the step that will do the work. You should find the installers under "dist".

Ping me if you have any questions.
Script seems to work just fine, though I'm not quite getting the right branch from the locale dir or something.  Like it's complaining about missing chrome/global/aboutRights.dtd,, and aboutSupport.dtd in l10n-central/id/toolkit (I'm using the 1.9.2 tag in the id locale).  When I manually put those files back in, it happily generated
I should say, for clarity -- it correctly downloaded the zip build and repackaged it into a .id zip build without problems.
If you look at the dashboard you could see that depending which locale you choose it will work smoothly and if not you should use compare-locale to generate a merged folder.

If the locale doesn't have everything that en-US it creates a folder called "merged" (which will contain no missing entities or files):
python ../../../compare-locales/scripts/compare-locales -m merged l10n.ini ../../../l10n-central or
(in dir /builds/moz2_slave/mozilla-central-linux-l10n-nightly/build/mozilla-central/browser/locales)

Make installers will check to see if the LOCALE_MERGEDIR exists and then uses that directory instead of the locale's checkout:
make installers-or LOCALE_MERGEDIR=$PWD/merged
(in dir /builds/moz2_slave/mozilla-central-linux-l10n-nightly/build/mozilla-central/browser/locales)
There was some discussion about this in #build today in ref. to a requested Indonesian repack. 

Vlad: should we be re-prioritizing this out of Future? What's the horizon on this? There are some other priorities here if it's helpful:
I don't know, tbh -- it all depends on a real estimate for time to get this set up.  It seems like our current zip repack infrastructure "just works", so I don't know if it's a matter of twiddling a config file, or something more involved than that.  Ideally I need to produce an Indonesian l10n build today, which I can do (and planned to do) manually, if need be.
I think we should reprioritize this up, because (1) we need to ship a localized 3.6 build one WinCE and (2) this should be a small project.

As vlad noted, producing a localized .zip build is already working when run manually. I just got it working too, no changes needed. So I think the only notable tasks here should be:

1) Modify build config to trigger creation of L10N builds for WinCE, like other platforms (just a matter of adding "wince" to "l10nPlatforms"?

2) Add a repackage-cab-% target to browser/locales/, and glue to feed it an existing .cab. [Basically, a .cab specific version of the existing repackage-zip-% target / .zip glue].

The latter of these is just mozilla-central code, so I'll go ahead and work on fixing that. I think once that's done, this should all Just Work.
Whiteboard: [l10n] → [l10n][nv]
Attached patch Patch v.1 (obsolete) — Splinter Review
This seems to be the easiest, if slightly hacky, fix to cause "make installers-AB_CD" to repack cabs, yielding an appropriately named .CAB in $DIST. It's basically just leveraging the existing ZIP repack, since the CAB generation wants the exact same directory tree as input.

I tried making a repackage-cab target, but that would require some rejiggering of repackage-zip so that we could ensure the same dir tree is being fed to both (ie, lest someone make changes to repackage-zip but not repackage-cab). Calling "make package MOZ_PKG_FORMAT=CAB" also suffers from wanting to do more work than is needed, so it seemed easier to just call the script directly.

Hopefully this is a good enough start that someone more familiar with the build and releng bits can easily complete this.
Attachment #412350 - Attachment is patch: true
Attachment #412350 - Attachment mime type: application/octet-stream → text/plain
Justin, do you know if the name you pass for the .inf file should be the localized display name or the non-localized appname? Like, on desktop, we install into the Firefox dir, but the desktop links are localized names.
Pike: Looks like it currently should be the non-localized name, as the generated inf in my tree gets:

AppName = "Namoroka"
InstallDir = %CE1%\%AppName%

We could modify the script to take both, though, and use the localized one for "AppName" and the non-localized one for "InstallDir".

Does "Mozilla" get localized? Right now that's hardcoded in the script, and could also become an argument if needed...
I will look into this next week. I have a working patch to add a nightly builder which needs a day or two of proper testing and debugging. Adding the nightly builder will help me get the right idea of how much work is needed for the release builder.

Justin can we get the patch attached reviewed and landed? The release side needs those targets to call them.
Assignee: nobody → armenzg
Priority: -- → P2
Assignee: armenzg → nobody
Component: Release Engineering: Future → Release Engineering
Attached patch Patch v.2Splinter Review
Reworked version of last patch; I didn't want to split the CAB creation into two places because they'd inevitably get out of sync.
Attachment #412350 - Attachment is obsolete: true
Attachment #414689 - Flags: review?(vladimir)
Blocks: 531275
No longer blocks: 531275
Component: Release Engineering → Build Config
Product: → Firefox
QA Contact: release → build.config
Version: other → 3.6 Branch
Changing ownership and product/component of the bug after filing bug 531275 which will tackle the Release Engineering specific tasks to make this happen.
Assignee: nobody → dolske
Comment on attachment 414689 [details] [diff] [review]
Patch v.2

This patch looks good to me.
Blocks: 531275
Attachment #414689 - Flags: review?(vladimir) → review+
Comment on attachment 414689 [details] [diff] [review]
Patch v.2

Attachment #414689 - Flags: approval1.9.2+
Pushed to 192:

Followup work in bug 531275 to actually start producing localized nightlies.
Closed: 11 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 3.7a1
>diff --git a/toolkit/mozapps/installer/ b/toolkit/mozapps/installer/

This change breaks en-US release builds by leaving the cab in the wrong place for uploading, see bug 535019 comment 6. The problem is that $(PACKAGE) includes $(PKG_PATH), which is set for the release case. 

Do you recall why this change was made ?
Resolution: FIXED → ---
Yeah, because this code path is only run once, and generates both ZIP and CAB in one shot. So $(PACKAGE) here is ".../", whereas we want ".../"

I suppose the alternative would be to so something like $(, or $(SOMETHING_FULL_PATH)$(PKG_BASENAME)?
Attached patch Fix release caseSplinter Review
I think this should work because $(PKG_PATH) is empty except in the release case. It's fragile w.r.t 
in toolkit/mozapps/installer/ changing. Perhaps a sed -e 's/zip$/cab/' on $(PACKAGE) instead ?
Attachment #418776 - Flags: review?
Comment on attachment 418776 [details] [diff] [review]
Fix release case

Ted, this will unbreak the location release cab's are placed, so we get them uploaded automatically. We can work around this for 3.6rc1 if it's too late but will need it to make localised releases work (coming as soon as dolske and armen get that figured out). Please see comment #24 for more comments.

I'd like to ask for approval1.9.2 but that seems to be disabled.
Attachment #418776 - Flags: review?(ted.mielczarek)
Attachment #418776 - Flags: review?(ted.mielczarek) → review+
Comment on attachment 418776 [details] [diff] [review]
Fix release case

Attachment #418776 - Flags: approval1.9.2+
Closed: 11 years ago11 years ago
Resolution: --- → FIXED
Component: Build Config → General
Product: Firefox → Firefox Build System
Target Milestone: Firefox 3.7a1 → mozilla3.7a1
You need to log in before you can comment on or make changes to this bug.