1 | # $Id: Makefile.kmk 102051 2023-11-09 19:53:51Z vboxsync $
|
---|
2 | ## @file
|
---|
3 | # Sub-Makefile for XPCOM.
|
---|
4 | #
|
---|
5 |
|
---|
6 | #
|
---|
7 | # Copyright (C) 2006-2023 Oracle and/or its affiliates.
|
---|
8 | #
|
---|
9 | # This file is part of VirtualBox base platform packages, as
|
---|
10 | # available from https://www.virtualbox.org.
|
---|
11 | #
|
---|
12 | # This program is free software; you can redistribute it and/or
|
---|
13 | # modify it under the terms of the GNU General Public License
|
---|
14 | # as published by the Free Software Foundation, in version 3 of the
|
---|
15 | # License.
|
---|
16 | #
|
---|
17 | # This program is distributed in the hope that it will be useful, but
|
---|
18 | # WITHOUT ANY WARRANTY; without even the implied warranty of
|
---|
19 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
---|
20 | # General Public License for more details.
|
---|
21 | #
|
---|
22 | # You should have received a copy of the GNU General Public License
|
---|
23 | # along with this program; if not, see <https://www.gnu.org/licenses>.
|
---|
24 | #
|
---|
25 | # SPDX-License-Identifier: GPL-3.0-only
|
---|
26 | #
|
---|
27 |
|
---|
28 | SUB_DEPTH = ../../..
|
---|
29 | include $(KBUILD_PATH)/subheader.kmk
|
---|
30 |
|
---|
31 | # Make sure our Config.kmk is included.
|
---|
32 | ifndef VBOX_PATH_XPCOM_SRC
|
---|
33 | include $(PATH_SUB_CURRENT)/Config.kmk
|
---|
34 | endif
|
---|
35 |
|
---|
36 | #
|
---|
37 | # Globals
|
---|
38 | #
|
---|
39 |
|
---|
40 | # File for filtering out C symbols from the XPCOM library. Used to avoid
|
---|
41 | # symbol namespace pollution, causing trouble with system libraries.
|
---|
42 | XPCOM_C_NAMESPACE_MAP = $(VBOX_PATH_XPCOM_SRC)/xpcom-namespace-cleanup.map
|
---|
43 | ifdef VBOX_WITH_XPCOM_NAMESPACE_CLEANUP
|
---|
44 | # At the moment, only Solaris uses the generated map file. GNU ld is smart
|
---|
45 | # enough to handle symbol wildcards itself.
|
---|
46 | if1of ($(KBUILD_TARGET), solaris)
|
---|
47 | XPCOM_C_NAMESPACE_MAP = $(PATH_TARGET)/xpcom-namespace-cleanup.map
|
---|
48 | OTHER_CLEAN += $(XPCOM_C_NAMESPACE_MAP)
|
---|
49 | endif
|
---|
50 | endif
|
---|
51 |
|
---|
52 | # @todo check whether VBoxXPCOMIPCC.so or VBoxXPCOMIPCD contain undefined
|
---|
53 | # symbols starting with NS_, PL_, PR_ or XPT. Would move the test time failure
|
---|
54 | # when missing a symbol renaming to a build time failure. Likewise, there
|
---|
55 | # should be a check whether VBoxXPCOM.so contains global C symbols (at least
|
---|
56 | # where the whitelisting of symbols via the map file is not used).
|
---|
57 |
|
---|
58 | #
|
---|
59 | # Header installs.
|
---|
60 | #
|
---|
61 | INSTALLS += \
|
---|
62 | NSPRPUB-HEADERS \
|
---|
63 | NSPRPUB-MD-HEADERS \
|
---|
64 | NSPRPUB-PRIV-HEADERS \
|
---|
65 | STRING-HEADERS \
|
---|
66 | XPCOM-HEADERS \
|
---|
67 | IPCD-HEADERS
|
---|
68 |
|
---|
69 | #
|
---|
70 | # The IDL compiler, typelib linker and xpt files.
|
---|
71 | #
|
---|
72 | BLDPROGS += \
|
---|
73 | xpidl \
|
---|
74 | xpt_link
|
---|
75 |
|
---|
76 | BLDDIRS += \
|
---|
77 | $(PATH_TARGET)/VBox-xpcom-xpt-files/
|
---|
78 |
|
---|
79 | #
|
---|
80 | # Always build the VBoxXPCOM import library.
|
---|
81 | #
|
---|
82 | IMPORT_LIBS += VBoxXPCOMImp
|
---|
83 |
|
---|
84 | #
|
---|
85 | # We build several libraries so that any linker command line
|
---|
86 | # length restrictions limit will be avoided. (Solaris, Mac?)
|
---|
87 | #
|
---|
88 | if !defined(VBOX_ONLY_SDK) && (!defined(VBOX_ONLY_EXTPACKS) || !defined(VBOX_ONLY_EXTPACKS_USE_IMPLIBS))
|
---|
89 |
|
---|
90 | VBOX_XPCOM_LIBRARIES := \
|
---|
91 | VBox-xpcom-nspr \
|
---|
92 | VBox-xpcom-typelib \
|
---|
93 | VBox-xpcom-string \
|
---|
94 | VBox-xpcom-base \
|
---|
95 | VBox-xpcom-ds \
|
---|
96 | VBox-xpcom-io \
|
---|
97 | VBox-xpcom-components \
|
---|
98 | VBox-xpcom-threads \
|
---|
99 | VBox-xpcom-xptinfo \
|
---|
100 | VBox-xpcom-xptcall \
|
---|
101 | VBox-xpcom-proxy \
|
---|
102 | VBox-xpcom-ipcshared \
|
---|
103 | VBoxXPCOMGlue_s \
|
---|
104 | $(if $(VBOX_WITH_XPCOM_GLUE_WHICH_IS_UNUSED),VBoxXPCOMGlue,)
|
---|
105 | LIBRARIES += $(VBOX_XPCOM_LIBRARIES)
|
---|
106 |
|
---|
107 | VBOX_XPCOM_DLLS := \
|
---|
108 | VBoxXPCOM \
|
---|
109 | VBoxXPCOMIPCC
|
---|
110 | DLLS += $(VBOX_XPCOM_DLLS)
|
---|
111 |
|
---|
112 | ifdef VBOX_WITH_32_ON_64_MAIN_API
|
---|
113 | LIBRARIES += $(addsuffix -x86,$(VBOX_XPCOM_LIBRARIES))
|
---|
114 | DLLS += $(addsuffix -x86,$(VBOX_XPCOM_DLLS))
|
---|
115 | endif
|
---|
116 |
|
---|
117 |
|
---|
118 | ifdef VBOX_WITH_TESTCASES
|
---|
119 | PROGRAMS += \
|
---|
120 | tstnsIFileTest \
|
---|
121 | tstTestArray \
|
---|
122 | tstTestAutoLock \
|
---|
123 | tstTestCOMPtr \
|
---|
124 | tstTestCOMPtrEq \
|
---|
125 | tstTestCRT \
|
---|
126 | tstTestFactory \
|
---|
127 | tstTestHashtables \
|
---|
128 | tstTestID \
|
---|
129 | tstTestObserverService \
|
---|
130 | tstTestXPIDLString \
|
---|
131 | tstTestXPTCInvoke \
|
---|
132 | tstTestDeque \
|
---|
133 | tstTestAutoPtr \
|
---|
134 | tstTestMinStringAPI \
|
---|
135 | tstTestStrings \
|
---|
136 | tstPrimitiveTest
|
---|
137 | # tstnsIFileEnumerator
|
---|
138 | # tstTestAtoms
|
---|
139 | # tstTestServMgr
|
---|
140 | # tstTestCallTemplates
|
---|
141 | # tstTestPermanentAtoms
|
---|
142 | # tstSimpleTypeLib
|
---|
143 | # tstXptDump
|
---|
144 | # tstXptLink
|
---|
145 | endif # VBOX_WITH_TESTCASES
|
---|
146 | PROGRAMS += VBoxXPCOMIPCD
|
---|
147 |
|
---|
148 | endif # !VBOX_ONLY_SDK && (!defined(VBOX_ONLY_EXTPACKS) || !defined(VBOX_ONLY_EXTPACKS_USE_IMPLIBS))
|
---|
149 |
|
---|
150 |
|
---|
151 |
|
---|
152 |
|
---|
153 | #
|
---|
154 | # SDK headers - lot's of files to install...
|
---|
155 | #
|
---|
156 | # Tip: If you are going to remove files here, you might
|
---|
157 | # wish to do a `kmk uninstall' first to avoid have
|
---|
158 | # obsoleted files in the $(INST_SDK) directory.
|
---|
159 | #
|
---|
160 | NSPRPUB-HEADERS_INST = $(INST_SDK)bindings/xpcom/include/nsprpub/
|
---|
161 | NSPRPUB-HEADERS_IFFLAGS = -m 644
|
---|
162 | NSPRPUB-HEADERS_SOURCES = \
|
---|
163 | nsprpub/pr/include/nspr.h \
|
---|
164 | nsprpub/lib/ds/plarena.h \
|
---|
165 | nsprpub/lib/ds/plarenas.h \
|
---|
166 | nsprpub/lib/ds/plhash.h \
|
---|
167 | nsprpub/lib/libc/include/plstr.h \
|
---|
168 | nsprpub/pr/include/prbit.h \
|
---|
169 | nsprpub/pr/include/prclist.h \
|
---|
170 | nsprpub/pr/include/prcvar.h \
|
---|
171 | nsprpub/pr/include/prerr.h \
|
---|
172 | nsprpub/pr/include/prerror.h \
|
---|
173 | nsprpub/pr/include/prinet.h \
|
---|
174 | nsprpub/pr/include/prinit.h \
|
---|
175 | nsprpub/pr/include/prinrval.h \
|
---|
176 | nsprpub/pr/include/prio.h \
|
---|
177 | nsprpub/pr/include/prlock.h \
|
---|
178 | nsprpub/pr/include/prlong.h \
|
---|
179 | nsprpub/pr/include/prmem.h \
|
---|
180 | nsprpub/pr/include/prmon.h \
|
---|
181 | nsprpub/pr/include/prprf.h \
|
---|
182 | nsprpub/pr/include/prthread.h \
|
---|
183 | nsprpub/pr/include/prtime.h \
|
---|
184 | nsprpub/pr/include/prtypes.h \
|
---|
185 | nsprpub/pr/include/md/_vbox.cfg=>prcpucfg.h
|
---|
186 | NSPRPUB-MD-HEADERS_INST = $(INST_SDK)bindings/xpcom/include/nsprpub/md/
|
---|
187 | NSPRPUB-MD-HEADERS_IFFLAGS = -m 644
|
---|
188 | NSPRPUB-MD-HEADERS_SOURCES = \
|
---|
189 | nsprpub/pr/include/md/_darwin.h \
|
---|
190 | nsprpub/pr/include/md/_freebsd.h \
|
---|
191 | nsprpub/pr/include/md/_linux.h \
|
---|
192 | nsprpub/pr/include/md/_netbsd.h \
|
---|
193 | nsprpub/pr/include/md/_openbsd.h \
|
---|
194 | nsprpub/pr/include/md/_solaris.h \
|
---|
195 | nsprpub/pr/include/md/_unix_errors.h \
|
---|
196 | nsprpub/pr/include/md/_unixos.h \
|
---|
197 | nsprpub/pr/include/md/_pth.h \
|
---|
198 | nsprpub/pr/include/md/prosdep.h \
|
---|
199 | \
|
---|
200 | nsprpub/pr/include/md/_freebsd.cfg \
|
---|
201 | nsprpub/pr/include/md/_linux.cfg \
|
---|
202 | nsprpub/pr/include/md/_darwin.cfg \
|
---|
203 | nsprpub/pr/include/md/_netbsd.cfg \
|
---|
204 | nsprpub/pr/include/md/_openbsd.cfg \
|
---|
205 | nsprpub/pr/include/md/_solaris32.cfg \
|
---|
206 | nsprpub/pr/include/md/_solaris64.cfg
|
---|
207 |
|
---|
208 | NSPRPUB-PRIV-HEADERS_INST = $(INST_SDK)bindings/xpcom/include/nsprpub/private/
|
---|
209 | NSPRPUB-PRIV-HEADERS_IFFLAGS = -m 644
|
---|
210 | NSPRPUB-PRIV-HEADERS_SOURCES = \
|
---|
211 | nsprpub/pr/include/private/pprio.h \
|
---|
212 | nsprpub/pr/include/private/pprthred.h \
|
---|
213 | nsprpub/pr/include/private/prpriv.h
|
---|
214 |
|
---|
215 | STRING-HEADERS_INST = $(INST_SDK)bindings/xpcom/include/string/
|
---|
216 | STRING-HEADERS_IFFLAGS = -m 644
|
---|
217 | STRING-HEADERS_SOURCES = \
|
---|
218 | xpcom/string/public/nsAString.h \
|
---|
219 | xpcom/string/public/nsAlgorithm.h \
|
---|
220 | xpcom/string/public/nsCharTraits.h \
|
---|
221 | xpcom/string/public/nsDependentString.h \
|
---|
222 | xpcom/string/public/nsDependentSubstring.h \
|
---|
223 | xpcom/string/public/nsEmbedString.h \
|
---|
224 | xpcom/string/public/nsLiteralString.h \
|
---|
225 | xpcom/string/public/nsObsoleteAString.h \
|
---|
226 | xpcom/string/public/nsPrintfCString.h \
|
---|
227 | xpcom/string/public/nsPromiseFlatString.h \
|
---|
228 | xpcom/string/public/nsReadableUtils.h \
|
---|
229 | xpcom/string/public/nsString.h \
|
---|
230 | xpcom/string/public/nsStringAPI.h \
|
---|
231 | xpcom/string/public/nsStringFwd.h \
|
---|
232 | xpcom/string/public/nsStringIterator.h \
|
---|
233 | xpcom/string/public/nsSubstring.h \
|
---|
234 | xpcom/string/public/nsSubstringTuple.h \
|
---|
235 | xpcom/string/public/nsTAString.h \
|
---|
236 | xpcom/string/public/nsTDependentString.h \
|
---|
237 | xpcom/string/public/nsTDependentSubstring.h \
|
---|
238 | xpcom/string/public/nsTObsoleteAString.h \
|
---|
239 | xpcom/string/public/nsTPromiseFlatString.h \
|
---|
240 | xpcom/string/public/nsTString.h \
|
---|
241 | xpcom/string/public/nsTSubstring.h \
|
---|
242 | xpcom/string/public/nsTSubstringTuple.h \
|
---|
243 | xpcom/string/public/nsUTF8Utils.h \
|
---|
244 | xpcom/string/public/nsXPIDLString.h \
|
---|
245 | xpcom/string/public/string-template-def-char.h \
|
---|
246 | xpcom/string/public/string-template-def-unichar.h \
|
---|
247 | xpcom/string/public/string-template-undef.h
|
---|
248 |
|
---|
249 | XPCOM-HEADERS_INST = $(INST_SDK)bindings/xpcom/include/xpcom/
|
---|
250 | XPCOM-HEADERS_IFFLAGS = -m 644
|
---|
251 | XPCOM-HEADERS_SOURCES = \
|
---|
252 | xpcom/base/nsAgg.h \
|
---|
253 | xpcom/io/nsAppDirectoryServiceDefs.h \
|
---|
254 | xpcom/ds/nsArray.h \
|
---|
255 | xpcom/ds/nsArrayEnumerator.h \
|
---|
256 | xpcom/ds/nsAtomService.h \
|
---|
257 | xpcom/ds/nsAutoBuffer.h \
|
---|
258 | xpcom/threads/nsAutoLock.h \
|
---|
259 | xpcom/base/nsAutoPtr.h \
|
---|
260 | xpcom/ds/nsBaseHashtable.h \
|
---|
261 | xpcom/ds/nsCOMArray.h \
|
---|
262 | xpcom/ds/nsCRT.h \
|
---|
263 | xpcom/components/nsCategoryManagerUtils.h \
|
---|
264 | xpcom/ds/nsClassHashtable.h \
|
---|
265 | xpcom/base/nsCom.h \
|
---|
266 | xpcom/components/nsComponentManagerObsolete.h \
|
---|
267 | xpcom/components/nsComponentManagerUtils.h \
|
---|
268 | xpcom/ds/nsCppSharedAllocator.h \
|
---|
269 | xpcom/ds/nsDataHashtable.h \
|
---|
270 | xpcom/base/nsDebugImpl.h \
|
---|
271 | xpcom/ds/nsDeque.h \
|
---|
272 | xpcom/io/nsDirectoryService.h \
|
---|
273 | xpcom/io/nsDirectoryServiceDefs.h \
|
---|
274 | xpcom/io/nsDirectoryServiceUtils.h \
|
---|
275 | xpcom/ds/nsDoubleHashtable.h \
|
---|
276 | xpcom/ds/nsEnumeratorUtils.h \
|
---|
277 | xpcom/base/nsError.h \
|
---|
278 | xpcom/threads/nsEventQueueUtils.h \
|
---|
279 | xpcom/ds/nsHashKeys.h \
|
---|
280 | xpcom/ds/nsHashSets.h \
|
---|
281 | xpcom/ds/nsHashtable.h \
|
---|
282 | xpcom/base/nsID.h \
|
---|
283 | xpcom/base/nsIID.h \
|
---|
284 | xpcom/components/nsIServiceManagerObsolete.h \
|
---|
285 | xpcom/components/nsIServiceManagerUtils.h \
|
---|
286 | xpcom/base/nsISupportsBase.h \
|
---|
287 | xpcom/ds/nsInt64.h \
|
---|
288 | xpcom/ds/nsInterfaceHashtable.h \
|
---|
289 | xpcom/io/nsLocalFile.h \
|
---|
290 | xpcom/io/nsLocalFileUnix.h \
|
---|
291 | xpcom/io/nsLocalFileOSX.h \
|
---|
292 | xpcom/components/nsModule.h \
|
---|
293 | xpcom/io/nsNativeCharsetUtils.h \
|
---|
294 | xpcom/components/nsNativeComponentLoader.h \
|
---|
295 | xpcom/ds/nsObserverService.h \
|
---|
296 | xpcom/components/nsObsoleteModuleLoading.h \
|
---|
297 | xpcom/proxy/public/nsProxiedService.h \
|
---|
298 | xpcom/proxy/public/nsProxyEvent.h \
|
---|
299 | xpcom/proxy/public/nsProxyRelease.h \
|
---|
300 | xpcom/ds/nsQuickSort.h \
|
---|
301 | xpcom/ds/nsRefPtrHashtable.h \
|
---|
302 | xpcom/io/nsScriptableInputStream.h \
|
---|
303 | xpcom/ds/nsStaticAtom.h \
|
---|
304 | xpcom/components/nsStaticComponent.h \
|
---|
305 | xpcom/ds/nsStaticNameTable.h \
|
---|
306 | xpcom/ds/nsStringEnumerator.h \
|
---|
307 | xpcom/io/nsStringIO.h \
|
---|
308 | xpcom/ds/nsSupportsArray.h \
|
---|
309 | xpcom/ds/nsSupportsPrimitives.h \
|
---|
310 | xpcom/ds/nsTHashtable.h \
|
---|
311 | xpcom/base/nsTraceRefcntImpl.h \
|
---|
312 | xpcom/ds/nsValueArray.h \
|
---|
313 | xpcom/ds/nsVariant.h \
|
---|
314 | xpcom/ds/nsVoidArray.h \
|
---|
315 | xpcom/base/nsWeakPtr.h \
|
---|
316 | xpcom/build/nsXPCOM.h \
|
---|
317 | xpcom/build/nsXPCOMCID.h \
|
---|
318 | xpcom/base/nscore.h \
|
---|
319 | xpcom/ds/pldhash.h \
|
---|
320 | xpcom/threads/plevent.h \
|
---|
321 | xpcom/components/xcDll.h \
|
---|
322 | xpcom/typelib/xpt/public/xpt_arena.h \
|
---|
323 | xpcom/typelib/xpt/public/xpt_struct.h \
|
---|
324 | xpcom/typelib/xpt/public/xpt_xdr.h \
|
---|
325 | xpcom/reflect/xptcall/public/xptcall.h \
|
---|
326 | xpcom/reflect/xptcall/public/xptcstubsdecl.inc \
|
---|
327 | xpcom/reflect/xptcall/public/xptcstubsdef.inc \
|
---|
328 | xpcom/reflect/xptinfo/public/xptinfo.h \
|
---|
329 | \
|
---|
330 | xpcom/glue/nsIInterfaceRequestorUtils.h \
|
---|
331 | xpcom/glue/nsISupportsImpl.h \
|
---|
332 | xpcom/glue/nsISupportsUtils.h \
|
---|
333 | xpcom/glue/nsIWeakReferenceUtils.h \
|
---|
334 | \
|
---|
335 | xpcom/glue/nsCOMPtr.h \
|
---|
336 | xpcom/glue/nsDebug.h \
|
---|
337 | xpcom/glue/nsGenericFactory.h \
|
---|
338 | xpcom/glue/nsIGenericFactory.h \
|
---|
339 | xpcom/glue/nsMemory.h \
|
---|
340 | xpcom/glue/nsTraceRefcnt.h \
|
---|
341 | xpcom/glue/nsWeakReference.h \
|
---|
342 | \
|
---|
343 | xpcom/glue/standalone/nsXPCOMGlue.h \
|
---|
344 | \
|
---|
345 | xpcom-config.h
|
---|
346 |
|
---|
347 | IPCD-HEADERS_INST = $(INST_SDK)bindings/xpcom/include/ipcd/
|
---|
348 | IPCD-HEADERS_IFFLAGS = -m 644
|
---|
349 | IPCD-HEADERS_SOURCES = \
|
---|
350 | ipc/ipcd/client/public/ipcCID.h \
|
---|
351 | ipc/ipcd/extensions/lock/public/ipcLockCID.h \
|
---|
352 | ipc/ipcd/util/public/ipcMessageReader.h \
|
---|
353 | ipc/ipcd/util/public/ipcMessageWriter.h \
|
---|
354 | ipc/ipcd/client/public/ipcdclient.h
|
---|
355 |
|
---|
356 |
|
---|
357 | #
|
---|
358 | # The IDL compiler.
|
---|
359 | #
|
---|
360 | # We build it statically because we cannot rely on additional .a files
|
---|
361 | # like in the original build
|
---|
362 | #
|
---|
363 | xpidl_TEMPLATE = XPComBldProg
|
---|
364 | xpidl_DEFS = EXPORT_XPT_API
|
---|
365 | ## @todo This assumes HOST == TARGET.
|
---|
366 | xpidl_INST = $(INST_BIN)
|
---|
367 | ## Obsolete hack: MacPorts is 32-bit on 10.5 and 64-bit on 10.6. Set your KBUILD_HOST_ARCH env.vars. accordingly.
|
---|
368 | #if "$(KBUILD_HOST).$(KBUILD_HOST_ARCH)" == "darwin.amd64" && defined(VBOX_MACOS_10_5_WORKAROUND)
|
---|
369 | # xpidl_BLD_TRG_ARCH = x86
|
---|
370 | # ## @todo kBuild ticket 84 workarounds:
|
---|
371 | # xpidl_DEFS.x86 = $(TEMPLATE_XPComBldProg_DEFS.x86)
|
---|
372 | # xpidl_CFLAGS.x86 = $(TEMPLATE_XPComBldProg_CFLAGS.x86)
|
---|
373 | # xpidl_CXXFLAGS.x86 = $(TEMPLATE_XPComBldProg_CXXFLAGS.x86)
|
---|
374 | # xpidl_LDFLAGS.x86 = $(TEMPLATE_XPComBldProg_LDFLAGS.x86)
|
---|
375 | #endif
|
---|
376 | ifdef VBOX_WITH_JAVA_SUPPORT_IN_XPIDL
|
---|
377 | xpidl_DEFS += VBOX_XPIDL_EMULATE_GENJIFACES VBOX_XPIDL_EMULATE_GENJIFACES_DIFF
|
---|
378 | endif
|
---|
379 | xpidl_SOURCES = \
|
---|
380 | xpcom/typelib/xpidl/xpidl.c \
|
---|
381 | xpcom/typelib/xpidl/xpidl_idl.c \
|
---|
382 | xpcom/typelib/xpidl/xpidl_util.c \
|
---|
383 | xpcom/typelib/xpidl/xpidl_header.c \
|
---|
384 | xpcom/typelib/xpidl/xpidl_typelib.c \
|
---|
385 | xpcom/typelib/xpidl/xpidl_doc.c \
|
---|
386 | xpcom/typelib/xpidl/xpidl_java.c \
|
---|
387 | xpcom/typelib/xpt/src/xpt_arena.c \
|
---|
388 | xpcom/typelib/xpt/src/xpt_struct.c \
|
---|
389 | xpcom/typelib/xpt/src/xpt_xdr.c
|
---|
390 |
|
---|
391 | # We do these ONCE.
|
---|
392 | libIDL_config_cflags := $(shell $(VBOX_LIBIDL_CONFIG) --cflags)
|
---|
393 | libIDL_config_libs := $(shell $(VBOX_LIBIDL_CONFIG) --libs)
|
---|
394 | xpidl_CFLAGS = \
|
---|
395 | $(libIDL_config_cflags)
|
---|
396 | if1of ($(KBUILD_HOST), linux solaris)
|
---|
397 | xpidl_LDFLAGS = \
|
---|
398 | $(filter-out -l%,$(libIDL_config_libs))
|
---|
399 | xpidl_LIBS.$(KBUILD_HOST) += \
|
---|
400 | $(subst -l,,$(filter -l%,$(libIDL_config_libs)))
|
---|
401 | else
|
---|
402 | xpidl_LDFLAGS = \
|
---|
403 | $(libIDL_config_libs)
|
---|
404 | endif
|
---|
405 | xpidl_LDFLAGS.linux = \
|
---|
406 | $(VBOX_LD_as_needed)
|
---|
407 |
|
---|
408 | #
|
---|
409 | # The XPT linker.
|
---|
410 | #
|
---|
411 | xpt_link_TEMPLATE = XPComBldProg
|
---|
412 | xpt_link_SOURCES = \
|
---|
413 | xpcom/typelib/xpt/tools/xpt_link.c \
|
---|
414 | xpcom/typelib/xpt/src/xpt_arena.c \
|
---|
415 | xpcom/typelib/xpt/src/xpt_struct.c \
|
---|
416 | xpcom/typelib/xpt/src/xpt_xdr.c
|
---|
417 |
|
---|
418 |
|
---|
419 | #
|
---|
420 | # The NSPR Library.
|
---|
421 | #
|
---|
422 | VBox-xpcom-nspr_TEMPLATE = XPComDll
|
---|
423 | VBox-xpcom-nspr_INSTTYPE = none
|
---|
424 | VBox-xpcom-nspr_DEFS = \
|
---|
425 | _NSPR_BUILD_ \
|
---|
426 | HAVE_LCHOWN=1 \
|
---|
427 | HAVE_STRERROR=1 \
|
---|
428 | FORCE_PR_LOG
|
---|
429 | VBox-xpcom-nspr_DEFS += \
|
---|
430 | VBOX_USE_IPRT_IN_NSPR
|
---|
431 | VBox-xpcom-nspr_DEFS.darwin.amd64 = \
|
---|
432 | VBOX_USE_MORE_IPRT_IN_NSPR
|
---|
433 | VBox-xpcom-nspr_DEFS.darwin.arm64 = \
|
---|
434 | VBOX_USE_MORE_IPRT_IN_NSPR
|
---|
435 | VBox-xpcom-nspr_DEFS.darwin = \
|
---|
436 | HAVE_BSD_FLOCK=1 \
|
---|
437 | HAVE_SOCKLEN_T=1 \
|
---|
438 | _PR_PTHREADS
|
---|
439 | VBox-xpcom-nspr_DEFS.freebsd = \
|
---|
440 | FREEBSD=1 \
|
---|
441 | HAVE_CVAR_BUILT_ON_SEM \
|
---|
442 | _PR_PTHREADS
|
---|
443 | ## @todo filling in the missing stuff, please don't just copy it from linux.
|
---|
444 | # FIXME: LINUX should be defined by _linux.cfg
|
---|
445 | VBox-xpcom-nspr_DEFS.linux = \
|
---|
446 | LINUX=1 \
|
---|
447 | _POSIX_SOURCE=1 \
|
---|
448 | _BSD_SOURCE=1 \
|
---|
449 | _SVID_SOURCE=1 \
|
---|
450 | _DEFAULT_SOURCE \
|
---|
451 | _REENTRANT=1 \
|
---|
452 | _LARGEFILE64_SOURCE=1 \
|
---|
453 | HAVE_FCNTL_FILE_LOCKING=1 \
|
---|
454 | HAVE_CVAR_BUILT_ON_SEM \
|
---|
455 | _PR_PTHREADS
|
---|
456 | # _BSD_SOURCE is here to keep the Glibc header files happy and make them include the right things
|
---|
457 | VBox-xpcom-nspr_DEFS.netbsd = \
|
---|
458 | _PR_PTHREADS
|
---|
459 | VBox-xpcom-nspr_DEFS.openbsd = \
|
---|
460 | _PR_PTHREADS
|
---|
461 | VBox-xpcom-nspr_DEFS.solaris = \
|
---|
462 | HAVE_FCNTL_FILE_LOCKING=1 \
|
---|
463 | HAVE_SOCKLEN_T=1 \
|
---|
464 | _PR_PTHREADS
|
---|
465 | VBox-xpcom-nspr_INCS = \
|
---|
466 | nsprpub/pr/include/private \
|
---|
467 | $(VBox-xpcom-nspr_0_OUTDIR)
|
---|
468 |
|
---|
469 | VBox-xpcom-nspr_SOURCES = \
|
---|
470 | nsprpub/pr/src/io/priometh.c \
|
---|
471 | nsprpub/pr/src/io/prmapopt.c \
|
---|
472 | nsprpub/pr/src/io/prprf.c \
|
---|
473 | nsprpub/pr/src/io/prstdio.c \
|
---|
474 | nsprpub/pr/src/misc/prerr.c \
|
---|
475 | nsprpub/pr/src/misc/prerror.c \
|
---|
476 | nsprpub/pr/src/misc/prerrortable.c \
|
---|
477 | nsprpub/pr/src/misc/prinit.c \
|
---|
478 | nsprpub/pr/src/misc/prinrval.c \
|
---|
479 | nsprpub/pr/src/misc/prlog2.c \
|
---|
480 | nsprpub/pr/src/misc/prlong.c \
|
---|
481 | nsprpub/pr/src/misc/prtime.c \
|
---|
482 | nsprpub/lib/ds/plarena.c \
|
---|
483 | nsprpub/lib/ds/plhash.c \
|
---|
484 | nsprpub/lib/libc/src/strlen.c \
|
---|
485 | nsprpub/lib/libc/src/strcpy.c \
|
---|
486 | nsprpub/lib/libc/src/strdup.c \
|
---|
487 | nsprpub/lib/libc/src/strcmp.c \
|
---|
488 | nsprpub/lib/libc/src/strccmp.c \
|
---|
489 | nsprpub/lib/libc/src/strchr.c \
|
---|
490 | nsprpub/lib/libc/src/strpbrk.c \
|
---|
491 | nsprpub/lib/libc/src/strstr.c \
|
---|
492 | nsprpub/lib/libc/src/strcstr.c
|
---|
493 |
|
---|
494 | ifeq ($(filter-out darwin freebsd linux netbsd openbsd solaris,$(KBUILD_TARGET)),) # unixish
|
---|
495 | VBox-xpcom-nspr_SOURCES += \
|
---|
496 | nsprpub/pr/src/md/unix/unix.c \
|
---|
497 | nsprpub/pr/src/md/unix/unix_errors.c \
|
---|
498 | nsprpub/pr/src/pthreads/ptio.c \
|
---|
499 | nsprpub/pr/src/pthreads/ptsynch.c \
|
---|
500 | nsprpub/pr/src/pthreads/ptthread.c
|
---|
501 | endif
|
---|
502 |
|
---|
503 | $(call KB_FN_DO_PASS0_ON_TARGET,VBox-xpcom-nspr)
|
---|
504 |
|
---|
505 | $(evalcall2 VBOX_XPCOM_X86,VBox-xpcom-nspr)
|
---|
506 |
|
---|
507 |
|
---|
508 | VBox-xpcom-typelib_TEMPLATE = XPComDll
|
---|
509 | VBox-xpcom-typelib_INSTTYPE = none
|
---|
510 | VBox-xpcom-typelib_SOURCES = \
|
---|
511 | xpcom/typelib/xpt/src/xpt_arena.c \
|
---|
512 | xpcom/typelib/xpt/src/xpt_struct.c \
|
---|
513 | xpcom/typelib/xpt/src/xpt_xdr.c
|
---|
514 | $(evalcall VBOX_XPCOM_X86,VBox-xpcom-typelib)
|
---|
515 |
|
---|
516 | VBox-xpcom-string_TEMPLATE = XPComDll
|
---|
517 | VBox-xpcom-string_INSTTYPE = none
|
---|
518 | VBox-xpcom-string_SOURCES = \
|
---|
519 | xpcom/string/src/nsAString.cpp \
|
---|
520 | xpcom/string/src/nsDependentSubstring.cpp \
|
---|
521 | xpcom/string/src/nsObsoleteAStringThunk.cpp \
|
---|
522 | xpcom/string/src/nsPrintfCString.cpp \
|
---|
523 | xpcom/string/src/nsPromiseFlatString.cpp \
|
---|
524 | xpcom/string/src/nsReadableUtils.cpp \
|
---|
525 | xpcom/string/src/nsSubstring.cpp \
|
---|
526 | xpcom/string/src/nsSubstringTuple.cpp \
|
---|
527 | xpcom/string/src/nsString.cpp \
|
---|
528 | xpcom/string/src/nsStringComparator.cpp \
|
---|
529 | xpcom/string/src/nsStringObsolete.cpp
|
---|
530 | $(evalcall VBOX_XPCOM_X86,VBox-xpcom-string)
|
---|
531 |
|
---|
532 | VBox-xpcom-base_TEMPLATE = XPComDll
|
---|
533 | VBox-xpcom-base_INSTTYPE = none
|
---|
534 | VBox-xpcom-base_DEFS = _IMPL_NS_COM
|
---|
535 | VBox-xpcom-base_SOURCES = \
|
---|
536 | xpcom/base/nsDebugImpl.cpp \
|
---|
537 | xpcom/base/nsErrorService.cpp \
|
---|
538 | xpcom/base/nsExceptionService.cpp \
|
---|
539 | xpcom/base/nsID.cpp \
|
---|
540 | xpcom/base/nsTraceRefcntImpl.cpp
|
---|
541 | $(evalcall VBOX_XPCOM_X86,VBox-xpcom-base)
|
---|
542 |
|
---|
543 | VBox-xpcom-ds_TEMPLATE = XPComDll
|
---|
544 | VBox-xpcom-ds_INSTTYPE = none
|
---|
545 | VBox-xpcom-ds_DEFS = _IMPL_NS_COM
|
---|
546 | VBox-xpcom-ds_SOURCES = \
|
---|
547 | xpcom/ds/pldhash.c \
|
---|
548 | xpcom/ds/nsAtomTable.cpp \
|
---|
549 | xpcom/ds/nsAtomService.cpp \
|
---|
550 | xpcom/ds/nsCRT.cpp \
|
---|
551 | xpcom/ds/nsDeque.cpp \
|
---|
552 | xpcom/ds/nsEmptyEnumerator.cpp \
|
---|
553 | xpcom/ds/nsEnumeratorUtils.cpp \
|
---|
554 | xpcom/ds/nsHashSets.cpp \
|
---|
555 | xpcom/ds/nsHashtable.cpp \
|
---|
556 | xpcom/ds/nsObserverList.cpp \
|
---|
557 | xpcom/ds/nsObserverService.cpp \
|
---|
558 | xpcom/ds/nsProperties.cpp \
|
---|
559 | xpcom/ds/nsQuickSort.cpp \
|
---|
560 | xpcom/ds/nsStaticNameTable.cpp \
|
---|
561 | xpcom/ds/nsStringEnumerator.cpp \
|
---|
562 | xpcom/ds/nsSupportsArray.cpp \
|
---|
563 | xpcom/ds/nsSupportsArrayEnumerator.cpp \
|
---|
564 | xpcom/ds/nsSupportsPrimitives.cpp \
|
---|
565 | xpcom/ds/nsTHashtable.cpp \
|
---|
566 | xpcom/ds/nsVariant.cpp \
|
---|
567 | xpcom/ds/nsVoidArray.cpp \
|
---|
568 | xpcom/ds/nsValueArray.cpp \
|
---|
569 | xpcom/ds/nsCOMArray.cpp \
|
---|
570 | xpcom/ds/nsArray.cpp \
|
---|
571 | xpcom/ds/nsArrayEnumerator.cpp
|
---|
572 | # xpcom/ds/nsHashPropertyBag.cpp
|
---|
573 | $(evalcall VBOX_XPCOM_X86,VBox-xpcom-ds)
|
---|
574 |
|
---|
575 | # @todo what about MOZ_USER_DIR?
|
---|
576 | VBox-xpcom-io_TEMPLATE = XPComDll
|
---|
577 | VBox-xpcom-io_INSTTYPE = none
|
---|
578 | ifdef VBOX_WITH_AUTOMATIC_DEFS_QUOTING
|
---|
579 | VBox-xpcom-io_DEFS = _IMPL_NS_COM MOZ_USER_DIR=".mozilla"
|
---|
580 | else
|
---|
581 | VBox-xpcom-io_DEFS = _IMPL_NS_COM MOZ_USER_DIR=\".mozilla\"
|
---|
582 | endif
|
---|
583 | if defined(VBOX_WITH_HARDENING) && defined(VBOX_PATH_APP_PRIVATE_ARCH)
|
---|
584 | ifdef VBOX_WITH_AUTOMATIC_DEFS_QUOTING
|
---|
585 | VBox-xpcom-io_DEFS += MOZ_DEFAULT_VBOX_XPCOM_HOME="$(VBOX_PATH_APP_PRIVATE_ARCH)"
|
---|
586 | else
|
---|
587 | VBox-xpcom-io_DEFS += MOZ_DEFAULT_VBOX_XPCOM_HOME=\"$(VBOX_PATH_APP_PRIVATE_ARCH)\"
|
---|
588 | endif
|
---|
589 | endif
|
---|
590 | VBox-xpcom-io_SOURCES = \
|
---|
591 | xpcom/io/nsAppFileLocationProvider.cpp \
|
---|
592 | xpcom/io/nsBinaryStream.cpp \
|
---|
593 | xpcom/io/nsByteArrayInputStream.cpp \
|
---|
594 | xpcom/io/nsDirectoryService.cpp \
|
---|
595 | xpcom/io/nsInputStreamTee.cpp \
|
---|
596 | xpcom/io/nsLocalFileCommon.cpp \
|
---|
597 | xpcom/io/nsScriptableInputStream.cpp \
|
---|
598 | xpcom/io/SpecialSystemDirectory.cpp \
|
---|
599 | xpcom/io/nsNativeCharsetUtils.cpp
|
---|
600 | if1of ($(KBUILD_TARGET) $(KBUILD_TARGET).$(KBUILD_TARGET_ARCH), freebsd linux netbsd openbsd solaris darwin.amd64 darwin.arm64)
|
---|
601 | VBox-xpcom-io_SOURCES += \
|
---|
602 | xpcom/io/nsLocalFileUnix.cpp
|
---|
603 | endif
|
---|
604 | $(evalcall VBOX_XPCOM_X86,VBox-xpcom-io)
|
---|
605 |
|
---|
606 | VBox-xpcom-components_TEMPLATE = XPComDll
|
---|
607 | VBox-xpcom-components_INSTTYPE = none
|
---|
608 | VBox-xpcom-components_DEFS = _IMPL_NS_COM EXPORT_XPTI_API
|
---|
609 | VBox-xpcom-components_SOURCES = \
|
---|
610 | xpcom/components/nsCategoryManager.cpp \
|
---|
611 | xpcom/components/nsComponentManager.cpp \
|
---|
612 | xpcom/components/nsComponentManagerObsolete.cpp \
|
---|
613 | xpcom/components/nsNativeComponentLoader.cpp \
|
---|
614 | xpcom/components/nsServiceManagerObsolete.cpp \
|
---|
615 | xpcom/components/xcDll.cpp \
|
---|
616 | xpcom/components/nsStaticComponentLoader.cpp
|
---|
617 | $(evalcall VBOX_XPCOM_X86,VBox-xpcom-components)
|
---|
618 |
|
---|
619 | VBox-xpcom-threads_TEMPLATE = XPComDll
|
---|
620 | VBox-xpcom-threads_INSTTYPE = none
|
---|
621 | VBox-xpcom-threads_DEFS = _IMPL_NS_COM
|
---|
622 | VBox-xpcom-threads_SOURCES = \
|
---|
623 | xpcom/threads/plevent.c \
|
---|
624 | xpcom/threads/nsAutoLock.cpp \
|
---|
625 | xpcom/threads/nsEventQueue.cpp \
|
---|
626 | xpcom/threads/nsEventQueueService.cpp
|
---|
627 | $(evalcall VBOX_XPCOM_X86,VBox-xpcom-threads)
|
---|
628 |
|
---|
629 | VBox-xpcom-xptinfo_TEMPLATE = XPComDll
|
---|
630 | VBox-xpcom-xptinfo_INSTTYPE = none
|
---|
631 | VBox-xpcom-xptinfo_DEFS = _IMPL_NS_COM _IMPL_NS_BASE EXPORT_XPTI_API EXPORT_XPT_API
|
---|
632 | VBox-xpcom-xptinfo_SOURCES = \
|
---|
633 | xpcom/reflect/xptinfo/src/xptiFile.cpp \
|
---|
634 | xpcom/reflect/xptinfo/src/xptiInterfaceInfo.cpp \
|
---|
635 | xpcom/reflect/xptinfo/src/xptiInterfaceInfoManager.cpp \
|
---|
636 | xpcom/reflect/xptinfo/src/xptiManifest.cpp \
|
---|
637 | xpcom/reflect/xptinfo/src/xptiMisc.cpp \
|
---|
638 | xpcom/reflect/xptinfo/src/xptiTypelibGuts.cpp \
|
---|
639 | xpcom/reflect/xptinfo/src/xptiWorkingSet.cpp \
|
---|
640 | xpcom/reflect/xptinfo/src/xptiZipItem.cpp \
|
---|
641 | xpcom/reflect/xptinfo/src/xptiZipLoader.cpp
|
---|
642 | $(evalcall VBOX_XPCOM_X86,VBox-xpcom-xptinfo)
|
---|
643 |
|
---|
644 |
|
---|
645 | VBox-xpcom-xptcall_TEMPLATE = XPComDllYasm
|
---|
646 | VBox-xpcom-xptcall_INSTTYPE = none
|
---|
647 | VBox-xpcom-xptcall_DEFS = _IMPL_NS_COM _IMPL_NS_BASE EXPORT_XPTC_API
|
---|
648 | VBox-xpcom-xptcall_DEFS.darwin = KEEP_STACK_16_BYTE_ALIGNED
|
---|
649 | VBox-xpcom-xptcall_SOURCES = xpcom/reflect/xptcall/src/xptcall.cpp
|
---|
650 | VBox-xpcom-xptcall_SOURCES.freebsd.x86 = xpcom/reflect/xptcall/src/md/unix/xptcinvoke_gcc_x86_unix.cpp \
|
---|
651 | xpcom/reflect/xptcall/src/md/unix/xptcstubs_gcc_x86_unix.cpp
|
---|
652 | VBox-xpcom-xptcall_SOURCES.linux.x86 = xpcom/reflect/xptcall/src/md/unix/xptcinvoke_gcc_x86_unix.cpp \
|
---|
653 | xpcom/reflect/xptcall/src/md/unix/xptcstubs_gcc_x86_unix.cpp
|
---|
654 | VBox-xpcom-xptcall_SOURCES.solaris.x86 = xpcom/reflect/xptcall/src/md/unix/xptcinvoke_x86_solaris.cpp \
|
---|
655 | xpcom/reflect/xptcall/src/md/unix/xptcstubs_x86_solaris.cpp
|
---|
656 | VBox-xpcom-xptcall_SOURCES.amd64 = xpcom/reflect/xptcall/src/md/unix/xptcinvoke_amd64_vbox.asm
|
---|
657 | VBox-xpcom-xptcall_SOURCES.arm64 = xpcom/reflect/xptcall/src/md/unix/xptcinvoke_arm64_vbox.cpp \
|
---|
658 | xpcom/reflect/xptcall/src/md/unix/xptcstubs_arm64_vbox.cpp
|
---|
659 | VBox-xpcom-xptcall_SOURCES.darwin.amd64 = xpcom/reflect/xptcall/src/md/unix/xptcstubs_amd64_darwin.cpp # Underscore prefix.
|
---|
660 | VBox-xpcom-xptcall_SOURCES.freebsd.amd64 = xpcom/reflect/xptcall/src/md/unix/xptcstubs_x86_64_linux.cpp
|
---|
661 | VBox-xpcom-xptcall_SOURCES.linux.amd64 = xpcom/reflect/xptcall/src/md/unix/xptcstubs_x86_64_linux.cpp
|
---|
662 | ifndef VBOX_GCC_USING_SOLARIS_AS
|
---|
663 | VBox-xpcom-xptcall_SOURCES.solaris.amd64 = xpcom/reflect/xptcall/src/md/unix/xptcstubs_x86_64_linux.cpp
|
---|
664 | else
|
---|
665 | VBox-xpcom-xptcall_SOURCES.solaris.amd64 = xpcom/reflect/xptcall/src/md/unix/xptcstubs_x86_64_solaris.cpp
|
---|
666 | endif
|
---|
667 |
|
---|
668 | xpcom/reflect/xptcall/src/md/unix/xptcstubs_x86_solaris.cpp_CXXFLAGS = -O0
|
---|
669 | # -O0 works fine, while -O1 doesn't. The gcc man page can't be listing all the -f*
|
---|
670 | # stuff that -O1 enables, because when using the options without -O1, it's -fomit-frame-pointer
|
---|
671 | # that triggers is, while -O1 -fno-omit-frame-pointer does not work. Anyway, it's probably a gcc/mozila
|
---|
672 | # bug and it's not worth investigating as I'm not the maintainger of the solaris gcc port. [bird, 2007-09-17]
|
---|
673 |
|
---|
674 | $(evalcall VBOX_XPCOM_X86,VBox-xpcom-xptcall)
|
---|
675 |
|
---|
676 |
|
---|
677 | VBox-xpcom-proxy_TEMPLATE = XPComDll
|
---|
678 | VBox-xpcom-proxy_INSTTYPE = none
|
---|
679 | VBox-xpcom-proxy_DEFS = _IMPL_NS_COM EXPORT_XPTC_API EXPORT_XPTI_API
|
---|
680 | VBox-xpcom-proxy_SOURCES = \
|
---|
681 | xpcom/proxy/src/nsProxyEvent.cpp \
|
---|
682 | xpcom/proxy/src/nsProxyEventClass.cpp \
|
---|
683 | xpcom/proxy/src/nsProxyEventObject.cpp \
|
---|
684 | xpcom/proxy/src/nsProxyObjectManager.cpp \
|
---|
685 | xpcom/proxy/src/nsProxyRelease.cpp
|
---|
686 | $(evalcall VBOX_XPCOM_X86,VBox-xpcom-proxy)
|
---|
687 |
|
---|
688 |
|
---|
689 | #
|
---|
690 | # The VBoxXPCOM Glue static libraries.
|
---|
691 | #
|
---|
692 | # This isn't the normal XPCOM glue (see the places in XPCOM where XPCOM_GLUE is
|
---|
693 | # checked), VirtualBox has its own glue library and this means this isn't used
|
---|
694 | # much (one reason is that we don't provide frozen APIs yet). All VBox XPCOM
|
---|
695 | # client applications are dependent on the given version of both the VBox XPCOM
|
---|
696 | # runtime (binary dependency) and VirtualBox component library (COM interface
|
---|
697 | # dependency). For this reason, VBox client applications link to the VBox XPCOM
|
---|
698 | # shared library directly (instead of linking to the standalone XPCOM glue
|
---|
699 | # library that would dynamically search for and load the installed XPCOM
|
---|
700 | # runtime). For the same reason, we link all parts of XPCOM into a single
|
---|
701 | # shared XPCOM library below (as opposed to the original XPCOM where e.g. NSPR
|
---|
702 | # lives in a separate DLL). Additionally there is VBox specific glue code to
|
---|
703 | # make both the client and server side code build with both XPCOM and COM,
|
---|
704 | # which should be made part of the SDK eventually, but this is a higher level
|
---|
705 | # of abstraction than this XPCOM specific glue code.
|
---|
706 | #
|
---|
707 | VBoxXPCOMGlue_COMMON_SOURCES = \
|
---|
708 | xpcom/glue/nsCOMPtr.cpp \
|
---|
709 | xpcom/glue/nsComponentManagerUtils.cpp \
|
---|
710 | xpcom/glue/nsDebug.cpp \
|
---|
711 | xpcom/glue/nsGenericFactory.cpp \
|
---|
712 | xpcom/glue/nsIInterfaceRequestorUtils.cpp \
|
---|
713 | xpcom/glue/nsMemory.cpp \
|
---|
714 | xpcom/glue/nsTraceRefcnt.cpp \
|
---|
715 | xpcom/glue/nsWeakReference.cpp
|
---|
716 |
|
---|
717 | # dependent glue library which goes in to the VBoxXPCOM shared library
|
---|
718 | VBoxXPCOMGlue_s_TEMPLATE = XPComDll
|
---|
719 | VBoxXPCOMGlue_s_INSTTYPE = none
|
---|
720 | VBoxXPCOMGlue_s_DEFS = _IMPL_NS_COM
|
---|
721 | VBoxXPCOMGlue_s_SOURCES = $(VBoxXPCOMGlue_COMMON_SOURCES)
|
---|
722 | $(evalcall VBOX_XPCOM_X86,VBoxXPCOMGlue_s)
|
---|
723 |
|
---|
724 | # standalone glue library which all third-party client apps (if any) will
|
---|
725 | # link with (currently completely unused and nit built, to be part of the SDK)
|
---|
726 | VBoxXPCOMGlue_TEMPLATE = XPComDll
|
---|
727 | VBoxXPCOMGlue_SOURCES = $(VBoxXPCOMGlue_COMMON_SOURCES)
|
---|
728 | #VBoxXPCOMGlue_INST = lib/ $(INST_SDK)lib/
|
---|
729 | $(evalcall VBOX_XPCOM_X86,VBoxXPCOMGlue)
|
---|
730 |
|
---|
731 |
|
---|
732 | #
|
---|
733 | # The VBoxXPCOM Shared Object, assembling all lib files.
|
---|
734 | #
|
---|
735 | VBoxXPCOM_TEMPLATE = XPComDll
|
---|
736 | VBoxXPCOM_NAME = $(basename $(notdir $(LIB_XPCOM)))
|
---|
737 | VBoxXPCOM_DEFS = BUILD_DCONNECT=1 _IMPL_NS_COM
|
---|
738 | ifdef VBOX_WITH_XPCOM_NAMESPACE_CLEANUP
|
---|
739 | VBoxXPCOM_LDFLAGS.linux = -Wl,--version-script=$(XPCOM_C_NAMESPACE_MAP)
|
---|
740 | VBoxXPCOM_LNK_DEPS.linux += $(XPCOM_C_NAMESPACE_MAP)
|
---|
741 | VBoxXPCOM_LDFLAGS.solaris = -Wl,-M,$(XPCOM_C_NAMESPACE_MAP)
|
---|
742 | VBoxXPCOM_LNK_DEPS.solaris += $(XPCOM_C_NAMESPACE_MAP)
|
---|
743 | endif
|
---|
744 | VBoxXPCOM_SOURCES = \
|
---|
745 | xpcom/build/nsXPComInit.cpp \
|
---|
746 | xpcom/build/nsStringAPI.cpp
|
---|
747 | VBoxXPCOM_SOURCES.darwin = \
|
---|
748 | vboxdeps.cpp
|
---|
749 | VBoxXPCOM_SOURCES.solaris = \
|
---|
750 | vboxdeps.cpp
|
---|
751 | VBoxXPCOM_LIBS = \
|
---|
752 | $(VBox-xpcom-typelib_1_TARGET) \
|
---|
753 | $(VBox-xpcom-string_1_TARGET) \
|
---|
754 | $(VBox-xpcom-base_1_TARGET) \
|
---|
755 | $(VBox-xpcom-ds_1_TARGET) \
|
---|
756 | $(VBox-xpcom-io_1_TARGET) \
|
---|
757 | $(VBox-xpcom-components_1_TARGET) \
|
---|
758 | $(VBox-xpcom-threads_1_TARGET) \
|
---|
759 | $(VBox-xpcom-xptinfo_1_TARGET) \
|
---|
760 | $(VBox-xpcom-xptcall_1_TARGET) \
|
---|
761 | $(VBox-xpcom-proxy_1_TARGET) \
|
---|
762 | $(VBox-xpcom-nspr_1_TARGET) \
|
---|
763 | $(VBoxXPCOMGlue_s_1_TARGET)
|
---|
764 | VBoxXPCOM_LIBS.linux = \
|
---|
765 | pthread dl
|
---|
766 |
|
---|
767 | ifeq ($(filter-out freebsd linux netbsd openbsd,$(KBUILD_TARGET)),) # gnu ld.
|
---|
768 | VBoxXPCOM_LDFLAGS = -Wl,--whole-archive \
|
---|
769 | $(VBox-xpcom-typelib_1_TARGET) \
|
---|
770 | $(VBox-xpcom-string_1_TARGET) \
|
---|
771 | $(VBox-xpcom-base_1_TARGET) \
|
---|
772 | $(VBox-xpcom-ds_1_TARGET) \
|
---|
773 | $(VBox-xpcom-io_1_TARGET) \
|
---|
774 | $(VBox-xpcom-components_1_TARGET) \
|
---|
775 | $(VBox-xpcom-threads_1_TARGET) \
|
---|
776 | $(VBox-xpcom-xptinfo_1_TARGET) \
|
---|
777 | $(VBox-xpcom-xptcall_1_TARGET) \
|
---|
778 | $(VBox-xpcom-proxy_1_TARGET) \
|
---|
779 | $(VBox-xpcom-nspr_1_TARGET) \
|
---|
780 | $(VBoxXPCOMGlue_s_1_TARGET) \
|
---|
781 | -Wl,--no-whole-archive
|
---|
782 | endif
|
---|
783 |
|
---|
784 | VBoxXPCOM_LDFLAGS.solaris += -Wl,-z,allextract \
|
---|
785 | $(VBox-xpcom-typelib_1_TARGET) \
|
---|
786 | $(VBox-xpcom-string_1_TARGET) \
|
---|
787 | $(VBox-xpcom-base_1_TARGET) \
|
---|
788 | $(VBox-xpcom-ds_1_TARGET) \
|
---|
789 | $(VBox-xpcom-io_1_TARGET) \
|
---|
790 | $(VBox-xpcom-components_1_TARGET) \
|
---|
791 | $(VBox-xpcom-threads_1_TARGET) \
|
---|
792 | $(VBox-xpcom-xptinfo_1_TARGET) \
|
---|
793 | $(VBox-xpcom-xptcall_1_TARGET) \
|
---|
794 | $(VBox-xpcom-proxy_1_TARGET) \
|
---|
795 | $(VBox-xpcom-nspr_1_TARGET) \
|
---|
796 | $(VBoxXPCOMGlue_s_1_TARGET) \
|
---|
797 | -Wl,-z,defaultextract
|
---|
798 |
|
---|
799 | # EF heap
|
---|
800 | #VBoxXPCOM_LIBS += $(LIB_RUNTIME_EF)
|
---|
801 | #VBoxXPCOM_LDFLAGS = -Wl,--whole-archive $(VBoxXPCOM_LIBS) -Wl,--no-whole-archive $(LIB_RUNTIME)
|
---|
802 | VBoxXPCOM_LDFLAGS.darwin = -install_name $(VBOX_DYLD_EXECUTABLE_PATH)/VBoxXPCOM.dylib
|
---|
803 |
|
---|
804 | #
|
---|
805 | # The 32-bit VBoxXPCOM Shared Object, assembling all lib files.
|
---|
806 | #
|
---|
807 | VBoxXPCOM-x86_TEMPLATE = XPComDll-x86
|
---|
808 | VBoxXPCOM-x86_EXTENDS = VBoxXPCOM
|
---|
809 | VBoxXPCOM-x86_NAME = VBoxXPCOM-x86
|
---|
810 | VBoxXPCOM-x86_LIBS = \
|
---|
811 | $(VBox-xpcom-typelib-x86_1_TARGET) \
|
---|
812 | $(VBox-xpcom-string-x86_1_TARGET) \
|
---|
813 | $(VBox-xpcom-base-x86_1_TARGET) \
|
---|
814 | $(VBox-xpcom-ds-x86_1_TARGET) \
|
---|
815 | $(VBox-xpcom-io-x86_1_TARGET) \
|
---|
816 | $(VBox-xpcom-components-x86_1_TARGET) \
|
---|
817 | $(VBox-xpcom-threads-x86_1_TARGET) \
|
---|
818 | $(VBox-xpcom-xptinfo-x86_1_TARGET) \
|
---|
819 | $(VBox-xpcom-xptcall-x86_1_TARGET) \
|
---|
820 | $(VBox-xpcom-proxy-x86_1_TARGET) \
|
---|
821 | $(VBox-xpcom-nspr-x86_1_TARGET) \
|
---|
822 | $(VBoxXPCOMGlue_s-x86_1_TARGET)
|
---|
823 |
|
---|
824 | ifeq ($(filter-out freebsd linux netbsd openbsd,$(KBUILD_TARGET)),) # gnu ld.
|
---|
825 | VBoxXPCOM-x86_LDFLAGS = -Wl,--whole-archive \
|
---|
826 | $(VBox-xpcom-typelib-x86_1_TARGET) \
|
---|
827 | $(VBox-xpcom-string-x86_1_TARGET) \
|
---|
828 | $(VBox-xpcom-base-x86_1_TARGET) \
|
---|
829 | $(VBox-xpcom-ds-x86_1_TARGET) \
|
---|
830 | $(VBox-xpcom-io-x86_1_TARGET) \
|
---|
831 | $(VBox-xpcom-components-x86_1_TARGET) \
|
---|
832 | $(VBox-xpcom-threads-x86_1_TARGET) \
|
---|
833 | $(VBox-xpcom-xptinfo-x86_1_TARGET) \
|
---|
834 | $(VBox-xpcom-xptcall-x86_1_TARGET) \
|
---|
835 | $(VBox-xpcom-proxy-x86_1_TARGET) \
|
---|
836 | $(VBox-xpcom-nspr-x86_1_TARGET) \
|
---|
837 | $(VBoxXPCOMGlue_s-x86_1_TARGET) \
|
---|
838 | -Wl,--no-whole-archive
|
---|
839 | endif
|
---|
840 |
|
---|
841 | VBoxXPCOM-x86_LDFLAGS.solaris += -Wl,-z,allextract \
|
---|
842 | $(VBox-xpcom-typelib-x86_1_TARGET) \
|
---|
843 | $(VBox-xpcom-string-x86_1_TARGET) \
|
---|
844 | $(VBox-xpcom-base-x86_1_TARGET) \
|
---|
845 | $(VBox-xpcom-ds-x86_1_TARGET) \
|
---|
846 | $(VBox-xpcom-io-x86_1_TARGET) \
|
---|
847 | $(VBox-xpcom-components-x86_1_TARGET) \
|
---|
848 | $(VBox-xpcom-threads-x86_1_TARGET) \
|
---|
849 | $(VBox-xpcom-xptinfo-x86_1_TARGET) \
|
---|
850 | $(VBox-xpcom-xptcall-x86_1_TARGET) \
|
---|
851 | $(VBox-xpcom-proxy-x86_1_TARGET) \
|
---|
852 | $(VBox-xpcom-nspr-x86_1_TARGET) \
|
---|
853 | $(VBoxXPCOMGlue_s-x86_1_TARGET) \
|
---|
854 | -Wl,-z,defaultextract
|
---|
855 |
|
---|
856 |
|
---|
857 | #
|
---|
858 | # VBoxXPCOMImp - Import library/hack.
|
---|
859 | #
|
---|
860 | ifdef VBOX_WITH_XPCOM_NAMESPACE_CLEANUP
|
---|
861 | $(call VBOX_GENERATE_IMPORT_TARGET_FN,VBoxXPCOMImp,VBoxXPCOM,VBoxXPCOM-mangled.def)
|
---|
862 | else
|
---|
863 | $(call VBOX_GENERATE_IMPORT_TARGET_FN,VBoxXPCOMImp,VBoxXPCOM,VBoxXPCOM.def)
|
---|
864 | endif
|
---|
865 |
|
---|
866 |
|
---|
867 | #
|
---|
868 | # IPC templates.
|
---|
869 | #
|
---|
870 | ifdef VBOX_IPC_RELEASE_LOG
|
---|
871 | IPC_LOGGING = 1
|
---|
872 | else ifneq ($(KBUILD_TYPE),release)
|
---|
873 | IPC_LOGGING = 1
|
---|
874 | endif
|
---|
875 |
|
---|
876 | TEMPLATE_XPComIpcDll = XPCOM IPC libraries
|
---|
877 | TEMPLATE_XPComIpcDll_EXTENDS = XPComDll
|
---|
878 | TEMPLATE_XPComIpcDll_DEFS = $(TEMPLATE_XPComDll_DEFS) BUILD_DCONNECT=1
|
---|
879 | ifdef VBOX_WITH_AUTOMATIC_DEFS_QUOTING
|
---|
880 | TEMPLATE_XPComIpcDll_DEFS += IPC_DAEMON_APP_NAME="VBoxXPCOMIPCD$(SUFF_EXE)"
|
---|
881 | else
|
---|
882 | TEMPLATE_XPComIpcDll_DEFS += IPC_DAEMON_APP_NAME=\"VBoxXPCOMIPCD$(SUFF_EXE)\"
|
---|
883 | endif
|
---|
884 | ifdef IPC_LOGGING
|
---|
885 | TEMPLATE_XPComIpcDll_DEFS += IPC_LOGGING
|
---|
886 | endif
|
---|
887 | TEMPLATE_XPComIpcDll_LIBS = $(VBoxXPCOM_1_TARGET) $(TEMPLATE_XPComDll_LIBS)
|
---|
888 | ifneq ($(KBUILD_TARGET),win)
|
---|
889 | ifeq ($(filter-out solaris.x86 %.amd64 %.sparc32 %.sparc64,$(KBUILD_TARGET).$(KBUILD_TARGET_ARCH)),) ## TODO: cleanup!
|
---|
890 | if defined(VBOX_WITH_RELATIVE_RUNPATH) && !defined(VBOX_WITH_HARDENING)
|
---|
891 | TEMPLATE_XPComIpcDll_LDFLAGS = $(filter-out '$(VBOX_GCC_RPATH_OPT)%',$(TEMPLATE_XPComDll_LDFLAGS)) '$(VBOX_GCC_RPATH_OPT)$(VBOX_WITH_RELATIVE_RUNPATH)/..'
|
---|
892 | endif
|
---|
893 | else ifndef VBOX_WITH_HARDENING
|
---|
894 | ifdef VBOX_WITH_RELATIVE_RUNPATH
|
---|
895 | TEMPLATE_XPComIpcDll_LDFLAGS = $(filter-out '$(VBOX_GCC_RPATH_OPT)%',$(TEMPLATE_XPComDll_LDFLAGS)) '$(VBOX_GCC_RPATH_OPT)$(VBOX_WITH_RELATIVE_RUNPATH)/..'
|
---|
896 | endif
|
---|
897 | endif
|
---|
898 | endif
|
---|
899 |
|
---|
900 | TEMPLATE_XPComIpcDll-x86 = 32-bit XPCOM IPC libraries
|
---|
901 | TEMPLATE_XPComIpcDll-x86_EXTENDS = XPComIpcDll
|
---|
902 | TEMPLATE_XPComIpcDll-x86_BLD_TRG_ARCH = x86
|
---|
903 | TEMPLATE_XPComIpcDll-x86_LIBS = $(VBoxXPCOM-x86_1_TARGET) $(TEMPLATE_XPComDll-x86_LIBS)
|
---|
904 |
|
---|
905 | TEMPLATE_XPComIpcExe = XPCOM IPC executables
|
---|
906 | TEMPLATE_XPComIpcExe_EXTENDS = XPComExe
|
---|
907 | TEMPLATE_XPComIpcExe_DEFS = $(TEMPLATE_XPComExe_DEFS) BUILD_DCONNECT=1
|
---|
908 | ifdef IPC_LOGGING
|
---|
909 | TEMPLATE_XPComIpcExe_DEFS += IPC_LOGGING
|
---|
910 | endif
|
---|
911 |
|
---|
912 | #
|
---|
913 | # Shared IPC code. Used by the IPC component as well as the executables.
|
---|
914 | #
|
---|
915 | VBox-xpcom-ipcshared_TEMPLATE = XPComIpcDll
|
---|
916 | VBox-xpcom-ipcshared_INSTTYPE = none
|
---|
917 | VBox-xpcom-ipcshared_SOURCES = \
|
---|
918 | ipc/ipcd/shared/src/ipcLog.cpp \
|
---|
919 | ipc/ipcd/shared/src/ipcConfig.cpp \
|
---|
920 | ipc/ipcd/shared/src/ipcMessage.cpp \
|
---|
921 | ipc/ipcd/shared/src/ipcMessagePrimitives.cpp \
|
---|
922 | ipc/ipcd/shared/src/ipcStringList.cpp \
|
---|
923 | ipc/ipcd/shared/src/ipcIDList.cpp \
|
---|
924 | ipc/ipcd/shared/src/ipcm.cpp
|
---|
925 | $(evalcall VBOX_XPCOM_X86,VBox-xpcom-ipcshared)
|
---|
926 |
|
---|
927 |
|
---|
928 | #
|
---|
929 | # DCONNECT client shared object
|
---|
930 | #
|
---|
931 | VBoxXPCOMIPCC_TEMPLATE = XPComIpcDll
|
---|
932 | VBoxXPCOMIPCC_INST = $(INST_BIN)components/
|
---|
933 | #VBoxXPCOMIPCC_DEFS = HAVE_DEPENDENT_LIBS - dependentLibs.h is linux specific, so this cannot be required.
|
---|
934 | VBoxXPCOMIPCC_SOURCES = \
|
---|
935 | ipc/ipcd/client/src/ipcdclient.cpp \
|
---|
936 | ipc/ipcd/client/src/ipcService.cpp \
|
---|
937 | ipc/ipcd/client/src/ipcModuleFactory.cpp \
|
---|
938 | ipc/ipcd/extensions/dconnect/src/ipcDConnectService.cpp \
|
---|
939 | \
|
---|
940 | ipc/ipcd/util/src/ipcMessageReader.cpp \
|
---|
941 | ipc/ipcd/util/src/ipcMessageWriter.cpp \
|
---|
942 | \
|
---|
943 | ipc/ipcd/extensions/lock/src/ipcLockProtocol.cpp \
|
---|
944 | ipc/ipcd/extensions/lock/src/ipcLockService.cpp \
|
---|
945 | \
|
---|
946 | ipc/ipcd/extensions/transmngr/src/tmTransactionService.cpp \
|
---|
947 | \
|
---|
948 | ipc/ipcd/extensions/transmngr/common/tmTransaction.cpp \
|
---|
949 | ipc/ipcd/extensions/transmngr/common/tmVector.cpp \
|
---|
950 | ipc/ipcd/client/src/ipcConnectionUnix.cpp
|
---|
951 | VBoxXPCOMIPCC_LDFLAGS.darwin = -install_name $(VBOX_DYLD_EXECUTABLE_PATH)/components/VBoxXPCOMIPCC.dylib
|
---|
952 | VBoxXPCOMIPCC_LIBS = \
|
---|
953 | $(VBox-xpcom-ipcshared_1_TARGET)
|
---|
954 |
|
---|
955 | # 32-bit version of the component.
|
---|
956 | $(evalcall VBOX_XPCOM_X86,VBoxXPCOMIPCC)
|
---|
957 | VBoxXPCOMIPCC-x86_LIBS = \
|
---|
958 | $(VBox-xpcom-ipcshared-x86_1_TARGET)
|
---|
959 |
|
---|
960 |
|
---|
961 | #
|
---|
962 | # DCONNECT daemon executable
|
---|
963 | #
|
---|
964 | VBoxXPCOMIPCD_TEMPLATE = XPComIpcExe
|
---|
965 | VBoxXPCOMIPCD_SOURCES = \
|
---|
966 | ipc/ipcd/daemon/src/ipcd.cpp \
|
---|
967 | ipc/ipcd/daemon/src/ipcClient.cpp \
|
---|
968 | ipc/ipcd/daemon/src/ipcCommandModule.cpp \
|
---|
969 | ipc/ipcd/daemon/src/ipcdUnix.cpp
|
---|
970 |
|
---|
971 |
|
---|
972 | #
|
---|
973 | # Include sub-makefiles for the Python<->XPCOM and Java<->XPCOM bridges.
|
---|
974 | #
|
---|
975 | ifndef VBOX_ONLY_EXTPACKS
|
---|
976 | # Find the Python headers for the Python<->XPCOM bridge if enabled.
|
---|
977 | ifdef VBOX_WITH_PYTHON
|
---|
978 | include $(PATH_SUB_CURRENT)/python/Makefile.kmk
|
---|
979 | endif
|
---|
980 |
|
---|
981 | ifdef VBOX_WITH_JXPCOM
|
---|
982 | include $(PATH_SUB_CURRENT)/java/Makefile.kmk
|
---|
983 | endif
|
---|
984 | endif # !VBOX_ONLY_EXTPACKS
|
---|
985 |
|
---|
986 |
|
---|
987 | #
|
---|
988 | # testcases
|
---|
989 | #
|
---|
990 | tstnsIFileEnumerator_TEMPLATE = XPComTstExe
|
---|
991 | tstnsIFileEnumerator_SOURCES = xpcom/tests/nsIFileEnumerator.cpp
|
---|
992 | tstnsIFileTest_TEMPLATE = XPComTstExe
|
---|
993 | tstnsIFileTest_SOURCES = xpcom/tests/nsIFileTest.cpp
|
---|
994 | tstTestArray_TEMPLATE = XPComTstExe
|
---|
995 | tstTestArray_SOURCES = xpcom/tests/TestArray.cpp
|
---|
996 | tstTestAtoms_TEMPLATE = XPComTstExe
|
---|
997 | tstTestAtoms_SOURCES = xpcom/tests/TestAtoms.cpp
|
---|
998 | tstTestAutoLock_TEMPLATE = XPComTstExe
|
---|
999 | tstTestAutoLock_SOURCES = xpcom/tests/TestAutoLock.cpp
|
---|
1000 | tstTestCallTemplates_TEMPLATE = XPComTstExe
|
---|
1001 | tstTestCallTemplates_SOURCES = xpcom/tests/TestCallTemplates.cpp
|
---|
1002 | tstTestCOMPtr_TEMPLATE = XPComTstExe
|
---|
1003 | tstTestCOMPtr_SOURCES = xpcom/tests/TestCOMPtr.cpp
|
---|
1004 | tstTestCOMPtrEq_TEMPLATE = XPComTstExe
|
---|
1005 | tstTestCOMPtrEq_SOURCES = xpcom/tests/TestCOMPtrEq.cpp
|
---|
1006 | tstTestCRT_TEMPLATE = XPComTstExe
|
---|
1007 | tstTestCRT_SOURCES = xpcom/tests/TestCRT.cpp
|
---|
1008 | tstTestFactory_TEMPLATE = XPComTstExe
|
---|
1009 | tstTestFactory_SOURCES = xpcom/tests/TestFactory.cpp
|
---|
1010 | tstTestHashtables_TEMPLATE = XPComTstExe
|
---|
1011 | tstTestHashtables_SOURCES = xpcom/tests/TestHashtables.cpp
|
---|
1012 | tstTestID_TEMPLATE = XPComTstExe
|
---|
1013 | tstTestID_SOURCES = xpcom/tests/TestID.cpp
|
---|
1014 | tstTestObserverService_TEMPLATE = XPComTstExe
|
---|
1015 | tstTestObserverService_SOURCES = xpcom/tests/TestObserverService.cpp
|
---|
1016 | tstTestPermanentAtoms_TEMPLATE = XPComTstExe
|
---|
1017 | tstTestPermanentAtoms_SOURCES = xpcom/tests/TestPermanentAtoms.cpp
|
---|
1018 | tstTestServMgr_TEMPLATE = XPComTstExe
|
---|
1019 | tstTestServMgr_SOURCES = xpcom/tests/TestServMgr.cpp
|
---|
1020 | tstTestServMgr_INCS = xpcom/tests/services
|
---|
1021 | tstTestXPIDLString_TEMPLATE = XPComTstExe
|
---|
1022 | tstTestXPIDLString_SOURCES = xpcom/tests/TestXPIDLString.cpp
|
---|
1023 | tstTestXPTCInvoke_TEMPLATE = XPComTstExe
|
---|
1024 | tstTestXPTCInvoke_SOURCES = xpcom/reflect/xptcall/tests/TestXPTCInvoke.cpp
|
---|
1025 | tstTestDeque_TEMPLATE = XPComTstExe
|
---|
1026 | tstTestDeque_SOURCES = xpcom/tests/TestDeque.cpp
|
---|
1027 | tstTestAutoPtr_TEMPLATE = XPComTstExe
|
---|
1028 | tstTestAutoPtr_SOURCES = xpcom/tests/TestAutoPtr.cpp
|
---|
1029 | tstTestMinStringAPI_TEMPLATE = XPComTstExe
|
---|
1030 | tstTestMinStringAPI_SOURCES = xpcom/tests/TestMinStringAPI.cpp
|
---|
1031 | tstTestStrings_TEMPLATE = XPComTstExe
|
---|
1032 | tstTestStrings_SOURCES = xpcom/tests/TestStrings.cpp
|
---|
1033 | tstPrimitiveTest_TEMPLATE = XPComTstExe
|
---|
1034 | tstPrimitiveTest_SOURCES = xpcom/typelib/xpt/tests/PrimitiveTest.c
|
---|
1035 | tstSimpleTypeLib_TEMPLATE = XPComTstExe
|
---|
1036 | tstSimpleTypeLib_SOURCES = xpcom/typelib/xpt/tests/SimpleTypeLib.c
|
---|
1037 | tstXptDump_TEMPLATE = XPComTstExe
|
---|
1038 | tstXptDump_SOURCES = xpcom/typelib/xpt/tools/xpt_dump.c
|
---|
1039 | tstXptLink_TEMPLATE = XPComTstExe
|
---|
1040 | tstXptLink_SOURCES = xpcom/typelib/xpt/tools/xpt_link.c
|
---|
1041 |
|
---|
1042 |
|
---|
1043 |
|
---|
1044 | OTHER_CLEAN += \
|
---|
1045 | $(PATH_TARGET)/VBox-xpcom-idl-timestamp \
|
---|
1046 | $(addprefix $(VBOX_PATH_SDK)/bindings/xpcom/include,$(notdir $(subst .idl,.h,$(XPCOM_IDLFILES)))) \
|
---|
1047 | $(addprefix $(VBOX_PATH_SDK)/bindings/xpcom/include,$(notdir $(subst .idl,.xpt,$(XPCOM_IDLFILES)))) \
|
---|
1048 | $(addprefix $(VBOX_PATH_SDK)/bindings/xpcom/idl/,$(notdir $(XPCOM_IDLFILES))) \
|
---|
1049 | $(addprefix $(PATH_TARGET)/VBox-xpcom-xpt-files/,$(notdir $(subst .idl,.xpt,$(XPCOM_IDLFILES))))
|
---|
1050 |
|
---|
1051 |
|
---|
1052 | #
|
---|
1053 | # Create and install VBoxXPCOMBase.xpt
|
---|
1054 | #
|
---|
1055 | INSTALLS += VBoxXPCOMBase-xpt-inst
|
---|
1056 | VBOX_XPTFILES = $(addprefix $(PATH_TARGET)/VBox-xpcom-xpt-files/, \
|
---|
1057 | nsIErrorService.xpt \
|
---|
1058 | nsIException.xpt \
|
---|
1059 | nsIExceptionService.xpt \
|
---|
1060 | nsIDebug.xpt \
|
---|
1061 | nsIInterfaceRequestor.xpt \
|
---|
1062 | nsIProgrammingLanguage.xpt \
|
---|
1063 | nsISupports.xpt \
|
---|
1064 | nsITraceRefcnt.xpt \
|
---|
1065 | nsIWeakReference.xpt \
|
---|
1066 | nsrootidl.xpt \
|
---|
1067 | nsIAtom.xpt \
|
---|
1068 | nsIAtomService.xpt \
|
---|
1069 | nsICollection.xpt \
|
---|
1070 | nsIEnumerator.xpt \
|
---|
1071 | nsIPropertyBag.xpt \
|
---|
1072 | nsIVariant.xpt \
|
---|
1073 | nsISerializable.xpt \
|
---|
1074 | nsIStringEnumerator.xpt \
|
---|
1075 | nsISupportsArray.xpt \
|
---|
1076 | nsISupportsIterators.xpt \
|
---|
1077 | nsIArray.xpt \
|
---|
1078 | nsIObserverService.xpt \
|
---|
1079 | nsIObserver.xpt \
|
---|
1080 | nsIProperties.xpt \
|
---|
1081 | nsISimpleEnumerator.xpt \
|
---|
1082 | nsISupportsPrimitives.xpt \
|
---|
1083 | nsIBinaryInputStream.xpt \
|
---|
1084 | nsIBinaryOutputStream.xpt \
|
---|
1085 | nsIByteArrayInputStream.xpt \
|
---|
1086 | nsIInputStreamTee.xpt \
|
---|
1087 | nsILineInputStream.xpt \
|
---|
1088 | nsIObjectInputStream.xpt \
|
---|
1089 | nsIObjectOutputStream.xpt \
|
---|
1090 | nsISeekableStream.xpt \
|
---|
1091 | nsIStreamBufferAccess.xpt \
|
---|
1092 | nsIAsyncInputStream.xpt \
|
---|
1093 | nsIAsyncOutputStream.xpt \
|
---|
1094 | nsIDirectoryService.xpt \
|
---|
1095 | nsIFile.xpt \
|
---|
1096 | nsILocalFile.xpt \
|
---|
1097 | nsIInputStream.xpt \
|
---|
1098 | nsIOutputStream.xpt \
|
---|
1099 | nsIScriptableInputStream.xpt \
|
---|
1100 | nsIComponentLoader.xpt \
|
---|
1101 | nsIComponentLoaderManager.xpt \
|
---|
1102 | nsIComponentManagerObsolete.xpt \
|
---|
1103 | nsINativeComponentLoader.xpt \
|
---|
1104 | nsIClassInfo.xpt \
|
---|
1105 | nsIComponentRegistrar.xpt \
|
---|
1106 | nsIFactory.xpt \
|
---|
1107 | nsIModule.xpt \
|
---|
1108 | nsIServiceManager.xpt \
|
---|
1109 | nsIComponentManager.xpt \
|
---|
1110 | nsICategoryManager.xpt \
|
---|
1111 | nsIRunnable.xpt \
|
---|
1112 | nsIEventTarget.xpt \
|
---|
1113 | nsIEventQueue.xpt \
|
---|
1114 | nsIEventQueueService.xpt \
|
---|
1115 | nsIInterfaceInfo.xpt \
|
---|
1116 | nsIInterfaceInfoManager.xpt \
|
---|
1117 | nsIXPTLoader.xpt)
|
---|
1118 |
|
---|
1119 | VBoxXPCOMBase-xpt-inst_INST = $(INST_BIN)components/
|
---|
1120 | VBoxXPCOMBase-xpt-inst_MODE = 0644
|
---|
1121 | VBoxXPCOMBase-xpt-inst_SOURCES = \
|
---|
1122 | $(PATH_TARGET)/VBox-xpcom-xpt-files/VBoxXPCOMBase.xpt
|
---|
1123 | VBoxXPCOMBase-xpt-inst_CLEAN = \
|
---|
1124 | $(VBOX_XPTFILES) \
|
---|
1125 | $(PATH_TARGET)/VBox-xpcom-xpt-files/VBoxXPCOMBase.xpt
|
---|
1126 |
|
---|
1127 | # combined typelib library
|
---|
1128 | $(PATH_TARGET)/VBox-xpcom-xpt-files/VBoxXPCOMBase.xpt: $$(VBOX_XPTFILES) | $$(xpt_link_1_TARGET) $(PATH_TARGET)/VBox-xpcom-xpt-files/
|
---|
1129 | $(call MSG_LINK,XPCOM_TYPELIB,$@)
|
---|
1130 | $(QUIET)$(MKDIR) -p -- $(PATH_STAGE_BIN)/components
|
---|
1131 | $(QUIET)$(xpt_link_1_TARGET) $@ $^
|
---|
1132 |
|
---|
1133 |
|
---|
1134 |
|
---|
1135 | # generate rules
|
---|
1136 | include $(FILE_KBUILD_SUB_FOOTER)
|
---|
1137 |
|
---|
1138 |
|
---|
1139 |
|
---|
1140 | #
|
---|
1141 | # Generate IDL rules.
|
---|
1142 | #
|
---|
1143 |
|
---|
1144 | ##
|
---|
1145 | # Define for compiling one IDL into a header and a typelib
|
---|
1146 | # @param idl The filename with everything.
|
---|
1147 | define def_IDL
|
---|
1148 | $(VBOX_PATH_SDK)/bindings/xpcom/include/$(notdir $(subst .idl,.h,$(idl))) \
|
---|
1149 | + $(PATH_TARGET)/VBox-xpcom-xpt-files/$(notdir $(subst .idl,.xpt,$(idl))): \
|
---|
1150 | $(VBOX_PATH_XPCOM_SRC)/$(idl) \
|
---|
1151 | | $$$$(xpidl_1_TARGET) \
|
---|
1152 | $(PATH_TARGET)/VBox-xpcom-xpt-files/
|
---|
1153 | $$(call MSG_TOOL,xpidl,XPCOM,$$<,$$@)
|
---|
1154 | $$(QUIET)$(MKDIR) -p $(VBOX_PATH_SDK)/bindings/xpcom/include $(VBOX_PATH_SDK)/bindings/xpcom/idl
|
---|
1155 | $$(QUIET)$$(xpidl_1_TARGET) -m header $(XPIDL_INCS) -e $$@ $$<
|
---|
1156 | $$(QUIET)$$(xpidl_1_TARGET) -m typelib $(XPIDL_INCS) -e $(addprefix $(PATH_TARGET)/VBox-xpcom-xpt-files/,$(notdir $(subst .idl,.xpt,$(idl)))) $$<
|
---|
1157 | $$(QUIET)$(CP) $$< $$(VBOX_PATH_SDK)/bindings/xpcom/idl
|
---|
1158 | endef
|
---|
1159 |
|
---|
1160 | $(foreach idl, $(XPCOM_IDLFILES), $(eval $(def_IDL)))
|
---|
1161 |
|
---|
1162 | # dummy target.
|
---|
1163 | $(PATH_TARGET)/VBox-xpcom-idl-timestamp: $$(addprefix $$(VBOX_PATH_SDK)/bindings/xpcom/include/,$$(notdir $$(subst .idl,.h,$$(XPCOM_IDLFILES))))
|
---|
1164 | $(call MSG_L1,IDL processing completed.)
|
---|
1165 | $(QUIET)$(MKDIR) -p $(dir $@)
|
---|
1166 | $(QUIET)$(APPEND) -t $@
|
---|
1167 |
|
---|
1168 | #
|
---|
1169 | # HACK ALERT! Make sure main doesn't start using xpidl before we're done
|
---|
1170 | # with the idl files here. The trick here is that we're using TARGET_xpidl,
|
---|
1171 | # i.e. the copy residing in obj/, while VBOX_XPIDL is pointing to
|
---|
1172 | # xpidl_1_STAGE_TARGET which is the one in bin/.
|
---|
1173 | #
|
---|
1174 | $(VBOX_XPIDL): | $(PATH_TARGET)/VBox-xpcom-idl-timestamp
|
---|
1175 |
|
---|
1176 |
|
---|
1177 | #
|
---|
1178 | # Generate linker map file filtering out unwanted global symbols.
|
---|
1179 | #
|
---|
1180 | $(PATH_TARGET)/xpcom-namespace-cleanup.map foo.map: $$(VBoxXPCOM_LIBS) $$(VBoxXPCOM_2_OBJS)
|
---|
1181 | $(call MSG_L1, Creating linker map $@ for scrubbing the symbol namespace)
|
---|
1182 | $(QUIET)$(APPEND) -t $@ '{ local: *; global: '
|
---|
1183 | $(QUIET)$(VBOX_NM) -p -g $^ \
|
---|
1184 | | $(SED) -n \
|
---|
1185 | -e '/^$$/b' \
|
---|
1186 | -e '/:$$/b' \
|
---|
1187 | -e '/ U /b' \
|
---|
1188 | -e 's/^[^ ]* [A-Z] \(.*\)$$/\1/' \
|
---|
1189 | -e 's/\<_Z[^ ]*$$/&;/p' \
|
---|
1190 | -e 's/\<VBoxNs[^ ]*$$/&;/p' \
|
---|
1191 | -e 's/\<_edata$$/&;/p' \
|
---|
1192 | -e 's/\<_end$$/&;/p' \
|
---|
1193 | -e 's/\<_etext$$/&;/p'\
|
---|
1194 | -e 's/\<_fini$$/&;/p' \
|
---|
1195 | -e 's/\<_init$$/&;/p' \
|
---|
1196 | --append $@
|
---|
1197 | $(QUIET)$(APPEND) $@ '};'
|
---|
1198 | #ifeq ($(KBUILD_TARGET),solaris)
|
---|
1199 | # # Temporary gcc 4.5.2 hack on Solaris which emits unknown mangled symbols for ctors/dtors for certain objects. See @bugref{5838}.
|
---|
1200 | # if $(VBOX_GCC_VERSION_CXX) == 40502
|
---|
1201 | # $(QUIET)$(SED) -re '/^_Z.*[C-D]5E/d' $@ > $@-sedtmp
|
---|
1202 | # $(QUIET)$(MV) $@-sedtmp $@
|
---|
1203 | # endif
|
---|
1204 | #endif
|
---|
1205 |
|
---|