|
|
1 # ***** BEGIN LICENSE BLOCK *****
2 # Version: MPL 1.1/GPL 2.0/LGPL 2.1
3 #
4 # The contents of this file are subject to the Mozilla Public License Version
5 # 1.1 (the "License"); you may not use this file except in compliance with
6 # the License. You may obtain a copy of the License at
7 # http://www.mozilla.org/MPL/
8 #
9 # Software distributed under the License is distributed on an "AS IS" basis,
10 # WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
11 # for the specific language governing rights and limitations under the
12 # License.
13 #
14 # The Original Code is the Mozilla build system.
15 #
16 # The Initial Developer of the Original Code is
17 # the Mozilla Foundation <http://www.mozilla.org/>.
18 # Portions created by the Initial Developer are Copyright (C) 2006
19 # the Initial Developer. All Rights Reserved.
20 #
21 # Contributor(s):
22 # Benjamin Smedberg <benjamin@smedbergs.us> (Initial Code)
23 #
24 # Alternatively, the contents of this file may be used under the terms of
25 # either the GNU General Public License Version 2 or later (the "GPL"), or
26 # the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
27 # in which case the provisions of the GPL or the LGPL are applicable instead
28 # of those above. If you wish to allow use of your version of this file only
29 # under the terms of either the GPL or the LGPL, and not to allow others to
30 # use your version of this file under the terms of the MPL, indicate your
31 # decision by deleting the provisions above and replace them with the notice
32 # and other provisions required by the GPL or the LGPL. If you do not delete
33 # the provisions above, a recipient may use your version of this file under
34 # the terms of any one of the MPL, the GPL or the LGPL.
35 #
36 # ***** END LICENSE BLOCK *****
37
38 ifdef LIBXUL_SDK
39 $(error toolkit-tiers.mk is not compatible with --enable-libxul-sdk=)
40 endif
41
42 include $(topsrcdir)/config/nspr/build.mk
43 include $(topsrcdir)/js/src/build.mk
44 include $(topsrcdir)/xpcom/build.mk
45 include $(topsrcdir)/netwerk/build.mk
46
47 TIERS += \
48 external \
49 gecko \
50 toolkit \
51 $(NULL)
52
53 #
54 # tier "external" - 3rd party individual libraries
55 #
56
57 ifndef MOZ_NATIVE_JPEG
58 tier_external_dirs += jpeg
59 endif
60
61 # Installer needs standalone libjar, hence standalone zlib
62 ifdef MOZ_INSTALLER
63 tier_external_dirs += modules/zlib/standalone
64 endif
65
66 ifdef MOZ_UPDATER
67 ifndef MOZ_NATIVE_BZ2
68 tier_external_dirs += modules/libbz2
69 endif
70 tier_external_dirs += modules/libmar
71 endif
72
73 ifndef MOZ_NATIVE_LCMS
74 tier_external_dirs += modules/lcms
75 endif
76
77 #
78 # tier "gecko" - core components
79 #
80
81 ifdef NS_TRACE_MALLOC
82 tier_gecko_dirs += tools/trace-malloc/lib
83 endif
84
85 tier_gecko_dirs += \
86 js/src/xpconnect \
87 intl/chardet \
88 $(NULL)
89
90 ifdef MOZ_ENABLE_GTK2
91 tier_gecko_dirs += widget/src/gtkxtbin
92 endif
93
94 ifdef MOZ_IPCD
95 tier_gecko_dirs += ipc/ipcd
96 endif
97
98 tier_gecko_dirs += \
99 modules/libutil \
100 modules/libjar \
101 db \
102 $(NULL)
103
104 ifdef MOZ_PERMISSIONS
105 tier_gecko_dirs += \
106 extensions/cookie \
107 extensions/permissions \
108 $(NULL)
109 endif
110
111 ifdef MOZ_STORAGE
112 tier_gecko_dirs += storage
113 endif
114
115 ifdef MOZ_RDF
116 tier_gecko_dirs += rdf
117 endif
118
119 ifdef MOZ_JSDEBUGGER
120 tier_gecko_dirs += js/jsd
121 endif
122
123 tier_gecko_dirs += \
124 uriloader \
125 modules/libimg \
126 caps \
127 parser/expat \
128 parser/xml \
129 parser/htmlparser \
130 gfx \
131 modules/libpr0n \
132 sun-java \
133 modules/plugin \
134 dom \
135 view \
136 widget \
137 content \
138 editor \
139 layout \
140 docshell \
141 webshell \
142 embedding \
143 xpfe/appshell \
144 $(NULL)
145
146 # Java Embedding Plugin
147 ifneq (,$(filter mac cocoa,$(MOZ_WIDGET_TOOLKIT)))
148 tier_gecko_dirs += plugin/oji/JEP
149 endif
150
151 ifdef MOZ_XMLEXTRAS
152 tier_gecko_dirs += extensions/xmlextras
153 endif
154
155 ifdef MOZ_WEBSERVICES
156 tier_gecko_dirs += extensions/webservices
157 endif
158
159 ifdef MOZ_UNIVERSALCHARDET
160 tier_gecko_dirs += extensions/universalchardet
161 endif
162
163 ifdef MOZ_OJI
164 tier_gecko_dirs += \
165 js/src/liveconnect \
166 modules/oji \
167 $(NULL)
168 endif
169
170 ifdef ACCESSIBILITY
171 tier_gecko_dirs += accessible
172 endif
173
174 #
175 # tier "toolkit" - xpfe & toolkit
176 #
177 # The division of "gecko" and "toolkit" is somewhat arbitrary, and related
178 # to history where "gecko" wasn't forked between seamonkey/firefox but
179 # "toolkit" was.
180 #
181
182 ifdef MOZ_XUL_APP
183 tier_toolkit_dirs += chrome
184 else
185 ifdef MOZ_XUL
186 tier_toolkit_dirs += rdf/chrome
187 else
188 tier_toolkit_dirs += embedding/minimo/chromelite
189 endif
190 endif
191
192 tier_toolkit_dirs += profile
193
194 # This must preceed xpfe
195 ifdef MOZ_JPROF
196 tier_toolkit_dirs += tools/jprof
197 endif
198
199 ifneq (,$(filter mac cocoa,$(MOZ_WIDGET_TOOLKIT)))
200 tier_toolkit_dirs += xpfe/bootstrap/appleevents
201 endif
202
203 tier_toolkit_dirs += \
204 xpfe \
205 toolkit/components \
206 $(NULL)
207
208 ifdef MOZ_ENABLE_XREMOTE
209 tier_toolkit_dirs += widget/src/xremoteclient
210 endif
211
212 ifdef MOZ_SPELLCHECK
213 tier_toolkit_dirs += extensions/spellcheck
214 endif
215
216 ifdef MOZ_XUL_APP
217 tier_toolkit_dirs += toolkit
218 endif
219
220 ifdef MOZ_XPINSTALL
221 tier_toolkit_dirs += xpinstall
222 endif
223
224 ifdef MOZ_PSM
225 tier_toolkit_dirs += security/manager
226 else
227 tier_toolkit_dirs += security/manager/boot/public security/manager/ssl/public
228 endif
229
230 ifdef MOZ_PREF_EXTENSIONS
231 tier_toolkit_dirs += extensions/pref
232 endif
233
234 # JavaXPCOM JNI code is compiled into libXUL
235 ifdef MOZ_JAVAXPCOM
236 tier_toolkit_dirs += extensions/java/xpcom/src
237 endif
238
239 ifndef BUILD_STATIC_LIBS
240 ifdef MOZ_XUL_APP
241 ifneq (,$(MOZ_ENABLE_GTK2))
242 tier_toolkit_dirs += embedding/browser/gtk
243 endif
244 endif
245 endif
246
247 ifdef MOZ_XUL_APP
248 ifndef BUILD_STATIC_LIBS
249 tier_toolkit_dirs += toolkit/library
250 endif
251 endif
252
253 ifdef MOZ_ENABLE_LIBXUL
254 tier_toolkit_dirs += xpcom/stub
255 endif
256
257 ifdef NS_TRACE_MALLOC
258 tier_toolkit_dirs += tools/trace-malloc
259 endif
260
261 ifdef MOZ_LDAP_XPCOM
262 tier_toolkit_staticdirs += directory/c-sdk
263 tier_toolkit_dirs += directory/xpcom
264 endif
265
266 ifdef MOZ_ENABLE_GNOME_COMPONENT
267 tier_toolkit_dirs += toolkit/system/gnome
268 endif
269
270 ifdef MOZ_ENABLE_DBUS
271 tier_toolkit_dirs += toolkit/system/dbus
272 endif
273
274 ifdef MOZ_LEAKY
275 tier_toolkit_dirs += tools/leaky
276 endif
277
278 ifdef MOZ_MAPINFO
279 tier_toolkit_dirs += tools/codesighs
280 endif
281
282 ifdef MOZ_MOCHITEST
283 tier_toolkit_dirs += testing/mochitest
284 endif