Bug 449474, Fx3.0.2 updates should force modules/distribution.js, and use the version...
[mozilla-1.9.git] / layout / build / Makefile.in
blob6422abd8b1c54ada912bab0d83619a9536c1606f
2 # ***** BEGIN LICENSE BLOCK *****
3 # Version: MPL 1.1/GPL 2.0/LGPL 2.1
5 # The contents of this file are subject to the Mozilla Public License Version
6 # 1.1 (the "License"); you may not use this file except in compliance with
7 # the License. You may obtain a copy of the License at
8 # http://www.mozilla.org/MPL/
10 # Software distributed under the License is distributed on an "AS IS" basis,
11 # WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
12 # for the specific language governing rights and limitations under the
13 # License.
15 # The Original Code is mozilla.org code.
17 # The Initial Developer of the Original Code is
18 # Netscape Communications Corporation.
19 # Portions created by the Initial Developer are Copyright (C) 1998
20 # the Initial Developer. All Rights Reserved.
22 # Contributor(s):
24 # Alternatively, the contents of this file may be used under the terms of
25 # either of the GNU General Public License Version 2 or later (the "GPL"),
26 # or 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.
36 # ***** END LICENSE BLOCK *****
38 DEPTH = ../..
39 topsrcdir = @top_srcdir@
40 srcdir = @srcdir@
41 VPATH = @srcdir@
43 include $(DEPTH)/config/autoconf.mk
45 # Solaris and Tru64 UNIX sh blows
46 ifeq ($(OS_ARCH),SunOS)
47 SHELL := ksh
48 endif
49 ifeq ($(OS_ARCH),OSF1)
50 SHELL := ksh
51 endif
53 MODULE = layout
54 LIBRARY_NAME = gklayout
55 EXPORT_LIBRARY = 1
56 IS_COMPONENT = 1
57 MODULE_NAME = nsLayoutModule
58 GRE_MODULE = 1
59 LIBXUL_LIBRARY = 1
61 PACKAGE_FILE = layout.pkg
62 PACKAGE_VARS += MOZ_XUL
64 ifndef MOZ_ENABLE_LIBXUL
65 EXTRA_DSO_LIBS = gkgfx
66 endif
67 EXTRA_DSO_LIBS += thebes
69 REQUIRES = xpcom \
70 string \
71 content \
72 gfx \
73 widget \
74 view \
75 locale \
76 necko \
77 dom \
78 storage \
79 editor \
80 txmgr \
81 webshell \
82 docshell \
83 htmlparser \
84 js \
85 xpconnect \
86 caps \
87 rdf \
88 xuldoc \
89 imglib2 \
90 pref \
91 unicharutil \
92 xultmpl \
93 lwbrk \
94 plugin \
95 commandhandler \
96 webbrwsr \
97 uconv \
98 txtsvc \
99 thebes \
100 $(NULL)
102 CPPSRCS = \
103 nsLayoutModule.cpp \
104 nsContentDLF.cpp \
105 nsLayoutStatics.cpp \
106 $(NULL)
108 EXPORTS = \
109 nsLayoutCID.h \
110 nsContentDLF.h \
111 nsLayoutStatics.h \
112 $(NULL)
114 SHARED_LIBRARY_LIBS = \
115 ../base/$(LIB_PREFIX)gkbase_s.$(LIB_SUFFIX) \
116 ../generic/$(LIB_PREFIX)gkgeneric_s.$(LIB_SUFFIX) \
117 ../forms/$(LIB_PREFIX)gkforms_s.$(LIB_SUFFIX) \
118 ../style/$(LIB_PREFIX)gkstyle_s.$(LIB_SUFFIX) \
119 ../tables/$(LIB_PREFIX)gktable_s.$(LIB_SUFFIX) \
120 ../xul/base/src/$(LIB_PREFIX)gkxulbase_s.$(LIB_SUFFIX) \
121 $(DEPTH)/content/base/src/$(LIB_PREFIX)gkconbase_s.$(LIB_SUFFIX) \
122 $(DEPTH)/content/canvas/src/$(LIB_PREFIX)gkconcvs_s.$(LIB_SUFFIX) \
123 $(DEPTH)/content/events/src/$(LIB_PREFIX)gkconevents_s.$(LIB_SUFFIX) \
124 $(DEPTH)/content/html/content/src/$(LIB_PREFIX)gkconhtmlcon_s.$(LIB_SUFFIX) \
125 $(DEPTH)/content/html/document/src/$(LIB_PREFIX)gkconhtmldoc_s.$(LIB_SUFFIX) \
126 $(DEPTH)/content/xml/content/src/$(LIB_PREFIX)gkconxmlcon_s.$(LIB_SUFFIX) \
127 $(DEPTH)/content/xml/document/src/$(LIB_PREFIX)gkconxmldoc_s.$(LIB_SUFFIX) \
128 $(DEPTH)/content/xslt/src/base/$(LIB_PREFIX)txbase_s.$(LIB_SUFFIX) \
129 $(DEPTH)/content/xslt/src/xml/$(LIB_PREFIX)txxml_s.$(LIB_SUFFIX) \
130 $(DEPTH)/content/xslt/src/xpath/$(LIB_PREFIX)txxpath_s.$(LIB_SUFFIX) \
131 $(DEPTH)/content/xslt/src/xslt/$(LIB_PREFIX)txxslt_s.$(LIB_SUFFIX) \
132 $(DEPTH)/content/xbl/src/$(LIB_PREFIX)gkconxbl_s.$(LIB_SUFFIX) \
133 $(DEPTH)/content/xul/document/src/$(LIB_PREFIX)gkconxuldoc_s.$(LIB_SUFFIX) \
134 $(DEPTH)/view/src/$(LIB_PREFIX)gkview_s.$(LIB_SUFFIX) \
135 $(DEPTH)/dom/src/base/$(LIB_PREFIX)jsdombase_s.$(LIB_SUFFIX) \
136 $(DEPTH)/dom/src/events/$(LIB_PREFIX)jsdomevents_s.$(LIB_SUFFIX) \
137 $(DEPTH)/dom/src/json/$(LIB_PREFIX)json_s.$(LIB_SUFFIX) \
138 $(DEPTH)/dom/src/jsurl/$(LIB_PREFIX)jsurl_s.$(LIB_SUFFIX) \
139 $(DEPTH)/dom/src/storage/$(LIB_PREFIX)jsdomstorage_s.$(LIB_SUFFIX) \
140 $(DEPTH)/dom/src/offline/$(LIB_PREFIX)jsdomoffline_s.$(LIB_SUFFIX) \
141 $(DEPTH)/editor/libeditor/text/$(LIB_PREFIX)texteditor_s.$(LIB_SUFFIX) \
142 $(DEPTH)/editor/libeditor/base/$(LIB_PREFIX)editorbase_s.$(LIB_SUFFIX) \
143 $(NULL)
145 ifdef NS_PRINTING
146 SHARED_LIBRARY_LIBS += \
147 ../printing/$(LIB_PREFIX)gkprinting_s.$(LIB_SUFFIX) \
148 $(NULL)
149 endif
151 ifdef MOZ_XUL
152 SHARED_LIBRARY_LIBS += \
153 ../xul/base/src/tree/src/$(LIB_PREFIX)gkxultree_s.$(LIB_SUFFIX) \
154 ../xul/base/src/grid/$(LIB_PREFIX)gkxulgrid_s.$(LIB_SUFFIX) \
155 $(DEPTH)/content/xul/content/src/$(LIB_PREFIX)gkconxulcon_s.$(LIB_SUFFIX) \
156 $(DEPTH)/content/xul/templates/src/$(LIB_PREFIX)gkconxultmpl_s.$(LIB_SUFFIX) \
157 $(NULL)
158 endif
160 ifndef MOZ_NO_INSPECTOR_APIS
161 LOCAL_INCLUDES += \
162 -I$(srcdir)/../inspector/src \
163 $(NULL)
164 REQUIRES += \
165 inspector \
166 $(NULL)
167 SHARED_LIBRARY_LIBS += ../inspector/src/$(LIB_PREFIX)inspector_s.$(LIB_SUFFIX)
168 else
169 DEFINES += -DMOZ_NO_INSPECTOR_APIS
170 endif
172 ifdef MOZ_MATHML
173 SHARED_LIBRARY_LIBS += \
174 ../mathml/content/src/$(LIB_PREFIX)gkmathmlcon_s.$(LIB_SUFFIX) \
175 ../mathml/base/src/$(LIB_PREFIX)gkmathmlbase_s.$(LIB_SUFFIX) \
176 $(DEPTH)/content/mathml/content/src/$(LIB_PREFIX)gkcontentmathml_s.$(LIB_SUFFIX) \
177 $(NULL)
178 endif
180 ifdef MOZ_XTF
181 SHARED_LIBRARY_LIBS += \
182 $(DEPTH)/content/xtf/src/$(LIB_PREFIX)gkcontentxtf_s.$(LIB_SUFFIX) \
183 $(NULL)
184 endif
186 ifdef MOZ_SVG
187 SHARED_LIBRARY_LIBS += \
188 ../svg/base/src/$(LIB_PREFIX)gksvgbase_s.$(LIB_SUFFIX) \
189 $(DEPTH)/content/svg/document/src/$(LIB_PREFIX)gkconsvgdoc_s.$(LIB_SUFFIX) \
190 $(DEPTH)/content/svg/content/src/$(LIB_PREFIX)gkcontentsvg_s.$(LIB_SUFFIX) \
191 $(NULL)
192 endif
194 ifdef MOZ_PLAINTEXT_EDITOR_ONLY
195 DEFINES += -DMOZILLA_PLAINTEXT_EDITOR_ONLY
196 else
197 SHARED_LIBRARY_LIBS += \
198 $(DEPTH)/editor/libeditor/html/$(LIB_PREFIX)htmleditor_s.$(LIB_SUFFIX) \
199 $(DEPTH)/editor/txtsvc/src/$(LIB_PREFIX)txtsvc_s.$(LIB_SUFFIX) \
200 $(NULL)
201 endif
203 ifdef MOZ_PERF_METRICS
204 SHARED_LIBRARY_LIBS += $(DEPTH)/modules/libutil/src/$(LIB_PREFIX)mozutil_s.$(LIB_SUFFIX)
205 endif
207 ifdef ENABLE_EDITOR_API_LOG
208 DEFINES += -DENABLE_EDITOR_API_LOG
209 endif
211 EXTRA_DSO_LDOPTS = \
212 $(LIBS_DIR) \
213 $(EXTRA_DSO_LIBS) \
214 $(MOZ_UNICHARUTIL_LIBS) \
215 $(MOZ_COMPONENT_LIBS) \
216 $(MOZ_JS_LIBS) \
217 $(NULL)
219 ifdef NS_TRACE_MALLOC
220 EXTRA_DSO_LIBS += tracemalloc
221 endif
223 ifdef MOZ_ENABLE_GTK2
224 EXTRA_DSO_LDOPTS += $(MOZ_GTK2_LIBS) \
225 -lXrender \
226 $(NULL)
227 endif
229 ifneq (,$(filter mac cocoa,$(MOZ_WIDGET_TOOLKIT)))
230 EXTRA_DSO_LDOPTS += \
231 $(TK_LIBS) \
232 $(NULL)
233 endif
235 # Add explicit X11 dependency when building against X11 toolkits
236 ifneq (,$(filter gtk2,$(MOZ_WIDGET_TOOLKIT)))
237 EXTRA_DSO_LDOPTS += $(XLDFLAGS) $(XLIBS)
238 endif
240 include $(topsrcdir)/config/rules.mk
242 LOCAL_INCLUDES += -I$(srcdir)/../base \
243 -I$(srcdir)/../generic \
244 -I$(srcdir)/../forms \
245 -I$(srcdir)/../tables \
246 -I$(srcdir)/../style \
247 -I$(srcdir)/../xul/content/src \
248 -I$(srcdir)/../xul/base/src \
249 -I$(topsrcdir)/content/base/src \
250 -I$(topsrcdir)/content/html/content/src \
251 -I$(topsrcdir)/content/html/document/src \
252 -I$(topsrcdir)/content/html/style/src \
253 -I$(topsrcdir)/content/xslt/src/base \
254 -I$(topsrcdir)/content/xslt/src/xml \
255 -I$(topsrcdir)/content/xslt/src/xpath \
256 -I$(topsrcdir)/content/xslt/src/xslt \
257 -I$(topsrcdir)/content/xul/content/src \
258 -I$(topsrcdir)/content/xul/document/src \
259 -I$(topsrcdir)/content/xul/templates/src \
260 -I$(topsrcdir)/content/events/src \
261 -I$(topsrcdir)/content/xbl/src \
262 -I$(topsrcdir)/view/src \
263 -I$(topsrcdir)/dom/src/base \
264 -I$(topsrcdir)/dom/src/json \
265 -I$(topsrcdir)/dom/src/jsurl \
266 -I$(topsrcdir)/dom/src/storage \
267 -I$(topsrcdir)/dom/src/offline \
268 -I. \
269 -I$(topsrcdir)/editor/libeditor/base \
270 -I$(topsrcdir)/editor/libeditor/text \
271 -I$(topsrcdir)/editor/libeditor/html \
272 -I$(topsrcdir)/editor/txtsvc/src \
273 -I$(topsrcdir)/editor/composer/src \
274 $(NULL)
276 ifdef MOZ_MATHML
277 LOCAL_INCLUDES += -I$(srcdir)/../mathml/content/src
278 endif
280 ifdef MOZ_SVG
281 LOCAL_INCLUDES += -I$(topsrcdir)/content/svg/content/src
282 endif
284 DEFINES += -D_IMPL_NS_LAYOUT
286 ifeq ($(OS_ARCH),IRIX)
287 ifeq ($(GNU_CXX),1)
288 LDFLAGS += -Wl,-LD_LAYOUT:lgot_buffer=50
289 endif
290 endif