Skip to content

Commit

Permalink
Backout revision e95f8bd7b519 and 84091f931dff (bug 1385227) for brea…
Browse files Browse the repository at this point in the history
…king Beta release automation.
  • Loading branch information
Pike committed Sep 16, 2017
1 parent d51bc95 commit f0543ab
Show file tree
Hide file tree
Showing 4 changed files with 64 additions and 47 deletions.
65 changes: 38 additions & 27 deletions browser/locales/Makefile.in
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,8 @@ PWD := $(CURDIR)
# These are defaulted to be compatible with the files the wget-en-US target
# pulls. You may override them if you provide your own files.
ZIP_IN ?= $(ABS_DIST)/$(PACKAGE)
WIN32_INSTALLER_IN ?= $(ABS_DIST)/$(PKG_INST_PATH)$(PKG_INST_BASENAME).exe
RETRIEVE_WINDOWS_INSTALLER = 1

MOZ_LANGPACK_EID=langpack-$(AB_CD)@firefox.mozilla.org
# For Nightly, we know where to get the builds from to do local repacks
Expand All @@ -41,6 +43,21 @@ endif
MOZ_SFX_PACKAGE=$(topsrcdir)/other-licenses/7zstub/firefox/7zSD.sfx
MOZ_INSTALLER_PATH=$(topsrcdir)/browser/installer/windows

ifeq (WINNT,$(OS_ARCH))
UNINSTALLER_PACKAGE_HOOK = $(RM) -r $(STAGEDIST)/uninstall; \
$(NSINSTALL) -D $(STAGEDIST)/uninstall; \
cp ../installer/windows/l10ngen/helper.exe $(STAGEDIST)/uninstall; \
$(RM) $(ABS_DIST)/l10n-stage/setup.exe; \
cp ../installer/windows/l10ngen/setup.exe $(ABS_DIST)/l10n-stage; \
$(NULL)

STUB_HOOK = $(NSINSTALL) -D '$(ABS_DIST)/$(PKG_INST_PATH)'; \
$(RM) '$(ABS_DIST)/$(PKG_INST_PATH)$(PKG_STUB_BASENAME).exe'; \
cp ../installer/windows/l10ngen/stub.exe '$(ABS_DIST)/$(PKG_INST_PATH)$(PKG_STUB_BASENAME).exe'; \
chmod 0755 '$(ABS_DIST)/$(PKG_INST_PATH)$(PKG_STUB_BASENAME).exe'; \
$(NULL)
endif

SEARCHPLUGINS_FILENAMES := $(shell $(call py_action,output_searchplugins_list,$(srcdir)/search/list.json $(AB_CD)))
SEARCHPLUGINS_PATH := .deps/generated_$(AB_CD)
SEARCHPLUGINS_TARGET := libs searchplugins
Expand Down Expand Up @@ -118,25 +135,26 @@ ifdef NIGHTLY_BUILD
@$(MAKE) -C ../extensions/webcompat-reporter/locales chrome AB_CD=$*
endif

package-win32-installer: WIN32_INSTALLER_OUT=$(ABS_DIST)/$(PKG_INST_PATH)$(PKG_INST_BASENAME).exe
package-win32-installer: MOZ_PKG_FORMAT=SFX7Z
package-win32-installer: $(SUBMAKEFILES)
@echo 'Packaging $(WIN32_INSTALLER_OUT).'
repackage-win32-installer: WIN32_INSTALLER_OUT=$(ABS_DIST)/$(PKG_INST_PATH)$(PKG_INST_BASENAME).exe
repackage-win32-installer: $(call ESCAPE_WILDCARD,$(WIN32_INSTALLER_IN)) $(SUBMAKEFILES) libs-$(AB_CD)
@echo 'Repackaging $(WIN32_INSTALLER_IN) into $(WIN32_INSTALLER_OUT).'
$(MAKE) -C $(DEPTH)/$(MOZ_BRANDING_DIRECTORY) export
$(MAKE) -C ../installer/windows CONFIG_DIR=l10ngen l10ngen/setup.exe l10ngen/7zSD.sfx
$(RM) -r $(STAGEDIST)/uninstall
$(NSINSTALL) -D $(STAGEDIST)/uninstall
cp ../installer/windows/l10ngen/helper.exe $(STAGEDIST)/uninstall
$(RM) $(ABS_DIST)/l10n-stage/setup.exe
cp ../installer/windows/l10ngen/setup.exe $(ABS_DIST)/l10n-stage
$(NSINSTALL) -D '$(ABS_DIST)/$(PKG_INST_PATH)'
(cd $(DIST)/l10n-stage; \
$(MAKE_PACKAGE))
mv -f '$(DIST)/l10n-stage/$(PACKAGE)' '$(WIN32_INSTALLER_OUT)'
if test -f '$(DIST)/l10n-stage/$(PACKAGE).asc'; then mv -f '$(DIST)/l10n-stage/$(PACKAGE).asc' '$(WIN32_INSTALLER_OUT).asc'; fi
ifdef MOZ_STUB_INSTALLER
$(RM) '$(ABS_DIST)/$(PKG_INST_PATH)$(PKG_STUB_BASENAME).exe'
cp ../installer/windows/l10ngen/stub.exe '$(ABS_DIST)/$(PKG_INST_PATH)$(PKG_STUB_BASENAME).exe'
chmod 0755 '$(ABS_DIST)/$(PKG_INST_PATH)$(PKG_STUB_BASENAME).exe'
$(MAKE) repackage-zip \
AB_CD=$(AB_CD) \
MOZ_PKG_FORMAT=SFX7Z \
ZIP_IN='$(WIN32_INSTALLER_IN)' \
ZIP_OUT='$(WIN32_INSTALLER_OUT)' \
SFX_HEADER='$(PWD)/../installer/windows/l10ngen/7zSD.sfx \
$(topsrcdir)/browser/installer/windows/app.tag'

ifeq (WINNT,$(OS_ARCH))
repackage-win32-installer-%: unpack
@$(MAKE) repackage-win32-installer AB_CD=$* WIN32_INSTALLER_IN='$(WIN32_INSTALLER_IN)'

repackage-zip-%: repackage-win32-installer-%
else
repackage-win32-installer-%: ;
endif


Expand All @@ -147,14 +165,7 @@ langpack: langpack-$(AB_CD)
# tinderbox scripts. Alter it with caution.

installers-%: IS_LANGUAGE_REPACK=1
installers-%:
@$(MAKE) clobber-$*
@$(MAKE) libs-$*
@$(MAKE) package-langpack-$*
@$(MAKE) repackage-zip-$*
ifeq (WINNT,$(OS_ARCH))
@$(MAKE) package-win32-installer AB_CD=$*
endif
installers-%: clobber-% langpack-% repackage-win32-installer-% repackage-zip-%
@echo 'repackaging done'

ifdef MOZ_UPDATER
Expand Down Expand Up @@ -201,7 +212,7 @@ l10n-check::
@# not being reset, overwriting the value they would get with MOZ_SIMPLE_PACKAGE_NAME
@# reset.
$(MAKE) installers-x-test L10NBASEDIR='$(PWD)' \
ZIP_IN='$(ZIP_IN)' MOZ_SIMPLE_PACKAGE_NAME=
ZIP_IN='$(ZIP_IN)' WIN32_INSTALLER_IN='$(WIN32_INSTALLER_IN)' MOZ_SIMPLE_PACKAGE_NAME=
$(PYTHON) $(topsrcdir)/toolkit/mozapps/installer/unpack.py $(DIST)/l10n-stage/$(MOZ_PKG_DIR)$(_RESPATH)
(cd $(DIST)/l10n-stage && test $$(cat $(MOZ_PKG_DIR)$(_RESPATH)/update.locale) = x-test)
@# package langpack as web extension, too, run some tests on it
Expand Down
5 changes: 1 addition & 4 deletions mobile/android/locales/Makefile.in
Original file line number Diff line number Diff line change
Expand Up @@ -59,10 +59,7 @@ endif
# builds. It is called from the tinderbox scripts. Alter it with caution.

installers-%: IS_LANGUAGE_REPACK=1
installers-%:
@$(MAKE) clobber-stage
@$(MAKE) libs-$*
@$(MAKE) repackage-zip-$*
installers-%: clobber-stage repackage-zip-%
@echo 'repackaging done'

# When we unpack fennec on MacOS X the platform.ini and application.ini are in slightly
Expand Down
35 changes: 22 additions & 13 deletions toolkit/locales/l10n.mk
Original file line number Diff line number Diff line change
Expand Up @@ -111,8 +111,22 @@ endif
# may be overridden if necessary.
MOZDEPTH ?= $(DEPTH)

ifdef MOZ_MAKE_COMPLETE_MAR
MAKE_COMPLETE_MAR = 1
ifeq ($(OS_ARCH), WINNT)
ifneq ($(MOZ_PKG_FORMAT), SFX7Z)
MAKE_COMPLETE_MAR =
endif
endif
endif
repackage-zip: UNPACKAGE='$(ZIP_IN)'
repackage-zip:
repackage-zip: libs-$(AB_CD)
# call a hook for apps to put their uninstall helper.exe into the package
$(UNINSTALLER_PACKAGE_HOOK)
# call a hook for apps to build the stub installer
ifdef MOZ_STUB_INSTALLER
$(STUB_HOOK)
endif
$(PYTHON) $(MOZILLA_DIR)/toolkit/mozapps/installer/l10n-repack.py $(STAGEDIST) $(DIST)/xpi-stage/locale-$(AB_CD) \
$(MOZ_PKG_EXTRAL10N) \
$(if $(filter omni,$(MOZ_PACKAGER_FORMAT)),$(if $(NON_OMNIJAR_FILES),--non-resource $(NON_OMNIJAR_FILES)))
Expand All @@ -132,9 +146,9 @@ endif
endif

$(NSINSTALL) -D $(DIST)/l10n-stage/$(PKG_PATH)
(cd $(DIST)/l10n-stage; \
$(MAKE_PACKAGE))
ifdef MOZ_MAKE_COMPLETE_MAR
cd $(DIST)/l10n-stage; \
$(MAKE_PACKAGE)
ifdef MAKE_COMPLETE_MAR
$(MAKE) -C $(MOZDEPTH)/tools/update-packaging full-update AB_CD=$(AB_CD) \
PACKAGE_BASE_DIR='$(ABS_DIST)/l10n-stage'
endif
Expand Down Expand Up @@ -193,18 +207,13 @@ endif
$(RM) -rf $(REAL_LOCALE_MERGEDIR)
$(MOZILLA_DIR)/mach compare-locales --l10n-base $(L10NBASEDIR) --merge-dir $(REAL_LOCALE_MERGEDIR) $*

langpack-%: LANGPACK_FILE=$(ABS_DIST)/$(PKG_LANGPACK_PATH)$(PKG_LANGPACK_BASENAME).xpi
langpack-%: AB_CD=$*
langpack-%: XPI_NAME=locale-$*
langpack-%: IS_LANGUAGE_REPACK=1
langpack-%: IS_LANGPACK=1
langpack-%: AB_CD=$*
langpack-%:
langpack-%: libs-%
@echo 'Making langpack $(LANGPACK_FILE)'
@$(MAKE) libs-$(AB_CD)
@$(MAKE) package-langpack-$(AB_CD)

package-langpack-%: LANGPACK_FILE=$(ABS_DIST)/$(PKG_LANGPACK_PATH)$(PKG_LANGPACK_BASENAME).xpi
package-langpack-%: XPI_NAME=locale-$*
package-langpack-%: AB_CD=$*
package-langpack-%:
$(NSINSTALL) -D $(DIST)/$(PKG_LANGPACK_PATH)
ifdef WEBEXT_LANGPACKS
$(call py_action,langpack_manifest,--locales $(AB_CD) --min-app-ver $(MOZ_APP_VERSION) --max-app-ver $(MOZ_APP_MAXVERSION) --app-name "$(MOZ_APP_DISPLAYNAME)" --defines $(NEW_APP_DEFINES) --input $(DIST)/xpi-stage/locale-$(AB_CD))
Expand Down
6 changes: 3 additions & 3 deletions tools/update-packaging/Makefile.in
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,9 @@ full-update:: complete-patch
ifeq ($(OS_TARGET), WINNT)
MOZ_PKG_FORMAT := SFX7Z
UNPACKAGE = '$(subst $(DIST),$(ABS_DIST),$(INSTALLER_PACKAGE))'
ifdef AB_CD
UNPACKAGE = '$(PACKAGE_BASE_DIR)/$(PACKAGE)'
endif
endif

include $(topsrcdir)/config/rules.mk
Expand All @@ -43,13 +46,10 @@ endif
dir-stage := $(call mkdir_deps,$(STAGE_DIR))

complete-patch:: $(dir-stage)
# unpack the windows installer, unless we're an l10n repack, we just packed this
ifndef IS_LANGUAGE_REPACK
ifeq ($(OS_TARGET), WINNT)
test -f $(UNPACKAGE)
$(RM) -rf '$(PACKAGE_DIR)'
cd $(PACKAGE_BASE_DIR) && $(INNER_UNMAKE_PACKAGE)
endif
endif
MAR=$(MAR_BIN) \
MOZ_PRODUCT_VERSION=$(MOZ_APP_VERSION) \
Expand Down

0 comments on commit f0543ab

Please sign in to comment.