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/.
7 include $(topsrcdir
)/config
/makefiles
/makeutils.mk
10 DIST_FILES
= $(srcdir)/application.ini
12 ifneq (android
,$(MOZ_WIDGET_TOOLKIT
))
14 DIST_FILES
+= update-settings.ini
19 APP_INI_DEPS
= $(LIBXUL_DIST
)/bin
/platform.ini
21 APP_INI_DEPS
= $(topsrcdir
)/config
/milestone.txt
24 APP_BUILDID
:= $(shell cat
$(DEPTH
)/config
/buildid
)
25 APP_INI_DEPS
+= $(DEPTH
)/config
/buildid
27 DEFINES
+= -DGRE_MILESTONE
=$(GRE_MILESTONE
) -DAPP_BUILDID
=$(APP_BUILDID
)
29 DEFINES
+= -DMOZ_APP_VERSION
="$(MOZ_APP_VERSION)"
30 APP_INI_DEPS
+= $(DEPTH
)/config
/autoconf.mk
32 MOZ_SOURCE_STAMP
:= $(firstword $(shell cd
$(topsrcdir
)/$(MOZ_BUILD_APP
)/..
&& hg parent
--template
="{node|short}\n" 2>/dev
/null
))
33 ifdef MOZ_SOURCE_STAMP
34 DEFINES
+= -DMOZ_SOURCE_STAMP
="$(MOZ_SOURCE_STAMP)"
37 source_repo ?
= $(call getSourceRepo
,$(topsrcdir
)/$(MOZ_BUILD_APP
)/..
)
38 ifneq (,$(source_repo
))
39 DEFINES
+= -DMOZ_SOURCE_REPO
="$(source_repo)"
43 -DMOZ_APP_BASENAME
="$(MOZ_APP_BASENAME)" \
44 -DMOZ_APP_VENDOR
="$(MOZ_APP_VENDOR)" \
45 -DMOZ_APP_ID
="$(MOZ_APP_ID)" \
46 -DMAR_CHANNEL_ID
="$(MAR_CHANNEL_ID)" \
47 -DACCEPTED_MAR_CHANNEL_IDS
="$(ACCEPTED_MAR_CHANNEL_IDS)" \
51 DEFINES
+= -DMOZ_APP_PROFILE
="$(MOZ_APP_PROFILE)"
54 ifdef MOZ_CRASHREPORTER
55 DEFINES
+= -DMOZ_CRASHREPORTER
58 ifdef MOZ_PROFILE_MIGRATOR
59 DEFINES
+= -DMOZ_PROFILE_MIGRATOR
62 ifdef MOZ_EXTENSION_MANAGER
63 DEFINES
+= -DMOZ_EXTENSION_MANAGER
68 # Put a useful .gdbinit in the bin directory, to be picked up automatically
69 # by GDB when we debug executables there.
70 # NOTE: Keep .gdbinit in the topsrcdir for people who run gdb from the topsrcdir.
71 GDBINIT_FILES
:= $(topsrcdir
)/.gdbinit
72 GDBINIT_DEST
= $(FINAL_TARGET
)
73 INSTALL_TARGETS
+= GDBINIT
75 include $(topsrcdir
)/config
/rules.mk
77 # we install to _leaktest/
79 include $(srcdir)/automation-build.mk
81 _LEAKTEST_DIR
= $(DEPTH
)/_leaktest
86 $(topsrcdir
)/testing
/profiles
/prefs_general.js \
89 $(topsrcdir
)/build
/pgo
/server-locations.txt \
90 $(topsrcdir
)/build
/pgo
/favicon.ico \
91 $(topsrcdir
)/build
/pgo
/blueprint
/sample.html \
92 $(topsrcdir
)/build
/pgo
/blueprint
/elements.html \
93 $(topsrcdir
)/build
/pgo
/blueprint
/forms.html \
94 $(topsrcdir
)/build
/pgo
/blueprint
/grid.html \
95 $(topsrcdir
)/build
/pgo
/blueprint
/test.jpg \
96 $(topsrcdir
)/build
/pgo
/blueprint
/test-small.jpg \
97 $(topsrcdir
)/build
/pgo
/blueprint
/valid.png \
98 $(topsrcdir
)/build
/pgo
/blueprint
/screen.css \
99 $(topsrcdir
)/build
/pgo
/blueprint
/print.css \
100 $(topsrcdir
)/build
/pgo
/blueprint
/grid.png \
101 $(topsrcdir
)/build
/pgo
/blueprint
/fancytype-screen.css \
104 leaktest.py
: leaktest.py.in
105 $(PYTHON
) $(topsrcdir
)/config
/Preprocessor.py
$^
> $@
107 GARBAGE
+= leaktest.py
109 ifdef MOZ_APP_BASENAME
110 $(FINAL_TARGET
)/application.ini
: $(APP_INI_DEPS
)
112 ifdef MOZ_APP_STATIC_INI
113 DEFINES
+= -DMOZ_APP_STATIC_INI
115 application.ini.h
: appini_header.py
$(FINAL_TARGET
)/application.ini
117 export:: application.ini.h
118 GARBAGE
+= application.ini.h
122 libs
:: $(_LEAKTEST_FILES
)
123 $(INSTALL
) $^
$(_LEAKTEST_DIR
)
126 _VALGRIND_DIR
= $(DEPTH
)/_valgrind
127 GARBAGE_DIRS
+= $(_VALGRIND_DIR
)
130 $(topsrcdir
)/build
/valgrind
/cross-architecture.sup \
131 $(topsrcdir
)/build
/valgrind
/i386-redhat-linux-gnu.sup \
132 $(topsrcdir
)/build
/valgrind
/x86_64-redhat-linux-gnu.sup \
135 libs
:: $(_VALGRIND_FILES
)
136 $(INSTALL
) $^
$(_VALGRIND_DIR
)
140 libs
:: $(topsrcdir
)/tools
/rb
/fix_stack_using_bpsyms.py
141 $(INSTALL
) $< $(DIST
)/bin
143 ifeq ($(OS_ARCH
),Darwin
)
144 libs
:: $(topsrcdir
)/tools
/rb
/fix_macosx_stack.py
145 $(INSTALL
) $< $(DIST
)/bin
148 ifeq ($(OS_ARCH
),Linux
)
149 libs
:: $(topsrcdir
)/tools
/rb
/fix-linux-stack.pl
150 $(INSTALL
) $< $(DIST
)/bin
153 GARBAGE
+= $(srcdir)/automationutils.pyc