Bug 339714 (part 0) - separate target to generate setup.exe (for l10n repackaging of the NSIS installer) r=robstrong

This commit is contained in:
benjamin%smedbergs.us 2006-06-27 20:27:41 +00:00
Родитель 60bb8803c0
Коммит a27b84bfea
2 изменённых файлов: 16 добавлений и 7 удалений

Просмотреть файл

@ -45,7 +45,7 @@ include $(DEPTH)/config/autoconf.mk
include $(topsrcdir)/toolkit/mozapps/installer/package-name.mk include $(topsrcdir)/toolkit/mozapps/installer/package-name.mk
CONFIG_DIR := $(shell pwd)/instgen CONFIG_DIR = instgen
SFX_MODULE = $(topsrcdir)/other-licenses/7zstub/firefox/7zSD.sfx SFX_MODULE = $(topsrcdir)/other-licenses/7zstub/firefox/7zSD.sfx
PP_LOCALIZED_FILES = \ PP_LOCALIZED_FILES = \
@ -78,6 +78,9 @@ include $(call EXPAND_LOCALE_SRCDIR,toolkit/locales)/installer/windows/charset.m
installer:: installer::
$(MAKE) -C .. installer-stage $(MAKE) -C .. installer-stage
$(MAKE) $(CONFIG_DIR)/setup.exe
$(CONFIG_DIR)/setup.exe::
$(RM) -rf instgen && mkdir instgen $(RM) -rf instgen && mkdir instgen
$(INSTALL) $(addprefix $(srcdir)/,$(INSTALLER_FILES)) instgen $(INSTALL) $(addprefix $(srcdir)/,$(INSTALLER_FILES)) instgen
$(INSTALL) $(addprefix $(DIST)/branding/,$(BRANDING_FILES)) instgen $(INSTALL) $(addprefix $(DIST)/branding/,$(BRANDING_FILES)) instgen

Просмотреть файл

@ -40,9 +40,10 @@
ifndef CONFIG_DIR ifndef CONFIG_DIR
$(error CONFIG_DIR must be set before including makensis.mk) $(error CONFIG_DIR must be set before including makensis.mk)
endif endif
ifndef SFX_MODULE
$(error SFX_MODULE must be set before including makensis.mk) ABS_CONFIG_DIR := $(shell cd $(CONFIG_DIR) && pwd)
endif
SFX_MODULE ?= $(error SFX_MODULE is not defined)
TOOLKIT_NSIS_FILES = \ TOOLKIT_NSIS_FILES = \
common.nsh \ common.nsh \
@ -51,13 +52,18 @@ TOOLKIT_NSIS_FILES = \
version.nsh \ version.nsh \
$(NULL) $(NULL)
installer:: $(CONFIG_DIR)/setup.exe::
$(INSTALL) $(addprefix $(topsrcdir)/toolkit/mozapps/installer/windows/nsis/,$(TOOLKIT_NSIS_FILES)) $(CONFIG_DIR) $(INSTALL) $(addprefix $(topsrcdir)/toolkit/mozapps/installer/windows/nsis/,$(TOOLKIT_NSIS_FILES)) $(CONFIG_DIR)
$(INSTALL) $(topsrcdir)/toolkit/mozapps/installer/windows/wizard/setuprsc/setup.ico $(CONFIG_DIR) $(INSTALL) $(topsrcdir)/toolkit/mozapps/installer/windows/wizard/setuprsc/setup.ico $(CONFIG_DIR)
cd $(CONFIG_DIR) && makensis.exe installer.nsi cd $(CONFIG_DIR) && makensis.exe installer.nsi
$(INSTALL) $(CONFIG_DIR)/removed-files.log $(CONFIG_DIR)/setup.exe $(DEPTH)/installer-stage
cd $(DEPTH)/installer-stage && $(CYGWIN_WRAPPER) 7z a -r -t7z $(CONFIG_DIR)/app.7z -mx -m0=BCJ2 -m1=LZMA:d24 -m2=LZMA:d19 -m3=LZMA:d19 -mb0:1 -mb0s1:2 -mb0s2:3 $(CONFIG_DIR)/7zSD.sfx:
$(CYGWIN_WRAPPER) upx --best -o $(CONFIG_DIR)/7zSD.sfx $(SFX_MODULE) $(CYGWIN_WRAPPER) upx --best -o $(CONFIG_DIR)/7zSD.sfx $(SFX_MODULE)
installer::
$(INSTALL) $(CONFIG_DIR)/removed-files.log $(CONFIG_DIR)/setup.exe $(DEPTH)/installer-stage
cd $(DEPTH)/installer-stage && $(CYGWIN_WRAPPER) 7z a -r -t7z $(ABS_CONFIG_DIR)/app.7z -mx -m0=BCJ2 -m1=LZMA:d24 -m2=LZMA:d19 -m3=LZMA:d19 -mb0:1 -mb0s1:2 -mb0s2:3
$(MAKE) $(CONFIG_DIR)/7zSD.sfx
$(NSINSTALL) -D $(DIST)/install/sea $(NSINSTALL) -D $(DIST)/install/sea
cat $(CONFIG_DIR)/7zSD.sfx $(CONFIG_DIR)/app.tag $(CONFIG_DIR)/app.7z > $(DIST)/install/sea/$(PKG_BASENAME).installer.exe cat $(CONFIG_DIR)/7zSD.sfx $(CONFIG_DIR)/app.tag $(CONFIG_DIR)/app.7z > $(DIST)/install/sea/$(PKG_BASENAME).installer.exe
chmod 0755 $(DIST)/install/sea/$(PKG_BASENAME).installer.exe chmod 0755 $(DIST)/install/sea/$(PKG_BASENAME).installer.exe