Bug 1223385 - use in-tree compare-locales in Makefiles, r=gps draft
authorJustin Wood <Callek@gmail.com>
Fri, 08 Jul 2016 11:59:27 -0400
changeset 385582 a436c68e9a0c39d233514ea1d9a77c489ed99268
parent 385581 0a19b60b4e0a4e9c30975c558c8039201b09a454
child 385583 2a8dd392a5ce83734d084f95c12274a81954e718
push id22538
push userCallek@gmail.com
push dateFri, 08 Jul 2016 17:03:11 +0000
reviewersgps
bugs1223385
milestone50.0a1
Bug 1223385 - use in-tree compare-locales in Makefiles, r=gps Also fix that the default merge dir in the mach command creates a directory that's the merge make target, and thus keeps that make target from actually running. MozReview-Commit-ID: HWZBPxWuHSy
b2g/locales/Makefile.in
browser/locales/Makefile.in
mobile/android/locales/Makefile.in
python/compare-locales/mach_commands.py
--- a/b2g/locales/Makefile.in
+++ b/b2g/locales/Makefile.in
@@ -131,17 +131,17 @@ ident:
 	@printf 'b2g_revision '
 	@$(PYTHON) $(topsrcdir)/config/printconfigsetting.py $(B2G_APPLICATION_INI_PATH) App SourceStamp
 	@printf 'buildid '
 	@$(PYTHON) $(topsrcdir)/config/printconfigsetting.py $(B2G_APPLICATION_INI_PATH) App BuildID
 
 merge-%:
 ifdef LOCALE_MERGEDIR
 	$(RM) -rf $(LOCALE_MERGEDIR)
-	MACOSX_DEPLOYMENT_TARGET= compare-locales -m $(LOCALE_MERGEDIR) $(srcdir)/l10n.ini $(L10NBASEDIR) $*
+	$(topsrcdir)/mach compare-locales --merge-dir $(LOCALE_MERGEDIR) $*
 endif
 	@echo
 
 # test target, depends on make package
 # try to repack x-test, with just toolkit/defines.inc being there
 l10n-check::
 	$(RM) -rf x-test
 	$(NSINSTALL) -D x-test/toolkit
--- a/browser/locales/Makefile.in
+++ b/browser/locales/Makefile.in
@@ -183,17 +183,17 @@ ident:
 	    $(STAGEDIST)/application.ini App SourceStamp
 	@printf 'buildid '
 	@$(PYTHON) $(topsrcdir)/config/printconfigsetting.py \
 	    $(STAGEDIST)/application.ini App BuildID
 
 merge-%:
 ifdef LOCALE_MERGEDIR
 	$(RM) -rf $(LOCALE_MERGEDIR)
-	MACOSX_DEPLOYMENT_TARGET= compare-locales -m $(LOCALE_MERGEDIR) $(srcdir)/l10n.ini $(L10NBASEDIR) $*
+	$(topsrcdir)/mach compare-locales --merge-dir $(LOCALE_MERGEDIR) $*
 endif
 	@echo
 
 # test target, depends on make package
 # try to repack x-test, with just toolkit/defines.inc being there
 l10n-check:: INNER_UNMAKE_PACKAGE=true
 l10n-check::
 	$(RM) -rf x-test
--- a/mobile/android/locales/Makefile.in
+++ b/mobile/android/locales/Makefile.in
@@ -77,11 +77,11 @@ ident:
 	@printf 'fennec_revision '
 	@$(PYTHON) $(topsrcdir)/config/printconfigsetting.py $(FENNEC_APPLICATION_INI_PATH) App SourceStamp
 	@printf 'buildid '
 	@$(PYTHON) $(topsrcdir)/config/printconfigsetting.py $(FENNEC_APPLICATION_INI_PATH) App BuildID
 
 merge-%:
 ifdef LOCALE_MERGEDIR
 	$(RM) -rf $(LOCALE_MERGEDIR)
-	MACOSX_DEPLOYMENT_TARGET= compare-locales -m $(LOCALE_MERGEDIR) $(srcdir)/l10n.ini $(L10NBASEDIR) $*
+	$(topsrcdir)/mach compare-locales --merge-dir $(LOCALE_MERGEDIR) $*
 endif
 	@echo
--- a/python/compare-locales/mach_commands.py
+++ b/python/compare-locales/mach_commands.py
@@ -65,17 +65,17 @@ class CompareLocales(MachCommandBase):
 
         if not merge_dir:
             try:
                 # self.substs is raising an Exception if we're not configured
                 # don't merge if we're not
                 merge_dir = mozpath.join(
                     self.topobjdir,
                     self.substs['MOZ_BUILD_APP'],
-                    'locales', 'merge-{ab_CD}'
+                    'locales', 'merge-dir-{ab_CD}'
                 )
             except Exception:
                 pass
 
         app = EnumerateApp(l10n_ini, l10n_base, locales)
         observer = compareApp(app, merge_stage=merge_dir,
                               clobber=True)
         print(observer.serialize().encode('utf-8', 'replace'))