VirtualBox

source: vbox/trunk/src/libs/xpcom18a4/Makefile.kmk@ 40425

Last change on this file since 40425 was 39252, checked in by vboxsync, 13 years ago

NOINST -> INSTTYPE=none; adding DEBUG_INSTTYPE=both if the NOINST was because of code signing. This will make the .PDBs be installed into stage/debug/ for signed drivers (i.e. with .INF files).

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 46.1 KB
Line 
1# $Id: Makefile.kmk 39252 2011-11-09 14:00:21Z vboxsync $
2## @file
3# Sub-Makefile for XPCOM.
4#
5
6#
7# Copyright (C) 2006-2007 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
18SUB_DEPTH = ../../..
19include $(KBUILD_PATH)/subheader.kmk
20
21# Make sure our Config.kmk is included.
22ifndef VBOX_PATH_XPCOM_SRC
23 include $(PATH_SUB_CURRENT)/Config.kmk
24endif
25
26#
27# Globals
28#
29
30# File for filtering out C symbols from the XPCOM library. Used to avoid
31# symbol namespace pollution, causing trouble with system libraries.
32XPCOM_C_NAMESPACE_MAP = $(VBOX_PATH_XPCOM_SRC)/xpcom-namespace-cleanup.map
33ifdef VBOX_WITH_XPCOM_NAMESPACE_CLEANUP
34 VBOX_NM = nm$(HOSTSUFF_EXE)
35 # At the moment, only Solaris uses the generated map file. GNU ld is smart
36 # enough to handle symbol wildcards itself.
37 if1of ($(KBUILD_TARGET), solaris)
38 XPCOM_C_NAMESPACE_MAP = $(PATH_TARGET)/xpcom-namespace-cleanup.map
39 OTHER_CLEAN += $(XPCOM_C_NAMESPACE_MAP)
40 endif
41endif
42
43# @todo check whether VBoxXPCOMIPCC.so or VBoxXPCOMIPCD contain undefined
44# symbols starting with NS_, PL_, PR_ or XPT. Would move the test time failure
45# when missing a symbol renaming to a build time failure. Likewise, there
46# should be a check whether VBoxXPCOM.so contains global C symbols (at least
47# where the whitelisting of symbols via the map file is not used).
48
49#
50# Header installs.
51#
52INSTALLS += \
53 NSPRPUB-HEADERS \
54 NSPRPUB-MD-HEADERS \
55 NSPRPUB-OBS-HEADERS \
56 NSPRPUB-PRIV-HEADERS \
57 STRING-HEADERS \
58 XPCOM-HEADERS \
59 IPCD-HEADERS
60
61#
62# The IDL compiler, typelib linker and xpt files.
63#
64BLDPROGS += \
65 xpidl \
66 xpt_link
67
68BLDDIRS += \
69 $(PATH_TARGET)/VBox-xpcom-xpt-files/
70
71#
72# We build several libraries so that any linker command line
73# length restrictions limit will be avoided. (Solaris, Mac?)
74#
75ifndef VBOX_ONLY_SDK
76
77LIBRARIES += \
78 VBox-xpcom-nspr \
79 VBox-xpcom-typelib \
80 VBox-xpcom-string \
81 VBox-xpcom-base \
82 VBox-xpcom-ds \
83 VBox-xpcom-io \
84 VBox-xpcom-components \
85 VBox-xpcom-threads \
86 VBox-xpcom-xptinfo \
87 VBox-xpcom-xptcall \
88 VBox-xpcom-proxy \
89 VBoxXPCOMGlue_s \
90 VBoxXPCOMGlue \
91 VBox-xpcom-ipcutils \
92 VBox-xpcom-ipcshared \
93 VBox-xpcom-ipcdlock \
94 VBox-xpcom-ipctransmgr \
95 VBox-xpcom-ipctmgrcom
96
97DLLS += \
98 VBoxXPCOM \
99 VBoxXPCOMIPCC
100
101 ifdef VBOX_WITH_TESTCASES
102PROGRAMS += \
103 tstnsIFileEnumerator \
104 tstnsIFileTest \
105 tstTestArray \
106 tstTestAtoms \
107 tstTestAutoLock \
108 tstTestCallTemplates \
109 tstTestCOMPtr \
110 tstTestCOMPtrEq \
111 tstTestCRT \
112 tstTestFactory \
113 tstTestHashtables \
114 tstTestID \
115 tstTestObserverService \
116 tstTestPipes \
117 tstTestServMgr \
118 tstTestThreads \
119 tstTestXPIDLString \
120 tstTestDeque \
121 tstTestAutoPtr \
122 tstTestMinStringAPI \
123 tstTestStrings \
124 tstPrimitiveTest \
125 tstSimpleTypeLib \
126 tstXptDump \
127 tstXptLink
128# tstTestPermanentAtoms
129 endif # VBOX_WITH_TESTCASES
130PROGRAMS += VBoxXPCOMIPCD
131
132endif # !VBOX_ONLY_SDK
133
134
135
136
137#
138# SDK headers - lot's of files to install...
139#
140# Tip: If you are going to remove files here, you might
141# wish to do a `kmk uninstall' first to avoid have
142# obsoleted files in the $(INST_SDK) directory.
143#
144NSPRPUB-HEADERS_INST = $(INST_SDK)bindings/xpcom/include/nsprpub/
145NSPRPUB-HEADERS_IFFLAGS = -m 644
146NSPRPUB-HEADERS_SOURCES = \
147 nsprpub/pr/include/nspr.h \
148 nsprpub/lib/ds/plarena.h \
149 nsprpub/lib/ds/plarenas.h \
150 nsprpub/lib/libc/include/plbase64.h \
151 nsprpub/lib/libc/include/plerror.h \
152 nsprpub/lib/libc/include/plgetopt.h \
153 nsprpub/lib/ds/plhash.h \
154 nsprpub/lib/libc/include/plresolv.h \
155 nsprpub/lib/libc/include/plstr.h \
156 nsprpub/pr/include/pratom.h \
157 nsprpub/pr/include/prbit.h \
158 nsprpub/pr/include/prclist.h \
159 nsprpub/pr/include/prcmon.h \
160 nsprpub/pr/include/prcountr.h \
161 nsprpub/pr/include/prcvar.h \
162 nsprpub/pr/include/prdtoa.h \
163 nsprpub/pr/include/prenv.h \
164 nsprpub/pr/include/prerr.h \
165 nsprpub/pr/include/prerror.h \
166 nsprpub/pr/include/prinet.h \
167 nsprpub/pr/include/prinit.h \
168 nsprpub/pr/include/prinrval.h \
169 nsprpub/pr/include/prio.h \
170 nsprpub/pr/include/pripcsem.h \
171 nsprpub/pr/include/prlink.h \
172 nsprpub/pr/include/prlock.h \
173 nsprpub/pr/include/prlog.h \
174 nsprpub/pr/include/prlong.h \
175 nsprpub/pr/include/prmem.h \
176 nsprpub/pr/include/prmon.h \
177 nsprpub/pr/include/prmwait.h \
178 nsprpub/pr/include/prnetdb.h \
179 nsprpub/pr/include/prolock.h \
180 nsprpub/pr/include/prpdce.h \
181 nsprpub/pr/include/prprf.h \
182 nsprpub/pr/include/prproces.h \
183 nsprpub/pr/include/prrng.h \
184 nsprpub/pr/include/prrwlock.h \
185 nsprpub/pr/include/prshm.h \
186 nsprpub/pr/include/prshma.h \
187 nsprpub/pr/include/prsystem.h \
188 nsprpub/pr/include/prthread.h \
189 nsprpub/pr/include/prtime.h \
190 nsprpub/pr/include/prtpool.h \
191 nsprpub/pr/include/prtrace.h \
192 nsprpub/pr/include/prtypes.h \
193 nsprpub/pr/include/prvrsion.h \
194 nsprpub/pr/include/prwin16.h \
195 nsprpub/pr/include/md/_vbox.cfg=>prcpucfg.h \
196
197NSPRPUB-MD-HEADERS_INST = $(INST_SDK)bindings/xpcom/include/nsprpub/md/
198NSPRPUB-MD-HEADERS_IFFLAGS = -m 644
199NSPRPUB-MD-HEADERS_SOURCES = \
200 nsprpub/pr/include/md/_iprt_atomic.h \
201 nsprpub/pr/include/md/_darwin.h \
202 nsprpub/pr/include/md/_freebsd.h \
203 nsprpub/pr/include/md/_l4v2.h \
204 nsprpub/pr/include/md/_linux.h \
205 nsprpub/pr/include/md/_macos.h \
206 nsprpub/pr/include/md/_netbsd.h \
207 nsprpub/pr/include/md/_openbsd.h \
208 nsprpub/pr/include/md/_os2_errors.h \
209 nsprpub/pr/include/md/_os2.h \
210 nsprpub/pr/include/md/_pcos.h \
211 nsprpub/pr/include/md/_solaris.h \
212 nsprpub/pr/include/md/_unix_errors.h \
213 nsprpub/pr/include/md/_unixos.h \
214 nsprpub/pr/include/md/_pth.h \
215 nsprpub/pr/include/md/prosdep.h \
216 \
217 nsprpub/pr/include/md/_freebsd.cfg \
218 nsprpub/pr/include/md/_linux.cfg \
219 nsprpub/pr/include/md/_darwin.cfg \
220 nsprpub/pr/include/md/_netbsd.cfg \
221 nsprpub/pr/include/md/_openbsd.cfg \
222 nsprpub/pr/include/md/_os2.cfg \
223 nsprpub/pr/include/md/_solaris32.cfg \
224 nsprpub/pr/include/md/_solaris64.cfg \
225 nsprpub/pr/include/md/_l4v2.cfg
226
227NSPRPUB-OBS-HEADERS_INST = $(INST_SDK)bindings/xpcom/include/nsprpub/obsolete/
228NSPRPUB-OBS-HEADERS_IFFLAGS = -m 644
229NSPRPUB-OBS-HEADERS_SOURCES = \
230 nsprpub/pr/include/obsolete/pralarm.h \
231 nsprpub/pr/include/obsolete/probslet.h \
232 nsprpub/pr/include/obsolete/protypes.h \
233 nsprpub/pr/include/obsolete/prsem.h
234
235NSPRPUB-PRIV-HEADERS_INST = $(INST_SDK)bindings/xpcom/include/nsprpub/private/
236NSPRPUB-PRIV-HEADERS_IFFLAGS = -m 644
237NSPRPUB-PRIV-HEADERS_SOURCES = \
238 nsprpub/pr/include/private/pprio.h \
239 nsprpub/pr/include/private/pprthred.h \
240 nsprpub/pr/include/private/prpriv.h
241
242STRING-HEADERS_INST = $(INST_SDK)bindings/xpcom/include/string/
243STRING-HEADERS_IFFLAGS = -m 644
244STRING-HEADERS_SOURCES = \
245 xpcom/string/public/nsAString.h \
246 xpcom/string/public/nsAlgorithm.h \
247 xpcom/string/public/nsCharTraits.h \
248 xpcom/string/public/nsDependentString.h \
249 xpcom/string/public/nsDependentSubstring.h \
250 xpcom/string/public/nsEmbedString.h \
251 xpcom/string/public/nsLiteralString.h \
252 xpcom/string/public/nsObsoleteAString.h \
253 xpcom/string/public/nsPrintfCString.h \
254 xpcom/string/public/nsPromiseFlatString.h \
255 xpcom/string/public/nsReadableUtils.h \
256 xpcom/string/public/nsString.h \
257 xpcom/string/public/nsStringAPI.h \
258 xpcom/string/public/nsStringFwd.h \
259 xpcom/string/public/nsStringIterator.h \
260 xpcom/string/public/nsSubstring.h \
261 xpcom/string/public/nsSubstringTuple.h \
262 xpcom/string/public/nsTAString.h \
263 xpcom/string/public/nsTDependentString.h \
264 xpcom/string/public/nsTDependentSubstring.h \
265 xpcom/string/public/nsTObsoleteAString.h \
266 xpcom/string/public/nsTPromiseFlatString.h \
267 xpcom/string/public/nsTString.h \
268 xpcom/string/public/nsTSubstring.h \
269 xpcom/string/public/nsTSubstringTuple.h \
270 xpcom/string/public/nsUTF8Utils.h \
271 xpcom/string/public/nsXPIDLString.h \
272 xpcom/string/public/string-template-def-char.h \
273 xpcom/string/public/string-template-def-unichar.h \
274 xpcom/string/public/string-template-undef.h
275
276XPCOM-HEADERS_INST = $(INST_SDK)bindings/xpcom/include/xpcom/
277XPCOM-HEADERS_IFFLAGS = -m 644
278XPCOM-HEADERS_SOURCES = \
279 xpcom/base/nsAgg.h \
280 xpcom/io/nsAppDirectoryServiceDefs.h \
281 xpcom/ds/nsArray.h \
282 xpcom/ds/nsArrayEnumerator.h \
283 xpcom/ds/nsAtomService.h \
284 xpcom/ds/nsAutoBuffer.h \
285 xpcom/threads/nsAutoLock.h \
286 xpcom/base/nsAutoPtr.h \
287 xpcom/ds/nsBaseHashtable.h \
288 xpcom/ds/nsCOMArray.h \
289 xpcom/ds/nsCRT.h \
290 xpcom/components/nsCategoryManagerUtils.h \
291 xpcom/ds/nsCheapSets.h \
292 xpcom/ds/nsClassHashtable.h \
293 xpcom/base/nsCom.h \
294 xpcom/components/nsComponentManagerObsolete.h \
295 xpcom/components/nsComponentManagerUtils.h \
296 xpcom/ds/nsCppSharedAllocator.h \
297 xpcom/ds/nsDataHashtable.h \
298 xpcom/base/nsDebugImpl.h \
299 xpcom/ds/nsDeque.h \
300 xpcom/io/nsDirectoryService.h \
301 xpcom/io/nsDirectoryServiceDefs.h \
302 xpcom/io/nsDirectoryServiceUtils.h \
303 xpcom/ds/nsDoubleHashtable.h \
304 xpcom/ds/nsEnumeratorUtils.h \
305 xpcom/base/nsError.h \
306 xpcom/io/nsEscape.h \
307 xpcom/threads/nsEventQueueUtils.h \
308 xpcom/io/nsFastLoadPtr.h \
309 xpcom/io/nsFastLoadService.h \
310 xpcom/ds/nsFixedSizeAllocator.h \
311 xpcom/ds/nsHashKeys.h \
312 xpcom/ds/nsHashSets.h \
313 xpcom/ds/nsHashtable.h \
314 xpcom/base/nsIAllocator.h \
315 xpcom/ds/nsIByteBuffer.h \
316 xpcom/base/nsID.h \
317 xpcom/base/nsIID.h \
318 xpcom/components/nsIServiceManagerObsolete.h \
319 xpcom/components/nsIServiceManagerUtils.h \
320 xpcom/base/nsISupportsBase.h \
321 xpcom/base/nsISupportsObsolete.h \
322 xpcom/ds/nsIUnicharBuffer.h \
323 xpcom/io/nsIUnicharInputStream.h \
324 xpcom/ds/nsInt64.h \
325 xpcom/ds/nsInterfaceHashtable.h \
326 xpcom/io/nsLinebreakConverter.h \
327 xpcom/io/nsLocalFile.h \
328 xpcom/io/nsLocalFileUnix.h \
329 xpcom/io/nsLocalFileOS2.h \
330 xpcom/io/nsLocalFileOSX.h \
331 xpcom/components/nsModule.h \
332 xpcom/io/nsMultiplexInputStream.h \
333 xpcom/io/nsNativeCharsetUtils.h \
334 xpcom/components/nsNativeComponentLoader.h \
335 xpcom/ds/nsObserverService.h \
336 xpcom/components/nsObsoleteModuleLoading.h \
337 xpcom/threads/nsProcess.h \
338 xpcom/proxy/public/nsProxiedService.h \
339 xpcom/proxy/public/nsProxyEvent.h \
340 xpcom/proxy/public/nsProxyRelease.h \
341 xpcom/ds/nsQuickSort.h \
342 xpcom/ds/nsRecyclingAllocator.h \
343 xpcom/ds/nsRefPtrHashtable.h \
344 xpcom/io/nsScriptableInputStream.h \
345 xpcom/ds/nsStaticAtom.h \
346 xpcom/components/nsStaticComponent.h \
347 xpcom/ds/nsStaticNameTable.h \
348 xpcom/io/nsStorageStream.h \
349 xpcom/io/nsStreamUtils.h \
350 xpcom/ds/nsStringEnumerator.h \
351 xpcom/io/nsStringIO.h \
352 xpcom/io/nsStringStream.h \
353 xpcom/ds/nsSupportsArray.h \
354 xpcom/ds/nsSupportsPrimitives.h \
355 xpcom/ds/nsTHashtable.h \
356 xpcom/ds/nsTextFormatter.h \
357 xpcom/ds/nsTime.h \
358 xpcom/base/nsTraceRefcntImpl.h \
359 xpcom/ds/nsUnitConversion.h \
360 xpcom/ds/nsValueArray.h \
361 xpcom/ds/nsVariant.h \
362 xpcom/ds/nsVoidArray.h \
363 xpcom/base/nsWeakPtr.h \
364 xpcom/build/nsXPCOM.h \
365 xpcom/build/nsXPCOMCID.h \
366 xpcom/base/nscore.h \
367 xpcom/ds/pldhash.h \
368 xpcom/threads/plevent.h \
369 xpcom/components/xcDll.h \
370 xpcom/typelib/xpt/public/xpt_arena.h \
371 xpcom/typelib/xpt/public/xpt_struct.h \
372 xpcom/typelib/xpt/public/xpt_xdr.h \
373 xpcom/reflect/xptcall/public/xptcall.h \
374 xpcom/reflect/xptcall/public/xptcstubsdecl.inc \
375 xpcom/reflect/xptcall/public/xptcstubsdef.inc \
376 xpcom/reflect/xptinfo/public/xptinfo.h \
377 \
378 xpcom/glue/nsIInterfaceRequestorUtils.h \
379 xpcom/glue/nsISupportsImpl.h \
380 xpcom/glue/nsISupportsUtils.h \
381 xpcom/glue/nsIWeakReferenceUtils.h \
382 \
383 xpcom/glue/nsCOMPtr.h \
384 xpcom/glue/nsDebug.h \
385 xpcom/glue/nsGenericFactory.h \
386 xpcom/glue/nsIGenericFactory.h \
387 xpcom/glue/nsMemory.h \
388 xpcom/glue/nsTraceRefcnt.h \
389 xpcom/glue/nsWeakReference.h \
390 \
391 xpcom/glue/standalone/nsXPCOMGlue.h \
392 \
393 xpcom-config.h
394
395IPCD-HEADERS_INST = $(INST_SDK)bindings/xpcom/include/ipcd/
396IPCD-HEADERS_IFFLAGS = -m 644
397IPCD-HEADERS_SOURCES = \
398 ipc/ipcd/client/public/ipcCID.h \
399 ipc/ipcd/extensions/lock/public/ipcLockCID.h \
400 ipc/ipcd/util/public/ipcMessageReader.h \
401 ipc/ipcd/util/public/ipcMessageWriter.h \
402 ipc/ipcd/daemon/public/ipcModule.h \
403 ipc/ipcd/daemon/public/ipcModuleUtil.h \
404 ipc/ipcd/client/public/ipcdclient.h
405
406
407#
408# The IDL compiler.
409#
410# We build it statically because we cannot rely on additional .a files
411# like in the original build
412#
413xpidl_TEMPLATE = XPCOMBLDPROG
414xpidl_DEFS = EXPORT_XPT_API
415## @todo This assumes HOST == TARGET.
416xpidl_INST = $(INST_BIN)
417## Obsolete hack: MacPorts is 32-bit on 10.5 and 64-bit on 10.6. Set your KBUILD_HOST_ARCH env.vars. accordingly.
418#if "$(KBUILD_HOST).$(KBUILD_HOST_ARCH)" == "darwin.amd64" && defined(VBOX_MACOS_10_5_WORKAROUND)
419# xpidl_BLD_TRG_ARCH = x86
420# ## @todo kBuild ticket 84 workarounds:
421# xpidl_DEFS.x86 = $(TEMPLATE_XPCOMBLDPROG_DEFS.x86)
422# xpidl_CFLAGS.x86 = $(TEMPLATE_XPCOMBLDPROG_CFLAGS.x86)
423# xpidl_CXXFLAGS.x86 = $(TEMPLATE_XPCOMBLDPROG_CXXFLAGS.x86)
424# xpidl_LDFLAGS.x86 = $(TEMPLATE_XPCOMBLDPROG_LDFLAGS.x86)
425#endif
426ifdef VBOX_WITH_JAVA_SUPPORT_IN_XPIDL
427 xpidl_DEFS += VBOX_XPIDL_EMULATE_GENJIFACES VBOX_XPIDL_EMULATE_GENJIFACES_DIFF
428endif
429xpidl_SOURCES = \
430 xpcom/typelib/xpidl/xpidl.c \
431 xpcom/typelib/xpidl/xpidl_idl.c \
432 xpcom/typelib/xpidl/xpidl_util.c \
433 xpcom/typelib/xpidl/xpidl_header.c \
434 xpcom/typelib/xpidl/xpidl_typelib.c \
435 xpcom/typelib/xpidl/xpidl_doc.c \
436 xpcom/typelib/xpidl/xpidl_java.c \
437 xpcom/typelib/xpt/src/xpt_arena.c \
438 xpcom/typelib/xpt/src/xpt_struct.c \
439 xpcom/typelib/xpt/src/xpt_xdr.c
440
441ifeq ($(KBUILD_TARGET),os2)
442 # glib and libIDL needed by XPCOM on OS/2.
443 ifeq ($(VBOX_PATH_GLIB),)
444 VBOX_PATH_GLIB := $(lastword $(sort $(wildcard $(PATH_DEVTOOLS_TRG)/glibidl/*/glibidl/gcc335)))
445 endif
446 VBOX_PATH_LIBIDL ?= $(VBOX_PATH_GLIB)
447 ifeq ($(wildcard $(VBOX_PATH_GLIB)),)
448 $(warning VBOX_PATH_GLIB is "$(VBOX_PATH_GLIB)" which is not a valid directory!)
449 endif
450 ifeq ($(wildcard $(VBOX_PATH_LIBIDL)),)
451 $(warning VBOX_PATH_LIBIDL is "$(VBOX_PATH_LIBIDL)" which is not a valid directory!)
452 endif
453 xpidl_INCS = \
454 $(VBOX_PATH_LIBIDL)/include \
455 $(VBOX_PATH_GLIB)/include
456 xpidl_LIBS = \
457 $(VBOX_PATH_LIBIDL)/lib/libidl.lib \
458 $(VBOX_PATH_LIBIDL)/lib/glib.lib
459 # install necessary DLLs to the same place where xpidl goes
460 INSTALLS += xpidl-DLLS
461 xpidl_ORDERDEPS = $(xpidl-DLLS_1_TARGET)
462 xpidl-DLLS_INST = $(xpidl_INST)
463 # static libraries of these may be provided instead,
464 # so copy DLLs only when they are present
465 xpidl-DLLS_SOURCES += $(wildcard $(VBOX_PATH_GLIB)/lib/glib.dll)
466 xpidl-DLLS_SOURCES += $(wildcard $(VBOX_PATH_LIBIDL)/lib/libIDL.dll)
467else
468 # We do these ONCE.
469 libIDL_config_cflags := $(shell $(VBOX_LIBIDL_CONFIG) --cflags)
470 libIDL_config_libs := $(shell $(VBOX_LIBIDL_CONFIG) --libs)
471 xpidl_CFLAGS = \
472 $(libIDL_config_cflags)
473 ifeq ($(BUILD_PLATFORM),linux)
474 xpidl_LDFLAGS = \
475 $(filter-out -l%,$(libIDL_config_libs))
476 else
477 xpidl_LDFLAGS = \
478 $(libIDL_config_libs)
479 endif
480 xpidl_LDFLAGS.linux = \
481 $(VBOX_LD_as_needed)
482 xpidl_LIBS.linux += \
483 $(subst -l,,$(filter -l%,$(libIDL_config_libs)))
484endif
485
486#
487# The XPT linker.
488#
489xpt_link_TEMPLATE = XPCOMBLDPROG
490xpt_link_SOURCES = \
491 xpcom/typelib/xpt/tools/xpt_link.c \
492 xpcom/typelib/xpt/src/xpt_arena.c \
493 xpcom/typelib/xpt/src/xpt_struct.c \
494 xpcom/typelib/xpt/src/xpt_xdr.c
495
496
497#
498# The NSPR Library.
499#
500VBox-xpcom-nspr_TEMPLATE = XPCOM
501VBox-xpcom-nspr_INSTTYPE = none
502VBox-xpcom-nspr_DEFS = \
503 _NSPR_BUILD_ \
504 HAVE_LCHOWN=1 \
505 HAVE_STRERROR=1 \
506 FORCE_PR_LOG
507VBox-xpcom-nspr_DEFS += \
508 VBOX_USE_IPRT_IN_NSPR
509VBox-xpcom-nspr_DEFS.darwin.amd64 = \
510 VBOX_USE_MORE_IPRT_IN_NSPR
511VBox-xpcom-nspr_DEFS.darwin = \
512 HAVE_BSD_FLOCK=1 \
513 _PR_PTHREADS
514VBox-xpcom-nspr_DEFS.freebsd = \
515 FREEBSD=1 \
516 HAVE_CVAR_BUILT_ON_SEM \
517 _PR_PTHREADS
518## @todo filling in the missing stuff, please don't just copy it from linux.
519# FIXME: LINUX should be defined by _linux.cfg
520VBox-xpcom-nspr_DEFS.linux = \
521 LINUX=1 \
522 _POSIX_SOURCE=1 \
523 _BSD_SOURCE=1 \
524 _SVID_SOURCE=1 \
525 _REENTRANT=1 \
526 _LARGEFILE64_SOURCE=1 \
527 HAVE_FCNTL_FILE_LOCKING=1 \
528 HAVE_CVAR_BUILT_ON_SEM \
529 _PR_PTHREADS
530# _BSD_SOURCE is here to keep the Glibc header files happy and make them include the right things
531# FIXME: L4 should be defined by _linux.cfg
532VBox-xpcom-nspr_DEFS.l4 = \
533 L4=1 \
534 _REENTRANT=1 \
535 _LARGEFILE64_SOURCE=1 \
536 _POSIX_SOURCE=1 \
537 _BSD_SOURCE=1 \
538 HAVE_FCNTL_FILE_LOCKING=1 \
539 HAVE_CVAR_BUILT_ON_SEM
540VBox-xpcom-nspr_DEFS.netbsd = \
541 _PR_PTHREADS
542VBox-xpcom-nspr_DEFS.openbsd = \
543 _PR_PTHREADS
544VBox-xpcom-nspr_DEFS.os2 =
545VBox-xpcom-nspr_DEFS.solaris = \
546 HAVE_FCNTL_FILE_LOCKING=1 \
547 _PR_PTHREADS
548VBox-xpcom-nspr_INCS = \
549 nsprpub/pr/include/private \
550 $(VBox-xpcom-nspr_0_OUTDIR)
551
552VBox-xpcom-nspr_SOURCES = \
553 nsprpub/pr/src/io/prfdcach.c \
554 nsprpub/pr/src/io/prmwait.c \
555 nsprpub/pr/src/io/priometh.c \
556 nsprpub/pr/src/io/pripv6.c \
557 nsprpub/pr/src/io/prmapopt.c \
558 nsprpub/pr/src/io/prlayer.c \
559 nsprpub/pr/src/io/prlog.c \
560 nsprpub/pr/src/io/prmmap.c \
561 nsprpub/pr/src/io/prpolevt.c \
562 nsprpub/pr/src/io/prprf.c \
563 nsprpub/pr/src/io/prscanf.c \
564 nsprpub/pr/src/io/prstdio.c \
565 nsprpub/pr/src/linking/prlink.c \
566 nsprpub/pr/src/malloc/prmalloc.c \
567 nsprpub/pr/src/malloc/prmem.c \
568 nsprpub/pr/src/md/prosdep.c \
569 nsprpub/pr/src/memory/prseg.c \
570 nsprpub/pr/src/memory/prshm.c \
571 nsprpub/pr/src/memory/prshma.c \
572 nsprpub/pr/src/misc/pralarm.c \
573 nsprpub/pr/src/misc/pratom.c \
574 nsprpub/pr/src/misc/prcountr.c \
575 nsprpub/pr/src/misc/prdtoa.c \
576 nsprpub/pr/src/misc/prenv.c \
577 nsprpub/pr/src/misc/prerr.c \
578 nsprpub/pr/src/misc/prerror.c \
579 nsprpub/pr/src/misc/prerrortable.c \
580 nsprpub/pr/src/misc/prinit.c \
581 nsprpub/pr/src/misc/prinrval.c \
582 nsprpub/pr/src/misc/pripc.c \
583 nsprpub/pr/src/misc/prlog2.c \
584 nsprpub/pr/src/misc/prlong.c \
585 nsprpub/pr/src/misc/prnetdb.c \
586 nsprpub/pr/src/misc/prolock.c \
587 nsprpub/pr/src/misc/prrng.c \
588 nsprpub/pr/src/misc/prsystem.c \
589 nsprpub/pr/src/misc/prtime.c \
590 nsprpub/pr/src/misc/prthinfo.c \
591 nsprpub/pr/src/misc/prtpool.c \
592 nsprpub/pr/src/misc/prtrace.c \
593 nsprpub/pr/src/threads/prcmon.c \
594 nsprpub/pr/src/threads/prrwlock.c \
595 nsprpub/pr/src/threads/prtpd.c \
596 nsprpub/pr/src/prvrsion.c \
597 nsprpub/lib/ds/plarena.c \
598 nsprpub/lib/ds/plhash.c \
599 nsprpub/lib/libc/src/strlen.c \
600 nsprpub/lib/libc/src/strcpy.c \
601 nsprpub/lib/libc/src/strdup.c \
602 nsprpub/lib/libc/src/strcat.c \
603 nsprpub/lib/libc/src/strcmp.c \
604 nsprpub/lib/libc/src/strccmp.c \
605 nsprpub/lib/libc/src/strchr.c \
606 nsprpub/lib/libc/src/strpbrk.c \
607 nsprpub/lib/libc/src/strstr.c \
608 nsprpub/lib/libc/src/strcstr.c \
609 nsprpub/lib/libc/src/strtok.c \
610 nsprpub/lib/libc/src/base64.c \
611 nsprpub/lib/libc/src/plerror.c \
612 nsprpub/lib/libc/src/plgetopt.c
613
614ifeq ($(filter-out darwin freebsd linux netbsd openbsd solaris,$(KBUILD_TARGET)),) # unixish
615VBox-xpcom-nspr_SOURCES += \
616 nsprpub/pr/src/md/unix/unix.c \
617 nsprpub/pr/src/md/unix/unix_errors.c \
618 nsprpub/pr/src/md/unix/uxproces.c \
619 nsprpub/pr/src/md/unix/uxrng.c \
620 nsprpub/pr/src/md/unix/uxshm.c \
621 nsprpub/pr/src/md/unix/uxwrap.c \
622 nsprpub/pr/src/pthreads/ptio.c \
623 nsprpub/pr/src/pthreads/ptsynch.c \
624 nsprpub/pr/src/pthreads/ptthread.c \
625 nsprpub/pr/src/pthreads/ptmisc.c
626endif
627
628VBox-xpcom-nspr_SOURCES.darwin = nsprpub/pr/src/md/unix/darwin.c
629VBox-xpcom-nspr_SOURCES.darwin.x86 = nsprpub/pr/src/md/unix/os_Darwin_x86.s
630
631VBox-xpcom-nspr_SOURCES.freebsd = nsprpub/pr/src/md/unix/freebsd.c
632
633VBox-xpcom-nspr_SOURCES.l4 = \
634 nsprpub/pr/src/io/prfile.c /* why not for Linux? */ \
635 nsprpub/pr/src/io/prio.c /* "" "" "" "" */ \
636 nsprpub/pr/src/io/prsocket.c \
637 nsprpub/pr/src/md/unix/unix.c \
638 nsprpub/pr/src/md/unix/unix_errors.c \
639 nsprpub/pr/src/md/unix/uxpoll.c \
640 nsprpub/pr/src/md/unix/uxproces.c \
641 nsprpub/pr/src/md/unix/uxrng.c \
642 nsprpub/pr/src/md/unix/uxshm.c \
643 nsprpub/pr/src/md/unix/uxwrap.c \
644 nsprpub/pr/src/md/unix/l4env.c \
645 nsprpub/pr/src/threads/prcthr.c \
646 nsprpub/pr/src/threads/prmon.c \
647 nsprpub/pr/src/threads/combined/prucpu.c \
648 nsprpub/pr/src/threads/combined/prucv.c \
649 nsprpub/pr/src/threads/combined/prulock.c \
650 nsprpub/pr/src/threads/combined/prustack.c \
651 nsprpub/pr/src/threads/combined/pruthr.c
652# nsprpub/pr/src/md/l4env/prnetdb.c \
653# nsprpub/pr/src/md/l4env/threads.c
654VBox-xpcom-nspr_SOURCES.l4.x86 = nsprpub/pr/src/md/unix/os_Linux_x86.s
655VBox-xpcom-nspr_SOURCES.l4.amd64 = nsprpub/pr/src/md/unix/os_Linux_x86_64.s
656
657VBox-xpcom-nspr_SOURCES.linux = nsprpub/pr/src/md/unix/linux.c
658VBox-xpcom-nspr_SOURCES.linux.x86 = nsprpub/pr/src/md/unix/os_Linux_x86.s
659VBox-xpcom-nspr_SOURCES.linux.amd64 = nsprpub/pr/src/md/unix/os_Linux_x86_64.s
660
661VBox-xpcom-nspr_SOURCES.os2 = \
662 nsprpub/pr/src/io/prdir.c \
663 nsprpub/pr/src/io/prfile.c \
664 nsprpub/pr/src/io/prio.c \
665 nsprpub/pr/src/io/prsocket.c \
666 nsprpub/pr/src/md/os2/os2misc.c \
667 nsprpub/pr/src/md/os2/os2sem.c \
668 nsprpub/pr/src/md/os2/os2inrval.c \
669 nsprpub/pr/src/md/os2/os2gc.c \
670 nsprpub/pr/src/md/os2/os2thred.c \
671 nsprpub/pr/src/md/os2/os2io.c \
672 nsprpub/pr/src/md/os2/os2cv.c \
673 nsprpub/pr/src/md/os2/os2sock.c \
674 nsprpub/pr/src/md/os2/os2_errors.c \
675 nsprpub/pr/src/md/os2/os2poll.c \
676 nsprpub/pr/src/md/os2/os2rng.c \
677 nsprpub/pr/src/threads/prdump.c \
678 nsprpub/pr/src/threads/prmon.c \
679 nsprpub/pr/src/threads/prsem.c \
680 nsprpub/pr/src/threads/prcthr.c \
681 nsprpub/pr/src/threads/combined/prucpu.c \
682 nsprpub/pr/src/threads/combined/prucv.c \
683 nsprpub/pr/src/threads/combined/prulock.c \
684 nsprpub/pr/src/threads/combined/prustack.c \
685 nsprpub/pr/src/threads/combined/pruthr.c
686# gcc/emx sources
687VBox-xpcom-nspr_SOURCES.os2 += \
688 nsprpub/pr/src/md/os2/os2emx.s \
689 nsprpub/pr/src/md/os2/os2vaclegacy.s
690# IBM VAC sources (not used)
691#VBox-xpcom-nspr_SOURCES.os2 += \
692# nsprpub/pr/src/md/os2/os2vacpp.asm
693
694VBox-xpcom-nspr_SOURCES.solaris = nsprpub/pr/src/md/unix/solaris.c
695VBox-xpcom-nspr_SOURCES.solaris.x86 = nsprpub/pr/src/md/unix/os_SunOS_x86.s
696VBox-xpcom-nspr_SOURCES.solaris.amd64 = nsprpub/pr/src/md/unix/os_SunOS_x86_64.s
697
698# generate build stamps
699nsprpub/pr/src/prvrsion.c_DEPS = $(VBox-xpcom-nspr_0_OUTDIR)/_pr_bld.h
700nsprpub/lib/ds/plvrsion.c_DEPS = $(VBox-xpcom-nspr_0_OUTDIR)/_pl_bld.h
701VBox-xpcom-nspr_CLEAN += \
702 $(VBox-xpcom-nspr_0_OUTDIR)/_pr_bld.h \
703 $(VBox-xpcom-nspr_0_OUTDIR)/_pl_bld.h
704
705$$(VBox-xpcom-nspr_0_OUTDIR)/_pr_bld.h: | $$(VBox-xpcom-nspr_0_OUTDIR)/
706 $(call MSG_GENERATE,,$@)
707 $(QUIET)$(APPEND) -t $@ '#define _BUILD_STRING "$(date +%Y-%m-%d %T)"'
708
709$$(VBox-xpcom-nspr_0_OUTDIR)/_pl_bld.h: | $$(VBox-xpcom-nspr_0_OUTDIR)/
710 $(call MSG_GENERATE,,$@)
711 $(QUIET)$(APPEND) -t $@ '#define _BUILD_STRING "$(date +%Y-%m-%d %T)"'
712
713
714VBox-xpcom-typelib_TEMPLATE = XPCOM
715VBox-xpcom-typelib_INSTTYPE = none
716VBox-xpcom-typelib_SOURCES = \
717 xpcom/typelib/xpt/src/xpt_arena.c \
718 xpcom/typelib/xpt/src/xpt_struct.c \
719 xpcom/typelib/xpt/src/xpt_xdr.c
720
721VBox-xpcom-string_TEMPLATE = XPCOM
722VBox-xpcom-string_INSTTYPE = none
723VBox-xpcom-string_SOURCES = \
724 xpcom/string/src/nsAString.cpp \
725 xpcom/string/src/nsDependentSubstring.cpp \
726 xpcom/string/src/nsObsoleteAStringThunk.cpp \
727 xpcom/string/src/nsPrintfCString.cpp \
728 xpcom/string/src/nsPromiseFlatString.cpp \
729 xpcom/string/src/nsReadableUtils.cpp \
730 xpcom/string/src/nsSubstring.cpp \
731 xpcom/string/src/nsSubstringTuple.cpp \
732 xpcom/string/src/nsString.cpp \
733 xpcom/string/src/nsStringComparator.cpp \
734 xpcom/string/src/nsStringObsolete.cpp
735
736VBox-xpcom-base_TEMPLATE = XPCOM
737VBox-xpcom-base_INSTTYPE = none
738VBox-xpcom-base_DEFS = _IMPL_NS_COM
739VBox-xpcom-base_SOURCES = \
740 xpcom/base/nsAllocator.cpp \
741 xpcom/base/nsConsoleMessage.cpp \
742 xpcom/base/nsConsoleService.cpp \
743 xpcom/base/nsDebugImpl.cpp \
744 xpcom/base/nsErrorService.cpp \
745 xpcom/base/nsExceptionService.cpp \
746 xpcom/base/nsID.cpp \
747 xpcom/base/nsMemoryImpl.cpp \
748 xpcom/base/nsTraceRefcntImpl.cpp \
749 xpcom/base/nsStackFrameUnix.cpp
750
751VBox-xpcom-ds_TEMPLATE = XPCOM
752VBox-xpcom-ds_INSTTYPE = none
753VBox-xpcom-ds_DEFS = _IMPL_NS_COM
754VBox-xpcom-ds_SOURCES = \
755 xpcom/ds/pldhash.c \
756 xpcom/ds/nsAtomTable.cpp \
757 xpcom/ds/nsAtomService.cpp \
758 xpcom/ds/nsByteBuffer.cpp \
759 xpcom/ds/nsCheapSets.cpp \
760 xpcom/ds/nsCRT.cpp \
761 xpcom/ds/nsDeque.cpp \
762 xpcom/ds/nsEmptyEnumerator.cpp \
763 xpcom/ds/nsEnumeratorUtils.cpp \
764 xpcom/ds/nsFixedSizeAllocator.cpp \
765 xpcom/ds/nsHashSets.cpp \
766 xpcom/ds/nsHashtable.cpp \
767 xpcom/ds/nsObserverList.cpp \
768 xpcom/ds/nsObserverService.cpp \
769 xpcom/ds/nsProperties.cpp \
770 xpcom/ds/nsPersistentProperties.cpp \
771 xpcom/ds/nsQuickSort.cpp \
772 xpcom/ds/nsRecyclingAllocator.cpp \
773 xpcom/ds/nsStaticNameTable.cpp \
774 xpcom/ds/nsStringEnumerator.cpp \
775 xpcom/ds/nsSupportsArray.cpp \
776 xpcom/ds/nsSupportsArrayEnumerator.cpp \
777 xpcom/ds/nsSupportsPrimitives.cpp \
778 xpcom/ds/nsTHashtable.cpp \
779 xpcom/ds/nsUnicharBuffer.cpp \
780 xpcom/ds/nsVariant.cpp \
781 xpcom/ds/nsVoidArray.cpp \
782 xpcom/ds/nsTextFormatter.cpp \
783 xpcom/ds/nsTimelineService.cpp \
784 xpcom/ds/nsValueArray.cpp \
785 xpcom/ds/nsCOMArray.cpp \
786 xpcom/ds/nsArray.cpp \
787 xpcom/ds/nsArrayEnumerator.cpp
788# xpcom/ds/nsHashPropertyBag.cpp
789
790# @todo what about MOZ_USER_DIR?
791VBox-xpcom-io_TEMPLATE = XPCOM
792VBox-xpcom-io_INSTTYPE = none
793VBox-xpcom-io_DEFS = _IMPL_NS_COM MOZ_USER_DIR=\".mozilla\"
794VBox-xpcom-io_INCS.darwin = \
795 xpcom/MoreFiles
796VBox-xpcom-io_SOURCES = \
797 xpcom/io/nsAppFileLocationProvider.cpp \
798 xpcom/io/nsBinaryStream.cpp \
799 xpcom/io/nsByteArrayInputStream.cpp \
800 xpcom/io/nsDirectoryService.cpp \
801 xpcom/io/nsEscape.cpp \
802 xpcom/io/nsFastLoadFile.cpp \
803 xpcom/io/nsFastLoadService.cpp \
804 xpcom/io/nsInputStreamTee.cpp \
805 xpcom/io/nsLinebreakConverter.cpp \
806 xpcom/io/nsLocalFileCommon.cpp \
807 xpcom/io/nsMultiplexInputStream.cpp \
808 xpcom/io/nsPipe3.cpp \
809 xpcom/io/nsStreamUtils.cpp \
810 xpcom/io/nsScriptableInputStream.cpp \
811 xpcom/io/nsSegmentedBuffer.cpp \
812 xpcom/io/SpecialSystemDirectory.cpp \
813 xpcom/io/nsStorageStream.cpp \
814 xpcom/io/nsStringStream.cpp \
815 xpcom/io/nsUnicharInputStream.cpp \
816 xpcom/io/nsNativeCharsetUtils.cpp
817VBox-xpcom-io_SOURCES.darwin.x86 = \
818 xpcom/io/nsLocalFileOSX.cpp \
819 xpcom/MoreFiles/FSCopyObject.c \
820 xpcom/MoreFiles/MoreFilesX.c
821VBox-xpcom-io_SOURCES.l4 = \
822 xpcom/io/nsLocalFileL4.cpp
823if1of ($(KBUILD_TARGET) $(KBUILD_TARGET).$(KBUILD_TARGET_ARCH), freebsd linux netbsd openbsd solaris darwin.amd64)
824VBox-xpcom-io_SOURCES += \
825 xpcom/io/nsLocalFileUnix.cpp
826endif
827VBox-xpcom-io_SOURCES.os2 = \
828 xpcom/io/nsLocalFileOS2.cpp
829
830VBox-xpcom-components_TEMPLATE = XPCOM
831VBox-xpcom-components_INSTTYPE = none
832VBox-xpcom-components_DEFS = _IMPL_NS_COM EXPORT_XPTI_API
833VBox-xpcom-components_SOURCES = \
834 xpcom/components/nsCategoryManager.cpp \
835 xpcom/components/nsComponentManager.cpp \
836 xpcom/components/nsComponentManagerObsolete.cpp \
837 xpcom/components/nsNativeComponentLoader.cpp \
838 xpcom/components/nsServiceManagerObsolete.cpp \
839 xpcom/components/xcDll.cpp \
840 xpcom/components/nsStaticComponentLoader.cpp
841
842VBox-xpcom-threads_TEMPLATE = XPCOM
843VBox-xpcom-threads_INSTTYPE = none
844VBox-xpcom-threads_DEFS = _IMPL_NS_COM
845VBox-xpcom-threads_SOURCES = \
846 xpcom/threads/plevent.c \
847 xpcom/threads/nsAutoLock.cpp \
848 xpcom/threads/nsEnvironment.cpp \
849 xpcom/threads/nsEventQueue.cpp \
850 xpcom/threads/nsEventQueueService.cpp \
851 xpcom/threads/nsThread.cpp \
852 xpcom/threads/nsTimerImpl.cpp \
853 xpcom/threads/nsProcessCommon.cpp \
854 xpcom/threads/TimerThread.cpp
855
856VBox-xpcom-xptinfo_TEMPLATE = XPCOM
857VBox-xpcom-xptinfo_INSTTYPE = none
858VBox-xpcom-xptinfo_DEFS = _IMPL_NS_COM _IMPL_NS_BASE EXPORT_XPTI_API EXPORT_XPT_API
859VBox-xpcom-xptinfo_SOURCES = \
860 xpcom/reflect/xptinfo/src/xptiFile.cpp \
861 xpcom/reflect/xptinfo/src/xptiInterfaceInfo.cpp \
862 xpcom/reflect/xptinfo/src/xptiInterfaceInfoManager.cpp \
863 xpcom/reflect/xptinfo/src/xptiManifest.cpp \
864 xpcom/reflect/xptinfo/src/xptiMisc.cpp \
865 xpcom/reflect/xptinfo/src/xptiTypelibGuts.cpp \
866 xpcom/reflect/xptinfo/src/xptiWorkingSet.cpp \
867 xpcom/reflect/xptinfo/src/xptiZipItem.cpp \
868 xpcom/reflect/xptinfo/src/xptiZipLoader.cpp
869
870
871VBox-xpcom-xptcall_TEMPLATE = XPCOM
872VBox-xpcom-xptcall_INSTTYPE = none
873VBox-xpcom-xptcall_DEFS = _IMPL_NS_COM _IMPL_NS_BASE EXPORT_XPTC_API
874VBox-xpcom-xptcall_DEFS.darwin = KEEP_STACK_16_BYTE_ALIGNED
875VBox-xpcom-xptcall_DEFS.l4 = L4
876VBox-xpcom-xptcall_DEFS.os2 = MOZ_NEED_LEADING_UNDERSCORE
877VBox-xpcom-xptcall_INCS.os2 = xpcom/reflect/xptcall/src/md/unix
878VBox-xpcom-xptcall_SOURCES = xpcom/reflect/xptcall/src/xptcall.cpp
879VBox-xpcom-xptcall_SOURCES.darwin.x86 = xpcom/reflect/xptcall/src/md/unix/xptcinvoke_unixish_x86.cpp \
880 xpcom/reflect/xptcall/src/md/unix/xptcstubs_unixish_x86.cpp
881VBox-xpcom-xptcall_SOURCES.darwin.amd64= xpcom/reflect/xptcall/src/md/unix/xptcinvoke_amd64_darwin.cpp \
882 xpcom/reflect/xptcall/src/md/unix/xptcstubs_amd64_darwin.cpp
883VBox-xpcom-xptcall_SOURCES.freebsd.x86 = xpcom/reflect/xptcall/src/md/unix/xptcinvoke_gcc_x86_unix.cpp \
884 xpcom/reflect/xptcall/src/md/unix/xptcstubs_gcc_x86_unix.cpp
885VBox-xpcom-xptcall_SOURCES.freebsd.amd64=xpcom/reflect/xptcall/src/md/unix/xptcinvoke_x86_64_linux.cpp \
886 xpcom/reflect/xptcall/src/md/unix/xptcstubs_x86_64_linux.cpp
887VBox-xpcom-xptcall_SOURCES.linux.x86 = xpcom/reflect/xptcall/src/md/unix/xptcinvoke_gcc_x86_unix.cpp \
888 xpcom/reflect/xptcall/src/md/unix/xptcstubs_gcc_x86_unix.cpp
889VBox-xpcom-xptcall_SOURCES.linux.amd64 = xpcom/reflect/xptcall/src/md/unix/xptcinvoke_x86_64_linux.cpp \
890 xpcom/reflect/xptcall/src/md/unix/xptcstubs_x86_64_linux.cpp
891VBox-xpcom-xptcall_SOURCES.os2 = xpcom/reflect/xptcall/src/md/os2/xptcinvoke_gcc_x86_os2.cpp \
892 xpcom/reflect/xptcall/src/md/os2/xptcstubs_gcc_x86_os2.cpp
893VBox-xpcom-xptcall_SOURCES.solaris.x86 = xpcom/reflect/xptcall/src/md/unix/xptcinvoke_x86_solaris.cpp \
894 xpcom/reflect/xptcall/src/md/unix/xptcstubs_x86_solaris.cpp
895VBox-xpcom-xptcall_SOURCES.solaris.amd64 = xpcom/reflect/xptcall/src/md/unix/xptcinvoke_x86_64_linux.cpp \
896 xpcom/reflect/xptcall/src/md/unix/xptcstubs_x86_64_linux.cpp
897
898xpcom/reflect/xptcall/src/md/unix/xptcstubs_x86_solaris.cpp_CXXFLAGS = -O0
899# -O0 works fine, while -O1 doesn't. The gcc man page can't be listing all the -f*
900# stuff that -O1 enables, because when using the options without -O1, it's -fomit-frame-pointer
901# that triggers is, while -O1 -fno-omit-frame-pointer does not work. Anyway, it's probably a gcc/mozila
902# bug and it's not worth investigating as I'm not the maintainger of the solaris gcc port. [bird, 2007-09-17]
903
904
905VBox-xpcom-proxy_TEMPLATE = XPCOM
906VBox-xpcom-proxy_INSTTYPE = none
907VBox-xpcom-proxy_DEFS = _IMPL_NS_COM EXPORT_XPTC_API EXPORT_XPTI_API
908VBox-xpcom-proxy_SOURCES = xpcom/proxy/src/nsProxyEvent.cpp \
909 xpcom/proxy/src/nsProxyEventClass.cpp \
910 xpcom/proxy/src/nsProxyEventObject.cpp \
911 xpcom/proxy/src/nsProxyObjectManager.cpp \
912 xpcom/proxy/src/nsProxyRelease.cpp
913
914
915#
916# The VBoxXPCOM Glue static libraries.
917#
918# See http://developer.mozilla.org/en/docs/XPCOM_Glue for details about the
919# original XPCOM glue library purpose and usage.
920#
921# We don't really use the glue library in the described way because we don't
922# provide frozen APIs (yet), so all VBox XPCOM client applications are
923# dependent on the given version of both the VBox XPCOM runtime (binary
924# dependency) and VirtualBox component library (COM interface dependency). For
925# this reason, VBox client applications link to the VBox XPCOM shared library
926# directly (instead of linking to the standalone XPCOM glue library that would
927# dynamically search for and load the installed XPCOM runtime). For the same
928# reason, we link all parts of XPCOM into a single shared XPCOM library below
929# (as opposed to the original XPCOM where e.g. NSPR lives in a separate DLL).
930#
931VBoxXPCOMGlue_COMMON_SOURCES = \
932 xpcom/glue/nsCOMPtr.cpp \
933 xpcom/glue/nsComponentManagerUtils.cpp \
934 xpcom/glue/nsDebug.cpp \
935 xpcom/glue/nsGenericFactory.cpp \
936 xpcom/glue/nsIInterfaceRequestorUtils.cpp \
937 xpcom/glue/nsMemory.cpp \
938 xpcom/glue/nsTraceRefcnt.cpp \
939 xpcom/glue/nsWeakReference.cpp
940
941# dependent glue library which goes in to the VBoxXPCOM shared library
942VBoxXPCOMGlue_s_TEMPLATE = XPCOM
943VBoxXPCOMGlue_s_INSTTYPE = none
944VBoxXPCOMGlue_s_DEFS = _IMPL_NS_COM
945VBoxXPCOMGlue_s_SOURCES = $(VBoxXPCOMGlue_COMMON_SOURCES)
946
947# standalone glue library which all third-party client apps (if any) will link with
948# (currently not used anywhere (see above) but still built to make sure
949# the code inside #ifdef XPCOM_GLUE compiles)
950VBoxXPCOMGlue_TEMPLATE = XPCOM
951VBoxXPCOMGlue_DEFS = XPCOM_GLUE
952VBoxXPCOMGlue_SOURCES = $(VBoxXPCOMGlue_COMMON_SOURCES) \
953 xpcom/glue/standalone/nsXPCOMGlue.cpp \
954 xpcom/glue/standalone/nsGREDirServiceProvider.cpp
955VBoxXPCOMGlue_SOURCES += \
956 $(VBox-xpcom-string_1_TARGET)
957#VBoxXPCOMGlue_INST = lib/ $(INST_SDK)lib/
958
959
960#
961# The VBoxXPCOM Shared Object, assembling all lib files.
962#
963VBoxXPCOM_TEMPLATE = XPCOM
964VBoxXPCOM_NAME = $(basename $(notdir $(LIB_XPCOM)))
965VBoxXPCOM_DEFS = BUILD_DCONNECT="1" _IMPL_NS_COM
966ifdef VBOX_WITH_XPCOM_NAMESPACE_CLEANUP
967 VBoxXPCOM_LDFLAGS.linux = -Wl,--version-script=$(XPCOM_C_NAMESPACE_MAP)
968 VBoxXPCOM_LNK_DEPS.linux += $(XPCOM_C_NAMESPACE_MAP)
969 VBoxXPCOM_LDFLAGS.solaris = -Wl,-M,$(XPCOM_C_NAMESPACE_MAP)
970 VBoxXPCOM_LNK_DEPS.solaris+= $(XPCOM_C_NAMESPACE_MAP)
971endif
972VBoxXPCOM_SOURCES = \
973 xpcom/build/nsXPComInit.cpp \
974 xpcom/build/nsStringAPI.cpp
975VBoxXPCOM_SOURCES.darwin = \
976 vboxdeps.cpp
977VBoxXPCOM_SOURCES.os2 = \
978 vboxdeps.cpp
979VBoxXPCOM_SOURCES.solaris = \
980 vboxdeps.cpp
981VBoxXPCOM_LIBS = \
982 $(VBox-xpcom-typelib_1_TARGET) \
983 $(VBox-xpcom-string_1_TARGET) \
984 $(VBox-xpcom-base_1_TARGET) \
985 $(VBox-xpcom-ds_1_TARGET) \
986 $(VBox-xpcom-io_1_TARGET) \
987 $(VBox-xpcom-components_1_TARGET) \
988 $(VBox-xpcom-threads_1_TARGET) \
989 $(VBox-xpcom-xptinfo_1_TARGET) \
990 $(VBox-xpcom-xptcall_1_TARGET) \
991 $(VBox-xpcom-proxy_1_TARGET) \
992 $(VBox-xpcom-nspr_1_TARGET) \
993 $(VBoxXPCOMGlue_s_1_TARGET)
994VBoxXPCOM_LIBS.linux = \
995 pthread dl
996
997ifeq ($(filter-out freebsd l4 linux netbsd openbsd,$(KBUILD_TARGET)),) # gnu ld.
998VBoxXPCOM_LDFLAGS = -Wl,--whole-archive \
999 $(VBox-xpcom-typelib_1_TARGET) \
1000 $(VBox-xpcom-string_1_TARGET) \
1001 $(VBox-xpcom-base_1_TARGET) \
1002 $(VBox-xpcom-ds_1_TARGET) \
1003 $(VBox-xpcom-io_1_TARGET) \
1004 $(VBox-xpcom-components_1_TARGET) \
1005 $(VBox-xpcom-threads_1_TARGET) \
1006 $(VBox-xpcom-xptinfo_1_TARGET) \
1007 $(VBox-xpcom-xptcall_1_TARGET) \
1008 $(VBox-xpcom-proxy_1_TARGET) \
1009 $(VBox-xpcom-nspr_1_TARGET) \
1010 $(VBoxXPCOMGlue_s_1_TARGET) \
1011 -Wl,--no-whole-archive
1012endif
1013
1014VBoxXPCOM_LDFLAGS.solaris += -Wl,-z,allextract \
1015 $(VBox-xpcom-typelib_1_TARGET) \
1016 $(VBox-xpcom-string_1_TARGET) \
1017 $(VBox-xpcom-base_1_TARGET) \
1018 $(VBox-xpcom-ds_1_TARGET) \
1019 $(VBox-xpcom-io_1_TARGET) \
1020 $(VBox-xpcom-components_1_TARGET) \
1021 $(VBox-xpcom-threads_1_TARGET) \
1022 $(VBox-xpcom-xptinfo_1_TARGET) \
1023 $(VBox-xpcom-xptcall_1_TARGET) \
1024 $(VBox-xpcom-proxy_1_TARGET) \
1025 $(VBox-xpcom-nspr_1_TARGET) \
1026 $(VBoxXPCOMGlue_s_1_TARGET) \
1027 -Wl,-z,defaultextract
1028
1029#VBoxXPCOM_LIBS.l4 = $(L4_LIBDIR)/libxpcomstubs.a $(L4_LIBDIR)/../libuc_c++.a \
1030# $(VBOX_PATH_L4_GCC3_INSTALL)/libsupc++.a $(VBOX_PATH_L4_GCC3_INSTALL)/libgcc_eh.a
1031# EF heap
1032#VBoxXPCOM_LIBS += $(LIB_RUNTIME_EF)
1033#VBoxXPCOM_LDFLAGS = -Wl,--whole-archive $(VBoxXPCOM_LIBS) -Wl,--no-whole-archive $(LIB_RUNTIME)
1034VBoxXPCOM_LDFLAGS.darwin = -install_name $(VBOX_DYLD_EXECUTABLE_PATH)/VBoxXPCOM.dylib
1035
1036ifdef VBOX_IPC_RELEASE_LOG
1037IPC_LOGGING = 1
1038else ifneq ($(KBUILD_TYPE),release)
1039IPC_LOGGING = 1
1040endif
1041
1042TEMPLATE_XPCOMIPC = XPCOM IPC libraries
1043TEMPLATE_XPCOMIPC_EXTENDS = XPCOM
1044TEMPLATE_XPCOMIPC_DEFS = \
1045 $(TEMPLATE_XPCOM_DEFS) BUILD_DCONNECT="1" \
1046 IPC_DAEMON_APP_NAME=\"VBoxXPCOMIPCD$(SUFF_EXE)\"
1047ifdef IPC_LOGGING
1048 TEMPLATE_XPCOMIPC_DEFS += IPC_LOGGING
1049endif
1050
1051TEMPLATE_XPCOMIPC_LIBS = $(VBoxXPCOM_1_TARGET) $(TEMPLATE_XPCOM_LIBS)
1052
1053TEMPLATE_XPCOMIPCEXE = XPCOM IPC executables
1054TEMPLATE_XPCOMIPCEXE_EXTENDS = XPCOMEXE
1055TEMPLATE_XPCOMIPCEXE_DEFS = $(TEMPLATE_XPCOMEXE_DEFS) BUILD_DCONNECT="1"
1056ifdef IPC_LOGGING
1057 TEMPLATE_XPCOMIPCEXE_DEFS += IPC_LOGGING
1058endif
1059
1060VBox-xpcom-ipcutils_TEMPLATE = XPCOMIPC
1061VBox-xpcom-ipcutils_INSTTYPE = none
1062VBox-xpcom-ipcutils_SOURCES = \
1063 ipc/ipcd/util/src/ipcMessageReader.cpp \
1064 ipc/ipcd/util/src/ipcMessageWriter.cpp
1065
1066VBox-xpcom-ipcshared_TEMPLATE = XPCOMIPC
1067VBox-xpcom-ipcshared_INSTTYPE = none
1068VBox-xpcom-ipcshared_SOURCES = \
1069 ipc/ipcd/shared/src/ipcLog.cpp \
1070 ipc/ipcd/shared/src/ipcConfig.cpp \
1071 ipc/ipcd/shared/src/ipcMessage.cpp \
1072 ipc/ipcd/shared/src/ipcMessagePrimitives.cpp \
1073 ipc/ipcd/shared/src/ipcStringList.cpp \
1074 ipc/ipcd/shared/src/ipcIDList.cpp \
1075 ipc/ipcd/shared/src/ipcm.cpp
1076
1077VBox-xpcom-ipcdlock_TEMPLATE = XPCOMIPC
1078VBox-xpcom-ipcdlock_INSTTYPE = none
1079VBox-xpcom-ipcdlock_SOURCES = \
1080 ipc/ipcd/extensions/lock/src/ipcLockProtocol.cpp \
1081 ipc/ipcd/extensions/lock/src/ipcLockService.cpp
1082
1083VBox-xpcom-ipctransmgr_TEMPLATE = XPCOMIPC
1084VBox-xpcom-ipctransmgr_INSTTYPE = none
1085VBox-xpcom-ipctransmgr_SOURCES = \
1086 ipc/ipcd/extensions/transmngr/src/tmTransactionService.cpp
1087
1088VBox-xpcom-ipctmgrcom_TEMPLATE = XPCOMIPC
1089VBox-xpcom-ipctmgrcom_INSTTYPE = none
1090VBox-xpcom-ipctmgrcom_SOURCES = \
1091 ipc/ipcd/extensions/transmngr/common/tmTransaction.cpp \
1092 ipc/ipcd/extensions/transmngr/common/tmVector.cpp
1093
1094
1095#
1096# DCONNECT client shared object
1097#
1098VBoxXPCOMIPCC_TEMPLATE = XPCOMIPC
1099VBoxXPCOMIPCC_NAME.os2 = VBoxIPCC
1100VBoxXPCOMIPCC_INST = $(INST_BIN)components/
1101#VBoxXPCOMIPCC_DEFS = HAVE_DEPENDENT_LIBS - dependentLibs.h is linux specific, so this cannot be required.
1102VBoxXPCOMIPCC_SOURCES = \
1103 ipc/ipcd/client/src/ipcdclient.cpp \
1104 ipc/ipcd/client/src/ipcService.cpp \
1105 ipc/ipcd/client/src/ipcModuleFactory.cpp \
1106 ipc/ipcd/extensions/dconnect/src/ipcDConnectService.cpp
1107ifeq ($(KBUILD_TARGET),win)
1108VBoxXPCOMIPCC_SOURCES += \
1109 ipc/ipcd/client/src/ipcConnectionWin.cpp
1110else
1111VBoxXPCOMIPCC_SOURCES += \
1112 ipc/ipcd/client/src/ipcConnectionUnix.cpp
1113endif
1114VBoxXPCOMIPCC_LDFLAGS.darwin = -install_name $(VBOX_DYLD_EXECUTABLE_PATH)/components/VBoxXPCOMIPCC.dylib
1115VBoxXPCOMIPCC_LIBS = \
1116 $(VBox-xpcom-ipcutils_1_TARGET) \
1117 $(VBox-xpcom-ipcshared_1_TARGET) \
1118 $(VBox-xpcom-ipcdlock_1_TARGET) \
1119 $(VBox-xpcom-ipctransmgr_1_TARGET) \
1120 $(VBox-xpcom-ipctmgrcom_1_TARGET)
1121# EF
1122#VBoxXPCOMIPCC_LIBS += $(LIB_RUNTIME)
1123
1124
1125#
1126# DCONNECT daemon executable
1127#
1128VBoxXPCOMIPCD_TEMPLATE = XPCOMIPCEXE
1129VBoxXPCOMIPCD_SOURCES = \
1130 ipc/ipcd/daemon/src/ipcd.cpp \
1131 ipc/ipcd/daemon/src/ipcClient.cpp \
1132 ipc/ipcd/daemon/src/ipcModuleReg.cpp \
1133 ipc/ipcd/daemon/src/ipcCommandModule.cpp
1134ifeq ($(KBUILD_TARGET),win)
1135 VBoxXPCOMIPCD_SOURCES += \
1136 ipc/ipcd/daemon/src/ipcdWin.cpp
1137else
1138 VBoxXPCOMIPCD_SOURCES += \
1139 ipc/ipcd/daemon/src/ipcdUnix.cpp
1140endif
1141
1142
1143#
1144# Include sub-makefiles for the Python<->XPCOM and Java<->XPCOM bridges.
1145#
1146
1147# Find the Python headers for the Python<->XPCOM bridge if enabled.
1148ifdef VBOX_WITH_PYTHON
1149 include $(PATH_SUB_CURRENT)/python/Makefile.kmk
1150endif
1151
1152ifdef VBOX_WITH_JXPCOM
1153 include $(PATH_SUB_CURRENT)/java/Makefile.kmk
1154endif
1155
1156
1157#
1158# testcases
1159#
1160tstnsIFileEnumerator_TEMPLATE = XPCOMTSTEXE
1161tstnsIFileEnumerator_SOURCES = xpcom/tests/nsIFileEnumerator.cpp
1162tstnsIFileTest_TEMPLATE = XPCOMTSTEXE
1163tstnsIFileTest_SOURCES = xpcom/tests/nsIFileTest.cpp
1164tstTestArray_TEMPLATE = XPCOMTSTEXE
1165tstTestArray_SOURCES = xpcom/tests/TestArray.cpp
1166tstTestAtoms_TEMPLATE = XPCOMTSTEXE
1167tstTestAtoms_SOURCES = xpcom/tests/TestAtoms.cpp
1168tstTestAutoLock_TEMPLATE = XPCOMTSTEXE
1169tstTestAutoLock_SOURCES = xpcom/tests/TestAutoLock.cpp
1170tstTestCallTemplates_TEMPLATE = XPCOMTSTEXE
1171tstTestCallTemplates_SOURCES = xpcom/tests/TestCallTemplates.cpp
1172tstTestCOMPtr_TEMPLATE = XPCOMTSTEXE
1173tstTestCOMPtr_SOURCES = xpcom/tests/TestCOMPtr.cpp
1174tstTestCOMPtrEq_TEMPLATE = XPCOMTSTEXE
1175tstTestCOMPtrEq_SOURCES = xpcom/tests/TestCOMPtrEq.cpp
1176tstTestCRT_TEMPLATE = XPCOMTSTEXE
1177tstTestCRT_SOURCES = xpcom/tests/TestCRT.cpp
1178tstTestFactory_TEMPLATE = XPCOMTSTEXE
1179tstTestFactory_SOURCES = xpcom/tests/TestFactory.cpp
1180tstTestHashtables_TEMPLATE = XPCOMTSTEXE
1181tstTestHashtables_SOURCES = xpcom/tests/TestHashtables.cpp
1182tstTestID_TEMPLATE = XPCOMTSTEXE
1183tstTestID_SOURCES = xpcom/tests/TestID.cpp
1184tstTestObserverService_TEMPLATE= XPCOMTSTEXE
1185tstTestObserverService_SOURCES = xpcom/tests/TestObserverService.cpp
1186tstTestPermanentAtoms_TEMPLATE = XPCOMTSTEXE
1187tstTestPermanentAtoms_SOURCES = xpcom/tests/TestPermanentAtoms.cpp
1188tstTestPipes_TEMPLATE = XPCOMTSTEXE
1189tstTestPipes_SOURCES = xpcom/tests/TestPipes.cpp
1190tstTestServMgr_TEMPLATE = XPCOMTSTEXE
1191tstTestServMgr_SOURCES = xpcom/tests/TestServMgr.cpp
1192tstTestServMgr_INCS = xpcom/tests/services
1193tstTestThreads_TEMPLATE = XPCOMTSTEXE
1194tstTestThreads_SOURCES = xpcom/tests/TestThreads.cpp
1195tstTestXPIDLString_TEMPLATE = XPCOMTSTEXE
1196tstTestXPIDLString_SOURCES = xpcom/tests/TestXPIDLString.cpp
1197tstTestDeque_TEMPLATE = XPCOMTSTEXE
1198tstTestDeque_SOURCES = xpcom/tests/TestDeque.cpp
1199tstTestAutoPtr_TEMPLATE = XPCOMTSTEXE
1200tstTestAutoPtr_SOURCES = xpcom/tests/TestAutoPtr.cpp
1201tstTestMinStringAPI_TEMPLATE = XPCOMTSTEXE
1202tstTestMinStringAPI_SOURCES = xpcom/tests/TestMinStringAPI.cpp
1203tstTestStrings_TEMPLATE = XPCOMTSTEXE
1204tstTestStrings_SOURCES = xpcom/tests/TestStrings.cpp
1205tstPrimitiveTest_TEMPLATE = XPCOMTSTEXE
1206tstPrimitiveTest_SOURCES = xpcom/typelib/xpt/tests/PrimitiveTest.c
1207tstSimpleTypeLib_TEMPLATE = XPCOMTSTEXE
1208tstSimpleTypeLib_SOURCES = xpcom/typelib/xpt/tests/SimpleTypeLib.c
1209tstXptDump_TEMPLATE = XPCOMTSTEXE
1210tstXptDump_SOURCES = xpcom/typelib/xpt/tools/xpt_dump.c
1211tstXptLink_TEMPLATE = XPCOMTSTEXE
1212tstXptLink_SOURCES = xpcom/typelib/xpt/tools/xpt_link.c
1213
1214
1215
1216OTHER_CLEAN += \
1217 $(PATH_TARGET)/VBox-xpcom-idl-timestamp \
1218 $(addprefix $(VBOX_PATH_SDK)/bindings/xpcom/include,$(notdir $(subst .idl,.h,$(XPCOM_IDLFILES)))) \
1219 $(addprefix $(VBOX_PATH_SDK)/bindings/xpcom/include,$(notdir $(subst .idl,.xpt,$(XPCOM_IDLFILES)))) \
1220 $(addprefix $(VBOX_PATH_SDK)/bindings/xpcom/idl/,$(notdir $(XPCOM_IDLFILES))) \
1221 $(addprefix $(PATH_TARGET)/VBox-xpcom-xpt-files/,$(notdir $(subst .idl,.xpt,$(XPCOM_IDLFILES))))
1222
1223
1224#
1225# Create and install VBoxXPCOMBase.xpt
1226#
1227INSTALLS += VBoxXPCOMBase-xpt-inst
1228VBOX_XPTFILES = $(addprefix $(PATH_TARGET)/VBox-xpcom-xpt-files/, \
1229 nsIConsoleListener.xpt \
1230 nsIConsoleMessage.xpt \
1231 nsIConsoleService.xpt \
1232 nsIErrorService.xpt \
1233 nsIException.xpt \
1234 nsIExceptionService.xpt \
1235 nsIDebug.xpt \
1236 nsIInterfaceRequestor.xpt \
1237 nsIMemory.xpt \
1238 nsIProgrammingLanguage.xpt \
1239 nsISupports.xpt \
1240 nsITraceRefcnt.xpt \
1241 nsIWeakReference.xpt \
1242 nsrootidl.xpt \
1243 nsIAtom.xpt \
1244 nsIAtomService.xpt \
1245 nsICollection.xpt \
1246 nsIEnumerator.xpt \
1247 nsIPersistentProperties2.xpt \
1248 nsIPropertyBag.xpt \
1249 nsIRecyclingAllocator.xpt \
1250 nsIVariant.xpt \
1251 nsISerializable.xpt \
1252 nsIStringEnumerator.xpt \
1253 nsISupportsArray.xpt \
1254 nsISupportsIterators.xpt \
1255 nsITimelineService.xpt \
1256 nsIArray.xpt \
1257 nsIObserverService.xpt \
1258 nsIObserver.xpt \
1259 nsIProperties.xpt \
1260 nsISimpleEnumerator.xpt \
1261 nsISupportsPrimitives.xpt \
1262 nsIBinaryInputStream.xpt \
1263 nsIBinaryOutputStream.xpt \
1264 nsIByteArrayInputStream.xpt \
1265 nsIFastLoadFileControl.xpt \
1266 nsIFastLoadService.xpt \
1267 nsIInputStreamTee.xpt \
1268 nsILineInputStream.xpt \
1269 nsIMultiplexInputStream.xpt \
1270 nsIObjectInputStream.xpt \
1271 nsIObjectOutputStream.xpt \
1272 nsIPipe.xpt \
1273 nsISeekableStream.xpt \
1274 nsIStorageStream.xpt \
1275 nsIStringStream.xpt \
1276 nsIStreamBufferAccess.xpt \
1277 nsIAsyncInputStream.xpt \
1278 nsIAsyncOutputStream.xpt \
1279 nsIDirectoryService.xpt \
1280 nsIFile.xpt \
1281 nsILocalFile.xpt \
1282 nsIInputStream.xpt \
1283 nsIOutputStream.xpt \
1284 nsIScriptableInputStream.xpt \
1285 nsIComponentLoader.xpt \
1286 nsIComponentLoaderManager.xpt \
1287 nsIComponentManagerObsolete.xpt \
1288 nsINativeComponentLoader.xpt \
1289 nsIClassInfo.xpt \
1290 nsIComponentRegistrar.xpt \
1291 nsIFactory.xpt \
1292 nsIModule.xpt \
1293 nsIServiceManager.xpt \
1294 nsIComponentManager.xpt \
1295 nsICategoryManager.xpt \
1296 nsIThread.xpt \
1297 nsITimer.xpt \
1298 nsITimerInternal.xpt \
1299 nsITimerManager.xpt \
1300 nsIRunnable.xpt \
1301 nsIEventTarget.xpt \
1302 nsIEventQueue.xpt \
1303 nsIEventQueueService.xpt \
1304 nsIEnvironment.xpt \
1305 nsIProcess.xpt \
1306 nsIInterfaceInfo.xpt \
1307 nsIInterfaceInfoManager.xpt \
1308 nsIXPTLoader.xpt)
1309
1310VBoxXPCOMBase-xpt-inst_INST = $(INST_BIN)components/
1311VBoxXPCOMBase-xpt-inst_MODE = 0644
1312VBoxXPCOMBase-xpt-inst_SOURCES = \
1313 $(PATH_TARGET)/VBox-xpcom-xpt-files/VBoxXPCOMBase.xpt
1314VBoxXPCOMBase-xpt-inst_CLEAN = \
1315 $(VBOX_XPTFILES) \
1316 $(PATH_TARGET)/VBox-xpcom-xpt-files/VBoxXPCOMBase.xpt
1317
1318# combined typelib library
1319$(PATH_TARGET)/VBox-xpcom-xpt-files/VBoxXPCOMBase.xpt: $$(VBOX_XPTFILES) | $$(xpt_link_1_TARGET) $(PATH_TARGET)/VBox-xpcom-xpt-files/
1320 $(call MSG_LINK,XPCOM_TYPELIB,$@)
1321 $(QUIET)$(MKDIR) -p -- $(PATH_STAGE_BIN)/components
1322 $(QUIET)$(xpt_link_1_TARGET) $@ $^
1323
1324
1325
1326# generate rules
1327include $(KBUILD_PATH)/subfooter.kmk
1328
1329
1330
1331#
1332# Generate IDL rules.
1333#
1334
1335##
1336# Define for compiling one IDL into a header and a typelib
1337# @param idl The filename with everything.
1338define def_IDL
1339$(VBOX_PATH_SDK)/bindings/xpcom/include/$(notdir $(subst .idl,.h,$(idl))) \
1340+ $(PATH_TARGET)/VBox-xpcom-xpt-files/$(notdir $(subst .idl,.xpt,$(idl))): \
1341 $(VBOX_PATH_XPCOM_SRC)/$(idl) \
1342 | $$$$(xpidl_1_TARGET) \
1343 $(PATH_TARGET)/VBox-xpcom-xpt-files/
1344 $$(call MSG_TOOL,xpidl,XPCOM,$$<,$$@)
1345 $$(QUIET)$(MKDIR) -p $(VBOX_PATH_SDK)/bindings/xpcom/include $(VBOX_PATH_SDK)/bindings/xpcom/idl
1346 $$(QUIET)$$(xpidl_1_TARGET) -m header $(XPIDL_INCS) -e $$@ $$<
1347 $$(QUIET)$$(xpidl_1_TARGET) -m typelib $(XPIDL_INCS) -e $(addprefix $(PATH_TARGET)/VBox-xpcom-xpt-files/,$(notdir $(subst .idl,.xpt,$(idl)))) $$<
1348 $$(QUIET)$(CP) $$< $$(VBOX_PATH_SDK)/bindings/xpcom/idl
1349endef
1350
1351$(foreach idl, $(XPCOM_IDLFILES), $(eval $(def_IDL)))
1352
1353# dummy target.
1354$(PATH_TARGET)/VBox-xpcom-idl-timestamp: $$(addprefix $$(VBOX_PATH_SDK)/bindings/xpcom/include/,$$(notdir $$(subst .idl,.h,$$(XPCOM_IDLFILES))))
1355 $(call MSG_L1,IDL processing completed.)
1356 $(QUIET)$(MKDIR) -p $(dir $@)
1357 $(QUIET)$(APPEND) -t $@
1358
1359#
1360# HACK ALERT! Make sure main doesn't start using xpidl before we're done
1361# with the idl files here. The trick here is that we're using TARGET_xpidl,
1362# i.e. the copy residing in obj/, while VBOX_XPIDL is pointing to
1363# xpidl_1_STAGE_TARGET which is the one in bin/.
1364#
1365$(VBOX_XPIDL): | $(PATH_TARGET)/VBox-xpcom-idl-timestamp
1366
1367
1368#
1369# Generate linker map file filtering out unwanted global symbols.
1370#
1371$(PATH_TARGET)/xpcom-namespace-cleanup.map foo.map: $$(VBoxXPCOM_LIBS) $$(VBoxXPCOM_OBJS_)
1372 $(call MSG_L1, Creating linker map $@ for scrubbing the symbol namespace)
1373 $(QUIET)$(APPEND) -t $@ '{ local: *; global: '
1374 $(QUIET)$(VBOX_NM) -p -g $^ \
1375 | $(SED) -n \
1376 -e '/^$$/b' \
1377 -e '/:$$/b' \
1378 -e '/ U /b' \
1379 -e 's/^[^ ]* [A-Z] \(.*\)$$/\1/' \
1380 -e 's/\<_Z[^ ]*$$/&;/p' \
1381 -e 's/\<VBoxNs[^ ]*$$/&;/p' \
1382 -e 's/\<_edata$$/&;/p' \
1383 -e 's/\<_end$$/&;/p' \
1384 -e 's/\<_etext$$/&;/p'\
1385 -e 's/\<_fini$$/&;/p' \
1386 -e 's/\<_init$$/&;/p' \
1387 --append $@
1388 $(QUIET)$(APPEND) $@ '};'
1389
Note: See TracBrowser for help on using the repository browser.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette