Closed Bug 659379 Opened 13 years ago Closed 13 years ago

Localized files not ordered in l10n omnijars

Categories

(Firefox Build System :: General, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: mwu, Assigned: mwu)

References

Details

Attachments

(1 file)

As Pike mentioned in bug 641614, we can't do s/en-US/$(AB_CD)/ since we don't unpack between repacks.
This patch stores jarlogs in their own locale specific directories to ensure we can always s/en-US/$(AB_CD)/. I added a JARLOG_DIR_AB_CD but it's not needed anymore and can be replaced with $(JARLOG_DIR)/$(AB_CD) if that's preferred.
Attachment #535090 - Flags: review?(ted.mielczarek)
Comment on attachment 535090 [details] [diff] [review]
Use per-locale jarlog directories

Review of attachment 535090 [details] [diff] [review]:
-----------------------------------------------------------------

r=me with one important change.

::: client.mk
@@ -211,4 @@
>  profiledbuild::
>  	$(MAKE) -f $(TOPSRCDIR)/client.mk realbuild MOZ_PROFILE_GENERATE=1
>  	$(MAKE) -C $(PGO_OBJDIR) package
> -	OBJDIR=${PGO_OBJDIR} $(PROFILE_GEN_SCRIPT)

Please don't change this, it's possible for people to use alternative profile generation scripts.

::: toolkit/locales/l10n.mk
@@ +139,5 @@
>  repackage-zip: UNPACKAGE="$(ZIP_IN)"
>  repackage-zip:  libs-$(AB_CD)
>  # Adjust jar logs with the new locale (can't use sed -i because of bug 373784)
> +	mkdir -p $(JARLOG_DIR_AB_CD)
> +	-cp -r $(JARLOG_DIR)/en-US/*.jar.log $(JARLOG_DIR_AB_CD)

We don't usually use mkdir / cp directly in Makefiles, but I'm not sure if it matters here. There's nothing non-portable in these two lines, is there?
Attachment #535090 - Flags: review?(ted.mielczarek) → review+
I thought that mkdir -p is not portable, but that's really just dark ages under tons of dust.
(In reply to comment #2)
> ::: toolkit/locales/l10n.mk
> @@ +139,5 @@
> >  repackage-zip: UNPACKAGE="$(ZIP_IN)"
> >  repackage-zip:  libs-$(AB_CD)
> >  # Adjust jar logs with the new locale (can't use sed -i because of bug 373784)
> > +	mkdir -p $(JARLOG_DIR_AB_CD)
> > +	-cp -r $(JARLOG_DIR)/en-US/*.jar.log $(JARLOG_DIR_AB_CD)
> 
> We don't usually use mkdir / cp directly in Makefiles, but I'm not sure if
> it matters here. There's nothing non-portable in these two lines, is there?

Just checked and mkdir -p and cp -r appear to be part of posix. Works on tier 1 platforms I know of, at least. Though, it appears that -R is preferred over -r on OSX.
http://hg.mozilla.org/mozilla-central/rev/dc8d154f3710

Used the wrong number though. Bug 641614 instead of this one.
Status: NEW → RESOLVED
Closed: 13 years ago
Resolution: --- → FIXED
Depends on: 663737
Blocks: 1195331
Product: Core → Firefox Build System
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: