VirtualBox

source: vbox/trunk/src/VBox/Frontends/VirtualBox/Makefile.kmk@ 28587

Last change on this file since 28587 was 28573, checked in by vboxsync, 15 years ago

FE/Qt4: enable new core always

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

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