bug 313956: expand installer .exe contents to make complete mar. r=ted.
[gecko.git] / xpcom / stub / Makefile.in
blobb248f903cdb3f42ea204ae5c002487c02cfbbd03
1 # vim:set ts=8 sw=8 sts=8 noet:
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 IBM Corporation.
18 # Portions created by IBM Corporation are Copyright (C) 2004
19 # IBM Corporation. All Rights Reserved.
21 # Contributor(s):
22 # Darin Fisher <darin@meer.net>
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 MODULE = xpcom
46 LIBRARY_NAME = xpcom
48 # The XPCOM glue uses realpath() on libxpcom.so to resolve any symlinks. We
49 # want it to find dist/bin and not xpcom/stub so we copy instead of symlinking.
50 NSDISTMODE = copy
52 # Do not set EXPORT_LIBRARY as we do not want xpcom in the static libs list
53 #EXPORT_LIBRARY = 1
54 GRE_MODULE = 1
55 MOZILLA_INTERNAL_API = 1
58 LOCAL_INCLUDES = -I$(srcdir)/../build
60 CPPSRCS = nsXPComStub.cpp
62 # If we have an import library, then copy that to the SDK. Otherwise,
63 # copy the shared library.
64 ifneq (,$(filter OS2 WINCE WINNT,$(OS_ARCH)))
65 SDK_LIBRARY = $(IMPORT_LIBRARY)
66 else
67 SDK_LIBRARY = $(SHARED_LIBRARY)
68 endif
70 # Force use of PIC
71 FORCE_USE_PIC = 1
73 FORCE_SHARED_LIB = 1
75 EXTRA_DSO_LDOPTS = $(LIBS_DIR)
77 DEPENDENT_LIBS_LIST += \
78 $(LIB_PREFIX)nspr4$(DLL_SUFFIX) \
79 $(LIB_PREFIX)plc4$(DLL_SUFFIX) \
80 $(LIB_PREFIX)plds4$(DLL_SUFFIX) \
81 $(LIB_PREFIX)mozalloc$(DLL_SUFFIX) \
82 $(NULL)
84 ifdef MOZ_ENABLE_LIBXUL
86 DEPENDENT_LIBS_LIST += \
87 $(LIB_PREFIX)nssutil3$(DLL_SUFFIX) \
88 $(LIB_PREFIX)softokn3$(DLL_SUFFIX) \
89 $(LIB_PREFIX)nss3$(DLL_SUFFIX) \
90 $(LIB_PREFIX)ssl3$(DLL_SUFFIX) \
91 $(LIB_PREFIX)smime3$(DLL_SUFFIX) \
92 $(NULL)
94 ifdef JS_SHARED_LIBRARY
95 DEPENDENT_LIBS_LIST += $(LIB_PREFIX)mozjs$(DLL_SUFFIX)
96 endif
98 ifndef MOZ_NATIVE_SQLITE
99 ifeq ($(OS_TARGET),OS2)
100 DEPENDENT_LIBS_LIST += mozsqlt3.dll
101 else
102 DEPENDENT_LIBS_LIST += $(LIB_PREFIX)mozsqlite3$(DLL_SUFFIX)
103 endif
104 endif
106 ifeq (bundle,$(MOZ_FS_LAYOUT))
107 EXTRA_DSO_LDOPTS += $(DIST)/bin/XUL
108 DEPENDENT_LIBS_LIST += XUL
109 else
110 EXTRA_DSO_LIBS = xul
111 DEPENDENT_LIBS_LIST += $(LIB_PREFIX)xul$(DLL_SUFFIX)
112 endif
114 else #!MOZ_ENABLE_LIBXUL
116 EXTRA_DSO_LIBS = xpcom_core
117 ifeq ($(OS_TARGET),OS2)
118 DEPENDENT_LIBS_LIST += xpcomcor.dll
119 else
120 DEPENDENT_LIBS_LIST += $(LIB_PREFIX)xpcom_core$(DLL_SUFFIX)
121 endif
123 endif #ifdef MOZ_ENABLE_LIBXUL
125 EXTRA_DSO_LDOPTS += \
126 $(EXTRA_DSO_LIBS) \
127 $(NSPR_LIBS) \
128 $(MOZALLOC_LIB) \
129 $(NULL)
131 include $(topsrcdir)/config/rules.mk
133 libs:: $(FINAL_TARGET)/dependentlibs.list
135 $(FINAL_TARGET)/dependentlibs.list: Makefile.in
136 $(EXIT_ON_ERROR) \
137 ( $(foreach dlib,$(DEPENDENT_LIBS_LIST),echo $(dlib);) ) > $@