1 | # $Id: Makefile.kmk 34063 2010-11-15 10:59:13Z vboxsync $
|
---|
2 | ## @file
|
---|
3 | # Makefile for the VirtualBox Qt GUI.
|
---|
4 | #
|
---|
5 |
|
---|
6 | #
|
---|
7 | # Copyright (C) 2006-2010 Oracle Corporation
|
---|
8 | #
|
---|
9 | # This file is part of VirtualBox Open Source Edition (OSE), as
|
---|
10 | # available from http://www.virtualbox.org. This file is free software;
|
---|
11 | # you can redistribute it and/or modify it under the terms of the GNU
|
---|
12 | # General Public License (GPL) as published by the Free Software
|
---|
13 | # Foundation, in version 2 as it comes in the "COPYING" file of the
|
---|
14 | # VirtualBox OSE distribution. VirtualBox OSE is distributed in the
|
---|
15 | # hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
|
---|
16 | #
|
---|
17 |
|
---|
18 | SUB_DEPTH = ../../../..
|
---|
19 | include $(KBUILD_PATH)/subheader.kmk
|
---|
20 |
|
---|
21 | #
|
---|
22 | # Globals.
|
---|
23 | #
|
---|
24 | VBOX_VIRTUALBOX4_SRC := $(PATH_SUB_CURRENT)
|
---|
25 | VBOX_VIRTUALBOX4_OUT_DIR := $(PATH_TARGET)/VirtualBox/misc
|
---|
26 |
|
---|
27 | # VBOX_WITH_REGISTRATION := 1
|
---|
28 |
|
---|
29 | # Ask the user to register at Sun. If this setting is disabled the user can
|
---|
30 | # still register using the menu if desired.
|
---|
31 | # VBOX_WITH_REGISTRATION_REQUEST := 1
|
---|
32 |
|
---|
33 | # For now this should be disabled in any case
|
---|
34 | ifdef VBOX_WITH_REGISTRATION
|
---|
35 | VBOX_WITH_REGISTRATION=
|
---|
36 | endif
|
---|
37 | ifdef VBOX_WITH_REGISTRATION_REQUEST
|
---|
38 | VBOX_WITH_REGISTRATION_REQUEST=
|
---|
39 | endif
|
---|
40 |
|
---|
41 | # Show the update notifier dialog during startup. If this setting is disabled
|
---|
42 | # the user can still update using the menu if desired.
|
---|
43 | ifndef VBOX_OSE
|
---|
44 | VBOX_WITH_UPDATE_REQUEST := 1
|
---|
45 | endif
|
---|
46 |
|
---|
47 | #
|
---|
48 | # The targets.
|
---|
49 | #
|
---|
50 | ifdef VBOX_WITH_HARDENING
|
---|
51 | PROGRAMS += VirtualBoxHardened
|
---|
52 | DLLS += VirtualBox
|
---|
53 | else
|
---|
54 | PROGRAMS += VirtualBox
|
---|
55 | endif
|
---|
56 |
|
---|
57 | INSTALLS += VirtualBox.nls
|
---|
58 |
|
---|
59 |
|
---|
60 | #
|
---|
61 | # Include the language lists.
|
---|
62 | #
|
---|
63 | include $(PATH_SUB_CURRENT)/nls/ApprovedLanguages.kmk
|
---|
64 |
|
---|
65 |
|
---|
66 | #
|
---|
67 | # Hardened VirtualBox.
|
---|
68 | #
|
---|
69 | VirtualBoxHardened_TEMPLATE = VBOXR3HARDENEDEXE
|
---|
70 | VirtualBoxHardened_SOURCES = src/hardenedmain.cpp
|
---|
71 | VirtualBoxHardened_NAME = VirtualBox
|
---|
72 | VirtualBoxHardened_INST.darwin = $(INST_BIN)VirtualBox $(INST_BIN)VirtualBoxVM
|
---|
73 |
|
---|
74 |
|
---|
75 | #
|
---|
76 | # Include Qt project file, we'll use FORMS and TRANSLATIONS in
|
---|
77 | # the VirtualBox setup below.
|
---|
78 | #
|
---|
79 | SAVED_TEMPLATE := $(TEMPLATE)
|
---|
80 | include $(PATH_SUB_CURRENT)/VBoxUI.pro
|
---|
81 |
|
---|
82 |
|
---|
83 | #
|
---|
84 | # VirtualBox - The GUI program.
|
---|
85 | #
|
---|
86 | USES += qt4
|
---|
87 | VirtualBox_TEMPLATE := $(if $(VBOX_WITH_HARDENING),VBOXQT4GUI,VBOXQT4GUIEXE)
|
---|
88 | VirtualBox_NAME = VirtualBox
|
---|
89 | ifndef VBOX_WITH_HARDENING # For the launch trick we need different inode numbers.
|
---|
90 | VirtualBox_INST.darwin = $(INST_BIN)VirtualBox $(INST_BIN)VirtualBoxVM
|
---|
91 | endif
|
---|
92 | VirtualBox_SDKS.win = WINPSDK DXSDK
|
---|
93 | if1of ($(KBUILD_TARGET), freebsd linux netbsd openbsd os2) # X11 + os2 ## @todo solaris
|
---|
94 | VirtualBox_SDKS += LIBSDL
|
---|
95 | endif
|
---|
96 |
|
---|
97 | ifdef VBOX_WITH_ICHAT_THEATER
|
---|
98 | # For testing iChat Theater stuff change the sdk path (HACK ALERT!)
|
---|
99 | VBOX_PATH_MACOSX_SDK = /Developer/SDKs/MacOSX10.5.sdk
|
---|
100 | endif
|
---|
101 |
|
---|
102 | VirtualBox_DEFS =
|
---|
103 | VirtualBox_DEFS.debug = VBOX_CHECK_STATE # QT_FATAL_ASSERT
|
---|
104 | VirtualBox_DEFS.darwin = VBOX_GUI_USE_QUARTZ2D VBOX_GUI_USE_QIMAGE
|
---|
105 | ifndef VBOX_WITH_COCOA_QT
|
---|
106 | VirtualBox_DEFS.darwin.x86= USE_HID_FOR_MODIFIERS
|
---|
107 | endif
|
---|
108 | VirtualBox_DEFS.freebsd = VBOX_GUI_USE_QIMAGE VBOX_GUI_USE_SDL
|
---|
109 | VirtualBox_DEFS.linux = VBOX_GUI_USE_QIMAGE VBOX_GUI_USE_SDL
|
---|
110 | VirtualBox_DEFS.netbsd = VBOX_GUI_USE_QIMAGE VBOX_GUI_USE_SDL
|
---|
111 | VirtualBox_DEFS.openbsd = VBOX_GUI_USE_QIMAGE VBOX_GUI_USE_SDL
|
---|
112 | VirtualBox_DEFS.solaris = VBOX_GUI_USE_QIMAGE #VBOX_GUI_USE_SDL
|
---|
113 | VirtualBox_DEFS.win = VBOX_GUI_USE_QIMAGE UNICODE QT_DLL
|
---|
114 | ifdef VBOX_WITH_ICHAT_THEATER
|
---|
115 | VirtualBox_DEFS.darwin += VBOX_WITH_ICHAT_THEATER
|
---|
116 | endif
|
---|
117 | ifneq ($(KBUILD_TYPE),release)
|
---|
118 | # non-release builds has some extra features.
|
---|
119 | VirtualBox_DEFS.win += VBOX_GUI_USE_DDRAW
|
---|
120 | endif
|
---|
121 | VirtualBox_DEFS += \
|
---|
122 | $(if $(VBOX_WITH_REGISTRATION),VBOX_WITH_REGISTRATION) \
|
---|
123 | $(if $(VBOX_WITH_REGISTRATION_REQUEST),VBOX_WITH_REGISTRATION_REQUEST) \
|
---|
124 | $(if $(VBOX_WITH_UPDATE_REQUEST),VBOX_WITH_UPDATE_REQUEST) \
|
---|
125 | $(if $(VBOX_WITH_ALSA),VBOX_WITH_ALSA) \
|
---|
126 | $(if $(VBOX_WITH_PULSE),VBOX_WITH_PULSE) \
|
---|
127 | $(if $(VBOX_WITH_SOLARIS_OSS),VBOX_WITH_SOLARIS_OSS) \
|
---|
128 | $(if $(VBOX_WITH_E1000),VBOX_WITH_E1000) \
|
---|
129 | $(if $(VBOX_WITH_NETFLT)$(eq $(KBUILD_TARGET),freebsd),VBOX_WITH_NETFLT) \
|
---|
130 | $(if $(VBOX_WITH_VDE),VBOX_WITH_VDE) \
|
---|
131 | $(if $(VBOX_WITH_EHCI),VBOX_WITH_EHCI)
|
---|
132 | ifdef VBOX_WITH_DEBUGGER_GUI
|
---|
133 | VirtualBox_DEFS += VBOX_WITH_DEBUGGER_GUI
|
---|
134 | if "$(KBUILD_TYPE)" != "release"
|
---|
135 | VirtualBox_DEFS += VBOX_WITH_DEBUGGER_GUI_MENU
|
---|
136 | endif
|
---|
137 | endif
|
---|
138 | ifdef VBOX_WITH_VIDEOHWACCEL
|
---|
139 | VirtualBox_DEFS += VBOX_WITH_VIDEOHWACCEL \
|
---|
140 | VBOX_GUI_USE_QGL
|
---|
141 | else ifdef VBOX_GUI_USE_QGL
|
---|
142 | VirtualBox_DEFS += VBOX_GUI_USE_QGL
|
---|
143 | endif
|
---|
144 | ifdef VBOX_WITH_VIRTIO
|
---|
145 | VirtualBox_DEFS += VBOX_WITH_VIRTIO
|
---|
146 | endif
|
---|
147 | ifdef VBOX_WITH_WDDM
|
---|
148 | VirtualBox_DEFS += VBOX_WITH_WDDM
|
---|
149 | endif
|
---|
150 | ifdef VBOX_WITH_CRHGSMI
|
---|
151 | VirtualBox_DEFS += VBOX_WITH_CRHGSMI
|
---|
152 | endif
|
---|
153 | ifdef VBOX_BLEEDING_EDGE
|
---|
154 | VirtualBox_src/selector/VBoxSelectorWnd.cpp_DEFS += \
|
---|
155 | VBOX_BLEEDING_EDGE=\"$(VBOX_BLEEDING_EDGE)\"
|
---|
156 | VirtualBox_src/runtime/UIMachineWindow.cpp_DEFS += \
|
---|
157 | VBOX_BLEEDING_EDGE=\"$(VBOX_BLEEDING_EDGE)\"
|
---|
158 | VirtualBox_src/VBoxAboutDlg.cpp_DEFS += \
|
---|
159 | VBOX_BLEEDING_EDGE=\"$(VBOX_BLEEDING_EDGE)\"
|
---|
160 | VirtualBox_src/main.cpp_DEFS += \
|
---|
161 | VBOX_BLEEDING_EDGE=\"$(VBOX_BLEEDING_EDGE)\"
|
---|
162 | endif
|
---|
163 |
|
---|
164 |
|
---|
165 | VBOX_GUI_INC_DIRS = \
|
---|
166 | ./src \
|
---|
167 | ./src/globals \
|
---|
168 | ./src/extensions \
|
---|
169 | ./src/settings \
|
---|
170 | ./src/settings/global \
|
---|
171 | ./src/settings/machine \
|
---|
172 | ./src/wizards/newvm \
|
---|
173 | ./src/wizards/newhd \
|
---|
174 | ./src/wizards/firstrun \
|
---|
175 | ./src/wizards/exportappliance \
|
---|
176 | ./src/wizards/importappliance \
|
---|
177 | ./src/widgets \
|
---|
178 | ./src/X11 \
|
---|
179 | ./src/darwin \
|
---|
180 | ./src/selector \
|
---|
181 | ./src/runtime \
|
---|
182 | ./src/runtime/fullscreen \
|
---|
183 | ./src/runtime/normal \
|
---|
184 | ./src/runtime/scale \
|
---|
185 | ./src/runtime/seamless
|
---|
186 |
|
---|
187 | ifdef VBOX_WITH_REGISTRATION
|
---|
188 | VBOX_GUI_INC_DIRS += \
|
---|
189 | ./src/wizards/registration
|
---|
190 | endif
|
---|
191 |
|
---|
192 | VirtualBox_INCS = \
|
---|
193 | $(VBOX_GUI_INC_DIRS) \
|
---|
194 | $(PATH_VirtualBox)/include
|
---|
195 |
|
---|
196 | # Necessary for the hdd backend enumeration
|
---|
197 | VirtualBox_LIBS = $(LIB_DDU)
|
---|
198 |
|
---|
199 | # This library is required for multi-monitor support
|
---|
200 | VirtualBox_LIBS.linux += Xinerama
|
---|
201 | VirtualBox_LIBS.solaris += Xinerama
|
---|
202 | VirtualBox_LIBS.freebsd += Xinerama
|
---|
203 |
|
---|
204 | ifneq ($(KBUILD_TARGET),win)
|
---|
205 | VirtualBox_CXXFLAGS += -Wno-switch
|
---|
206 | endif
|
---|
207 |
|
---|
208 | ifdef VBOX_WITH_VIDEOHWACCEL
|
---|
209 | # Necessary for save state support
|
---|
210 | VirtualBox_LIBS += $(LIB_VMM)
|
---|
211 | endif
|
---|
212 | ifeq ($(KBUILD_TYPE),release)
|
---|
213 | VirtualBox_LDFLAGS.win += /SUBSYSTEM:windows
|
---|
214 | else
|
---|
215 | VirtualBox_LDFLAGS.linux+= -rdynamic # for backtrace_symbols()
|
---|
216 | ifeq ($(USERNAME),dmik)
|
---|
217 | VirtualBox_LDFLAGS.win += /SUBSYSTEM:windows
|
---|
218 | else
|
---|
219 | VirtualBox_LDFLAGS.win += /SUBSYSTEM:console
|
---|
220 | endif
|
---|
221 | endif
|
---|
222 |
|
---|
223 | if defined(VBOX_WITH_VIDEOHWACCEL) || defined(VBOX_GUI_USE_QGL)
|
---|
224 | VirtualBox_LDFLAGS.win += /DelayLoad:QtOpenGLVBox4.dll /DelayLoad:OPENGL32.dll
|
---|
225 | endif
|
---|
226 |
|
---|
227 | VirtualBox_LDFLAGS.darwin = \
|
---|
228 | -framework AppKit -framework Carbon \
|
---|
229 | $(if $(VBOX_WITH_HARDENING),-install_name $(VBOX_DYLD_EXECUTABLE_PATH)/VirtualBox.dylib)
|
---|
230 | ifdef VBOX_WITH_ICHAT_THEATER
|
---|
231 | VirtualBox_LDFLAGS.darwin += -framework InstantMessage -framework QuartzCore
|
---|
232 | endif
|
---|
233 | if defined(VBOX_WITH_VIDEOHWACCEL) || defined(VBOX_GUI_USE_QGL)
|
---|
234 | VirtualBox_LDFLAGS.darwin += -framework OpenGL
|
---|
235 | endif
|
---|
236 |
|
---|
237 | VirtualBox_LIBS.win = \
|
---|
238 | $(PATH_SDK_WINPSDK_LIB)/Htmlhelp.Lib \
|
---|
239 | $(PATH_SDK_DXSDK_LIB)/ddraw.lib \
|
---|
240 | $(PATH_SDK_DXSDK_LIB)/dxguid.lib
|
---|
241 | if1of ($(KBUILD_TARGET), freebsd linux netbsd openbsd solaris) # X11
|
---|
242 | VirtualBox_LIBS += $(PATH_DLL)/VBoxKeyboard$(VBOX_SUFF_DLL)
|
---|
243 | endif
|
---|
244 |
|
---|
245 | if defined(VBOX_WITH_VIDEOHWACCEL) || defined(VBOX_GUI_USE_QGL)
|
---|
246 | VirtualBox_LIBS.win += $(PATH_SDK_WINPSDK_LIB)/Opengl32.lib
|
---|
247 | VirtualBox_LIBS.solaris += GL
|
---|
248 | VirtualBox_LIBS.linux += GL
|
---|
249 | VirtualBox_LIBS.freebsd += GL
|
---|
250 | endif
|
---|
251 |
|
---|
252 | # Headers containing definitions of classes that use the Q_OBJECT macro.
|
---|
253 | VirtualBox_QT_MOCHDRS = \
|
---|
254 | src/VBoxAboutDlg.h \
|
---|
255 | src/VBoxGlobalSettings.h \
|
---|
256 | src/VBoxMediaManagerDlg.h \
|
---|
257 | src/VBoxSnapshotDetailsDlg.h \
|
---|
258 | src/VBoxTakeSnapshotDlg.h \
|
---|
259 | src/VBoxUpdateDlg.h \
|
---|
260 | src/VBoxVMInformationDlg.h \
|
---|
261 | src/VBoxVMLogViewer.h \
|
---|
262 | src/globals/VBoxGlobal.h \
|
---|
263 | src/globals/VBoxProblemReporter.h \
|
---|
264 | src/globals/VBoxUtils.h \
|
---|
265 | src/globals/UIMainEventListener.h \
|
---|
266 | src/globals/UIExtraDataEventHandler.h \
|
---|
267 | src/extensions/QIAdvancedSlider.h \
|
---|
268 | src/extensions/QIArrowButtonPress.h \
|
---|
269 | src/extensions/QIArrowButtonSwitch.h \
|
---|
270 | src/extensions/QIArrowSplitter.h \
|
---|
271 | src/extensions/QIDialog.h \
|
---|
272 | src/extensions/QIFileDialog.h \
|
---|
273 | src/extensions/QIHotKeyEdit.h \
|
---|
274 | src/extensions/QIHttp.h \
|
---|
275 | src/extensions/QILabel.h \
|
---|
276 | src/extensions/QILabelSeparator.h \
|
---|
277 | src/extensions/QIListView.h \
|
---|
278 | src/extensions/QIMainDialog.h \
|
---|
279 | src/extensions/QIMessageBox.h \
|
---|
280 | src/extensions/QIRichToolButton.h \
|
---|
281 | src/extensions/QISplitter.h \
|
---|
282 | src/extensions/QIStateIndicator.h \
|
---|
283 | src/extensions/QIStatusBar.h \
|
---|
284 | src/extensions/QITabWidget.h \
|
---|
285 | src/extensions/QIToolButton.h \
|
---|
286 | src/extensions/QITableView.h \
|
---|
287 | src/extensions/QITreeView.h \
|
---|
288 | src/extensions/QITreeWidget.h \
|
---|
289 | src/extensions/QIWidgetValidator.h \
|
---|
290 | src/extensions/QIWizard.h \
|
---|
291 | src/settings/UISettingsDialog.h \
|
---|
292 | src/settings/UISettingsDialogSpecific.h \
|
---|
293 | src/settings/UISettingsPage.h \
|
---|
294 | src/settings/VBoxSettingsSelector.h \
|
---|
295 | src/settings/global/UIGlobalSettingsGeneral.h \
|
---|
296 | src/settings/global/UIGlobalSettingsInput.h \
|
---|
297 | src/settings/global/UIGlobalSettingsUpdate.h \
|
---|
298 | src/settings/global/UIGlobalSettingsLanguage.h \
|
---|
299 | src/settings/global/UIGlobalSettingsNetwork.h \
|
---|
300 | src/settings/global/UIGlobalSettingsNetworkDetails.h \
|
---|
301 | src/settings/machine/UIMachineSettingsGeneral.h \
|
---|
302 | src/settings/machine/UIMachineSettingsSystem.h \
|
---|
303 | src/settings/machine/UIMachineSettingsDisplay.h \
|
---|
304 | src/settings/machine/UIMachineSettingsStorage.h \
|
---|
305 | src/settings/machine/UIMachineSettingsAudio.h \
|
---|
306 | src/settings/machine/UIMachineSettingsNetwork.h \
|
---|
307 | src/settings/machine/UIMachineSettingsPortForwardingDlg.h \
|
---|
308 | src/settings/machine/UIMachineSettingsSerial.h \
|
---|
309 | src/settings/machine/UIMachineSettingsParallel.h \
|
---|
310 | src/settings/machine/UIMachineSettingsUSB.h \
|
---|
311 | src/settings/machine/UIMachineSettingsUSBFilterDetails.h \
|
---|
312 | src/settings/machine/UIMachineSettingsSF.h \
|
---|
313 | src/settings/machine/UIMachineSettingsSFDetails.h \
|
---|
314 | src/wizards/newvm/UINewVMWzd.h \
|
---|
315 | src/wizards/newhd/UINewHDWzd.h \
|
---|
316 | src/wizards/firstrun/UIFirstRunWzd.h \
|
---|
317 | src/wizards/exportappliance/UIExportApplianceWzd.h \
|
---|
318 | src/wizards/importappliance/UIImportApplianceWzd.h \
|
---|
319 | src/widgets/UIBar.h \
|
---|
320 | src/widgets/UIDownloader.h \
|
---|
321 | src/widgets/UIDownloaderAdditions.h \
|
---|
322 | src/widgets/UIDownloaderUserManual.h \
|
---|
323 | src/widgets/UIPopupBox.h \
|
---|
324 | src/widgets/UISpacerWidgets.h \
|
---|
325 | src/widgets/UISpecialControls.h \
|
---|
326 | src/widgets/VBoxApplianceEditorWgt.h \
|
---|
327 | src/widgets/UIBootTable.h \
|
---|
328 | src/widgets/VBoxExportApplianceWgt.h \
|
---|
329 | src/widgets/VBoxFilePathSelectorWidget.h \
|
---|
330 | src/widgets/VBoxImportApplianceWgt.h \
|
---|
331 | src/widgets/VBoxLineTextEdit.h \
|
---|
332 | src/widgets/VBoxMediaComboBox.h \
|
---|
333 | src/widgets/VBoxMiniToolBar.h \
|
---|
334 | src/widgets/VBoxOSTypeSelectorButton.h \
|
---|
335 | src/widgets/VBoxOSTypeSelectorWidget.h \
|
---|
336 | src/widgets/VBoxProgressDialog.h \
|
---|
337 | src/widgets/VBoxWarningPane.h \
|
---|
338 | src/selector/UIVMDesktop.h \
|
---|
339 | src/selector/UIVMListView.h \
|
---|
340 | src/selector/UIVMPreviewWindow.h \
|
---|
341 | src/selector/UIVMItem.h \
|
---|
342 | src/selector/UIVirtualBoxEventHandler.h \
|
---|
343 | src/selector/VBoxSelectorWnd.h \
|
---|
344 | src/selector/VBoxSnapshotsWgt.h \
|
---|
345 | src/runtime/UIActionsPool.h \
|
---|
346 | src/runtime/UIConsoleEventHandler.h \
|
---|
347 | src/runtime/UIIndicatorsPool.h \
|
---|
348 | src/runtime/UIKeyboardHandler.h \
|
---|
349 | src/runtime/UIMachine.h \
|
---|
350 | src/runtime/UIMachineLogic.h \
|
---|
351 | src/runtime/UIMachineView.h \
|
---|
352 | src/runtime/UIMouseHandler.h \
|
---|
353 | src/runtime/UIMultiScreenLayout.h \
|
---|
354 | src/runtime/UISession.h \
|
---|
355 | src/runtime/UIVMCloseDialog.h \
|
---|
356 | src/runtime/fullscreen/UIKeyboardHandlerFullscreen.h \
|
---|
357 | src/runtime/fullscreen/UIMachineLogicFullscreen.h \
|
---|
358 | src/runtime/fullscreen/UIMachineViewFullscreen.h \
|
---|
359 | src/runtime/fullscreen/UIMachineWindowFullscreen.h \
|
---|
360 | src/runtime/normal/UIKeyboardHandlerNormal.h \
|
---|
361 | src/runtime/normal/UIMachineLogicNormal.h \
|
---|
362 | src/runtime/normal/UIMachineViewNormal.h \
|
---|
363 | src/runtime/normal/UIMachineWindowNormal.h \
|
---|
364 | src/runtime/scale/UIKeyboardHandlerScale.h \
|
---|
365 | src/runtime/scale/UIMachineLogicScale.h \
|
---|
366 | src/runtime/scale/UIMachineViewScale.h \
|
---|
367 | src/runtime/scale/UIMachineWindowScale.h \
|
---|
368 | src/runtime/seamless/UIKeyboardHandlerSeamless.h \
|
---|
369 | src/runtime/seamless/UIMachineLogicSeamless.h \
|
---|
370 | src/runtime/seamless/UIMachineViewSeamless.h \
|
---|
371 | src/runtime/seamless/UIMachineWindowSeamless.h
|
---|
372 |
|
---|
373 | VirtualBox_QT_MOCHDRS.darwin += \
|
---|
374 | src/darwin/UIWindowMenuManager.h
|
---|
375 |
|
---|
376 | # Sources containing local definitions of classes that use the Q_OBJECT macro.
|
---|
377 | VirtualBox_QT_MOCSRCS = \
|
---|
378 | src/VBoxMediaManagerDlg.cpp \
|
---|
379 | src/globals/UIExtraDataEventHandler.cpp \
|
---|
380 | src/extensions/QISplitter.cpp \
|
---|
381 | src/selector/UIVMDesktop.cpp \
|
---|
382 | src/settings/UISettingsDialogSpecific.cpp \
|
---|
383 | src/settings/machine/UIMachineSettingsPortForwardingDlg.cpp \
|
---|
384 | src/runtime/UIActionsPool.cpp \
|
---|
385 | src/runtime/UIIndicatorsPool.cpp \
|
---|
386 | src/runtime/UIMachine.cpp \
|
---|
387 | src/runtime/UIMachineLogic.cpp \
|
---|
388 | src/runtime/UIMachineMenuBar.cpp
|
---|
389 |
|
---|
390 | VirtualBox_QT_MOCSRCS.darwin += \
|
---|
391 | src/darwin/UIWindowMenuManager.cpp
|
---|
392 | VirtualBox_QT_MOCSRCS.win += \
|
---|
393 | src/extensions/QIFileDialog.cpp
|
---|
394 |
|
---|
395 | ifdef VBOX_WITH_REGISTRATION
|
---|
396 | VirtualBox_QT_MOCHDRS += \
|
---|
397 | src/wizards/registration/UIRegistrationWzd.h
|
---|
398 | endif
|
---|
399 |
|
---|
400 | ifdef VBOX_WITH_XPCOM
|
---|
401 | VirtualBox_QT_MOCSRCS += \
|
---|
402 | src/globals/COMDefs.cpp
|
---|
403 | endif
|
---|
404 |
|
---|
405 | ifdef VBOX_WITH_REGISTRATION
|
---|
406 | VirtualBox_QT_MOCSRCS += \
|
---|
407 | src/wizards/registration/UIRegistrationWzd.cpp
|
---|
408 | endif
|
---|
409 |
|
---|
410 | VirtualBox_SOURCES = \
|
---|
411 | src/main.cpp \
|
---|
412 | src/VBoxAboutDlg.cpp \
|
---|
413 | src/VBoxGlobalSettings.cpp \
|
---|
414 | src/VBoxHelpActions.cpp \
|
---|
415 | src/VBoxMediaManagerDlg.cpp \
|
---|
416 | src/VBoxMedium.cpp \
|
---|
417 | src/VBoxSnapshotDetailsDlg.cpp \
|
---|
418 | src/VBoxTakeSnapshotDlg.cpp \
|
---|
419 | src/VBoxUpdateDlg.cpp \
|
---|
420 | src/VBoxVMInformationDlg.cpp \
|
---|
421 | src/VBoxVMLogViewer.cpp \
|
---|
422 | src/globals/COMDefs.cpp \
|
---|
423 | src/globals/VBoxDefs.cpp \
|
---|
424 | src/globals/VBoxGlobal.cpp \
|
---|
425 | src/globals/VBoxProblemReporter.cpp \
|
---|
426 | src/globals/UIIconPool.cpp \
|
---|
427 | src/globals/UIMainEventListener.cpp \
|
---|
428 | src/globals/UIExtraDataEventHandler.cpp \
|
---|
429 | src/globals/UIImageTools.cpp \
|
---|
430 | src/extensions/QIAdvancedSlider.cpp \
|
---|
431 | src/extensions/QIArrowButtonPress.cpp \
|
---|
432 | src/extensions/QIArrowButtonSwitch.cpp \
|
---|
433 | src/extensions/QIArrowSplitter.cpp \
|
---|
434 | src/extensions/QIDialog.cpp \
|
---|
435 | src/extensions/QIDialogButtonBox.cpp \
|
---|
436 | src/extensions/QIFileDialog.cpp \
|
---|
437 | src/extensions/QIHotKeyEdit.cpp \
|
---|
438 | src/extensions/QILabel.cpp \
|
---|
439 | src/extensions/QILabelSeparator.cpp \
|
---|
440 | src/extensions/QILineEdit.cpp \
|
---|
441 | src/extensions/QIListView.cpp \
|
---|
442 | src/extensions/QIMainDialog.cpp \
|
---|
443 | src/extensions/QIMessageBox.cpp \
|
---|
444 | src/extensions/QIRichToolButton.cpp \
|
---|
445 | src/extensions/QISplitter.cpp \
|
---|
446 | src/extensions/QIStateIndicator.cpp \
|
---|
447 | src/extensions/QIStatusBar.cpp \
|
---|
448 | src/extensions/QITableView.cpp \
|
---|
449 | src/extensions/QITreeView.cpp \
|
---|
450 | src/extensions/QITreeWidget.cpp \
|
---|
451 | src/extensions/QIWidgetValidator.cpp \
|
---|
452 | src/extensions/QIWizard.cpp \
|
---|
453 | src/settings/UISettingsDialog.cpp \
|
---|
454 | src/settings/UISettingsDialogSpecific.cpp \
|
---|
455 | src/settings/UISettingsPage.cpp \
|
---|
456 | src/settings/VBoxSettingsSelector.cpp \
|
---|
457 | src/settings/global/UIGlobalSettingsGeneral.cpp \
|
---|
458 | src/settings/global/UIGlobalSettingsInput.cpp \
|
---|
459 | src/settings/global/UIGlobalSettingsUpdate.cpp \
|
---|
460 | src/settings/global/UIGlobalSettingsLanguage.cpp \
|
---|
461 | src/settings/global/UIGlobalSettingsNetwork.cpp \
|
---|
462 | src/settings/global/UIGlobalSettingsNetworkDetails.cpp \
|
---|
463 | src/settings/machine/UIMachineSettingsGeneral.cpp \
|
---|
464 | src/settings/machine/UIMachineSettingsSystem.cpp \
|
---|
465 | src/settings/machine/UIMachineSettingsDisplay.cpp \
|
---|
466 | src/settings/machine/UIMachineSettingsStorage.cpp \
|
---|
467 | src/settings/machine/UIMachineSettingsAudio.cpp \
|
---|
468 | src/settings/machine/UIMachineSettingsNetwork.cpp \
|
---|
469 | src/settings/machine/UIMachineSettingsPortForwardingDlg.cpp \
|
---|
470 | src/settings/machine/UIMachineSettingsSerial.cpp \
|
---|
471 | src/settings/machine/UIMachineSettingsParallel.cpp \
|
---|
472 | src/settings/machine/UIMachineSettingsUSB.cpp \
|
---|
473 | src/settings/machine/UIMachineSettingsUSBFilterDetails.cpp \
|
---|
474 | src/settings/machine/UIMachineSettingsSF.cpp \
|
---|
475 | src/settings/machine/UIMachineSettingsSFDetails.cpp \
|
---|
476 | src/wizards/newvm/UINewVMWzd.cpp \
|
---|
477 | src/wizards/newhd/UINewHDWzd.cpp \
|
---|
478 | src/wizards/firstrun/UIFirstRunWzd.cpp \
|
---|
479 | src/wizards/exportappliance/UIExportApplianceWzd.cpp \
|
---|
480 | src/wizards/importappliance/UIImportApplianceWzd.cpp \
|
---|
481 | src/widgets/UIBar.cpp \
|
---|
482 | src/widgets/UIDownloader.cpp \
|
---|
483 | src/widgets/UIDownloaderAdditions.cpp \
|
---|
484 | src/widgets/UIDownloaderUserManual.cpp \
|
---|
485 | src/widgets/UIPopupBox.cpp \
|
---|
486 | src/widgets/UISpecialControls.cpp \
|
---|
487 | src/widgets/UIToolBar.cpp \
|
---|
488 | src/widgets/VBoxApplianceEditorWgt.cpp \
|
---|
489 | src/widgets/UIBootTable.cpp \
|
---|
490 | src/widgets/VBoxExportApplianceWgt.cpp \
|
---|
491 | src/widgets/VBoxFilePathSelectorWidget.cpp \
|
---|
492 | src/widgets/VBoxGuestRAMSlider.cpp \
|
---|
493 | src/widgets/VBoxImportApplianceWgt.cpp \
|
---|
494 | src/widgets/VBoxLineTextEdit.cpp \
|
---|
495 | src/widgets/VBoxMediaComboBox.cpp \
|
---|
496 | src/widgets/VBoxMiniToolBar.cpp \
|
---|
497 | src/widgets/VBoxOSTypeSelectorButton.cpp \
|
---|
498 | src/widgets/VBoxOSTypeSelectorWidget.cpp \
|
---|
499 | src/widgets/VBoxProgressDialog.cpp \
|
---|
500 | src/widgets/VBoxWarningPane.cpp \
|
---|
501 | src/selector/UIVMDesktop.cpp \
|
---|
502 | src/selector/UIVMItem.cpp \
|
---|
503 | src/selector/UIVMListView.cpp \
|
---|
504 | src/selector/UIVMPreviewWindow.cpp \
|
---|
505 | src/selector/UIVirtualBoxEventHandler.cpp \
|
---|
506 | src/selector/VBoxSelectorWnd.cpp \
|
---|
507 | src/selector/VBoxSnapshotsWgt.cpp \
|
---|
508 | src/runtime/UIActionsPool.cpp \
|
---|
509 | src/runtime/UIConsoleEventHandler.cpp \
|
---|
510 | src/runtime/UIFrameBuffer.cpp \
|
---|
511 | src/runtime/UIFrameBufferQGL.cpp \
|
---|
512 | src/runtime/UIFrameBufferQImage.cpp \
|
---|
513 | src/runtime/UIFrameBufferSDL.cpp \
|
---|
514 | src/runtime/UIIndicatorsPool.cpp \
|
---|
515 | src/runtime/UIKeyboardHandler.cpp \
|
---|
516 | src/runtime/UIMachine.cpp \
|
---|
517 | src/runtime/UIMachineLogic.cpp \
|
---|
518 | src/runtime/UIMachineMenuBar.cpp \
|
---|
519 | src/runtime/UIMachineView.cpp \
|
---|
520 | src/runtime/UIMachineWindow.cpp \
|
---|
521 | src/runtime/UIMouseHandler.cpp \
|
---|
522 | src/runtime/UIMultiScreenLayout.cpp \
|
---|
523 | src/runtime/UISession.cpp \
|
---|
524 | src/runtime/UIVMCloseDialog.cpp \
|
---|
525 | src/runtime/fullscreen/UIKeyboardHandlerFullscreen.cpp \
|
---|
526 | src/runtime/fullscreen/UIMachineLogicFullscreen.cpp \
|
---|
527 | src/runtime/fullscreen/UIMachineViewFullscreen.cpp \
|
---|
528 | src/runtime/fullscreen/UIMachineWindowFullscreen.cpp \
|
---|
529 | src/runtime/normal/UIKeyboardHandlerNormal.cpp \
|
---|
530 | src/runtime/normal/UIMachineLogicNormal.cpp \
|
---|
531 | src/runtime/normal/UIMachineViewNormal.cpp \
|
---|
532 | src/runtime/normal/UIMachineWindowNormal.cpp \
|
---|
533 | src/runtime/scale/UIKeyboardHandlerScale.cpp \
|
---|
534 | src/runtime/scale/UIMachineLogicScale.cpp \
|
---|
535 | src/runtime/scale/UIMachineViewScale.cpp \
|
---|
536 | src/runtime/scale/UIMachineWindowScale.cpp \
|
---|
537 | src/runtime/seamless/UIKeyboardHandlerSeamless.cpp \
|
---|
538 | src/runtime/seamless/UIMachineLogicSeamless.cpp \
|
---|
539 | src/runtime/seamless/UIMachineViewSeamless.cpp \
|
---|
540 | src/runtime/seamless/UIMachineWindowSeamless.cpp
|
---|
541 |
|
---|
542 | VirtualBox_SOURCES.win += \
|
---|
543 | src/runtime/UIFrameBufferDirectDraw.cpp
|
---|
544 | VirtualBox_SOURCES.darwin += \
|
---|
545 | src/runtime/UIFrameBufferQuartz2D.cpp \
|
---|
546 | src/darwin/UIAbstractDockIconPreview.cpp \
|
---|
547 | src/darwin/UIWindowMenuManager.cpp \
|
---|
548 | src/darwin/UICocoaDockIconPreview.mm
|
---|
549 |
|
---|
550 | if1of ($(KBUILD_TARGET), freebsd linux netbsd openbsd solaris) # X11
|
---|
551 | ifndef VBOX_OSE
|
---|
552 | VirtualBox_QT_MOCHDRS += \
|
---|
553 | src/VBoxLicenseViewer.h
|
---|
554 | VirtualBox_SOURCES += \
|
---|
555 | src/VBoxLicenseViewer.cpp
|
---|
556 | else
|
---|
557 | VirtualBox_VBOX_EXTRA_NLS_SOURCES += \
|
---|
558 | src/VBoxLicenseViewer.h \
|
---|
559 | src/VBoxLicenseViewer.cpp
|
---|
560 | endif
|
---|
561 | VirtualBox_SOURCES += \
|
---|
562 | src/X11/XKeyboard-new.cpp \
|
---|
563 | src/X11/VBoxX11Helper.cpp
|
---|
564 | else
|
---|
565 | VirtualBox_VBOX_EXTRA_NLS_SOURCES += \
|
---|
566 | src/VBoxLicenseViewer.h \
|
---|
567 | src/VBoxLicenseViewer.cpp
|
---|
568 | endif
|
---|
569 |
|
---|
570 | ifdef VBOX_WITH_REGISTRATION
|
---|
571 | VirtualBox_SOURCES += \
|
---|
572 | src/wizards/registration/UIRegistrationWzd.cpp
|
---|
573 | endif
|
---|
574 |
|
---|
575 | VirtualBox_SOURCES.win += \
|
---|
576 | src/win/VirtualBox.rc
|
---|
577 |
|
---|
578 | VirtualBox_SOURCES.darwin += \
|
---|
579 | src/darwin/DarwinKeyboard.cpp \
|
---|
580 | src/darwin/VBoxUtils-darwin.cpp
|
---|
581 |
|
---|
582 | ifdef VBOX_WITH_ICHAT_THEATER
|
---|
583 | VirtualBox_SOURCES.darwin += \
|
---|
584 | src/darwin/VBoxIChatTheaterWrapper.m
|
---|
585 | endif
|
---|
586 |
|
---|
587 | ifdef VBOX_WITH_COCOA_QT
|
---|
588 | VirtualBox_DEFS += VBOX_DARWIN_USE_NATIVE_CONTROLS
|
---|
589 | VirtualBox_SOURCES.darwin += \
|
---|
590 | src/darwin/CocoaEventHelper.mm \
|
---|
591 | src/darwin/UICocoaApplication.mm \
|
---|
592 | src/darwin/VBoxUtils-darwin-cocoa.mm \
|
---|
593 | src/darwin/UICocoaSpecialControls.mm
|
---|
594 | VirtualBox_QT_MOCHDRS.darwin += \
|
---|
595 | src/darwin/UICocoaSpecialControls.h
|
---|
596 | endif
|
---|
597 |
|
---|
598 | ifdef VBOX_GUI_WITH_SYSTRAY
|
---|
599 | VirtualBox_DEFS += VBOX_GUI_WITH_SYSTRAY
|
---|
600 | VirtualBox_QT_MOCHDRS += \
|
---|
601 | src/selector/VBoxTrayIcon.h
|
---|
602 | VirtualBox_SOURCES += \
|
---|
603 | src/selector/VBoxTrayIcon.cpp
|
---|
604 | endif
|
---|
605 |
|
---|
606 | if defined(VBOX_WITH_VIDEOHWACCEL) || defined(VBOX_GUI_USE_QGL)
|
---|
607 | VirtualBox_SOURCES += \
|
---|
608 | src/VBoxFBQGL.cpp \
|
---|
609 | src/VBoxFBOverlay.cpp \
|
---|
610 | src/VBoxGLSupportInfo.cpp
|
---|
611 | endif
|
---|
612 | # The Qt modules we're using.
|
---|
613 | # (The include directory and lib/framework for each module will be added by the Qt4 unit.)
|
---|
614 | VirtualBox_QT_MODULES = Core Gui Network
|
---|
615 |
|
---|
616 | if defined(VBOX_WITH_VIDEOHWACCEL) || defined(VBOX_GUI_USE_QGL)
|
---|
617 | VirtualBox_QT_MODULES += OpenGL
|
---|
618 | endif
|
---|
619 |
|
---|
620 | # Import QDesigner UI sources and translations from VBoxUI.pro.
|
---|
621 | ifndef VBOX_WITH_REGISTRATION
|
---|
622 | FORMS := $(filter-out src/wizards/registration/UIRegistrationWzdPage1.ui,$(FORMS))
|
---|
623 | endif
|
---|
624 | $(eval VirtualBox_SOURCES += $(FORMS))
|
---|
625 |
|
---|
626 | # Resource files with some OSE differences (VirtualBoxBrand.qrc is created further down).
|
---|
627 | VirtualBox_SOURCES += VirtualBox1.qrc
|
---|
628 | VirtualBox1.qrc_RCCFLAGS = -name BASIC1
|
---|
629 | VirtualBox_SOURCES += VirtualBox2.qrc
|
---|
630 | VirtualBox2.qrc_RCCFLAGS = -name BASIC2
|
---|
631 | ifeq ($(KBUILD_TARGET),darwin)
|
---|
632 | VirtualBox_SOURCES += VirtualBoxMac.qrc
|
---|
633 | VirtualBoxMac.qrc_RCCFLAGS = -name MAC
|
---|
634 | else
|
---|
635 | VirtualBox_SOURCES += VirtualBoxOther.qrc
|
---|
636 | VirtualBoxOther.qrc_RCCFLAGS = -name OTHER
|
---|
637 | endif
|
---|
638 | VirtualBox_SOURCES += $(VBOX_VIRTUALBOX4_OUT_DIR)/VirtualBoxBrand.qrc
|
---|
639 | $(VBOX_VIRTUALBOX4_OUT_DIR)/VirtualBoxBrand.qrc_RCCFLAGS = -name BRAND
|
---|
640 | if defined(VBOX_WITH_VIDEOHWACCEL) || defined(VBOX_GUI_USE_QGL)
|
---|
641 | VirtualBox_SOURCES += VirtualBoxShaders.qrc
|
---|
642 | VirtualBoxShaders.qrc_RCCFLAGS = -name SHADERS
|
---|
643 | endif
|
---|
644 |
|
---|
645 | # Import the translation source from VBoxUI.pro and add the qt_xx_YY counterparts
|
---|
646 | VirtualBox_QT_TRANSLATIONS := $(TRANSLATIONS) \
|
---|
647 | $(patsubst nls/VirtualBox_%.ts,nls/qt_%.ts, $(filter nls/VirtualBox_%.ts,$(TRANSLATIONS)))
|
---|
648 | # Compress the translation units.
|
---|
649 | VirtualBox_LRCFLAGS = -silent
|
---|
650 | # Where to install the translations (a separate install target, VirtualBox-nls-inst is created).
|
---|
651 | VirtualBox_QT_TRANSLATIONS_INST = $(INST_BIN)nls/
|
---|
652 |
|
---|
653 |
|
---|
654 | ## @todo how to detect what tool is used?
|
---|
655 | ## @todo GCC3 seems to lack -Wno-missing-base-class-initializer, so we use
|
---|
656 | # more generic -Wno-extra
|
---|
657 | # bird: What about $(if $(VBOX_GCC_Wno-missing-base-class-initializer),$(VBOX_GCC_Wno-missing-base-class-initializer),$(VBOX_GCC_Wno-extra))?
|
---|
658 | ifdef VBOX_WITH_XPCOM
|
---|
659 | VirtualBox_src/globals/COMDefs.cpp_CXXFLAGS = $(VBOX_GCC_Wno-extra)
|
---|
660 | endif
|
---|
661 |
|
---|
662 |
|
---|
663 | #
|
---|
664 | # Generate the COM wrappers.
|
---|
665 | #
|
---|
666 | ## @todo This needs some cleaning up perhaps...
|
---|
667 | ## @todo kBuild: Non-existing +| targets should be tried remade or what?
|
---|
668 | VirtualBox_BLDDIRS += $(PATH_VirtualBox)/include
|
---|
669 | VirtualBox_INTERMEDIATES += $(PATH_VirtualBox)/include/COMWrappers.h
|
---|
670 | VirtualBox_CLEAN += \
|
---|
671 | $(PATH_VirtualBox)/include/COMWrappers \
|
---|
672 | $(PATH_VirtualBox)/include/COMWrappers.tmp \
|
---|
673 | $(PATH_VirtualBox)/include/COMWrappers.h \
|
---|
674 | $(PATH_VirtualBox)/include/COMWrappers.cpp
|
---|
675 | VirtualBox_SOURCES += $(PATH_VirtualBox)/include/COMWrappers.cpp
|
---|
676 |
|
---|
677 | $$(PATH_VirtualBox)/include/COMWrappers \
|
---|
678 | +| $$(PATH_VirtualBox)/include/COMWrappers.h \
|
---|
679 | +| $$(PATH_VirtualBox)/include/COMWrappers.cpp: \
|
---|
680 | $(VBOX_XIDL_FILE) \
|
---|
681 | $(VBOX_VIRTUALBOX4_SRC)/src/globals/COMWrappers.xsl \
|
---|
682 | | $$(dir $$@)
|
---|
683 | $(call MSG_GENERATE,VirtualBox,$<,$@)
|
---|
684 | $(QUIET)$(RM) -f $@ $@.tmp $@.h $@.cpp
|
---|
685 | $(QUIET)$(VBOX_XSLTPROC) -o $@ $(VBOX_VIRTUALBOX4_SRC)/src/globals/COMWrappers.xsl $<
|
---|
686 |
|
---|
687 | $(QUIET)$(SED) -e '1,/\/\/ wrapper definitions/ !d' \
|
---|
688 | --output $@.tmp $@
|
---|
689 | $(QUIET)$(CP) --changed $@.tmp $@.h
|
---|
690 |
|
---|
691 | $(QUIET)$(APPEND) -t -n $@.tmp \
|
---|
692 | '/*' \
|
---|
693 | ' * DO NOT EDIT! This is a generated file, see COMWrappers.h for details.' \
|
---|
694 | ' */' \
|
---|
695 | '' \
|
---|
696 | '#include "VBoxGlobal.h"' \
|
---|
697 | ''
|
---|
698 | $(QUIET)$(SED) -e '/\/\/ wrapper definitions/,9999999 !d' \
|
---|
699 | -e 's/^inline //' \
|
---|
700 | --append $@.tmp $@
|
---|
701 | $(QUIET)$(CP) --changed $@.tmp $@.cpp
|
---|
702 | $(QUIET)$(RM) -f $@.tmp
|
---|
703 |
|
---|
704 |
|
---|
705 | # alias for generating the COM Wrappers file.
|
---|
706 | testwrappers:: $$(PATH_VirtualBox)/include/COMWrappers.h
|
---|
707 |
|
---|
708 |
|
---|
709 | #
|
---|
710 | # Generate qrc file with branded icons.
|
---|
711 | #
|
---|
712 | VirtualBox_BLDDIRS += $(VBOX_VIRTUALBOX4_OUT_DIR)
|
---|
713 | VirtualBox_CLEAN += $(VBOX_VIRTUALBOX4_OUT_DIR)/VirtualBoxBrand.qrc
|
---|
714 | $(VBOX_VIRTUALBOX4_OUT_DIR)/VirtualBoxBrand.qrc: \
|
---|
715 | $(VBOX_VIRTUALBOX4_SRC)/VirtualBoxBrand.qrc \
|
---|
716 | | $$(dir $$@)
|
---|
717 | $(call MSG_GENERATE,VirtualBox,$<,$@)
|
---|
718 | $(QUIET)$(SED) \
|
---|
719 | -e 's;@VBOX_ABOUT_PNG@;$(VBOX_BRAND_GUI_ABOUT_PNG);g' \
|
---|
720 | -e 's;@VBOX_ABOUT_16PX_PNG@;$(VBOX_BRAND_GUI_ABOUT_16PX_PNG);g' \
|
---|
721 | -e 's;@VBOX_VBOX_16PX_PNG@;$(VBOX_BRAND_GUI_VBOX_16PX_PNG);g' \
|
---|
722 | -e 's;@VBOX_VBOX_20PX_PNG@;$(VBOX_BRAND_GUI_VBOX_20PX_PNG);g' \
|
---|
723 | -e 's;@VBOX_VBOX_32PX_PNG@;$(VBOX_BRAND_GUI_VBOX_32PX_PNG);g' \
|
---|
724 | -e 's;@VBOX_VBOX_40PX_PNG@;$(VBOX_BRAND_GUI_VBOX_40PX_PNG);g' \
|
---|
725 | -e 's;@VBOX_VBOX_48PX_PNG@;$(VBOX_BRAND_GUI_VBOX_48PX_PNG);g' \
|
---|
726 | -e 's;@VBOX_VBOX_64PX_PNG@;$(VBOX_BRAND_GUI_VBOX_64PX_PNG);g' \
|
---|
727 | -e 's;@VBOX_CUBE_42PX_PNG@;$(VBOX_BRAND_GUI_CUBE_42PX_PNG);g' \
|
---|
728 | --output $@ \
|
---|
729 | $<
|
---|
730 |
|
---|
731 |
|
---|
732 | #
|
---|
733 | # Precompiled header - non-functional atm.
|
---|
734 | #
|
---|
735 | ifdef VBOX_WITH_PRECOMPILED_HEADERS
|
---|
736 | VirtualBox_INCS <= $(VirtualBox_0_OUTDIR)/include
|
---|
737 | VirtualBox_DEFS += VBOX_WITH_PRECOMPILED_HEADERS
|
---|
738 | VirtualBox_CXXFLAGS += -Winvalid-pch -fpch-preprocess
|
---|
739 | VirtualBox_INTERMEDIATES += $(VirtualBox_0_OUTDIR)/include/precomp.h.gch
|
---|
740 |
|
---|
741 | tstx: $$(VirtualBox_0_OUTDIR)/include/precomp.h.gch
|
---|
742 |
|
---|
743 | $$(VirtualBox_0_OUTDIR)/include/precomp.h.gch: \
|
---|
744 | $(PATH_SUB_CURRENT)/src/precomp.h \
|
---|
745 | $$(VirtualBox_0_OUTDIR)/include/COMWrappers.h \
|
---|
746 | $$(filter %.gen.h, $$(VirtualBox_INTERMEDIATES) ) \
|
---|
747 | $(VBOX_PATH_SDK)/bindings/xpcom/include/VirtualBox_XPCOM.h \
|
---|
748 | | $$(dir $$@)
|
---|
749 | time 'g++-4.0' \
|
---|
750 | '-c' \
|
---|
751 | '-g' \
|
---|
752 | $(if-expr "$(KBUILD_TYPE)" == "debug", , -O2 ) \
|
---|
753 | '-pipe' \
|
---|
754 | '-Wall' \
|
---|
755 | '-Wextra' \
|
---|
756 | '-Wno-missing-field-initializers' \
|
---|
757 | '-Wno-trigraphs' \
|
---|
758 | '-frtti' \
|
---|
759 | '-fno-exceptions' \
|
---|
760 | '-Wno-non-virtual-dtor' \
|
---|
761 | '-Wno-long-long' \
|
---|
762 | \
|
---|
763 | '-fshort-wchar' \
|
---|
764 | '-fno-strict-aliasing' \
|
---|
765 | '-fvisibility=hidden' \
|
---|
766 | '-DVBOX_HAVE_VISIBILITY_HIDDEN' \
|
---|
767 | '-DRT_USE_VISIBILITY_DEFAULT' \
|
---|
768 | '-fvisibility-inlines-hidden' \
|
---|
769 | '-Winvalid-pch' \
|
---|
770 | '-fpch-preprocess' \
|
---|
771 | \
|
---|
772 | '-F$(PATH_SDK_QT4)/Frameworks' \
|
---|
773 | '-mmacosx-version-min=10.5' \
|
---|
774 | '-isysroot' \
|
---|
775 | '/Developer/SDKs/MacOSX10.5.sdk' \
|
---|
776 | '-m32' \
|
---|
777 | \
|
---|
778 | $(foreach inc,$(VirtualBox_INCS),\$(NL)$(TAB)-I$(inc)) \
|
---|
779 | '-I$(PATH_ROOT)/include' \
|
---|
780 | '-I$(PATH_OUT)' \
|
---|
781 | '-DVBOX' \
|
---|
782 | '-DVBOX_WITH_DEBUGGER' \
|
---|
783 | '-DVBOX_WITH_64_BITS_GUESTS' \
|
---|
784 | $(if-expr "$(KBUILD_TYPE)" == "debug", '-DDEBUG' '-DDEBUG_bird' '-DDEBUG_USERNAME=bird' '-DVBOX_CHECK_STATE' ,) \
|
---|
785 | '-DRT_OS_DARWIN' \
|
---|
786 | '-D__DARWIN__' \
|
---|
787 | '-DRT_ARCH_X86' \
|
---|
788 | '-D__X86__' \
|
---|
789 | '-DIN_RING3' \
|
---|
790 | '-DQT_NO_DEBUG' \
|
---|
791 | '-DQT_THREAD_SUPPORT' \
|
---|
792 | '-DQT_SHARED' \
|
---|
793 | '-DHAVE_CONFIG_H' \
|
---|
794 | '-DHC_ARCH_BITS=32' \
|
---|
795 | '-DGC_ARCH_BITS=64' \
|
---|
796 | '-DVBOX_WITH_XPCOM' \
|
---|
797 | '-DVBOX_WITH_REGISTRATION' \
|
---|
798 | '-DVBOX_WITH_REGISTRATION_REQUEST' \
|
---|
799 | '-DVBOX_WITH_UPDATE_REQUEST' \
|
---|
800 | '-DVBOX_WITH_ALSA' \
|
---|
801 | '-DVBOX_WITH_PULSE' \
|
---|
802 | '-DVBOX_WITH_E1000' \
|
---|
803 | '-DVBOX_WITH_NETFLT' \
|
---|
804 | '-DVBOX_WITH_DEBUGGER_GUI' \
|
---|
805 | $(if-expr "$(KBUILD_TYPE)" != "release", '-DVBOX_WITH_DEBUGGER_GUI_MENU', ) \
|
---|
806 | '-DVBOX_WITH_VIDEOHWACCEL' \
|
---|
807 | '-DVBOX_GUI_USE_QGL' \
|
---|
808 | '-DVBOX_WITH_VIRTIO' \
|
---|
809 | '-DVBOX_WITH_PRECOMPILED_HEADERS' \
|
---|
810 | '-DVBOX_DARWIN_USE_NATIVE_CONTROLS' \
|
---|
811 | '-DQT_CORE_LIB' \
|
---|
812 | '-DQT_GUI_LIB' \
|
---|
813 | '-DQT_NETWORK_LIB' \
|
---|
814 | '-DQT_OPENGL_LIB' \
|
---|
815 | '-DMAC_OS_X_VERSION_MIN_REQUIRED=1050' \
|
---|
816 | '-DMAC_OS_X_VERSION_MAX_ALLOWED=1050' \
|
---|
817 | '-DVBOX_GUI_USE_QUARTZ2D' \
|
---|
818 | '-DVBOX_GUI_USE_QIMAGE' \
|
---|
819 | '-o' $@ $<
|
---|
820 | endif
|
---|
821 |
|
---|
822 | ifeq ($(KBUILD_TARGET),win)
|
---|
823 | #
|
---|
824 | # On Windows we'll have to generate/edit part of the resource file.
|
---|
825 | # The IDI_ICON1 name is Qt specific.
|
---|
826 | #
|
---|
827 | src/win/VirtualBox.rc_INCS = $(PATH_VirtualBox)
|
---|
828 | src/win/VirtualBox.rc_DEPS = $(PATH_VirtualBox)/VirtualBox-icon.rc
|
---|
829 | src/win/VirtualBox.rc_CLEAN = $(PATH_VirtualBox)/VirtualBox-icon.rc
|
---|
830 |
|
---|
831 | $$(PATH_VirtualBox)/VirtualBox-icon.rc: $(MAKEFILE_CURRENT) $(VBOX_WINDOWS_ICON_FILE) | $$(dir $$@)
|
---|
832 | $(APPEND) -t $@ 'IDI_ICON1 ICON "$(subst /,\\,$(VBOX_WINDOWS_ICON_FILE))"'
|
---|
833 |
|
---|
834 | endif # win
|
---|
835 |
|
---|
836 |
|
---|
837 | ifeq ($(KBUILD_TARGET),darwin)
|
---|
838 | #
|
---|
839 | # Create directories for each approved language or the application
|
---|
840 | # menu won't be translated.
|
---|
841 | #
|
---|
842 | INSTALLS += VirtualBox.lproj
|
---|
843 | VirtualBox.lproj_INST = $(INST_VIRTUALBOX)Contents/Resources/
|
---|
844 | VirtualBox.lproj_MODE = 755
|
---|
845 | VirtualBox.lproj_DIRS := $(addsuffix .lproj,$(VBOX_APPROVED_GUI_LANGUAGES))
|
---|
846 |
|
---|
847 | #
|
---|
848 | # On OS X (darwin) we need to install icon resources and compulsory bundle contents.
|
---|
849 | # The VirtualBoxVM.app helper is for launching VMs (fixes some issues with the dock).
|
---|
850 | #
|
---|
851 | INSTALLS += VirtualBox.app
|
---|
852 | VirtualBox.app_INST = $(INST_VIRTUALBOX)Contents/
|
---|
853 | VirtualBox.app_MODE = 644
|
---|
854 | VirtualBox.app_SOURCES = \
|
---|
855 | src/darwin/PkgInfo \
|
---|
856 | $(PATH_VirtualBox.app)/Info.plist \
|
---|
857 | $(VBOX_MACOSX_ICON_FILE)=>Resources/virtualbox.icns
|
---|
858 |
|
---|
859 | $$(PATH_VirtualBox.app)/Info.plist: $(PATH_SUB_CURRENT)/src/darwin/Info.plist $(VBOX_VERSION_MK) | $$(@D)/
|
---|
860 | $(call MSG_GENERATE,VirtualBox.app,$<,$@)
|
---|
861 | $(QUIET)$(RM) -f $@
|
---|
862 | $(QUIET)$(SED) \
|
---|
863 | -e 's/@VBOX_VERSION_STRING@/$(VBOX_VERSION_STRING)/g' \
|
---|
864 | -e 's/@VBOX_VERSION_MAJOR@/$(VBOX_VERSION_MAJOR)/g' \
|
---|
865 | -e 's/@VBOX_VERSION_MINOR@/$(VBOX_VERSION_MINOR)/g' \
|
---|
866 | -e 's/@VBOX_VERSION_BUILD@/$(VBOX_VERSION_BUILD)/g' \
|
---|
867 | -e 's/@VBOX_VENDOR@/$(VBOX_VENDOR)/g' \
|
---|
868 | -e 's/@VBOX_PRODUCT@/$(VBOX_PRODUCT)/g' \
|
---|
869 | -e 's/@VBOX_C_YEAR@/$(VBOX_C_YEAR)/g' \
|
---|
870 | $< > $@
|
---|
871 |
|
---|
872 | INSTALLS += VirtualBoxVM.app
|
---|
873 | VirtualBoxVM.app_INST = $(VirtualBox.app_INST)Resources/VirtualBoxVM.app/Contents/
|
---|
874 | VirtualBoxVM.app_MODE = 644
|
---|
875 | VirtualBoxVM.app_SOURCES = \
|
---|
876 | src/darwin/VM-PkgInfo=>PkgInfo \
|
---|
877 | $(PATH_VirtualBoxVM.app)/VM-Info.plist=>Info.plist
|
---|
878 | VirtualBoxVM.app_SYMLINKS = \
|
---|
879 | MacOS=>../../../MacOS/ \
|
---|
880 | Resources=>../../../Resources/
|
---|
881 |
|
---|
882 | $$(PATH_VirtualBoxVM.app)/VM-Info.plist: $(PATH_SUB_CURRENT)/src/darwin/VM-Info.plist $(VBOX_VERSION_MK) | $$(@D)/
|
---|
883 | $(call MSG_GENERATE,VirtualBoxVM.app,$<,$@)
|
---|
884 | $(QUIET)$(RM) -f $@
|
---|
885 | $(QUIET)$(SED) \
|
---|
886 | -e 's/@VBOX_VERSION_STRING@/$(VBOX_VERSION_STRING)/g' \
|
---|
887 | -e 's/@VBOX_VERSION_MAJOR@/$(VBOX_VERSION_MAJOR)/g' \
|
---|
888 | -e 's/@VBOX_VERSION_MINOR@/$(VBOX_VERSION_MINOR)/g' \
|
---|
889 | -e 's/@VBOX_VERSION_BUILD@/$(VBOX_VERSION_BUILD)/g' \
|
---|
890 | -e 's/@VBOX_VENDOR@/$(VBOX_VENDOR)/g' \
|
---|
891 | -e 's/@VBOX_PRODUCT@/$(VBOX_PRODUCT)/g' \
|
---|
892 | -e 's/@VBOX_C_YEAR@/$(VBOX_C_YEAR)/g' \
|
---|
893 | --output $@ $<
|
---|
894 | endif # darwin
|
---|
895 |
|
---|
896 | #
|
---|
897 | # App for testing GL support
|
---|
898 | #
|
---|
899 | if defined(VBOX_WITH_VIDEOHWACCEL)
|
---|
900 | if1of ($(KBUILD_TARGET), win linux freebsd)
|
---|
901 | LIBRARIES += VBoxOGL2D
|
---|
902 | VBoxOGL2D_TEMPLATE = VBOXR3STATIC
|
---|
903 | VBoxOGL2D_USES = qt4
|
---|
904 | VBoxOGL2D_SDKS = QT4
|
---|
905 | VBoxOGL2D_DEFS = IN_RING3 QT_NO_DEBUG QT_THREAD_SUPPORT QT_SHARED HAVE_CONFIG_H $(ARCH_BITS_DEFS) VBOX_WITH_VIDEOHWACCEL VBOX_GUI_USE_QGL
|
---|
906 | VBoxOGL2D_QT_MODULES += OpenGL
|
---|
907 | VBoxOGL2D_SOURCES = \
|
---|
908 | src/VBoxGLSupportInfo.cpp
|
---|
909 | VBoxOGL2D_INCS = include
|
---|
910 | endif
|
---|
911 | endif
|
---|
912 |
|
---|
913 | #
|
---|
914 | # Testcase for the darwin keyboard routines.
|
---|
915 | #
|
---|
916 | ifdef VBOX_WITH_TESTCASES
|
---|
917 | PROGRAMS.darwin += tstDarwinKeyboard
|
---|
918 | tstDarwinKeyboard_NAME = tstDarwinKeyboard
|
---|
919 | tstDarwinKeyboard_TEMPLATE = VBOXR3TSTEXE
|
---|
920 | tstDarwinKeyboard_DEFS.x86 = USE_HID_FOR_MODIFIERS
|
---|
921 | tstDarwinKeyboard_INCS = include
|
---|
922 | tstDarwinKeyboard_SOURCES = \
|
---|
923 | src/darwin/tstDarwinKeyboard.cpp \
|
---|
924 | src/darwin/DarwinKeyboard.cpp
|
---|
925 | tstDarwinKeyboard_SOURCES.amd64 = \
|
---|
926 | src/darwin/CocoaEventHelper.mm
|
---|
927 | tstDarwinKeyboard_LDFLAGS = -framework IOKit -framework Carbon -framework AppKit
|
---|
928 | tstDarwinKeyboard_LIBS = \
|
---|
929 | $(LIB_RUNTIME)
|
---|
930 | endif
|
---|
931 |
|
---|
932 |
|
---|
933 | # Unset everything that was loaded from VBoxUI.pro.
|
---|
934 | TEMPLATE := $(SAVED_TEMPLATE)
|
---|
935 | SAVED_TEMPLATE :=
|
---|
936 | LANGUAGE :=
|
---|
937 | FORMS :=
|
---|
938 | TRANSLATIONS :=
|
---|
939 | IMAGES :=
|
---|
940 |
|
---|
941 |
|
---|
942 | # Commit the magic.
|
---|
943 | # (note: before custom rules that make usage of generated variables!).
|
---|
944 | include $(KBUILD_PATH)/subfooter.kmk
|
---|
945 |
|
---|
946 | #
|
---|
947 | # Update all known NLS translation (.ts) files in the nls/ subdirectory.
|
---|
948 | #
|
---|
949 | # NOTE: This target is intended to be run only by the GUI maintainer shortly
|
---|
950 | # before a new product release. VirtualBox_xx_YY.ts is a template for new
|
---|
951 | # languages and should never be actually translated or installed.
|
---|
952 | #
|
---|
953 | # For Qt >= 4.6.0 it maybe necessary to add -I $(VBOX_GUI_INC_DIRS) to the
|
---|
954 | # lupdate call
|
---|
955 | #
|
---|
956 | #VirtualBox_QT_TRANSLATIONS = nls/VirtualBox_de.ts
|
---|
957 | updatenls:: makeallnls nls/VirtualBox_en.ts
|
---|
958 |
|
---|
959 | makeallnls:: \
|
---|
960 | $(foreach header,$(VBOX_GUI_INC_DIRS),$(wildcard $(header)/*.h)) \
|
---|
961 | $(filter-out %.qrc,$(VirtualBox_SOURCES) $(VirtualBox_VBOX_EXTRA_NLS_SOURCES))
|
---|
962 | $(call MSG_L1,lupdate all languages (nls/*.ts))
|
---|
963 | $(QUIET)$(TOOL_QT4_LUPDATE) \
|
---|
964 | $^ \
|
---|
965 | -ts \
|
---|
966 | $(filter-out nls/VirtualBox_en.ts,$(filter-out nls/qt_%.ts,$(VirtualBox_QT_TRANSLATIONS))) \
|
---|
967 | nls/VirtualBox_xx_YY.ts
|
---|
968 |
|
---|
969 | # Create the English translation file. This is something special cause it will
|
---|
970 | # contain the plural forms only.
|
---|
971 | nls/VirtualBox_en.ts: \
|
---|
972 | $(foreach header,$(VBOX_GUI_INC_DIRS),$(wildcard $(header)/*.h)) \
|
---|
973 | $(filter-out %.qrc,$(VirtualBox_SOURCES) $(VirtualBox_VBOX_EXTRA_NLS_SOURCES))
|
---|
974 | $(call MSG_L1,lupdate $@)
|
---|
975 | $(QUIET)$(TOOL_QT4_LUPDATE) \
|
---|
976 | $^ \
|
---|
977 | -ts \
|
---|
978 | $@
|
---|
979 | $(QUIET)$(SED) -n -i -e \
|
---|
980 | '/<context>/,/<\/context>/!p;/<context>/h;/<name>/H;/<message numerus="yes">/,/<\/message>/H;/<\/context>/{H;x;/<message/p}' \
|
---|
981 | $@
|
---|
982 |
|
---|