Source code

Revision control

Other Tools

1
# vim:set ts=8 sw=8 sts=8 noet:
2
# This Source Code Form is subject to the terms of the Mozilla Public
3
# License, v. 2.0. If a copy of the MPL was not distributed with this
4
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
5
6
include $(topsrcdir)/config/config.mk
7
8
9
SUBMAKEFILES += \
10
$(DEPTH)/$(MOZ_BRANDING_DIRECTORY)/Makefile \
11
$(DEPTH)/$(MOZ_BRANDING_DIRECTORY)/locales/Makefile \
12
$(NULL)
13
14
# This makefile uses variable overrides from the libs-% target to
15
# build non-default locales to non-default dist/ locations. Be aware!
16
17
PWD := $(CURDIR)
18
19
# These are defaulted to be compatible with the files the wget-en-US target
20
# pulls. You may override them if you provide your own files.
21
ZIP_IN ?= $(ABS_DIST)/$(PACKAGE)
22
23
ifdef MOZ_DEV_EDITION
24
MOZ_LANGPACK_EID=langpack-$(AB_CD)@devedition.mozilla.org
25
else
26
MOZ_LANGPACK_EID=langpack-$(AB_CD)@firefox.mozilla.org
27
endif
28
# For Nightly, we know where to get the builds from to do local repacks
29
ifdef NIGHTLY_BUILD
31
endif
32
33
ifneq (,$(filter cocoa,$(MOZ_WIDGET_TOOLKIT)))
34
MOZ_PKG_MAC_DSSTORE=$(ABS_DIST)/branding/dsstore
35
MOZ_PKG_MAC_BACKGROUND=$(ABS_DIST)/branding/background.png
36
MOZ_PKG_MAC_ICON=$(ABS_DIST)/branding/disk.icns
37
MOZ_PKG_MAC_EXTRA=--symlink '/Applications:/ '
38
endif
39
40
ifeq ($(CPU_ARCH), aarch64)
41
MOZ_SFX_PACKAGE=$(topsrcdir)/other-licenses/7zstub/firefox/7zSD.ARM64.sfx
42
else
43
MOZ_SFX_PACKAGE=$(topsrcdir)/other-licenses/7zstub/firefox/7zSD.Win32.sfx
44
endif
45
46
# Required for l10n.mk - defines a list of app sub dirs that should
47
# be included in langpack xpis.
48
DIST_SUBDIRS = $(DIST_SUBDIR)
49
50
include $(topsrcdir)/config/rules.mk
51
52
include $(topsrcdir)/toolkit/locales/l10n.mk
53
54
libs-%: AB_CD=$*
55
libs-%:
56
$(if $(filter en-US,$(AB_CD)),, @$(MAKE) merge-$*)
57
$(NSINSTALL) -D $(DIST)/install
58
@$(MAKE) -C ../../toolkit/locales libs-$* XPI_ROOT_APPID='$(XPI_ROOT_APPID)'
59
@$(MAKE) -C ../../services/sync/locales AB_CD=$* XPI_NAME=locale-$*
60
@$(MAKE) -C ../../extensions/spellcheck/locales AB_CD=$* XPI_NAME=locale-$*
61
ifneq (,$(wildcard ../extensions/formautofill/locales))
62
@$(MAKE) -C ../extensions/formautofill/locales AB_CD=$* XPI_NAME=locale-$*
63
endif
64
@$(MAKE) -C ../extensions/report-site-issue/locales AB_CD=$* XPI_NAME=locale-$*
65
@$(MAKE) -C ../../devtools/client/locales AB_CD=$* XPI_NAME=locale-$* XPI_ROOT_APPID='$(XPI_ROOT_APPID)'
66
@$(MAKE) -C ../../devtools/startup/locales AB_CD=$* XPI_NAME=locale-$* XPI_ROOT_APPID='$(XPI_ROOT_APPID)'
67
@$(MAKE) libs AB_CD=$* XPI_NAME=locale-$* PREF_DIR=$(PREF_DIR)
68
@$(MAKE) multilocale.txt-$* AB_CD=$* XPI_NAME=locale-$*
69
@$(MAKE) -C $(DEPTH)/$(MOZ_BRANDING_DIRECTORY)/locales AB_CD=$* XPI_NAME=locale-$*
70
71
chrome-%: AB_CD=$*
72
chrome-%: IS_LANGUAGE_REPACK=1
73
chrome-%:
74
$(if $(filter en-US,$(AB_CD)),, @$(MAKE) merge-$*)
75
@$(MAKE) -C ../../toolkit/locales chrome-$*
76
@$(MAKE) -C ../../services/sync/locales chrome AB_CD=$*
77
@$(MAKE) -C ../../extensions/spellcheck/locales chrome AB_CD=$*
78
ifneq (,$(wildcard ../extensions/formautofill/locales))
79
@$(MAKE) -C ../extensions/formautofill/locales chrome AB_CD=$*
80
endif
81
@$(MAKE) -C ../../devtools/client/locales chrome AB_CD=$*
82
@$(MAKE) -C ../../devtools/startup/locales chrome AB_CD=$*
83
@$(MAKE) chrome AB_CD=$*
84
@$(MAKE) -C $(DEPTH)/$(MOZ_BRANDING_DIRECTORY)/locales chrome AB_CD=$*
85
@$(MAKE) -C ../extensions/report-site-issue/locales chrome AB_CD=$*
86
87
package-win32-installer: $(SUBMAKEFILES)
88
$(MAKE) -C ../installer/windows CONFIG_DIR=l10ngen ZIP_IN='$(ZIP_OUT)' installer
89
90
langpack: langpack-$(AB_CD)
91
92
# This is a generic target that will make a langpack, repack ZIP (+tarball)
93
# builds, and repack an installer if applicable. It is called from the
94
# tinderbox scripts. Alter it with caution.
95
96
installers-%: IS_LANGUAGE_REPACK=1
97
installers-%:
98
@$(MAKE) clobber-$*
99
@$(MAKE) libs-$*
100
@$(MAKE) package-langpack-$*
101
@$(MAKE) repackage-zip-$*
102
ifeq (WINNT,$(OS_ARCH))
103
@$(MAKE) package-win32-installer AB_CD=$*
104
endif
105
@echo 'repackaging done'
106
107
ident:
108
@printf 'fx_revision '
109
@$(PYTHON3) $(topsrcdir)/config/printconfigsetting.py \
110
'$(STAGEDIST)'/application.ini App SourceStamp
111
@printf 'buildid '
112
@$(PYTHON3) $(topsrcdir)/config/printconfigsetting.py \
113
'$(STAGEDIST)'/application.ini App BuildID