1 | # $Id: Config.kmk 95622 2022-07-13 17:49:31Z vboxsync $
|
---|
2 | ## @file
|
---|
3 | # XPCOM kBuild Configuration file.
|
---|
4 | #
|
---|
5 |
|
---|
6 | #
|
---|
7 | # Copyright (C) 2006-2017 Oracle Corporation
|
---|
8 | #
|
---|
9 | # This file is part of VirtualBox Open Source Edition (OSE), as
|
---|
10 | # available from http://www.virtualbox.org. This file is free software;
|
---|
11 | # you can redistribute it and/or modify it under the terms of the GNU
|
---|
12 | # General Public License (GPL) as published by the Free Software
|
---|
13 | # Foundation, in version 2 as it comes in the "COPYING" file of the
|
---|
14 | # VirtualBox OSE distribution. VirtualBox OSE is distributed in the
|
---|
15 | # hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
|
---|
16 | #
|
---|
17 |
|
---|
18 | # Include the top-level configure file.
|
---|
19 | ifndef VBOX_ROOT_CONFIG_KMK_INCLUDED
|
---|
20 | include $(PATH_ROOT)/Config.kmk
|
---|
21 | endif
|
---|
22 |
|
---|
23 | #
|
---|
24 | # Globals.
|
---|
25 | #
|
---|
26 | VBOX_PATH_XPCOM_SRC := $(PATH_ROOT)/src/libs/xpcom18a4
|
---|
27 |
|
---|
28 |
|
---|
29 | #
|
---|
30 | # Template for building the XPCOM libraries (shared).
|
---|
31 | #
|
---|
32 | TEMPLATE_XPCOM = XPCOM libraries (shared)
|
---|
33 | TEMPLATE_XPCOM_EXTENDS = VBOXR3NP
|
---|
34 | ## @todo correct inheritance here to make it use all the VBOXR3NP settings instead of overriding all of them.
|
---|
35 | TEMPLATE_XPCOM_ASTOOL = $(TEMPLATE_VBOXR3NP_TOOL)
|
---|
36 | TEMPLATE_XPCOM_ASFLAGS = $(NO_SUCH_VARIABLE)
|
---|
37 | TEMPLATE_XPCOM_ASFLAGS.x86 = -m32
|
---|
38 | TEMPLATE_XPCOM_ASFLAGS.amd64 = -m64
|
---|
39 | TEMPLATE_XPCOM_ASDEFS = $(NO_SUCH_VARIABLE)
|
---|
40 | TEMPLATE_XPCOM_CXXFLAGS = -g -pipe -ansi -Wall -Wno-unused -Wno-non-virtual-dtor \
|
---|
41 | $(VBOX_GCC_Wno-invalid-offsetof) -Wno-sign-compare -Wno-unused -Wno-ctor-dtor-privacy \
|
---|
42 | $(VBOX_GCC_fvisibility-inlines-hidden) $(VBOX_GCC_fvisibility-hidden) \
|
---|
43 | $(VBOX_GCC_fdiagnostics-show-option) $(VBOX_GCC_Wno-delete-non-virtual-dtor) \
|
---|
44 | $(VBOX_GCC_SANITIZER_FLAGS) $(VBOX_GCC_OPT) $(VBOX_GCC_FP)
|
---|
45 | #if !defined(VBOX_GCC_Wno-delete-non-virtual-dtor) && defined(VBOX_GCC_Wno-non-virtual-dtor)
|
---|
46 | ifndef VBOX_GCC_Wno-delete-non-virtual-dtor
|
---|
47 | ifdef VBOX_GCC_Wno-non-virtual-dtor
|
---|
48 | TEMPLATE_XPCOM_CXXFLAGS += $(VBOX_GCC_Wno-non-virtual-dtor)
|
---|
49 | endif
|
---|
50 | endif
|
---|
51 | TEMPLATE_XPCOM_CXXFLAGS.x86 = -m32
|
---|
52 | TEMPLATE_XPCOM_CXXFLAGS.amd64 = -m64
|
---|
53 | TEMPLATE_XPCOM_CXXFLAGS.arm64 = -m64
|
---|
54 | TEMPLATE_XPCOM_CXXFLAGS.darwin = -fpascal-strings -fshort-wchar -fno-common -fno-rtti $(VBOX_DARWIN_DEF_SDK_CXXFLAGS)
|
---|
55 | TEMPLATE_XPCOM_CXXFLAGS.freebsd = -pthread
|
---|
56 | TEMPLATE_XPCOM_CXXFLAGS.linux = -pthread
|
---|
57 | TEMPLATE_XPCOM_CXXFLAGS.solaris = -fno-omit-frame-pointer # for now anyway.
|
---|
58 | TEMPLATE_XPCOM_CFLAGS = -g -pipe -Wall -Wno-unused -Wno-parentheses -Wno-uninitialized $(VBOX_GCC_fvisibility-hidden) \
|
---|
59 | $(VBOX_GCC_fdiagnostics-show-option) $(VBOX_GCC_SANITIZER_FLAGS) $(VBOX_GCC_OPT) $(VBOX_GCC_FP)
|
---|
60 | TEMPLATE_XPCOM_CFLAGS.x86 = -m32
|
---|
61 | TEMPLATE_XPCOM_CFLAGS.amd64 = -m64
|
---|
62 | TEMPLATE_XPCOM_CFLAGS.arm64 = -m64
|
---|
63 | TEMPLATE_XPCOM_CFLAGS.freebsd = -pthread
|
---|
64 | TEMPLATE_XPCOM_CFLAGS.linux = -pthread -ansi
|
---|
65 | TEMPLATE_XPCOM_CFLAGS.solaris = -fno-omit-frame-pointer # for now anyway.
|
---|
66 | TEMPLATE_XPCOM_DEFS = \
|
---|
67 | MOZILLA_CLIENT=1 \
|
---|
68 | NDEBUG=1 \
|
---|
69 | _IMPL_NS_COM \
|
---|
70 | IN_RING3 \
|
---|
71 | VBOX_USE_IPRT_IN_XPCOM
|
---|
72 | ifdef VBOX_WITH_AUTOMATIC_DEFS_QUOTING
|
---|
73 | TEMPLATE_XPCOM_DEFS += \
|
---|
74 | XPCOM_DLL_BASE="$(basename $(notdir $(LIB_XPCOM)))" \
|
---|
75 | MOZ_DLL_SUFFIX="$(suffix $(LIB_XPCOM))"
|
---|
76 | else
|
---|
77 | TEMPLATE_XPCOM_DEFS += \
|
---|
78 | XPCOM_DLL_BASE=\"$(basename $(notdir $(LIB_XPCOM)))\" \
|
---|
79 | MOZ_DLL_SUFFIX=\"$(suffix $(LIB_XPCOM))\"
|
---|
80 | endif
|
---|
81 |
|
---|
82 | ifdef VBOX_WITH_XPCOM_NAMESPACE_CLEANUP
|
---|
83 | TEMPLATE_XPCOM_DEFS += VBOX_WITH_XPCOM_NAMESPACE_CLEANUP
|
---|
84 | endif
|
---|
85 | TEMPLATE_XPCOM_DEFS.x86 = i386=1
|
---|
86 | ifdef VBOX_WITH_AUTOMATIC_DEFS_QUOTING
|
---|
87 | TEMPLATE_XPCOM_DEFS.amd64 = HAVE_VA_LIST_AS_ARRAY HAVE_VA_COPY VA_COPY(a,b)=__builtin_va_copy(a,b)
|
---|
88 | else
|
---|
89 | TEMPLATE_XPCOM_DEFS.amd64 = HAVE_VA_LIST_AS_ARRAY HAVE_VA_COPY VA_COPY\(a\,b\)=__builtin_va_copy\(a\,b\)
|
---|
90 | endif
|
---|
91 | ifdef VBOX_WITH_AUTOMATIC_DEFS_QUOTING
|
---|
92 | TEMPLATE_XPCOM_DEFS.arm64 = HAVE_VA_LIST_AS_ARRAY HAVE_VA_COPY VA_COPY(a,b)=__builtin_va_copy(a,b)
|
---|
93 | else
|
---|
94 | TEMPLATE_XPCOM_DEFS.arm64 = HAVE_VA_LIST_AS_ARRAY HAVE_VA_COPY VA_COPY\(a\,b\)=__builtin_va_copy\(a\,b\)
|
---|
95 | endif
|
---|
96 | ifdef VBOX_WITH_AUTOMATIC_DEFS_QUOTING
|
---|
97 | TEMPLATE_XPCOM_DEFS.darwin = OSTYPE="Darwin8.8.1" OSARCH="Darwin" XP_UNIX=1 XP_MACOSX=1 TARGET_CARBON=1 HAVE_VISIBILITY_ATTRIBUTE=1 DARWIN=1 $(TEMPLATE_VBOXR3NP_DEFS.darwin)
|
---|
98 | else
|
---|
99 | TEMPLATE_XPCOM_DEFS.darwin = OSTYPE=\"Darwin8.8.1\" OSARCH=\"Darwin\" XP_UNIX=1 XP_MACOSX=1 TARGET_CARBON=1 HAVE_VISIBILITY_ATTRIBUTE=1 DARWIN=1 $(TEMPLATE_VBOXR3NP_DEFS.darwin)
|
---|
100 | endif
|
---|
101 | TEMPLATE_XPCOM_DEFS.darwin.amd64 = VBOX_MACOSX_FOLLOWS_UNIX_IO
|
---|
102 | TEMPLATE_XPCOM_DEFS.darwin.arm64 = VBOX_MACOSX_FOLLOWS_UNIX_IO
|
---|
103 | ifdef VBOX_WITH_AUTOMATIC_DEFS_QUOTING
|
---|
104 | TEMPLATE_XPCOM_DEFS.freebsd = OSTYPE="FreeBSD5+" OSARCH="FreeBSD" XP_UNIX=1 FREEBSD=1 HAVE_VISIBILITY_ATTRIBUTE=1
|
---|
105 | else
|
---|
106 | TEMPLATE_XPCOM_DEFS.freebsd = OSTYPE=\"FreeBSD5+\" OSARCH=\"FreeBSD\" XP_UNIX=1 FREEBSD=1 HAVE_VISIBILITY_ATTRIBUTE=1
|
---|
107 | endif
|
---|
108 | ifdef VBOX_WITH_AUTOMATIC_DEFS_QUOTING
|
---|
109 | TEMPLATE_XPCOM_DEFS.linux = OSTYPE="Linux2.6" OSARCH="Linux" XP_UNIX=1 _GNU_SOURCE HAVE_VISIBILITY_ATTRIBUTE=1 ## @todo LINUX=1
|
---|
110 | else
|
---|
111 | TEMPLATE_XPCOM_DEFS.linux = OSTYPE=\"Linux2.6\" OSARCH=\"Linux\" XP_UNIX=1 _GNU_SOURCE HAVE_VISIBILITY_ATTRIBUTE=1 ## @todo LINUX=1
|
---|
112 | endif
|
---|
113 | # Don't define BSD_SELECT because bsdselect() from kLIBC <= 0.6.3 has problems on SMP
|
---|
114 | ifdef VBOX_WITH_AUTOMATIC_DEFS_QUOTING
|
---|
115 | TEMPLATE_XPCOM_DEFS.os2 = OSTYPE="OS/2_4.5" OSARCH="OS/2" XP_OS2 XP_PC OS2=4
|
---|
116 | else
|
---|
117 | TEMPLATE_XPCOM_DEFS.os2 = OSTYPE=\"OS/2_4.5\" OSARCH=\"OS/2\" XP_OS2 XP_PC OS2=4
|
---|
118 | endif
|
---|
119 | ifdef VBOX_WITH_AUTOMATIC_DEFS_QUOTING
|
---|
120 | TEMPLATE_XPCOM_DEFS.solaris = OSTYPE="Solaris10" OSARCH="Solaris" XP_UNIX=1 XP_SOLARIS=1 HAVE_LIBDL=1 HAVE_SENDFILEV=1 SOLARIS=1 _REENTRANT
|
---|
121 | else
|
---|
122 | TEMPLATE_XPCOM_DEFS.solaris = OSTYPE=\"Solaris10\" OSARCH=\"Solaris\" XP_UNIX=1 XP_SOLARIS=1 HAVE_LIBDL=1 HAVE_SENDFILEV=1 SOLARIS=1 _REENTRANT
|
---|
123 | endif
|
---|
124 | TEMPLATE_XPCOM_LDFLAGS = $(TEMPLATE_VBOXR3NP_LDFLAGS)
|
---|
125 | ifdef VBOX_WITH_RUNPATH
|
---|
126 | TEMPLATE_XPCOM_LDFLAGS += '$(VBOX_GCC_RPATH_OPT)$(VBOX_WITH_RUNPATH)'
|
---|
127 | else ifdef VBOX_WITH_RELATIVE_RUNPATH
|
---|
128 | TEMPLATE_XPCOM_LDFLAGS += '$(VBOX_GCC_RPATH_OPT)$(VBOX_WITH_RELATIVE_RUNPATH)'
|
---|
129 | endif
|
---|
130 | TEMPLATE_XPCOM_LDFLAGS.x86 = -m32
|
---|
131 | TEMPLATE_XPCOM_LDFLAGS.amd64 = -m64
|
---|
132 | TEMPLATE_XPCOM_LDFLAGS.arm64 = -m64
|
---|
133 | TEMPLATE_XPCOM_LDFLAGS.darwin = $(TEMPLATE_VBOXR3NP_LDFLAGS.darwin) \
|
---|
134 | -fshort-wchar -fno-rtti -fno-exceptions -fpascal-strings \
|
---|
135 | -current_version $(VBOX_VERSION_MAJOR).$(VBOX_VERSION_MINOR).$(VBOX_VERSION_BUILD) \
|
---|
136 | -compatibility_version $(VBOX_VERSION_MAJOR).$(VBOX_VERSION_MINOR).$(VBOX_VERSION_BUILD) \
|
---|
137 | -framework CoreServices \
|
---|
138 | -framework CoreFoundation \
|
---|
139 | -framework Foundation \
|
---|
140 | -framework AppKit \
|
---|
141 | -framework Carbon
|
---|
142 | ## @todo why is -fno-exceptions here.
|
---|
143 | ifn1of ($(KBUILD_TARGET), os2 win)
|
---|
144 | TEMPLATE_XPCOM_CXXFLAGS += -fPIC
|
---|
145 | TEMPLATE_XPCOM_CFLAGS += -fPIC
|
---|
146 | TEMPLATE_XPCOM_LDFLAGS += -fPIC
|
---|
147 | TEMPLATE_XPCOM_DEFS += MOZ_PRESERVE_PIC
|
---|
148 | endif
|
---|
149 | TEMPLATE_XPCOM_INCS = $(VBOX_PATH_XPCOM_SRC)/xpcom/build \
|
---|
150 | $(VBOX_PATH_XPCOM_SRC)/xpcom/ds \
|
---|
151 | $(VBOX_PATH_XPCOM_SRC)/xpcom/io \
|
---|
152 | $(VBOX_PATH_XPCOM_SRC)/xpcom/base \
|
---|
153 | $(VBOX_PATH_XPCOM_SRC)/xpcom/components \
|
---|
154 | $(VBOX_PATH_XPCOM_SRC)/xpcom/threads \
|
---|
155 | $(VBOX_PATH_XPCOM_SRC)/xpcom/proxy/src \
|
---|
156 | $(VBOX_PATH_XPCOM_SRC)/xpcom/reflect/xptcall/src \
|
---|
157 | $(VBOX_PATH_XPCOM_SRC)/ipc/ipcd/client/src \
|
---|
158 | $(VBOX_PATH_XPCOM_SRC)/ipc/ipcd/shared/src \
|
---|
159 | $(VBOX_PATH_XPCOM_SRC)/ipc/ipcd/extensions/lock/src \
|
---|
160 | $(VBOX_PATH_XPCOM_SRC)/ipc/ipcd/extensions/transmngr/src \
|
---|
161 | $(VBOX_PATH_XPCOM_SRC)/ipc/ipcd/extensions/dconnect/src \
|
---|
162 | $(VBOX_PATH_XPCOM_SRC)/ipc/ipcd/extensions/transmngr/common \
|
---|
163 | $(VBOX_PATH_SDK)/bindings/xpcom/include \
|
---|
164 | $(VBOX_PATH_SDK)/bindings/xpcom/include/nsprpub \
|
---|
165 | $(VBOX_PATH_SDK)/bindings/xpcom/include/string \
|
---|
166 | $(VBOX_PATH_SDK)/bindings/xpcom/include/xpcom \
|
---|
167 | $(VBOX_PATH_SDK)/bindings/xpcom/include/ipcd \
|
---|
168 | .
|
---|
169 | ifn1of ($(VBOX_DEF_MACOSX_VERSION_MIN),10.4 10.5 10.6 10.7) # FlatCarbon is gone starting 10.8 (or Xcode 5.0).
|
---|
170 | TEMPLATE_XPCOM_DEFS.darwin += VBOX_WITH_NEWER_OSX_SDK
|
---|
171 | TEMPLATE_XPCOM_INCS.darwin = \
|
---|
172 | $(VBOX_PATH_MACOSX_SDK)/System/Library/Frameworks/CoreFoundation.framework/Versions/A/Headers/ \
|
---|
173 | $(VBOX_PATH_MACOSX_SDK)/System/Library/Frameworks/CoreServices.framework/Versions/A/Frameworks/CarbonCore.framework/Versions/A/Headers/ \
|
---|
174 | $(VBOX_PATH_MACOSX_SDK)/System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/HIServices.framework/Versions/A/Headers/
|
---|
175 | else
|
---|
176 | TEMPLATE_XPCOM_INCS.darwin = $(VBOX_PATH_MACOSX_SDK)/Developer/Headers/FlatCarbon
|
---|
177 | endif
|
---|
178 | TEMPLATE_XPCOM_LIBS.solaris = sendfile
|
---|
179 | TEMPLATE_XPCOM_ORDERDEPS = $(foreach hdrinst, $(filter %-HEADERS, $(INSTALLS)), $($(hdrinst)_1_TARGET)) \
|
---|
180 | $(PATH_TARGET)/VBox-xpcom-idl-timestamp
|
---|
181 | ifeq ($(KBUILD_TARGET),os2)
|
---|
182 | ifndef USE_OS2_TOOLKIT_HEADERS
|
---|
183 | TEMPLATE_XPCOM_DEFS.os2 += OS2EMX_PLAIN_CHAR
|
---|
184 | endif
|
---|
185 | TEMPLATE_XPCOM_DEFS.os2 += XP_OS2_EMX OS2=4
|
---|
186 | # this is at least for strnicmp()
|
---|
187 | TEMPLATE_XPCOM_DEFS.os2 += _EMX_SOURCE
|
---|
188 | # @@todo shouldn't this be somehow default for ASTOOL?
|
---|
189 | TEMPLATE_XPCOM_ASFLAGS.os2 += -Zomf
|
---|
190 | endif
|
---|
191 |
|
---|
192 | # When using IPRT in NSRP or/and using IPRT for logging, link with IPRT.
|
---|
193 | TEMPLATE_XPCOM_LIBS += $(LIB_RUNTIME)
|
---|
194 |
|
---|
195 |
|
---|
196 | #
|
---|
197 | # Same as XPCOM except using YASM/NASM instead of the gnu/unix assembler.
|
---|
198 | #
|
---|
199 | TEMPLATE_XPCOMYASM = XPCOM w/ yasm
|
---|
200 | TEMPLATE_XPCOMYASM_EXTENDS = XPCOM
|
---|
201 | TEMPLATE_XPCOMYASM_ASTOOL = $(TEMPLATE_VBOXR3NP_ASTOOL)
|
---|
202 | TEMPLATE_XPCOMYASM_ASFLAGS = $(TEMPLATE_VBOXR3NP_ASFLAGS)
|
---|
203 | TEMPLATE_XPCOMYASM_ASFLAGS.x86 = $(TEMPLATE_VBOXR3NP_ASFLAGS.x86)
|
---|
204 | TEMPLATE_XPCOMYASM_ASFLAGS.amd64 = $(TEMPLATE_VBOXR3NP_ASFLAGS.amd64)
|
---|
205 | TEMPLATE_XPCOMYASM_ASDEFS = $(TEMPLATE_VBOXR3NP_DEFS)
|
---|
206 |
|
---|
207 |
|
---|
208 | #
|
---|
209 | # Template for building the XPCOM executables.
|
---|
210 | # Used as a base template by XPCOMTSTEXE and XPCOMIPCEXE.
|
---|
211 | #
|
---|
212 | TEMPLATE_XPCOMEXE = XPCOM executable files
|
---|
213 | TEMPLATE_XPCOMEXE_EXTENDS = XPCOM
|
---|
214 | ## @todo undo -fPIC.
|
---|
215 | TEMPLATE_XPCOMEXE_INCS = ipc/ipcd/shared/src \
|
---|
216 | $(VBOX_PATH_SDK)/bindings/xpcom/include \
|
---|
217 | $(VBOX_PATH_SDK)/bindings/xpcom/include/nsprpub \
|
---|
218 | $(VBOX_PATH_SDK)/bindings/xpcom/include/string \
|
---|
219 | $(VBOX_PATH_SDK)/bindings/xpcom/include/xpcom \
|
---|
220 | $(VBOX_PATH_SDK)/bindings/xpcom/include/ipcd \
|
---|
221 | .
|
---|
222 | TEMPLATE_XPCOMEXE_LIBS = \
|
---|
223 | $(VBox-xpcom-ipcshared_1_TARGET) \
|
---|
224 | $(VBoxXPCOM_1_TARGET) \
|
---|
225 | $(TEMPLATE_XPCOM_LIBS)
|
---|
226 | TEMPLATE_XPCOMEXE_LIBS.freebsd = $(LIB_PTHREAD)
|
---|
227 | TEMPLATE_XPCOMEXE_LIBS.linux = dl $(LIB_PTHREAD)
|
---|
228 | TEMPLATE_XPCOMEXE_LDFLAGS.darwin = -bind_at_load $(filter-out -current_version -compatibility_version $(VBOX_VERSION_MAJOR).$(VBOX_VERSION_MINOR).$(VBOX_VERSION_BUILD),$(TEMPLATE_XPCOM_LDFLAGS.darwin))
|
---|
229 |
|
---|
230 |
|
---|
231 | #
|
---|
232 | # Template for building the XPCOM testcase executables
|
---|
233 | #
|
---|
234 | TEMPLATE_XPCOMTSTEXE = XPCOM executable files (testcases)
|
---|
235 | TEMPLATE_XPCOMTSTEXE_EXTENDS = XPCOMEXE
|
---|
236 | TEMPLATE_XPCOMTSTEXE_CXXFLAGS = $(TEMPLATE_XPCOMEXE_CXXFLAGS) -Wno-format
|
---|
237 | TEMPLATE_XPCOMTSTEXE_CFLAGS = $(TEMPLATE_XPCOMEXE_CFLAGS) -Wno-format
|
---|
238 | TEMPLATE_XPCOMTSTEXE_INST = $(INST_TESTCASE)
|
---|
239 | ifdef VBOX_WITH_RUNPATH
|
---|
240 | TEMPLATE_XPCOMTSTEXE_LDFLAGS = '$(VBOX_GCC_RPATH_OPT)$(VBOX_WITH_RUNPATH)' $(TEMPLATE_XPCOMEXE_LDFLAGS)
|
---|
241 | else ifdef VBOX_WITH_RELATIVE_RUNPATH
|
---|
242 | TEMPLATE_XPCOMTSTEXE_LDFLAGS = '$(VBOX_GCC_RPATH_OPT)$(VBOX_WITH_RELATIVE_RUNPATH)/..' $(TEMPLATE_XPCOMEXE_LDFLAGS)
|
---|
243 | endif
|
---|
244 | if "$(KBUILD_TARGET)" == "win" && defined(VBOX_SIGNING_MODE)
|
---|
245 | TEMPLATE_XPCOMTSTEXE_POST_CMDS =
|
---|
246 | endif
|
---|
247 |
|
---|
248 |
|
---|
249 | #
|
---|
250 | # Template for building XPCOM executables for running at build time.
|
---|
251 | #
|
---|
252 | # It extends the BLDPROG template in config.kmk but overrides CFLAGS
|
---|
253 | # and CXXFLAGS completely at the moment.
|
---|
254 | #
|
---|
255 | TEMPLATE_XPCOMBLDPROG = XPCOM Build programs executables
|
---|
256 | TEMPLATE_XPCOMBLDPROG_EXTENDS = VBoxBldProg
|
---|
257 | ## @todo Verify that this doesn't blow up because of template inheriance ordering. (we're assuming XPCOMEXE is expanded when this is being used.)
|
---|
258 | TEMPLATE_XPCOMBLDPROG_DEFS = \
|
---|
259 | $(TEMPLATE_VBoxBldProg_DEFS) \
|
---|
260 | $(filter-out VBOX_USE_IPRT_IN_XPCOM, $(TEMPLATE_XPCOMEXE_DEFS))
|
---|
261 | TEMPLATE_XPCOMBLDPROG_DEFS.$(KBUILD_HOST) = $(TEMPLATE_VBoxBldProg_DEFS.$(KBUILD_HOST)) $(TEMPLATE_XPCOMEXE_DEFS.$(KBUILD_HOST))
|
---|
262 | TEMPLATE_XPCOMBLDPROG_DEFS.x86 = $(TEMPLATE_VBoxBldProg_DEFS.x86) $(TEMPLATE_XPCOMEXE_DEFS.x86)
|
---|
263 | TEMPLATE_XPCOMBLDPROG_DEFS.amd64 = $(TEMPLATE_VBoxBldProg_DEFS.amd64) $(TEMPLATE_XPCOMEXE_DEFS.amd64)
|
---|
264 | TEMPLATE_XPCOMBLDPROG_INCS = \
|
---|
265 | $(VBOX_PATH_SDK)/bindings/xpcom/include \
|
---|
266 | $(VBOX_PATH_SDK)/bindings/xpcom/include/nsprpub \
|
---|
267 | $(VBOX_PATH_SDK)/bindings/xpcom/include/string \
|
---|
268 | $(VBOX_PATH_SDK)/bindings/xpcom/include/xpcom \
|
---|
269 | $(VBOX_PATH_SDK)/bindings/xpcom/include/ipcd
|
---|
270 | TEMPLATE_XPCOMBLDPROG_CFLAGS = $(filter-out -pedantic -Wshadow, $(TEMPLATE_VBOX_BLDPROG_CFLAGS)) $(VBOX_GCC_Wno-int-to-pointer-cast) $(VBOX_GCC_Wno-pointer-to-int-cast) -Wno-format
|
---|
271 | TEMPLATE_XPCOMBLDPROG_CXXFLAGS.darwin = $(TEMPLATE_VBoxBldProg_CXXFLAGS.darwin) -fpascal-strings -fshort-wchar -fno-common -fno-rtti
|
---|
272 | TEMPLATE_XPCOMBLDPROG_CXXFLAGS.solaris = $(TEMPLATE_VBoxBldProg_CXXFLAGS.solaris) -fno-omit-frame-pointer # for now anyway.
|
---|
273 | TEMPLATE_XPCOMBLDPROG_LDFLAGS.darwin = $(TEMPLATE_VBoxBldProg_LDFLAGS.darwin) -fpascal-strings -fshort-wchar -fno-rtti -fno-exceptions
|
---|
274 | TEMPLATE_XPCOMBLDPROG_ORDERDEPS = $(foreach hdrinst, $(filter %-HEADERS, $(INSTALLS)), $($(hdrinst)_1_TARGET))
|
---|
275 |
|
---|
276 |
|
---|
277 | ifeq ($(VBOX_DEF_MACOSX_VERSION_MIN),10.4)
|
---|
278 | #
|
---|
279 | # Template for building VBoxPython against the Mac OS X 10.4 SDK.
|
---|
280 | # ASSUMES that the SDK bits are in the .darwin properties we're overriding below.
|
---|
281 | #
|
---|
282 | TEMPLATE_XPCOMOSX104 = XPCOM libraries (shared) built against the Mac OS X 10.4 SDK
|
---|
283 | TEMPLATE_XPCOMOSX104_EXTENDS = XPCOM
|
---|
284 | TEMPLATE_XPCOMOSX104_CXXFLAGS.darwin = $(filter-out $(VBOX_DARWIN_DEF_SDK_CXXFLAGS),$(TEMPLATE_XPCOM_CXXFLAGS.darwin)) $(VBOX_DARWIN_DEF_SDK_10_4_CXXFLAGS)
|
---|
285 | TEMPLATE_XPCOMOSX104_CFLAGS.darwin = $(filter-out $(VBOX_DARWIN_DEF_SDK_CFLAGS),$(TEMPLATE_XPCOM_CFLAGS.darwin)) $(VBOX_DARWIN_DEF_SDK_10_4_CFLAGS)
|
---|
286 | TEMPLATE_XPCOMOSX104_LDFLAGS.darwin = $(filter-out $(VBOX_DARWIN_DEF_SDK_LDFLAGS),$(TEMPLATE_XPCOM_LDFLAGS.darwin)) $(VBOX_DARWIN_DEF_SDK_10_4_LDFLAGS)
|
---|
287 | TEMPLATE_XPCOMOSX104_DEFS.darwin = $(filter-out $(VBOX_DARWIN_DEF_SDK_DEFS),$(TEMPLATE_XPCOM_DEFS.darwin)) $(VBOX_DARWIN_DEF_SDK_10_4_DEFS)
|
---|
288 | TEMPLATE_XPCOMOSX104_INCS.darwin = $(VBOX_PATH_MACOSX_SDK_10_4)/Developer/Headers/FlatCarbon
|
---|
289 | endif
|
---|
290 |
|
---|
291 | #
|
---|
292 | # Template for building VBoxPython against the Mac OS X 10.5 SDK.
|
---|
293 | # ASSUMES that the SDK bits are in the .darwin properties we're overriding below.
|
---|
294 | #
|
---|
295 | TEMPLATE_XPCOMOSX105 = XPCOM libraries (shared) built against the Mac OS X 10.5 SDK
|
---|
296 | TEMPLATE_XPCOMOSX105_EXTENDS = XPCOM
|
---|
297 | TEMPLATE_XPCOMOSX105_CXXFLAGS.darwin = $(filter-out $(VBOX_DARWIN_DEF_SDK_CXXFLAGS),$(TEMPLATE_XPCOM_CXXFLAGS.darwin)) $(VBOX_DARWIN_DEF_SDK_10_5_CXXFLAGS)
|
---|
298 | TEMPLATE_XPCOMOSX105_CFLAGS.darwin = $(filter-out $(VBOX_DARWIN_DEF_SDK_CFLAGS),$(TEMPLATE_XPCOM_CFLAGS.darwin)) $(VBOX_DARWIN_DEF_SDK_10_5_CFLAGS)
|
---|
299 | TEMPLATE_XPCOMOSX105_LDFLAGS.darwin = $(filter-out $(VBOX_DARWIN_DEF_SDK_LDFLAGS),$(TEMPLATE_XPCOM_LDFLAGS.darwin)) $(VBOX_DARWIN_DEF_SDK_10_5_LDFLAGS)
|
---|
300 | TEMPLATE_XPCOMOSX105_DEFS.darwin = $(filter-out $(VBOX_DARWIN_DEF_SDK_DEFS),$(TEMPLATE_XPCOM_DEFS.darwin)) $(VBOX_DARWIN_DEF_SDK_10_5_DEFS)
|
---|
301 | TEMPLATE_XPCOMOSX105_INCS.darwin = $(VBOX_PATH_MACOSX_SDK_10_5)/Developer/Headers/FlatCarbon
|
---|
302 |
|
---|
303 | #
|
---|
304 | # Template for building VBoxPython against the Mac OS X 10.6 SDK.
|
---|
305 | # ASSUMES that the SDK bits are in the .darwin properties we're overriding below.
|
---|
306 | #
|
---|
307 | TEMPLATE_XPCOMOSX106 = XPCOM libraries (shared) built against the Mac OS X 10.6 SDK
|
---|
308 | TEMPLATE_XPCOMOSX106_EXTENDS = XPCOM
|
---|
309 | TEMPLATE_XPCOMOSX106_CXXFLAGS.darwin = $(filter-out $(VBOX_DARWIN_DEF_SDK_CXXFLAGS),$(TEMPLATE_XPCOM_CXXFLAGS.darwin)) $(VBOX_DARWIN_DEF_SDK_10_6_CXXFLAGS)
|
---|
310 | TEMPLATE_XPCOMOSX106_CFLAGS.darwin = $(filter-out $(VBOX_DARWIN_DEF_SDK_CFLAGS),$(TEMPLATE_XPCOM_CFLAGS.darwin)) $(VBOX_DARWIN_DEF_SDK_10_6_CFLAGS)
|
---|
311 | TEMPLATE_XPCOMOSX106_LDFLAGS.darwin = $(filter-out $(VBOX_DARWIN_DEF_SDK_LDFLAGS),$(TEMPLATE_XPCOM_LDFLAGS.darwin)) $(VBOX_DARWIN_DEF_SDK_10_6_LDFLAGS)
|
---|
312 | TEMPLATE_XPCOMOSX106_DEFS.darwin = $(filter-out $(VBOX_DARWIN_DEF_SDK_DEFS),$(TEMPLATE_XPCOM_DEFS.darwin)) $(VBOX_DARWIN_DEF_SDK_10_6_DEFS)
|
---|
313 | TEMPLATE_XPCOMOSX106_INCS.darwin = $(VBOX_PATH_MACOSX_SDK_10_6)/Developer/Headers/FlatCarbon
|
---|
314 |
|
---|
315 | #
|
---|
316 | # Template for building VBoxPython against the Mac OS X 10.7 SDK.
|
---|
317 | # ASSUMES that the SDK bits are in the .darwin properties we're overriding below.
|
---|
318 | #
|
---|
319 | TEMPLATE_XPCOMOSX107 = XPCOM libraries (shared) built against the Mac OS X 10.7 SDK
|
---|
320 | TEMPLATE_XPCOMOSX107_EXTENDS = XPCOM
|
---|
321 | TEMPLATE_XPCOMOSX107_TOOL = LLVMGXX42MACHO
|
---|
322 | TEMPLATE_XPCOMOSX107_CXXFLAGS.darwin = $(filter-out $(VBOX_DARWIN_DEF_SDK_CXXFLAGS),$(TEMPLATE_XPCOM_CXXFLAGS.darwin)) $(VBOX_DARWIN_DEF_SDK_10_7_CXXFLAGS)
|
---|
323 | TEMPLATE_XPCOMOSX107_CFLAGS.darwin = $(filter-out $(VBOX_DARWIN_DEF_SDK_CFLAGS),$(TEMPLATE_XPCOM_CFLAGS.darwin)) $(VBOX_DARWIN_DEF_SDK_10_7_CFLAGS)
|
---|
324 | TEMPLATE_XPCOMOSX107_LDFLAGS.darwin = $(filter-out $(VBOX_DARWIN_DEF_SDK_LDFLAGS),$(TEMPLATE_XPCOM_LDFLAGS.darwin)) $(VBOX_DARWIN_DEF_SDK_10_7_LDFLAGS)
|
---|
325 | TEMPLATE_XPCOMOSX107_DEFS.darwin = $(filter-out $(VBOX_DARWIN_DEF_SDK_DEFS),$(TEMPLATE_XPCOM_DEFS.darwin)) $(VBOX_DARWIN_DEF_SDK_10_7_DEFS)
|
---|
326 | TEMPLATE_XPCOMOSX107_INCS.darwin = $(VBOX_PATH_MACOSX_SDK_10_7)/Developer/Headers/FlatCarbon
|
---|
327 |
|
---|
328 |
|
---|
329 | #
|
---|
330 | # Creates a x86 target for an XPCOM target if so desired.
|
---|
331 | # The target is specified as the first argument: $(evalcall VBOX_XPCOM_X86,target).
|
---|
332 | #
|
---|
333 | ifdef VBOX_WITH_32_ON_64_MAIN_API
|
---|
334 | define VBOX_XPCOM_X86
|
---|
335 | $(1)-x86_TEMPLATE := $(strip $($(1)_TEMPLATE))-x86
|
---|
336 | $(1)-x86_EXTENDS := $(1)
|
---|
337 | endef
|
---|
338 | else
|
---|
339 | define VBOX_XPCOM_X86
|
---|
340 | endef
|
---|
341 | endif
|
---|
342 |
|
---|
343 | # Corresponding 32-bit template(s).
|
---|
344 | TEMPLATE_XPCOM-x86 = 32-bit XPCOM libraries (shared)
|
---|
345 | TEMPLATE_XPCOM-x86_EXTENDS = XPCOM
|
---|
346 | TEMPLATE_XPCOM-x86_BLD_TRG_ARCH = x86
|
---|
347 | TEMPLATE_XPCOM-x86_DEFS = $(TEMPLATE_XPCOM_DEFS) VBOX_IN_32_ON_64_MAIN_API
|
---|
348 | TEMPLATE_XPCOM-x86_LIBS = $(subst $(LIB_RUNTIME),$(VBOX_LIB_RUNTIME_X86),$(TEMPLATE_XPCOM_LIBS))
|
---|
349 |
|
---|
350 | TEMPLATE_XPCOMYASM-x86 = 32-bit XPCOM libraries (shared) with YASM as assembler.
|
---|
351 | TEMPLATE_XPCOMYASM-x86_EXTENDS = XPCOMYASM
|
---|
352 | TEMPLATE_XPCOMYASM-x86_BLD_TRG_ARCH = x86
|
---|
353 | TEMPLATE_XPCOMYASM-x86_DEFS = $(TEMPLATE_XPCOMYASM_DEFS) VBOX_IN_32_ON_64_MAIN_API
|
---|
354 | TEMPLATE_XPCOMYASM-x86_LIBS = $(subst $(LIB_RUNTIME),$(VBOX_LIB_RUNTIME_X86),$(TEMPLATE_XPCOMYASM_LIBS))
|
---|
355 |
|
---|
356 |
|
---|
357 | #
|
---|
358 | # The list of XPCOM's IDL files.
|
---|
359 | # This is used by the java bindings as well as the XPCOM build.
|
---|
360 | #
|
---|
361 | XPCOM_IDLFILES = \
|
---|
362 | xpcom/base/nsIDebug.idl \
|
---|
363 | xpcom/base/nsIInterfaceRequestor.idl \
|
---|
364 | xpcom/base/nsIMemory.idl \
|
---|
365 | xpcom/base/nsIProgrammingLanguage.idl \
|
---|
366 | xpcom/base/nsISupports.idl \
|
---|
367 | xpcom/base/nsITraceRefcnt.idl \
|
---|
368 | xpcom/base/nsIWeakReference.idl \
|
---|
369 | xpcom/base/nsIConsoleMessage.idl \
|
---|
370 | xpcom/base/nsIConsoleService.idl \
|
---|
371 | xpcom/base/nsIConsoleListener.idl \
|
---|
372 | xpcom/base/nsIErrorService.idl \
|
---|
373 | xpcom/base/nsIException.idl \
|
---|
374 | xpcom/base/nsIExceptionService.idl \
|
---|
375 | xpcom/base/nsrootidl.idl \
|
---|
376 | xpcom/components/nsIClassInfo.idl \
|
---|
377 | xpcom/components/nsIComponentRegistrar.idl \
|
---|
378 | xpcom/components/nsIFactory.idl \
|
---|
379 | xpcom/components/nsIModule.idl \
|
---|
380 | xpcom/components/nsIServiceManager.idl \
|
---|
381 | xpcom/components/nsIComponentManager.idl \
|
---|
382 | xpcom/components/nsICategoryManager.idl \
|
---|
383 | xpcom/components/nsIComponentLoader.idl \
|
---|
384 | xpcom/components/nsINativeComponentLoader.idl \
|
---|
385 | xpcom/components/nsIComponentManagerObsolete.idl \
|
---|
386 | xpcom/components/nsIComponentLoaderManager.idl \
|
---|
387 | xpcom/ds/nsISupportsArray.idl \
|
---|
388 | xpcom/ds/nsICollection.idl \
|
---|
389 | xpcom/ds/nsISerializable.idl \
|
---|
390 | xpcom/ds/nsIEnumerator.idl \
|
---|
391 | xpcom/ds/nsISimpleEnumerator.idl \
|
---|
392 | xpcom/ds/nsIObserverService.idl \
|
---|
393 | xpcom/ds/nsIObserver.idl \
|
---|
394 | xpcom/ds/nsIAtom.idl \
|
---|
395 | xpcom/ds/nsIAtomService.idl \
|
---|
396 | xpcom/ds/nsIProperties.idl \
|
---|
397 | xpcom/ds/nsIPersistentProperties2.idl \
|
---|
398 | xpcom/ds/nsIRecyclingAllocator.idl \
|
---|
399 | xpcom/ds/nsIStringEnumerator.idl \
|
---|
400 | xpcom/ds/nsISupportsPrimitives.idl \
|
---|
401 | xpcom/ds/nsISupportsIterators.idl \
|
---|
402 | xpcom/ds/nsIVariant.idl \
|
---|
403 | xpcom/ds/nsITimelineService.idl \
|
---|
404 | xpcom/ds/nsIArray.idl \
|
---|
405 | xpcom/ds/nsIPropertyBag.idl \
|
---|
406 | xpcom/ds/nsIHashable.idl \
|
---|
407 | xpcom/io/nsIDirectoryService.idl \
|
---|
408 | xpcom/io/nsIDirectoryEnumerator.idl \
|
---|
409 | xpcom/io/nsIFile.idl \
|
---|
410 | xpcom/io/nsILocalFile.idl \
|
---|
411 | xpcom/io/nsILocalFileMac.idl \
|
---|
412 | xpcom/io/nsIInputStream.idl \
|
---|
413 | xpcom/io/nsIObjectInputStream.idl \
|
---|
414 | xpcom/io/nsIBinaryInputStream.idl \
|
---|
415 | xpcom/io/nsIObjectOutputStream.idl \
|
---|
416 | xpcom/io/nsIBinaryOutputStream.idl \
|
---|
417 | xpcom/io/nsIOutputStream.idl \
|
---|
418 | xpcom/io/nsIStreamBufferAccess.idl \
|
---|
419 | xpcom/io/nsIByteArrayInputStream.idl \
|
---|
420 | xpcom/io/nsISeekableStream.idl \
|
---|
421 | xpcom/io/nsIFastLoadFileControl.idl \
|
---|
422 | xpcom/io/nsIFastLoadService.idl \
|
---|
423 | xpcom/io/nsIInputStreamTee.idl \
|
---|
424 | xpcom/io/nsIMultiplexInputStream.idl \
|
---|
425 | xpcom/io/nsIPipe.idl \
|
---|
426 | xpcom/io/nsIAsyncInputStream.idl \
|
---|
427 | xpcom/io/nsIAsyncOutputStream.idl \
|
---|
428 | xpcom/io/nsIScriptableInputStream.idl \
|
---|
429 | xpcom/io/nsIStorageStream.idl \
|
---|
430 | xpcom/io/nsIStringStream.idl \
|
---|
431 | xpcom/io/nsILineInputStream.idl \
|
---|
432 | xpcom/proxy/public/nsIProxyObjectManager.idl \
|
---|
433 | xpcom/threads/nsIEventQueueService.idl \
|
---|
434 | xpcom/threads/nsIEventQueue.idl \
|
---|
435 | xpcom/threads/nsIEventTarget.idl \
|
---|
436 | xpcom/threads/nsIRunnable.idl \
|
---|
437 | xpcom/threads/nsIThread.idl \
|
---|
438 | xpcom/threads/nsITimer.idl \
|
---|
439 | xpcom/threads/nsIEnvironment.idl \
|
---|
440 | xpcom/threads/nsITimerInternal.idl \
|
---|
441 | xpcom/threads/nsITimerManager.idl \
|
---|
442 | xpcom/threads/nsIProcess.idl \
|
---|
443 | xpcom/reflect/xptinfo/public/nsIInterfaceInfo.idl \
|
---|
444 | xpcom/reflect/xptinfo/public/nsIInterfaceInfoManager.idl \
|
---|
445 | xpcom/reflect/xptinfo/public/nsIXPTLoader.idl \
|
---|
446 | ipc/ipcd/client/public/ipcIService.idl \
|
---|
447 | ipc/ipcd/client/public/ipcIMessageObserver.idl \
|
---|
448 | ipc/ipcd/client/public/ipcIClientObserver.idl \
|
---|
449 | ipc/ipcd/extensions/lock/public/ipcILockService.idl \
|
---|
450 | ipc/ipcd/extensions/transmngr/public/ipcITransactionService.idl \
|
---|
451 | ipc/ipcd/extensions/dconnect/public/ipcIDConnectService.idl \
|
---|
452 | ipc/ipcd/extensions/transmngr/public/ipcITransactionObserver.idl
|
---|
453 |
|
---|
454 | #
|
---|
455 | # The include path for the XPCOM IDL files above.
|
---|
456 | #
|
---|
457 | XPIDL_INCS = \
|
---|
458 | -I $(VBOX_PATH_XPCOM_SRC)/xpcom/base/ \
|
---|
459 | -I $(VBOX_PATH_XPCOM_SRC)/xpcom/ds/ \
|
---|
460 | -I $(VBOX_PATH_XPCOM_SRC)/xpcom/components/ \
|
---|
461 | -I $(VBOX_PATH_XPCOM_SRC)/xpcom/io/ \
|
---|
462 | -I $(VBOX_PATH_XPCOM_SRC)/xpcom/threads/ \
|
---|
463 | -I $(VBOX_PATH_XPCOM_SRC)/xpcom/reflect/xptinfo/public/
|
---|
464 |
|
---|