Bug 737833 - Only do metro registration for metro builds. r=rstrong
[gecko.git] / xulrunner / stub / Makefile.in
blob4a489f4fcfaf5b48f836a83c9da762e5aa6c6498
1 # This Source Code Form is subject to the terms of the Mozilla Public
2 # License, v. 2.0. If a copy of the MPL was not distributed with this
3 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
5 DEPTH = @DEPTH@
6 topsrcdir = @top_srcdir@
7 srcdir = @srcdir@
8 VPATH = @srcdir@
10 include $(DEPTH)/config/autoconf.mk
12 MODULE = xulrunner
14 # Statically link against the RTL on windows
15 USE_STATIC_LIBS = 1
16 # Don't create a dependency on mozglue
17 MOZ_GLUE_LDFLAGS =
19 CPPSRCS = nsXULStub.cpp
21 # The value of XULRUNNER_STUB_NAME is generated by configure to allow XULRunner
22 # apps to override it using the --with-xulrunner-stub-name=<appname> argument.
23 # If this configure argument is not present then the default name is 'xulrunner'
24 # for Mac OS X and 'xulrunner-stub' for all other platforms.
25 PROGRAM = $(XULRUNNER_STUB_NAME)$(BIN_SUFFIX)
27 LOCAL_INCLUDES = \
28 -I$(topsrcdir)/xpcom/build \
29 -I$(topsrcdir)/xpcom/base \
30 $(NULL)
32 DEFINES += -DXPCOM_GLUE
33 STL_FLAGS=
35 LIBS = \
36 $(XPCOM_STANDALONE_STATICRUNTIME_GLUE_LDOPTS) \
37 $(NULL)
39 # Need to link with CoreFoundation on Mac
40 ifeq (cocoa,$(MOZ_WIDGET_TOOLKIT))
41 LIBS += \
42 $(TK_LIBS) \
43 $(NULL)
44 endif
46 ifeq ($(OS_ARCH),WINNT)
47 RCINCLUDE = xulrunner-stub.rc
48 ifndef GNU_CC
49 RCFLAGS += -DMOZ_XULRUNNER -I$(srcdir)
50 else
51 RCFLAGS += -DMOZ_XULRUNNER --include-dir $(srcdir)
52 endif
53 LOCAL_INCLUDES += -I$(topsrcdir)/toolkit/xre
54 endif
56 ifndef MOZ_WINCONSOLE
57 ifdef MOZ_DEBUG
58 MOZ_WINCONSOLE = 1
59 else
60 MOZ_WINCONSOLE = 0
61 endif
62 endif
64 include $(topsrcdir)/config/config.mk
66 ifdef _MSC_VER
67 WIN32_EXE_LDFLAGS += -ENTRY:wmainCRTStartup
68 endif
70 include $(topsrcdir)/config/rules.mk
72 ifeq ($(OS_ARCH),WINNT)
73 OS_LIBS += $(call EXPAND_LIBNAME,shell32)
74 endif
76 ifeq (cocoa,$(MOZ_WIDGET_TOOLKIT))
78 FRAMEWORK_NAME = XUL
79 FRAMEWORK_VERSION = $(MOZILLA_VERSION)
81 FRAMEWORK_DIR = \
82 $(DIST)/$(FRAMEWORK_NAME).framework/Versions/$(FRAMEWORK_VERSION)
84 $(FRAMEWORK_DIR):
85 $(NSINSTALL) -D $@
87 $(FRAMEWORK_DIR)/$(PROGRAM): $(PROGRAM) $(FRAMEWORK_DIR)
88 $(NSINSTALL) $(PROGRAM) $(FRAMEWORK_DIR)
90 libs:: $(FRAMEWORK_DIR)/$(PROGRAM)
91 endif