1 | # $Id: Makefile.kmk 6307 2008-01-09 17:25:59Z vboxsync $
|
---|
2 | ## @file
|
---|
3 | # Top level makefile.
|
---|
4 | #
|
---|
5 |
|
---|
6 | #
|
---|
7 | # Copyright (C) 2006-2007 innotek GmbH
|
---|
8 | #
|
---|
9 | # This file is part of VirtualBox Open Source Edition (OSE), as
|
---|
10 | # available from http://www.virtualbox.org. This file is free software;
|
---|
11 | # you can redistribute it and/or modify it under the terms of the GNU
|
---|
12 | # General Public License (GPL) as published by the Free Software
|
---|
13 | # Foundation, in version 2 as it comes in the "COPYING" file of the
|
---|
14 | # VirtualBox OSE distribution. VirtualBox OSE is distributed in the
|
---|
15 | # hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
|
---|
16 | #
|
---|
17 |
|
---|
18 | DEPTH = .
|
---|
19 | include $(PATH_KBUILD)/header.kmk
|
---|
20 |
|
---|
21 | ifdef VBOX_WITH_DOCS
|
---|
22 | ifndef VBOX_ONLY_ADDITIONS
|
---|
23 | SUBDIRS = doc/manual
|
---|
24 | endif
|
---|
25 | endif
|
---|
26 | SUBDIRS += src
|
---|
27 |
|
---|
28 | ifndef VBOX_ONLY_ADDITIONS
|
---|
29 | #
|
---|
30 | # Install external binaries (mostly redistributable parts of tools we use).
|
---|
31 | # This must be done *before* we build the manual.
|
---|
32 | #
|
---|
33 | # To avoid dragging in unnecessary tools and sdks here, we don't use the .win
|
---|
34 | # and .linux property suffixes.
|
---|
35 | #
|
---|
36 | INSTALLS = bin
|
---|
37 |
|
---|
38 | bin_INST = $(INST_BIN)
|
---|
39 |
|
---|
40 | # The SDL DLLs
|
---|
41 | ifeq ($(filter-out win os2,$(BUILD_TARGET)),)
|
---|
42 | ifneq ($(VBOX_WITH_VBOXSDL)$(VBOX_WITH_VBOXBFE),)
|
---|
43 | include $(PATH_KBUILD)/sdks/LIBSDL.kmk
|
---|
44 | bin_SOURCES += \
|
---|
45 | $(DLL_SDK_LIBSDL_SDL)
|
---|
46 | ifdef VBOX_WITH_SECURELABEL
|
---|
47 | bin_SOURCES += \
|
---|
48 | $(DLL_SDK_LIBSDL_SDLTTF)
|
---|
49 | endif
|
---|
50 | ifeq ($(BUILD_TARGET),os2)
|
---|
51 | bin_SOURCES += \
|
---|
52 | $(DLL_SDK_LIBSDL_FSLIB)
|
---|
53 | endif
|
---|
54 | endif
|
---|
55 | endif
|
---|
56 |
|
---|
57 |
|
---|
58 | # The Qt DLLs.
|
---|
59 | ifneq ($(VBOX_WITH_QTGUI),)
|
---|
60 | ifeq ($(BUILD_TARGET),win)
|
---|
61 | #include $(PATH_KBUILD)/sdks/QT3.kmk
|
---|
62 | #bin_SOURCES += \
|
---|
63 | # $(DLL_SDK_QT3_QT)
|
---|
64 | ifeq ($(BUILD_TARGET).$(BUILD_TARGET_ARCH),win.x86)
|
---|
65 | VBOX_DLL_QT ?= $(VBOX_PATH_QT)/bin/qt-mt333.dll
|
---|
66 | else ifeq ($(BUILD_TARGET).$(BUILD_TARGET_ARCH),win.amd64)
|
---|
67 | VBOX_DLL_QT ?= $(PATH_DEVTOOLS)/win.amd64/Qt/v3.3.8/lib/qt-mt338.dll=>qt-mt338.dll
|
---|
68 | endif
|
---|
69 | ifdef VBOX_DLL_QT
|
---|
70 | bin_SOURCES += \
|
---|
71 | $(VBOX_DLL_QT)=>$(not-dir $(VBOX_DLL_QT))
|
---|
72 | endif
|
---|
73 | else ifeq ($(BUILD_TARGET),os2)
|
---|
74 | VBOX_DLL_QT ?= $(lastword $(sort $(wildcard $(VBOX_PATH_QT)/bin/*qt*.dll)))
|
---|
75 | ifneq ($(strip $(VBOX_DLL_QT)),)
|
---|
76 | bin_SOURCES += \
|
---|
77 | $(VBOX_DLL_QT)=>$(not-dir $(VBOX_DLL_QT))
|
---|
78 | endif
|
---|
79 | else ifeq ($(VBOX_MUST_INSTALL_LIB_QT),1)
|
---|
80 | bin_SOURCES += \
|
---|
81 | $(LIB_QT)
|
---|
82 | endif
|
---|
83 | endif
|
---|
84 |
|
---|
85 |
|
---|
86 | # The compiler runtime DLLs.
|
---|
87 | ifeq ($(BUILD_TARGET).$(VBOX_WITHOUT_COMPILER_REDIST),win.)
|
---|
88 | ifdef VBOX_USE_VCC80
|
---|
89 | include $(PATH_KBUILD)/tools/VCC80X86.kmk
|
---|
90 | include $(PATH_KBUILD)/tools/VCC80AMD64.kmk
|
---|
91 | bin_SOURCES.x86 += \
|
---|
92 | $(PATH_TOOL_VCC80X86)/redist/x86/Microsoft.VC80.CRT/Microsoft.VC80.CRT.manifest=>Microsoft.VC80.CRT/Microsoft.VC80.CRT.manifest \
|
---|
93 | $(PATH_TOOL_VCC80X86)/redist/x86/Microsoft.VC80.CRT/msvcr80.dll=>Microsoft.VC80.CRT/msvcr80.dll \
|
---|
94 | $(PATH_TOOL_VCC80X86)/redist/x86/Microsoft.VC80.CRT/msvcp80.dll=>Microsoft.VC80.CRT/msvcp80.dll \
|
---|
95 | $(PATH_TOOL_VCC80X86)/redist/x86/Microsoft.VC80.CRT/Microsoft.VC80.CRT.manifest=>testcase/Microsoft.VC80.CRT/Microsoft.VC80.CRT.manifest \
|
---|
96 | $(PATH_TOOL_VCC80X86)/redist/x86/Microsoft.VC80.CRT/msvcr80.dll=>testcase/Microsoft.VC80.CRT/msvcr80.dll \
|
---|
97 | $(PATH_TOOL_VCC80X86)/redist/x86/Microsoft.VC80.CRT/msvcp80.dll=>testcase/Microsoft.VC80.CRT/msvcp80.dll
|
---|
98 | bin_SOURCES.amd64 += \
|
---|
99 | $(PATH_TOOL_VCC80AMD64)/redist/amd64/Microsoft.VC80.CRT/Microsoft.VC80.CRT.manifest=>Microsoft.VC80.CRT/Microsoft.VC80.CRT.manifest \
|
---|
100 | $(PATH_TOOL_VCC80AMD64)/redist/amd64/Microsoft.VC80.CRT/msvcr80.dll=>Microsoft.VC80.CRT/msvcr80.dll \
|
---|
101 | $(PATH_TOOL_VCC80AMD64)/redist/amd64/Microsoft.VC80.CRT/msvcp80.dll=>Microsoft.VC80.CRT/msvcp80.dll \
|
---|
102 | $(PATH_TOOL_VCC80AMD64)/redist/amd64/Microsoft.VC80.CRT/Microsoft.VC80.CRT.manifest=>testcase/Microsoft.VC80.CRT/Microsoft.VC80.CRT.manifest \
|
---|
103 | $(PATH_TOOL_VCC80AMD64)/redist/amd64/Microsoft.VC80.CRT/msvcr80.dll=>testcase/Microsoft.VC80.CRT/msvcr80.dll \
|
---|
104 | $(PATH_TOOL_VCC80AMD64)/redist/amd64/Microsoft.VC80.CRT/msvcp80.dll=>testcase/Microsoft.VC80.CRT/msvcp80.dll
|
---|
105 | endif
|
---|
106 | ifndef VBOX_USE_VCC80
|
---|
107 | VBOX_INSTALL_VCC70_RT = 1
|
---|
108 | endif
|
---|
109 | ifeq ($(BUILD_TARGET).$(BUILD_TARGET_ARCH),win.x86)
|
---|
110 | VBOX_INSTALL_VCC70_RT = 1
|
---|
111 | endif
|
---|
112 | ifdef VBOX_INSTALL_VCC70_RT
|
---|
113 | include $(PATH_KBUILD)/tools/VCC70.kmk
|
---|
114 | ## @todo Move these defines to VCC70.
|
---|
115 | DLL_TOOL_VCC70_MSVCR71 ?= $(PATH_TOOL_VCC70)/bin/msvcr71.dll
|
---|
116 | ifneq ($(wildcard $(DLL_TOOL_VCC70_MSVCR71)),)
|
---|
117 | bin_SOURCES += \
|
---|
118 | $(DLL_TOOL_VCC70_MSVCR71)=>msvcr71.dll \
|
---|
119 | $(DLL_TOOL_VCC70_MSVCR71)=>testcase/msvcr71.dll
|
---|
120 | endif
|
---|
121 | DLL_TOOL_VCC70_MSVCP71 ?= $(PATH_TOOL_VCC70)/bin/msvcp71.dll
|
---|
122 | ifneq ($(wildcard $(DLL_TOOL_VCC70_MSVCP71)),)
|
---|
123 | bin_SOURCES += \
|
---|
124 | $(DLL_TOOL_VCC70_MSVCP71)=>msvcp71.dll \
|
---|
125 | $(DLL_TOOL_VCC70_MSVCP71)=>testcase/msvcp71.dll
|
---|
126 | endif
|
---|
127 | DLL_TOOL_VCC70_MSVCRT ?= $(PATH_TOOL_VCC70)/bin/msvcrt.dll
|
---|
128 | ifneq ($(wildcard $(DLL_TOOL_VCC70_MSVCRT)),)
|
---|
129 | bin_SOURCES += \
|
---|
130 | $(DLL_TOOL_VCC70_MSVCRT)=>msvcrt.dll \
|
---|
131 | $(DLL_TOOL_VCC70_MSVCRT)=>testcase/msvcrt.dll
|
---|
132 | endif
|
---|
133 | endif
|
---|
134 | endif
|
---|
135 |
|
---|
136 |
|
---|
137 | #
|
---|
138 | # Install additions iso from the build server.
|
---|
139 | # The $(CP)/$(RM) stuff can be replaced by a simple $(TOUCH) once that has
|
---|
140 | # been added to kBuild.
|
---|
141 | #
|
---|
142 | ## @todo need kmk_builtin_touch!
|
---|
143 | ifdef VBOX_WITH_ADDITIONS_FROM_BUILD_SERVER
|
---|
144 | INSTALLS += buildserver-additions
|
---|
145 | buildserver-additions_INST = $(INST_ADDITIONS)
|
---|
146 | buildserver-additions_MODE = 0644
|
---|
147 | buildserver-additions_SOURCES = $(PATH_TARGET)/VBoxGuestAdditions.iso
|
---|
148 | buildserver-additions_CLEANS = $(PATH_TARGET)/VBoxGuestAdditions.iso $(PATH_TARGET)/VBoxGuestAdditions.iso.tmp
|
---|
149 |
|
---|
150 | $(PATH_TARGET)/VBoxGuestAdditions.iso: $(VBOX_SVN_REV_KMK) $(PATH_DEVTOOLS)/bin/additions.sh | $(call DIRDEP, $(PATH_TARGET))
|
---|
151 | $(RM) -f $(PATH_TARGET)/VBoxGuestAdditions.iso $(PATH_TARGET)/VBoxGuestAdditions.iso.tmp
|
---|
152 | # $(PATH_DEVTOOLS)/bin/additions.sh --cmd fetch --filename $(PATH_TARGET)/VBoxGuestAdditions.iso.tmp
|
---|
153 | $(KMK) --affinity 1 -f $(MAKEFILE) buildserver-additions-affinity-hack
|
---|
154 | $(CP) -f $(PATH_TARGET)/VBoxGuestAdditions.iso.tmp $(PATH_TARGET)/VBoxGuestAdditions.iso
|
---|
155 | $(RM) -f $(PATH_TARGET)/VBoxGuestAdditions.iso.tmp
|
---|
156 | $(QUIET)$(APPEND) $@ done
|
---|
157 |
|
---|
158 | buildserver-additions-affinity-hack:
|
---|
159 | $(SHELL) $(PATH_DEVTOOLS)/bin/additions.sh --cmd fetch --filename $(PATH_TARGET)/VBoxGuestAdditions.iso.tmp
|
---|
160 | endif
|
---|
161 |
|
---|
162 |
|
---|
163 | #
|
---|
164 | # Install staged binaries on platforms where we can't cross
|
---|
165 | # compile things.
|
---|
166 | #
|
---|
167 | ifneq ($(filter-out linux win l4, $(BUILD_TARGET)),)
|
---|
168 | VBOX_PATH_STAGED ?= .
|
---|
169 |
|
---|
170 | # Additions.
|
---|
171 | ifndef VBOX_WITH_LINUX_ADDITIONS
|
---|
172 | ifndef VBOX_WITH_WIN32_ADDITIONS
|
---|
173 | ifneq ($(wildcard $(VBOX_PATH_STAGED)/VBoxGuestAdditions.iso),)
|
---|
174 | INSTALLS += staged-additions
|
---|
175 | staged-additions_INST = $(INST_ADDITIONS)
|
---|
176 | staged-additions_MODE = 0644
|
---|
177 | staged-additions_SOURCES = $(VBOX_PATH_STAGED)/VBoxGuestAdditions.iso
|
---|
178 | endif
|
---|
179 | endif
|
---|
180 | endif
|
---|
181 |
|
---|
182 | # guesttool.exe
|
---|
183 | ifndef VBOX_WITH_WIN32_ADDITIONS
|
---|
184 | ifneq ($(wildcard $(VBOX_PATH_STAGED)/guesttool.exe),)
|
---|
185 | INSTALLS += staged-guesttool
|
---|
186 | staged-guesttool_INST = $(INST_BIN)
|
---|
187 | staged-guesttool_SOURCES = $(VBOX_PATH_STAGED)/guesttool.exe
|
---|
188 | endif
|
---|
189 | endif
|
---|
190 |
|
---|
191 | endif
|
---|
192 |
|
---|
193 | endif # !VBOX_ONLY_ADDITIONS
|
---|
194 |
|
---|
195 |
|
---|
196 | include $(PATH_KBUILD)/footer.kmk
|
---|
197 |
|
---|
198 |
|
---|
199 | #
|
---|
200 | # Generate documentation.
|
---|
201 | # (This should be converted into a separate pass or merged with an existing one later.)
|
---|
202 | #
|
---|
203 | docs: docs.Core
|
---|
204 | $(KMK) -C src/VBox/Main docs
|
---|
205 | $(KMK) -C src/VBox/Runtime docs
|
---|
206 |
|
---|
207 | docs.Core: $(PATH_TARGET)/docs.Core
|
---|
208 |
|
---|
209 |
|
---|
210 |
|
---|
211 | #
|
---|
212 | # The core (VMM+REM+Devices+Main) documentation.
|
---|
213 | #
|
---|
214 | # This includes so much because we wish to have the complete CFGM
|
---|
215 | # and GCFGM lists.
|
---|
216 | #
|
---|
217 | OTHER_CLEAN += \
|
---|
218 | $(PATH_TARGET)/Doxyfile \
|
---|
219 | $(PATH_TARGET)/Doxyfile.dep
|
---|
220 |
|
---|
221 | DOXYGEN_INPUT_DIRS = \
|
---|
222 | include/iprt \
|
---|
223 | include/VBox \
|
---|
224 | include/VBox/com \
|
---|
225 | include/VBox/HostServices \
|
---|
226 | src/VBox/VMM \
|
---|
227 | src/VBox/VMM/VMMR0 \
|
---|
228 | src/VBox/VMM/VMMGC \
|
---|
229 | src/VBox/VMM/VMMAll \
|
---|
230 | src/VBox/VMM/PATM \
|
---|
231 | src/VBox/VMM/PATM/VMMR0 \
|
---|
232 | src/VBox/VMM/PATM/VMMGC \
|
---|
233 | src/VBox/VMM/PATM/VMMAll \
|
---|
234 | src/VBox/VMM/VMMSwitcher \
|
---|
235 | src/VBox/Debugger \
|
---|
236 | src/VBox/Devices/ \
|
---|
237 | src/VBox/Devices/Audio \
|
---|
238 | src/VBox/Devices/Bus \
|
---|
239 | src/VBox/Devices/Graphics \
|
---|
240 | src/VBox/Devices/Graphics/BIOS \
|
---|
241 | src/VBox/Devices/Input \
|
---|
242 | src/VBox/Devices/Networking \
|
---|
243 | src/VBox/Devices/PC \
|
---|
244 | src/VBox/Devices/PC/BIOS \
|
---|
245 | src/VBox/Devices/Parallel \
|
---|
246 | src/VBox/Devices/Serial \
|
---|
247 | src/VBox/Devices/Storage \
|
---|
248 | src/VBox/Devices/VBoxHDDFormats \
|
---|
249 | src/VBox/Devices/VBoxHDDFormats/StorageCraft \
|
---|
250 | src/VBox/Devices/USB \
|
---|
251 | src/VBox/Devices/USB/darwin \
|
---|
252 | src/VBox/Devices/USB/linux \
|
---|
253 | src/VBox/Devices/USB/os2 \
|
---|
254 | src/VBox/Devices/USB/solaris \
|
---|
255 | src/VBox/Devices/USB/vrdp \
|
---|
256 | src/VBox/Devices/USB/win32 \
|
---|
257 | src/VBox/Devices/VMMDev \
|
---|
258 | src/VBox/Main/include \
|
---|
259 | src/VBox/Main/include/hgcm \
|
---|
260 | src/VBox/Main/ \
|
---|
261 | src/VBox/Main/glue \
|
---|
262 | src/VBox/Main/hgcm \
|
---|
263 | src/VBox/Main/webservice \
|
---|
264 | src/VBox/Main/xml \
|
---|
265 | src/VBox/Main/darwin \
|
---|
266 | src/VBox/Main/linux \
|
---|
267 | src/VBox/Main/os2 \
|
---|
268 | src/VBox/Main/solaris \
|
---|
269 | src/VBox/Main/win32 \
|
---|
270 | src/VBox/HostServices/ \
|
---|
271 | src/VBox/HostServices/SharedClipboard \
|
---|
272 | src/VBox/HostServices/SharedFolders \
|
---|
273 | src/VBox/HostServices/SharedOpenGL \
|
---|
274 | src/VBox/HostDrivers/Support \
|
---|
275 | src/VBox/HostDrivers/Support/darwin \
|
---|
276 | src/VBox/HostDrivers/Support/freebsd \
|
---|
277 | src/VBox/HostDrivers/Support/l4 \
|
---|
278 | src/VBox/HostDrivers/Support/linux \
|
---|
279 | src/VBox/HostDrivers/Support/os2 \
|
---|
280 | src/VBox/HostDrivers/Support/solaris \
|
---|
281 | src/VBox/HostDrivers/Support/win \
|
---|
282 | src/VBox/HostDrivers/VBoxTAP/ \
|
---|
283 | src/VBox/HostDrivers/VBoxTAP/win \
|
---|
284 | src/VBox/HostDrivers/VBoxTAP/darwin \
|
---|
285 | src/VBox/HostDrivers/VBoxUSB/ \
|
---|
286 | src/VBox/HostDrivers/VBoxUSB/darwin \
|
---|
287 | src/VBox/HostDrivers/VBoxUSB/os2 \
|
---|
288 | src/VBox/HostDrivers/VBoxUSB/win \
|
---|
289 | src/VBox/HostDrivers/VBoxUSB/win/Device \
|
---|
290 | src/VBox/HostDrivers/VBoxUSB/win/Device/amd64 \
|
---|
291 | src/VBox/HostDrivers/VBoxUSB/win/Device/x86 \
|
---|
292 | src/VBox/HostDrivers/VBoxUSB/win/Filter \
|
---|
293 | src/VBox/HostDrivers/VBoxUSB/win/Install \
|
---|
294 | src/VBox/HostDrivers/VBoxUSB/win/Monitor \
|
---|
295 | src/VBox/HostDrivers/VBoxUSB/win/Monitor/win32 \
|
---|
296 | src/VBox/HostDrivers/VBoxUSB/win/Monitor/win64 \
|
---|
297 | src/VBox/HostDrivers/VBoxUSB/win/usbd \
|
---|
298 |
|
---|
299 | # These must come first in order to make things look nice.
|
---|
300 | DOXYGEN_INPUT_FIRST =\
|
---|
301 | $(PATH_ROOT)/doc/VBox-doc.c \
|
---|
302 | $(PATH_ROOT)/doc/VBox-CodingGuidelines.cpp \
|
---|
303 | $(PATH_ROOT)/src/VBox/VMM/VMMCodingGuidelines.cpp \
|
---|
304 | $(PATH_ROOT)/src/VBox/VMM/VMMDocsRawMode.cpp \
|
---|
305 | $(PATH_ROOT)/include/VBox/cdefs.h \
|
---|
306 | $(PATH_ROOT)/include/VBox/vmapi.h \
|
---|
307 | $(PATH_ROOT)/include/VBox/vmm.h \
|
---|
308 | $(PATH_ROOT)/include/VBox/cpum.h \
|
---|
309 | $(PATH_ROOT)/include/VBox/mm.h \
|
---|
310 | $(PATH_ROOT)/include/VBox/pgm.h \
|
---|
311 | $(PATH_ROOT)/include/VBox/selm.h \
|
---|
312 | $(PATH_ROOT)/include/VBox/trpm.h \
|
---|
313 | $(PATH_ROOT)/include/VBox/patm.h \
|
---|
314 | $(PATH_ROOT)/include/VBox/dbgf.h \
|
---|
315 | $(PATH_ROOT)/include/VBox/stam.h \
|
---|
316 | $(PATH_ROOT)/include/VBox/em.h \
|
---|
317 | $(PATH_ROOT)/include/VBox/pdm.h \
|
---|
318 | $(PATH_ROOT)/include/VBox/rem.h \
|
---|
319 | $(PATH_ROOT)/include/VBox/iom.h \
|
---|
320 | $(PATH_ROOT)/include/VBox/cfgm.h \
|
---|
321 | $(PATH_ROOT)/include/VBox/tm.h \
|
---|
322 | $(PATH_ROOT)/include/VBox/csam.h \
|
---|
323 | $(PATH_ROOT)/include/VBox/ssm.h \
|
---|
324 | $(PATH_ROOT)/include/VBox/hwaccm.h \
|
---|
325 | $(PATH_ROOT)/include/VBox/hwacc_svm.h \
|
---|
326 | $(PATH_ROOT)/include/VBox/hwacc_vmx.h \
|
---|
327 | $(PATH_ROOT)/\
|
---|
328 | $(PATH_ROOT)/src/VBox/VMM/CFGMInternal.h \
|
---|
329 | $(PATH_ROOT)/src/VBox/VMM/CPUMInternal.h \
|
---|
330 | $(PATH_ROOT)/src/VBox/VMM/DBGFInternal.h \
|
---|
331 | $(PATH_ROOT)/src/VBox/VMM/EMInternal.h \
|
---|
332 | $(PATH_ROOT)/src/VBox/VMM/HWACCMInternal.h \
|
---|
333 | $(PATH_ROOT)/src/VBox/VMM/IOMInternal.h \
|
---|
334 | $(PATH_ROOT)/src/VBox/VMM/MMInternal.h \
|
---|
335 | $(PATH_ROOT)/src/VBox/VMM/PDMInternal.h \
|
---|
336 | $(PATH_ROOT)/src/VBox/VMM/PGMInternal.h \
|
---|
337 | $(PATH_ROOT)/src/VBox/VMM/PATM/CSAMInternal.h \
|
---|
338 | $(PATH_ROOT)/src/VBox/VMM/PATM/PATMInternal.h \
|
---|
339 | $(PATH_ROOT)/src/VBox/VMM/REMInternal.h \
|
---|
340 | $(PATH_ROOT)/src/VBox/VMM/SELMInternal.h \
|
---|
341 | $(PATH_ROOT)/src/VBox/VMM/SSMInternal.h \
|
---|
342 | $(PATH_ROOT)/src/VBox/VMM/STAMInternal.h \
|
---|
343 | $(PATH_ROOT)/src/VBox/VMM/TMInternal.h \
|
---|
344 | $(PATH_ROOT)/src/VBox/VMM/TRPMInternal.h \
|
---|
345 | $(PATH_ROOT)/src/VBox/VMM/VMInternal.h \
|
---|
346 | $(PATH_ROOT)/src/VBox/VMM/VMMInternal.h \
|
---|
347 | $(PATH_ROOT)/\
|
---|
348 | $(PATH_ROOT)/include/VBox/vm.h \
|
---|
349 | \
|
---|
350 | $(PATH_ROOT)/include/VBox/sup.h \
|
---|
351 | $(PATH_ROOT)/include/VBox/VBoxHDD.h \
|
---|
352 | $(PATH_ROOT)/include/VBox/types.h \
|
---|
353 | $(PATH_ROOT)/include/VBox/err.h \
|
---|
354 | $(PATH_ROOT)/include/VBox/x86.h \
|
---|
355 | $(PATH_ROOT)/include/VBox/cpumdis.h \
|
---|
356 | $(PATH_ROOT)/include/VBox/dbggui.h \
|
---|
357 | $(PATH_ROOT)/include/VBox/dis.h \
|
---|
358 | $(PATH_ROOT)/include/VBox/disopcode.h \
|
---|
359 | $(PATH_ROOT)/include/VBox/intnet.h \
|
---|
360 | $(PATH_ROOT)/include/VBox/settings.h \
|
---|
361 | $(PATH_ROOT)/include/VBox/pci.h \
|
---|
362 | $(PATH_ROOT)/include/VBox/scsi.h \
|
---|
363 | $(PATH_ROOT)/include/VBox/shflsvc.h \
|
---|
364 | $(PATH_ROOT)/include/VBox/hgcmsvc.h \
|
---|
365 | $(PATH_ROOT)/include/VBox/usb.h \
|
---|
366 | $(PATH_ROOT)/include/VBox/vusb.h \
|
---|
367 | $(PATH_ROOT)/\
|
---|
368 | $(PATH_ROOT)/include/VBox/log.h \
|
---|
369 | $(PATH_ROOT)/include/VBox/param.h \
|
---|
370 | $(PATH_ROOT)/include/VBox/version.h
|
---|
371 |
|
---|
372 | DOXYGEN_INPUT := \
|
---|
373 | $(filter-out %.cpp.h, $(sort $(wildcard $(addsuffix /*.h, $(DOXYGEN_INPUT_DIRS)))) ) \
|
---|
374 | $(foreach dir, $(DOXYGEN_INPUT_DIRS), $(wildcard $(dir)/*.cpp $(dir)/.c $(dir)/.asm))
|
---|
375 | DOXYGEN_INPUT := \
|
---|
376 | $(DOXYGEN_INPUT_FIRST) \
|
---|
377 | $(filter-out $(DOXYGEN_INPUT_FIRST), $(DOXYGEN_INPUT))
|
---|
378 |
|
---|
379 | # And some some additional stuff.
|
---|
380 | DOXYGEN_INPUT += \
|
---|
381 | $(PATH_ROOT)/src/recompiler/VBoxRecompiler.c \
|
---|
382 | $(PATH_ROOT)/src/recompiler/VBoxREMWrapper.cpp
|
---|
383 |
|
---|
384 |
|
---|
385 | DOXYGEN_OUTPUT = $(PATH_OUT)/docs/Core
|
---|
386 |
|
---|
387 | -include $(PATH_TARGET)/Doxyfile.dep
|
---|
388 |
|
---|
389 | # Generate the Doxyfile
|
---|
390 | $(PATH_TARGET)/Doxyfile: Doxyfile.Core \
|
---|
391 | $(comp-vars DOXYGEN_INPUT,DOXYGEN_INPUT_PREV,FORCE) \
|
---|
392 | $(comp-vars DOXYGEN_OUTPUT,DOXYGEN_OUTPUT_PREV,FORCE) \
|
---|
393 | | $(call DIRDEP, $(PATH_TARGET))
|
---|
394 | $(RM) -f $@ $@.tmp $(PATH_TARGET)/Doxyfile.dep
|
---|
395 | $(CP) -f Doxyfile.Core $@.tmp
|
---|
396 | $(APPEND) $@.tmp
|
---|
397 | $(APPEND) $@.tmp "OUTPUT_DIRECTORY = $(DOXYGEN_OUTPUT)"
|
---|
398 | $(APPEND) $@.tmp "WARN_LOGFILE = $(DOXYGEN_OUTPUT)/errors"
|
---|
399 | $(APPEND) $@.tmp "INCLUDE_PATH = $(PATH_ROOT)/include $(PATH_ROOT)/src/VBox/VMM $(PATH_ROOT)/src/VBox/Main/include "
|
---|
400 | $(APPEND) $@.tmp "INCLUDE_FILE_PATTERNS = *.cpp.h"
|
---|
401 | $(APPEND) $@.tmp
|
---|
402 | $(APPEND) $@.tmp "INPUT = $(DOXYGEN_INPUT)"
|
---|
403 | $(APPEND) $@.tmp
|
---|
404 | $(APPEND) $@.tmp "PREDEFINED += $(DEFS) $(DEFS.$(BUILD_TARGET)) $(DEFS.$(BUILD_TARGET_ARCH)) $(ARCH_BITS_DEFS)"
|
---|
405 | $(APPEND) $@.tmp "PREDEFINED += ARCH_BITS=HC_ARCH_BITS R3_ARCH_BITS=HC_ARCH_BITS R0_ARCH_BITS=HC_ARCH_BITS "
|
---|
406 | $(APPEND) $@.tmp
|
---|
407 | $(MV) -f $@.tmp $@
|
---|
408 | @$(APPEND) $(PATH_TARGET)/Doxyfile.dep "DOXYGEN_OUTPUT_PREV = $(DOXYGEN_OUTPUT)"
|
---|
409 | @$(APPEND) $(PATH_TARGET)/Doxyfile.dep "DOXYGEN_INPUT_PREV = $(DOXYGEN_INPUT)"
|
---|
410 |
|
---|
411 | # Create the output directory.
|
---|
412 | $(call DIRDEP, $(DOXYGEN_OUTPUT)):
|
---|
413 | $(MKDIR) -p $@
|
---|
414 |
|
---|
415 | # Do the actual job.
|
---|
416 | $(PATH_TARGET)/docs.Core: $(PATH_TARGET)/Doxyfile $(DOXYGEN_INPUT) | $(call DIRDEP, $(DOXYGEN_OUTPUT))
|
---|
417 | $(RM) -f $(wildcard $(DOXYGEN_OUTPUT)/html/*) $(PATH_TARGET)/docs.Core
|
---|
418 | doxygen $(PATH_TARGET)/Doxyfile
|
---|
419 | $(APPEND) $(PATH_TARGET)/docs.Core
|
---|
420 |
|
---|
421 |
|
---|
422 | #
|
---|
423 | # Generate x86.mac and err.mac.
|
---|
424 | #
|
---|
425 | incs:
|
---|
426 | $(SED) -f include/VBox/err.sed include/VBox/err.h > include/VBox/err.mac
|
---|
427 | echo '%include "iprt/err.mac"' >> include/VBox/err.mac
|
---|
428 | $(SED) -f include/VBox/err.sed include/iprt/err.h > include/iprt/err.mac
|
---|
429 | $(SED) -e '/__VBox_x86_h__/d' -e '/#define/!d' -e 's/#define/%define/' include/VBox/x86.h > include/VBox/x86.mac
|
---|
430 |
|
---|
431 |
|
---|
432 | #
|
---|
433 | # Generate Visual SlickEdit tagging #defines.
|
---|
434 | #
|
---|
435 | vslick.h: include/VBox/cdefs.h Makefile
|
---|
436 | echo '// autogenerated' > $@.tmp
|
---|
437 | #echo '#define __BEGIN_DECLS ' >> $@.tmp
|
---|
438 | #echo '#define __END_DECLS ' >> $@.tmp
|
---|
439 |
|
---|
440 | echo '#define ATL_NO_VTABLE ' >> $@.tmp
|
---|
441 | echo '#define BEGIN_COM_MAP(a) ' >> $@.tmp
|
---|
442 | echo '#define END_COM_MAP(a) ' >> $@.tmp
|
---|
443 |
|
---|
444 | echo '#define CHECKREADY if(!isReady()) return E_UNEXPECTED; ' >> $@.tmp
|
---|
445 | echo '#define COM_DECL_READONLY_ENUM_AND_COLLECTION(a) ' >> $@.tmp
|
---|
446 | echo '#define COM_INTERFACE_ENTRY(a) ' >> $@.tmp
|
---|
447 | echo '#define COMGETTER(n) Get##n ' >> $@.tmp
|
---|
448 | echo '#define COMSETTER(n) Set##n ' >> $@.tmp
|
---|
449 | echo '#define DECLARE_NOT_AGGREGATABLE(a) ' >> $@.tmp
|
---|
450 | echo '#define DECLARE_PROTECT_FINAL_CONSTRUCT(a) ' >> $@.tmp
|
---|
451 | echo '#define NS_DECL_ISUPPORTS ' >> $@.tmp
|
---|
452 | echo '#define NS_IMETHOD NS_IMETHOD_(nsresult) ' >> $@.tmp
|
---|
453 | echo '#define NS_IMETHOD_(type) type ' >> $@.tmp
|
---|
454 | echo '#define PARSERS_EXPORT ' >> $@.tmp
|
---|
455 | echo '#define SAX_EXPORT ' >> $@.tmp
|
---|
456 | echo '#define STDMETHOD(a) NS_IMETHOD a ' >> $@.tmp
|
---|
457 | echo '#define XERCES_CPP_NAMESPACE_BEGIN ' >> $@.tmp
|
---|
458 | echo '#define XERCES_CPP_NAMESPACE_END ' >> $@.tmp
|
---|
459 |
|
---|
460 | echo '#define CTXAllSUFF(var) var##R3 ' >> $@.tmp
|
---|
461 | echo '#define CTXSUFF(var) var##HC ' >> $@.tmp
|
---|
462 | echo '#define OTHERCTXSUFF(var) var##GC ' >> $@.tmp
|
---|
463 | echo '#define CTXALLMID(first, last) first##R3##last ' >> $@.tmp
|
---|
464 | echo '#define CTXMID(first, last) first##HC##last ' >> $@.tmp
|
---|
465 | echo '#define OTHERCTXMID(first, last) first##GC##last ' >> $@.tmp
|
---|
466 | echo '#define CTXTYPE(GCType, R3Type, R0Type) R3Type ' >> $@.tmp
|
---|
467 | echo '#define GCPTRTYPE(GCType) GCType ' >> $@.tmp
|
---|
468 | echo '#define GCTYPE(GCType, HCType) GCType ' >> $@.tmp
|
---|
469 | echo '#define HCPTRTYPE(HCType) HCType ' >> $@.tmp
|
---|
470 | echo '#define R0PTRTYPE(R3Type) R3Type ' >> $@.tmp
|
---|
471 | echo '#define R3PTRTYPE(R0Type) R0Type ' >> $@.tmp
|
---|
472 | echo '#define RT_SRC_POS __FILE__, __LINE__, __PRETTY_FUNCTION__ ' >> $@.tmp
|
---|
473 | echo '#define RT_SRC_POS_DECL const char *pszFile, unsigned iLine, const char *pszFunction ' >> $@.tmp
|
---|
474 | echo '#define RT_SRC_POS_ARGS pszFile, iLine, pszFunction ' >> $@.tmp
|
---|
475 | echo '#define RTCALL' >> $@.tmp
|
---|
476 | echo '#define DECLINLINE(type) inline type ' >> $@.tmp
|
---|
477 |
|
---|
478 | echo '#define PDM_SRC_POS __FILE__, __LINE__, __PRETTY_FUNCTION__ ' >> $@.tmp
|
---|
479 | echo '#define PDM_SRC_POS_DECL const char *pszFile, unsigned iLine, const char *pszFunction ' >> $@.tmp
|
---|
480 | echo '#define PDM_SRC_POS_ARGS pszFile, iLine, pszFunction ' >> $@.tmp
|
---|
481 | echo '#define PDMDEVINSINT_DECLARED 1' >> $@.tmp
|
---|
482 | echo '#define VBOXCALL' >> $@.tmp
|
---|
483 |
|
---|
484 | $(SED) -e '/__cdecl/d' \
|
---|
485 | -e '/^ *# *define.*DECL/!d' \
|
---|
486 | -e '/DECLS/d' \
|
---|
487 | -e '/_SRC_POS_DECL/d' \
|
---|
488 | -e '/declspec/d' \
|
---|
489 | -e 's/# */#/g' \
|
---|
490 | -e 's/ */ /g' \
|
---|
491 | -e '/(type) DECLEXPORT/d' \
|
---|
492 | -e 's/ *VBOXCALL//' \
|
---|
493 | -e 's/ *RTCALL//' \
|
---|
494 | -e 's/(type) DECLIMPORT(type)/(type) type/' \
|
---|
495 | -e '/ DECLASM(type) type/d' \
|
---|
496 | -e '/define *DECL..CALLBACKMEMBER(type[^)]*) *RT/d' \
|
---|
497 | -e '/define *DECLINLINE(type)/d' \
|
---|
498 | \
|
---|
499 | include/iprt/cdefs.h \
|
---|
500 | include/VBox/cdefs.h \
|
---|
501 | >> $@.tmp
|
---|
502 | sort $@.tmp | sort | sed -e 's/$$/\n/' > $@.tmp2
|
---|
503 | $(MV) -f $@.tmp2 $@
|
---|
504 | $(RM) -f $@.tmp $@.tmp2 $@.tmp3
|
---|
505 |
|
---|
506 |
|
---|
507 | ## add tools fetching to the 'up' / 'update' target.
|
---|
508 | up update::
|
---|
509 | # this doesn't work of course if kmk is updated: svn$(HOSTSUFF_EXE) up $(PATH_KBUILD)
|
---|
510 | ifndef VBOX_OSE
|
---|
511 | $(MAKE) -C tools fetch
|
---|
512 | else
|
---|
513 | $(MAKE) -C tools -f Makefile-ose.kmk fetch
|
---|
514 | endif
|
---|
515 |
|
---|
516 | up2 update2::
|
---|
517 | $(SVN) up src/lib/kStuff
|
---|
518 | if1of ($(BUILD_PLATFORM),win os2)
|
---|
519 | $(ECHO) This may fail if kmk.exe is updated.
|
---|
520 | endif
|
---|
521 | $(SVN) up kBuild
|
---|
522 |
|
---|
523 | #
|
---|
524 | # Build the additions, all of them.
|
---|
525 | #
|
---|
526 | # This is currently tailored (hardcoded) for the additions
|
---|
527 | # build box. Can make it pretty and configurable later.
|
---|
528 | #
|
---|
529 | # The fetching must be done in serial fashion, while the building
|
---|
530 | # should be more flexible wrt to -jN.
|
---|
531 | #
|
---|
532 | additions-fetch:
|
---|
533 | + $(KMK) -C tools fetch
|
---|
534 | + $(KMK) -C tools fetch BUILD_TARGET_ARCH=x86 BUILD_TARGET=linux
|
---|
535 | # + $(KMK) -C tools fetch BUILD_TARGET_ARCH=x86 BUILD_TARGET=os2
|
---|
536 | + $(KMK) -C tools fetch BUILD_TARGET_ARCH=x86 BUILD_TARGET=solaris
|
---|
537 | + $(KMK) -C tools fetch BUILD_TARGET_ARCH=x86 BUILD_TARGET=win
|
---|
538 |
|
---|
539 |
|
---|
540 | additions-build: \
|
---|
541 | additions-build-win.x86 \
|
---|
542 | additions-build-solaris.x86 \
|
---|
543 | additions-build-os2.x86 \
|
---|
544 | additions-build-linux.x86
|
---|
545 |
|
---|
546 | VBOX_ADDITIONS_BUILD = VBOX_ONLY_ADDITIONS=1 VBOX_WITHOUT_ADDITIONS_ISO=1 BUILD_TYPE=$(BUILD_TYPE) all packing
|
---|
547 |
|
---|
548 | additions-build-win.x86:
|
---|
549 | ifeq ($(BUILD_TARGET),win)
|
---|
550 | + $(KMK) BUILD_TARGET_ARCH=x86 VBOX_ADDITIONS_WIN32_ONLY=1 $(VBOX_ADDITIONS_BUILD)
|
---|
551 | else
|
---|
552 | ssh vbox@192.168.27.5 " cd c:/vbox/add && ./tools/env.sh --no-wine kmk BUILD_TARGET_ARCH=x86 VBOX_ADDITIONS_WIN32_ONLY=1 $(VBOX_ADDITIONS_BUILD) "
|
---|
553 | endif
|
---|
554 |
|
---|
555 | additions-build-solaris.x86:
|
---|
556 | #ifeq ($(BUILD_TARGET),solaris)
|
---|
557 | # + $(KMK) BUILD_TARGET_ARCH=x86 $(VBOX_ADDITIONS_BUILD)
|
---|
558 | #else
|
---|
559 | # ssh vbox@192.168.27.4 " cd /mnt/vbox/add && ./tools/env.sh --no-wine kmk BUILD_TARGET_ARCH=x86 $(VBOX_ADDITIONS_BUILD) "
|
---|
560 | #endif
|
---|
561 |
|
---|
562 | additions-build-os2.x86:
|
---|
563 | #ifeq ($(BUILD_TARGET),os2)
|
---|
564 | # + $(KMK) BUILD_TARGET_ARCH=x86
|
---|
565 | #else
|
---|
566 | # ssh vbox@192.168.27.3 " cd /mnt/vbox/add && ./tools/env.sh --no-wine kmk BUILD_TARGET_ARCH=x86 $(VBOX_ADDITIONS_BUILD) "
|
---|
567 | #endif
|
---|
568 |
|
---|
569 | additions-build-linux.x86:
|
---|
570 | ifeq ($(BUILD_TARGET),linux)
|
---|
571 | + $(KMK) BUILD_TARGET_ARCH=x86 VBOX_ADDITIONS_LINUX_ONLY=1 $(VBOX_ADDITIONS_BUILD)
|
---|
572 | else
|
---|
573 | ssh vbox@192.168.27.2 " cd /mnt/vbox/add && ./tools/env.sh --no-wine kmk BUILD_TARGET_ARCH=x86 VBOX_ADDITIONS_LINUX_ONLY=1 $(VBOX_ADDITIONS_BUILD) "
|
---|
574 | endif
|
---|
575 |
|
---|
576 |
|
---|
577 | additions-packing:
|
---|
578 | + $(KMK) VBOX_ONLY_ADDITIONS=1 \
|
---|
579 | VBOX_WITH_ADDITIONS_ISO.win.x86=1 \
|
---|
580 | VBOX_WITH_ADDITIONS_ISO.linux.x86=1 \
|
---|
581 | -C src/VBox/Additions \
|
---|
582 | $(VBOX_PATH_ADDITIONS)/VBoxGuestAdditions.iso
|
---|
583 |
|
---|
584 |
|
---|
585 | #
|
---|
586 | # Generate VirtualBox-OSE-x.x.x.tar.bz2 tarballs for distribution
|
---|
587 | #
|
---|
588 | # - includes kBuild
|
---|
589 | # - must be executed on an OSE checkout
|
---|
590 | #
|
---|
591 |
|
---|
592 | # the path where to store the tarball
|
---|
593 | TARBALLPATH ?= $(shell cd $(PATH_ROOT)/..; pwd)
|
---|
594 | #TARBALLPATH ?= $(abspath $(PATH_ROOT)/..) - this should also do the trick without spawning a shell.
|
---|
595 | # the root directory inside the tarball
|
---|
596 | TARBALLROOT ?= VirtualBox-$(VBOX_VERSION_STRING)
|
---|
597 | # the name of the tarball file
|
---|
598 | TARBALLNAME ?= VirtualBox-$(VBOX_VERSION_STRING).tar.bz2
|
---|
599 | snapshot:
|
---|
600 | @$(call MSG_L1,Creating tarball $(TARBALLPATH)/$(TARBALLNAME))
|
---|
601 | @if [ -d "$(PATH_ROOT)/src/VBox/Devices/USB" ]; then echo; echo "Found USB stuff, refused to build OSE tarball!"; echo; exit 1; fi
|
---|
602 | $(QUIET)$(MKDIR) -p $(TARBALLPATH)
|
---|
603 | $(QUIET)$(RM) -f $(wildcard $(TARBALLPATH)/VirtualBox*)
|
---|
604 | $(QUIET)$(LN_SYMLINK) $(PATH_ROOT) $(TARBALLPATH)/$(TARBALLROOT)
|
---|
605 | $(QUIET)tar -cjh --owner 0 --group 0 --totals \
|
---|
606 | --exclude=.svn \
|
---|
607 | --exclude=$(TARBALLROOT)/out \
|
---|
608 | --exclude=$(TARBALLROOT)/env.sh \
|
---|
609 | --exclude=$(TARBALLROOT)/configure.log \
|
---|
610 | --exclude=$(TARBALLROOT)/AutoConfig.kmk \
|
---|
611 | --exclude=$(TARBALLROOT)/LocalConfig.kmk \
|
---|
612 | -C $(TARBALLPATH) \
|
---|
613 | -f $(TARBALLPATH)/$(TARBALLNAME) \
|
---|
614 | $(TARBALLROOT)
|
---|
615 | $(QUIET)$(RM) $(TARBALLPATH)/$(TARBALLROOT)
|
---|