diff --git a/browser/installer/allowed-dupes.mn b/browser/installer/allowed-dupes.mn index 2a8ebd3afb64..3b6020ec93e1 100644 --- a/browser/installer/allowed-dupes.mn +++ b/browser/installer/allowed-dupes.mn @@ -145,6 +145,8 @@ res/table-remove-column.gif res/table-remove-row-active.gif res/table-remove-row-hover.gif res/table-remove-row.gif +res/multilocale.txt +update.locale # Aurora branding browser/chrome/browser/content/branding/icon64.png browser/chrome/devtools/content/framework/dev-edition-promo/dev-edition-logo.png diff --git a/browser/locales/Makefile.in b/browser/locales/Makefile.in index f903bc8f6724..c15931bf7248 100644 --- a/browser/locales/Makefile.in +++ b/browser/locales/Makefile.in @@ -86,7 +86,7 @@ endif @$(MAKE) -C ../../devtools/shim/locales AB_CD=$* XPI_NAME=locale-$* XPI_ROOT_APPID='$(XPI_ROOT_APPID)' @$(MAKE) -B searchplugins AB_CD=$* XPI_NAME=locale-$* @$(MAKE) libs AB_CD=$* XPI_NAME=locale-$* PREF_DIR=$(PREF_DIR) - @$(MAKE) multilocale.json-$* AB_CD=$* XPI_NAME=locale-$* + @$(MAKE) multilocale.txt-$* AB_CD=$* XPI_NAME=locale-$* @$(MAKE) -C $(DEPTH)/$(MOZ_BRANDING_DIRECTORY)/locales AB_CD=$* XPI_NAME=locale-$* chrome-%: AB_CD=$* diff --git a/mobile/android/installer/allowed-dupes.mn b/mobile/android/installer/allowed-dupes.mn index 9959d00e5e27..2ced520e17ed 100644 --- a/mobile/android/installer/allowed-dupes.mn +++ b/mobile/android/installer/allowed-dupes.mn @@ -46,5 +46,7 @@ res/table-remove-column.gif res/table-remove-row-active.gif res/table-remove-row-hover.gif res/table-remove-row.gif +res/multilocale.txt modules/commonjs/index.js chrome/toolkit/content/global/XPCNativeWrapper.js +update.locale diff --git a/mobile/android/locales/Makefile.in b/mobile/android/locales/Makefile.in index 4d91107aaf46..9febfcd33d09 100644 --- a/mobile/android/locales/Makefile.in +++ b/mobile/android/locales/Makefile.in @@ -44,7 +44,7 @@ libs-%: $(if $(filter en-US,$(AB_CD)),, @$(MAKE) merge-$*) @$(MAKE) -C $(DEPTH)/mobile/locales libs-$* @$(MAKE) libs AB_CD=$* XPI_NAME=locale-$* PREF_DIR=defaults/pref - @$(MAKE) multilocale.json-$* AB_CD=$* XPI_NAME=locale-$* + @$(MAKE) multilocale.txt-$* AB_CD=$* XPI_NAME=locale-$* ifeq ($(OS_TARGET),Android) @$(MAKE) -C $(DEPTH)/mobile/android/base/locales AB_CD=$* XPI_NAME=locale-$* endif diff --git a/toolkit/locales/gen_multilocale.py b/toolkit/locales/gen_multilocale.py index 31f598de1364..136c09eee94a 100644 --- a/toolkit/locales/gen_multilocale.py +++ b/toolkit/locales/gen_multilocale.py @@ -4,7 +4,6 @@ from __future__ import print_function, unicode_literals -import json import sys @@ -12,9 +11,8 @@ def main(output, *locales): locales = list(locales) if "en-US" not in locales: locales.append("en-US") - json.dump({ - "locales": locales - }, output) + + print(",".join(locales), file=output) if __name__ == '__main__': diff --git a/toolkit/locales/moz.build b/toolkit/locales/moz.build index e94f04d12bb0..1998838ec212 100644 --- a/toolkit/locales/moz.build +++ b/toolkit/locales/moz.build @@ -16,12 +16,12 @@ if 'gtk' in CONFIG['MOZ_WIDGET_TOOLKIT']: JAR_MANIFESTS += ['jar.mn'] GENERATED_FILES = [ - 'multilocale.json', + 'multilocale.txt', ] -multilocale = GENERATED_FILES['multilocale.json'] +multilocale = GENERATED_FILES['multilocale.txt'] multilocale.script = 'gen_multilocale.py' FINAL_TARGET_FILES.res += [ - '!multilocale.json', + '!multilocale.txt', ] if CONFIG['MOZ_CRASHREPORTER']: diff --git a/toolkit/mozapps/installer/l10n-repack.py b/toolkit/mozapps/installer/l10n-repack.py index f41f2712cb01..a1cdfe0db15e 100644 --- a/toolkit/mozapps/installer/l10n-repack.py +++ b/toolkit/mozapps/installer/l10n-repack.py @@ -24,7 +24,7 @@ NON_CHROME = set([ 'extensions/langpack-*@*', 'distribution/extensions/langpack-*@*', 'chrome/**/searchplugins/*.xml', - '**/multilocale.json' + '**/multilocale.txt' ]) diff --git a/toolkit/mozapps/installer/packager.mk b/toolkit/mozapps/installer/packager.mk index 4c4e73ed8963..49133c9c9beb 100644 --- a/toolkit/mozapps/installer/packager.mk +++ b/toolkit/mozapps/installer/packager.mk @@ -32,7 +32,7 @@ export USE_ELF_HACK ELF_HACK_FLAGS # Override the value of OMNIJAR_NAME from config.status with the value # set earlier in this file. -stage-package: multilocale.json locale-manifest.in $(MOZ_PKG_MANIFEST) $(MOZ_PKG_MANIFEST_DEPS) +stage-package: multilocale.txt locale-manifest.in $(MOZ_PKG_MANIFEST) $(MOZ_PKG_MANIFEST_DEPS) OMNIJAR_NAME=$(OMNIJAR_NAME) \ NO_PKG_FILES="$(NO_PKG_FILES)" \ $(PYTHON) $(MOZILLA_DIR)/toolkit/mozapps/installer/packager.py $(DEFINES) $(ACDEFINES) \ @@ -204,23 +204,23 @@ BASE_PATH:=@RESPATH@ MULTILOCALE_DIR = $(DIST)/$(RESPATH)/res endif -# This version of the target uses MOZ_CHROME_MULTILOCALE to build multilocale.json +# This version of the target uses MOZ_CHROME_MULTILOCALE to build multilocale.txt # and places it in dist/bin/res - it should be used when packaging a build. -multilocale.json: LOCALES?=$(MOZ_CHROME_MULTILOCALE) -multilocale.json: - $(call py_action,file_generate,$(MOZILLA_DIR)/toolkit/locales/gen_multilocale.py main '$(MULTILOCALE_DIR)/multilocale.json' $(MDDEPDIR)/multilocale.json.pp $(ALL_LOCALES)) +multilocale.txt: LOCALES?=$(MOZ_CHROME_MULTILOCALE) +multilocale.txt: + $(call py_action,file_generate,$(MOZILLA_DIR)/toolkit/locales/gen_multilocale.py main '$(MULTILOCALE_DIR)/multilocale.txt' $(MDDEPDIR)/multilocale.txt.pp $(ALL_LOCALES)) -# This version of the target uses AB_CD to build multilocale.json and places it +# This version of the target uses AB_CD to build multilocale.txt and places it # in the $(XPI_NAME)/res dir - it should be used when repackaging a build. -multilocale.json-%: LOCALES?=$(AB_CD) -multilocale.json-%: MULTILOCALE_DIR=$(DIST)/xpi-stage/$(XPI_NAME)/res -multilocale.json-%: - $(call py_action,file_generate,$(MOZILLA_DIR)/toolkit/locales/gen_multilocale.py main '$(MULTILOCALE_DIR)/multilocale.json' $(MDDEPDIR)/multilocale.json.pp $(ALL_LOCALES)) +multilocale.txt-%: LOCALES?=$(AB_CD) +multilocale.txt-%: MULTILOCALE_DIR=$(DIST)/xpi-stage/$(XPI_NAME)/res +multilocale.txt-%: + $(call py_action,file_generate,$(MOZILLA_DIR)/toolkit/locales/gen_multilocale.py main '$(MULTILOCALE_DIR)/multilocale.txt' $(MDDEPDIR)/multilocale.txt.pp $(ALL_LOCALES)) locale-manifest.in: LOCALES?=$(MOZ_CHROME_MULTILOCALE) locale-manifest.in: $(GLOBAL_DEPS) FORCE printf '\n[multilocale]\n' > $@ - printf '$(BASE_PATH)/res/multilocale.json\n' >> $@ + printf '$(BASE_PATH)/res/multilocale.txt\n' >> $@ for LOCALE in $(ALL_LOCALES) ;\ do \ for ENTRY in $(MOZ_CHROME_LOCALE_ENTRIES) ;\