2005-06-16 22:28:09 +00:00
|
|
|
# vim:set ts=8 sw=8 sts=8 noet:
|
|
|
|
#
|
2012-05-21 11:12:37 +00:00
|
|
|
# This Source Code Form is subject to the terms of the Mozilla Public
|
|
|
|
# License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
|
|
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
2005-06-16 22:28:09 +00:00
|
|
|
|
2012-08-04 18:26:44 +00:00
|
|
|
DEPTH = @DEPTH@
|
2005-06-16 22:28:09 +00:00
|
|
|
topsrcdir = @top_srcdir@
|
|
|
|
srcdir = @srcdir@
|
|
|
|
VPATH = @srcdir@
|
|
|
|
|
|
|
|
include $(DEPTH)/config/autoconf.mk
|
|
|
|
|
2008-09-17 20:53:09 +00:00
|
|
|
# input location for the build, usually $(DIST)
|
|
|
|
# set this to $(DIST)/l10n-stage per override for L10n builds
|
|
|
|
PACKAGE_BASE_DIR = $(DIST)
|
|
|
|
|
2005-06-16 22:28:09 +00:00
|
|
|
# Default output location for update archive
|
2008-09-17 20:53:09 +00:00
|
|
|
STAGE_DIR = $(DIST)/$(PKG_UPDATE_PATH)
|
2005-06-16 22:28:09 +00:00
|
|
|
|
2009-09-19 02:59:53 +00:00
|
|
|
ifeq (cocoa,$(MOZ_WIDGET_TOOLKIT))
|
2006-02-24 18:17:31 +00:00
|
|
|
ifdef UNIVERSAL_BINARY
|
2008-09-17 20:53:09 +00:00
|
|
|
ifneq (,$(filter %/l10n-stage,$(PACKAGE_BASE_DIR)))
|
2011-10-27 17:27:56 +00:00
|
|
|
PACKAGE_DIR = $(PACKAGE_BASE_DIR)/$(MOZ_PKG_DIR)/$(MOZ_MACBUNDLE_NAME)
|
2008-03-13 18:39:38 +00:00
|
|
|
else
|
2011-10-27 17:27:56 +00:00
|
|
|
PACKAGE_DIR = $(PACKAGE_BASE_DIR)/universal/$(MOZ_PKG_DIR)/$(MOZ_MACBUNDLE_NAME)
|
2008-03-13 18:39:38 +00:00
|
|
|
endif
|
2006-02-24 18:17:31 +00:00
|
|
|
else
|
2011-10-27 17:27:56 +00:00
|
|
|
PACKAGE_DIR = $(PACKAGE_BASE_DIR)/$(MOZ_PKG_DIR)/$(MOZ_MACBUNDLE_NAME)
|
2006-02-24 18:17:31 +00:00
|
|
|
endif
|
2005-07-05 21:51:26 +00:00
|
|
|
else
|
2008-12-24 14:08:08 +00:00
|
|
|
PACKAGE_DIR = $(PACKAGE_BASE_DIR)/$(MOZ_PKG_DIR)
|
2005-07-05 21:51:26 +00:00
|
|
|
endif
|
|
|
|
|
2009-12-15 21:36:13 +00:00
|
|
|
MAR_BIN = $(LIBXUL_DIST)/host/bin/mar$(HOST_BIN_SUFFIX)
|
|
|
|
MBSDIFF_BIN = $(LIBXUL_DIST)/host/bin/mbsdiff$(HOST_BIN_SUFFIX)
|
2006-03-08 00:48:57 +00:00
|
|
|
|
2012-08-08 07:33:16 +00:00
|
|
|
.DEFAULT_GOAL := full-update
|
2005-08-28 03:27:14 +00:00
|
|
|
full-update:: complete-patch
|
|
|
|
|
2011-04-11 16:23:26 +00:00
|
|
|
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
|
|
|
|
|
2011-12-07 22:06:52 +00:00
|
|
|
include $(topsrcdir)/config/rules.mk
|
|
|
|
include $(topsrcdir)/toolkit/mozapps/installer/signing.mk
|
|
|
|
include $(topsrcdir)/toolkit/mozapps/installer/packager.mk
|
|
|
|
|
|
|
|
ifdef MOZ_EXTERNAL_SIGNING_FORMAT
|
|
|
|
# We can't use signcode on mar files
|
|
|
|
MOZ_EXTERNAL_SIGNING_FORMAT := $(filter-out signcode,$(MOZ_EXTERNAL_SIGNING_FORMAT))
|
|
|
|
MOZ_EXTERNAL_SIGNING_FORMAT := mar $(MOZ_EXTERNAL_SIGNING_FORMAT)
|
|
|
|
endif
|
|
|
|
|
2012-05-03 10:22:33 +00:00
|
|
|
dir-stage := $(call mkdir_deps,$(STAGE_DIR))
|
|
|
|
|
|
|
|
complete-patch:: $(dir-stage)
|
2011-04-11 16:23:26 +00:00
|
|
|
ifeq ($(OS_TARGET), WINNT)
|
|
|
|
test -f $(UNPACKAGE)
|
|
|
|
$(RM) -rf "$(PACKAGE_DIR)"
|
|
|
|
cd $(PACKAGE_BASE_DIR) && $(INNER_UNMAKE_PACKAGE)
|
|
|
|
endif
|
2006-03-08 00:48:57 +00:00
|
|
|
MAR=$(MAR_BIN) \
|
2005-08-28 03:27:14 +00:00
|
|
|
$(srcdir)/make_full_update.sh \
|
2008-09-17 20:53:09 +00:00
|
|
|
"$(STAGE_DIR)/$(PKG_UPDATE_BASENAME).complete.mar" \
|
2005-08-28 03:27:14 +00:00
|
|
|
"$(PACKAGE_DIR)"
|
2011-12-07 22:06:52 +00:00
|
|
|
ifdef MOZ_SIGN_PACKAGE_CMD
|
|
|
|
$(MOZ_SIGN_PACKAGE_CMD) "$(STAGE_DIR)/$(PKG_UPDATE_BASENAME).complete.mar"
|
|
|
|
endif
|
2005-08-28 03:27:14 +00:00
|
|
|
|
2012-05-03 10:22:33 +00:00
|
|
|
partial-patch:: $(dir-stage)
|
2006-03-08 00:48:57 +00:00
|
|
|
MAR=$(MAR_BIN) \
|
|
|
|
MBSDIFF=$(MBSDIFF_BIN) \
|
2005-08-28 03:27:14 +00:00
|
|
|
$(srcdir)/make_incremental_update.sh \
|
2008-09-17 20:53:09 +00:00
|
|
|
"$(STAGE_DIR)/$(PKG_UPDATE_BASENAME).partial.$(SRC_BUILD_ID)-$(DST_BUILD_ID).mar" \
|
2005-08-28 03:27:14 +00:00
|
|
|
"$(SRC_BUILD)" \
|
|
|
|
"$(DST_BUILD)"
|
2011-12-07 22:06:52 +00:00
|
|
|
ifdef MOZ_SIGN_PACKAGE_CMD
|
|
|
|
$(MOZ_SIGN_PACKAGE_CMD) "$(STAGE_DIR)/$(PKG_UPDATE_BASENAME).partial.$(SRC_BUILD_ID)-$(DST_BUILD_ID).mar"
|
|
|
|
endif
|