Fix opt failures using gczeal. (r=Waldo)
[mozilla-central.git] / browser / components / build / Makefile.in
blob3947a1fe8c5f7fdb85b46eaddf4136bf6a7d0b16
1 DEPTH=../../..
2 topsrcdir=@top_srcdir@
3 srcdir=@srcdir@
4 VPATH=@srcdir@
6 include $(DEPTH)/config/autoconf.mk
8 MODULE = browsercomps
9 LIBRARY_NAME = browsercomps
10 SHORT_LIBNAME = brwsrcmp
11 IS_COMPONENT = 1
12 MODULE_NAME = nsBrowserCompsModule
13 FORCE_SHARED_LIB = 1
15 # Because we are an application component, link against the CRT statically
16 # (on Windows, but only if we're not building our own CRT for jemalloc)
17 ifndef MOZ_MEMORY
18 USE_STATIC_LIBS = 1
19 endif
22 EXPORTS = nsBrowserCompsCID.h
24 CPPSRCS = nsModule.cpp \
25 $(NULL)
27 ifeq ($(OS_ARCH),WINNT)
28 OS_LIBS += $(call EXPAND_LIBNAME,ole32 shell32)
29 endif
31 LOCAL_INCLUDES = \
32 -I$(srcdir)/../shell/src \
33 -I$(srcdir)/../feeds/src \
34 -I$(srcdir)/../places/src \
35 -I$(srcdir)/../privatebrowsing/src \
36 -I$(srcdir)/../about \
37 -I$(srcdir)/../dirprovider \
38 $(NULL)
40 ifeq ($(OS_ARCH),WINNT)
41 OS_LIBS += $(call EXPAND_LIBNAME,version)
42 endif
44 SHARED_LIBRARY_LIBS = \
45 ../feeds/src/$(LIB_PREFIX)browser_feeds_s.$(LIB_SUFFIX) \
46 ../privatebrowsing/src/$(LIB_PREFIX)privatebrowsing_s.$(LIB_SUFFIX) \
47 ../about/$(LIB_PREFIX)browserabout_s.$(LIB_SUFFIX) \
48 ../dirprovider/$(LIB_PREFIX)browserdir_s.$(LIB_SUFFIX) \
49 $(NULL)
51 ifneq (,$(filter windows cocoa gtk2, $(MOZ_WIDGET_TOOLKIT)))
52 SHARED_LIBRARY_LIBS += ../shell/src/$(LIB_PREFIX)shellservice_s.$(LIB_SUFFIX)
53 endif
55 EXTRA_DSO_LDOPTS += $(call EXPAND_LIBNAME_PATH,unicharutil_external_s,$(LIBXUL_DIST)/lib)
57 # migration requires mozreg, which doesn't build on WINCE; only include
58 # it on non-CE
59 ifndef WINCE
60 LOCAL_INCLUDES += -I$(srcdir)/../migration/src
61 SHARED_LIBRARY_LIBS += ../migration/src/$(LIB_PREFIX)migration_s.$(LIB_SUFFIX)
62 EXTRA_DSO_LDOPTS += $(LIBXUL_DIST)/lib/$(LIB_PREFIX)mozreg_s.$(LIB_SUFFIX)
63 endif
65 # This has to come after the above chunk, because mozreg_s has dependencies on
66 # stuff in MOZ_COMPONENT_LIBS.
67 EXTRA_DSO_LDOPTS += \
68 $(LIBXUL_DIST)/lib/$(LIB_PREFIX)xpcomglue_s.$(LIB_SUFFIX) \
69 $(MOZ_COMPONENT_LIBS) \
70 $(NULL)
72 # Mac: Need to link with CoreFoundation for Mac Migrators (PList reading code)
73 # GTK2: Need to link with glib for GNOME shell service
74 ifneq (,$(filter cocoa gtk2,$(MOZ_WIDGET_TOOLKIT)))
75 EXTRA_DSO_LDOPTS += \
76 $(TK_LIBS) \
77 $(NULL)
78 endif
80 ifndef MOZ_ENABLE_LIBXUL
81 ifeq ($(MOZ_WIDGET_TOOLKIT),windows)
82 # Doesn't work, couldn't figure out why
83 #EXTRA_DSO_LIBS += thebes
84 EXTRA_DSO_LDOPTS += $(LIBXUL_DIST)/lib/$(LIB_PREFIX)thebes.$(IMPORT_LIB_SUFFIX)
85 endif
86 endif
88 include $(topsrcdir)/config/rules.mk