1 | # $Id: Makefile.kmk 12191 2008-09-08 00:33:11Z vboxsync $
|
---|
2 | ## @file
|
---|
3 | # Makefile for the VirtualBox Qt3 GUI.
|
---|
4 | #
|
---|
5 |
|
---|
6 | #
|
---|
7 | # Copyright (C) 2006-2007 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 |
|
---|
22 | # TESTING
|
---|
23 | USE_KBUILD_QT3_UNIT = 1
|
---|
24 |
|
---|
25 | DEPTH = ../../../..
|
---|
26 | include $(KBUILD_PATH)/header.kmk
|
---|
27 |
|
---|
28 | #
|
---|
29 | # Globals.
|
---|
30 | #
|
---|
31 | VBOX_PATH_VIRTUALBOX3_SRC := $(PATH_SUB_CURRENT)
|
---|
32 | VBOX_WITH_REGISTRATION := 1
|
---|
33 | VBOX_WITH_REGISTRATION_REQUEST := 1
|
---|
34 |
|
---|
35 |
|
---|
36 | #
|
---|
37 | # The targets.
|
---|
38 | #
|
---|
39 | ifdef VBOX_WITH_HARDENING
|
---|
40 | PROGRAMS += VirtualBox3Hardened
|
---|
41 | DLLS += VirtualBox
|
---|
42 | else
|
---|
43 | PROGRAMS += VirtualBox
|
---|
44 | endif
|
---|
45 | ifeq ($(filter-out freebsd linux openbsd netbsd solaris,$(KBUILD_TARGET)),) # X11
|
---|
46 | DLLS += VBoxKeyboard3
|
---|
47 | OTHERS += $(PATH_BIN)/vboxkeyboard3.tar.gz
|
---|
48 | endif
|
---|
49 | DLLS.os2 += VBoxHlp
|
---|
50 | ifndef USE_KBUILD_QT3_UNIT
|
---|
51 | INSTALLS += VirtualBox.nls
|
---|
52 | endif
|
---|
53 |
|
---|
54 |
|
---|
55 | ifeq ($(KBUILD_TARGET),os2)
|
---|
56 | #
|
---|
57 | # VBoxHlp - helper DLL for OS/2.
|
---|
58 | #
|
---|
59 | VBoxHlp_ASTOOL = NASM
|
---|
60 | VBoxHlp_ASFLAGS = -f obj
|
---|
61 | VBoxHlp_DEFS = IN_RING3 IN_VBOXHLP
|
---|
62 | VBoxHlp_CXXFLAGS = -fno-exceptions
|
---|
63 | VBoxHlp_LDFLAGS = -nostdlib -los2
|
---|
64 | VBoxHlp_LDFLAGS += -Zlinker option -Zlinker manyautodata
|
---|
65 | VBoxHlp_SOURCES = \
|
---|
66 | src/os2/VBoxHlp.asm \
|
---|
67 | src/os2/VBoxHlp.cpp
|
---|
68 |
|
---|
69 | #
|
---|
70 | # Hack for installing the qt.dll when building for OS/2.
|
---|
71 | #
|
---|
72 | ifneq ($(strip $(VBOX_DLL_QT)),)
|
---|
73 | INSTALLS.os2 += qt.dll
|
---|
74 | qt.dll_INST = $(INST_BIN)
|
---|
75 | qt.dll_SOURCES += \
|
---|
76 | $(VBOX_DLL_QT)=>$(not-dir $(VBOX_DLL_QT))
|
---|
77 | endif
|
---|
78 | endif # OS/2
|
---|
79 |
|
---|
80 |
|
---|
81 | #
|
---|
82 | # VBoxKeyboard3 - keyboard library for X11.
|
---|
83 | #
|
---|
84 | VBoxKeyboard3_TEMPLATE = VBOXR3
|
---|
85 | VBoxKeyboard3_SOURCES = \
|
---|
86 | src/linux/keyboard-new.c
|
---|
87 | VBoxKeyboard3_TARSOURCES = \
|
---|
88 | $(VBoxKeyboard3_SOURCES) \
|
---|
89 | src/linux/COPYING.LIB \
|
---|
90 | src/linux/keyboard.h \
|
---|
91 | src/linux/keyboard-layouts.h \
|
---|
92 | src/linux/keyboard-list.h \
|
---|
93 | src/linux/keyboard-tables.h \
|
---|
94 | src/linux/keyboard-types.h \
|
---|
95 | src/linux/Makefile
|
---|
96 | VBoxKeyboard3_LIBS = X11
|
---|
97 | VBoxKeyboard3_LIBPATH = $(VBOX_LIBPATH_X11)
|
---|
98 |
|
---|
99 |
|
---|
100 | #
|
---|
101 | # vboxkeyboard3.tar.gz - the LGPLed keyboard library must always be
|
---|
102 | # redistributed with usable sources.
|
---|
103 | #
|
---|
104 | SOURCE_DIRECTORY = vboxkeyboard3
|
---|
105 | DIRECTORY_PREFIX = src/linux/
|
---|
106 |
|
---|
107 | $(PATH_TARGET)/$(SOURCE_DIRECTORY):
|
---|
108 | $(MKDIR) -p $(@D)
|
---|
109 | $(LN_SYMLINK) $(abspath $(PATH_CURRENT))/$(DIRECTORY_PREFIX) $@
|
---|
110 |
|
---|
111 | $(PATH_BIN)/vboxkeyboard3.tar.gz: $(VBoxKeyboard3_TARSOURCES) $(PATH_TARGET)/$(SOURCE_DIRECTORY)
|
---|
112 | $(call MSG_TOOL,tar/gzip,,$@)
|
---|
113 | $(QUIET)cd $(PATH_TARGET) && tar -chf - $(addprefix $(SOURCE_DIRECTORY)/,$(subst $(DIRECTORY_PREFIX),,$(VBoxKeyboard3_TARSOURCES))) | gzip - > $@
|
---|
114 |
|
---|
115 |
|
---|
116 | #
|
---|
117 | # Hardened VirtualBox4.
|
---|
118 | #
|
---|
119 | VirtualBox3Hardened_TEMPLATE = VBOXR3HARDENEDEXE
|
---|
120 | VirtualBox3Hardened_SOURCES = src/hardenedmain.cpp
|
---|
121 | VirtualBox3Hardened_NAME = VirtualBox3
|
---|
122 | ifeq ($(KBUILD_TARGET),darwin) ## @todo use .darwin when ticket 36 has been fixed.
|
---|
123 | #VirtualBox3Hardened_INST.darwin = $(INST_BIN)VirtualBox3 $(INST_BIN)VirtualBoxVM3
|
---|
124 | VirtualBox3Hardened_INST = $(INST_BIN)VirtualBox3 $(INST_BIN)VirtualBoxVM3
|
---|
125 | endif
|
---|
126 |
|
---|
127 |
|
---|
128 | #
|
---|
129 | # Note: I'm doing this right here because the GUI will _not_ run
|
---|
130 | # without that file which might be annoying for developers!
|
---|
131 | #
|
---|
132 | ## @todo is is an ugly hack, change into an install target or make the root Makefile do this!
|
---|
133 | ifndef VBOX_OSE
|
---|
134 | ifeq ($(filter-out freebsd linux netbsd openbsd solaris,$(KBUILD_TARGET)),) # linux only, yea, right.
|
---|
135 | $(VBOX_LICENSE_BIN): $(VBOX_LICENSE_SRC)
|
---|
136 | $(call MSG_GENERATE,,$@)
|
---|
137 | $(QUIET)$(CP) $< $@
|
---|
138 |
|
---|
139 | $(PATH_BIN)/VirtualBox3: $(VBOX_LICENSE_BIN)
|
---|
140 | endif
|
---|
141 | endif
|
---|
142 |
|
---|
143 |
|
---|
144 | #
|
---|
145 | # Include Qt project file, we'll use FORMS, TRANSLATIONS and IMAGES
|
---|
146 | # in the VirtualBox(3) setup below.
|
---|
147 | #
|
---|
148 | SAVED_TEMPLATE := $(TEMPLATE)
|
---|
149 | include $(PATH_SUB_CURRENT)/VBoxUI.pro
|
---|
150 |
|
---|
151 |
|
---|
152 | # Import images from VBoxUI.pro and add some additional ones
|
---|
153 | # that differs between OSE and PEUL.
|
---|
154 | VirtualBox_QT_IMAGES := $(IMAGES)
|
---|
155 | ifdef VBOX_OSE
|
---|
156 | VirtualBox_QT_IMAGES += \
|
---|
157 | images/OSE/about.png \
|
---|
158 | images/OSE/about_tile.png \
|
---|
159 | images/OSE/about_16px.png \
|
---|
160 | images/OSE/VirtualBox_16px.png \
|
---|
161 | images/OSE/VirtualBox_20px.png \
|
---|
162 | images/OSE/VirtualBox_32px.png \
|
---|
163 | images/OSE/VirtualBox_40px.png \
|
---|
164 | images/OSE/VirtualBox_48px.png \
|
---|
165 | images/OSE/VirtualBox_64px.png \
|
---|
166 | images/OSE/VirtualBox_cube_42px.png
|
---|
167 | else
|
---|
168 | VirtualBox_QT_IMAGES += \
|
---|
169 | images/NonOSE/about.png \
|
---|
170 | images/NonOSE/about_16px.png \
|
---|
171 | images/NonOSE/VirtualBox_16px.png \
|
---|
172 | images/NonOSE/VirtualBox_20px.png \
|
---|
173 | images/NonOSE/VirtualBox_32px.png \
|
---|
174 | images/NonOSE/VirtualBox_40px.png \
|
---|
175 | images/NonOSE/VirtualBox_48px.png \
|
---|
176 | images/NonOSE/VirtualBox_64px.png \
|
---|
177 | images/NonOSE/VirtualBox_cube_42px.png
|
---|
178 | endif
|
---|
179 |
|
---|
180 |
|
---|
181 |
|
---|
182 | #
|
---|
183 | # VirtualBox - The GUI program.
|
---|
184 | #
|
---|
185 | VirtualBox_TEMPLATE := $(if $(VBOX_WITH_HARDENING),VBOXQTGUI,VBOXQTGUIEXE)
|
---|
186 | VirtualBox_NAME = VirtualBox3
|
---|
187 | ifndef VBOX_WITH_HARDENING # For the launch trick we need different inode numbers.
|
---|
188 | ifeq ($(KBUILD_TARGET),darwin) ## @todo use .darwin when ticket 36 has been fixed.
|
---|
189 | #VirtualBox_INST.darwin = $(INST_BIN)VirtualBox3 $(INST_BIN)VirtualBoxVM3
|
---|
190 | VirtualBox_INST = $(INST_BIN)VirtualBox3 $(INST_BIN)VirtualBoxVM3
|
---|
191 | endif
|
---|
192 | endif
|
---|
193 | ifdef USE_KBUILD_QT3_UNIT
|
---|
194 | USES += qt3
|
---|
195 | VirtualBox_USES = qt3
|
---|
196 | VirtualBox_SDKS += QT3
|
---|
197 | VirtualBox_QTTOOL = QT3
|
---|
198 | endif
|
---|
199 | VirtualBox_SDKS.win = WINPSDK DXSDK
|
---|
200 | #ifeq ($(filter-out freebsd linux netbsd openbsd os2 solaris,$(KBUILD_TARGET)),) - later
|
---|
201 | ifeq ($(filter-out freebsd linux netbsd openbsd os2,$(KBUILD_TARGET)),) # X11 + os2
|
---|
202 | VirtualBox_SDKS += LIBSDL
|
---|
203 | endif
|
---|
204 |
|
---|
205 | # For testing iChat Theater stuff change the sdk path (HACK ALERT)
|
---|
206 | ifdef VBOX_WITH_ICHAT_THEATER
|
---|
207 | VBOX_PATH_MACOSX_SDK = /Developer/SDKs/MacOSX10.5.sdk
|
---|
208 | endif
|
---|
209 |
|
---|
210 | # Import translation sources
|
---|
211 | ifdef USE_KBUILD_QT3_UNIT
|
---|
212 | VirtualBox3_QT_TRANSLATIONS := $(TRANSLATIONS) \
|
---|
213 | $(patsubst nls/VirtualBox_%.ts,nls/qt_%.ts, $(filter nls/VirtualBox_%.ts,$(TRANSLATIONS)))
|
---|
214 | else
|
---|
215 | VirtualBox_QT_TRANSLATIONS := $(TRANSLATIONS)
|
---|
216 | # Each nls/VirtualBox_xx_YY.ts file must have a qt_xx_YY.ts counterpart
|
---|
217 | VirtualBox_QT_TRANSLATIONS_QT := \
|
---|
218 | $(patsubst nls/VirtualBox_%.ts,nls/qt_%.ts,\
|
---|
219 | $(filter nls/VirtualBox_%.ts,$(VirtualBox_QT_TRANSLATIONS)))
|
---|
220 | endif
|
---|
221 | VirtualBox_LRCFLAGS = -nocompress
|
---|
222 | VirtualBox_QT_TRANSLATIONS_INST = $(INST_BIN)nls3/
|
---|
223 |
|
---|
224 | # QDesigner UI sources are imported from VBoxUI.pro.
|
---|
225 | ## @todo move down.
|
---|
226 | ifndef VBOX_WITH_REGISTRATION
|
---|
227 | FORMS := $(filter-out ui/VBoxRegistrationDlg.ui,$(FORMS))
|
---|
228 | endif
|
---|
229 | ifdef USE_KBUILD_QT3_UNIT
|
---|
230 | $(eval VirtualBox_SOURCES += $(FORMS) )
|
---|
231 | else
|
---|
232 | VirtualBox_QT_UISRCS := $(FORMS)
|
---|
233 | endif
|
---|
234 |
|
---|
235 | # Headers containing definitions of classes that use the Q_OBJECT macro
|
---|
236 | VirtualBox_QT_MOCHDRS = \
|
---|
237 | include/QIWidgetValidator.h \
|
---|
238 | include/QIHotKeyEdit.h \
|
---|
239 | include/QIStatusBar.h \
|
---|
240 | include/QIStateIndicator.h \
|
---|
241 | include/QIMessageBox.h \
|
---|
242 | include/QIRichLabel.h \
|
---|
243 | include/VBoxGlobalSettings.h \
|
---|
244 | include/VBoxUtils.h \
|
---|
245 | include/VBoxGlobal.h \
|
---|
246 | include/VBoxVMListBox.h \
|
---|
247 | include/VBoxMediaComboBox.h \
|
---|
248 | include/VBoxSelectorWnd.h \
|
---|
249 | include/VBoxConsoleWnd.h \
|
---|
250 | include/VBoxConsoleView.h \
|
---|
251 | include/VBoxProblemReporter.h \
|
---|
252 | include/VBoxDownloaderWgt.h \
|
---|
253 | include/VBoxNetworkFramework.h
|
---|
254 |
|
---|
255 | # Sources containing local definitions of classes that use the Q_OBJECT macro
|
---|
256 | VirtualBox_QT_MOCSRCS = src/VBoxSelectorWnd.cpp
|
---|
257 | ifeq ($(filter-out freebsd linux netbsd openbsd solaris,$(KBUILD_TARGET)),) # X11
|
---|
258 | VirtualBox_QT_MOCSRCS += src/VBoxGlobal.cpp
|
---|
259 | endif
|
---|
260 | ifdef VBOX_WITH_XPCOM
|
---|
261 | VirtualBox_QT_MOCSRCS += src/COMDefs.cpp
|
---|
262 | endif
|
---|
263 |
|
---|
264 | # UI headers (ui.h) containing local definitions of classes that use the Q_OBJECT macro
|
---|
265 | ifdef USE_KBUILD_QT3_UNIT
|
---|
266 | ## @todo move up
|
---|
267 | VirtualBox_QT_MOCSRCS += \
|
---|
268 | ui/VBoxVMSettingsDlg.ui.h \
|
---|
269 | ui/VBoxVMLogViewer.ui.h \
|
---|
270 | ui/VBoxSharedFoldersSettings.ui.h \
|
---|
271 | ui/VBoxHardDiskSettings.ui.h
|
---|
272 |
|
---|
273 | else # !USE_KBUILD_QT3_UNIT
|
---|
274 | VirtualBox_QT_MOCUIHDRS = \
|
---|
275 | ui/VBoxVMSettingsDlg.ui.h \
|
---|
276 | ui/VBoxVMLogViewer.ui.h \
|
---|
277 | ui/VBoxSharedFoldersSettings.ui.h \
|
---|
278 | ui/VBoxHardDiskSettings.ui.h
|
---|
279 |
|
---|
280 | # All generated sources. Note: this list MUST be in sync with Qt source
|
---|
281 | # generation rules defined somewhere below!
|
---|
282 | VirtualBox_GENSRCS = \
|
---|
283 | $(foreach moc,$(notdir $(basename $(VirtualBox_QT_MOCHDRS))), $(PATH_VirtualBox)/moc/moc_$(moc).cpp) \
|
---|
284 | $(foreach ui,$(notdir $(basename $(VirtualBox_QT_UISRCS))), $(PATH_VirtualBox)/ui/$(ui).cpp $(PATH_VirtualBox)/moc/moc_$(ui).cpp) \
|
---|
285 | $(PATH_VirtualBox)/ui/vbox_image_collection.cpp
|
---|
286 |
|
---|
287 | # All generated headers. Note: this list MUST be in sync with Qt source
|
---|
288 | # generation rules defined somewhere below!
|
---|
289 | VirtualBox_GENHDRS = \
|
---|
290 | $(foreach mocui,$(notdir $(basename $(VirtualBox_QT_MOCUIHDRS))), $(PATH_VirtualBox)/moc/$(mocui).moc) \
|
---|
291 | $(foreach moc,$(notdir $(basename $(VirtualBox_QT_MOCSRCS))), $(PATH_VirtualBox)/moc/$(moc).moc) \
|
---|
292 | $(foreach ui,$(notdir $(basename $(VirtualBox_QT_UISRCS))), $(PATH_VirtualBox)/ui/$(ui).h)
|
---|
293 |
|
---|
294 | # All existing .ui.h files for known .ui sources
|
---|
295 | VirtualBox_QT_UIHDRS = \
|
---|
296 | $(wildcard $(addsuffix .h,$(VirtualBox_QT_UISRCS)))
|
---|
297 |
|
---|
298 | # All header files
|
---|
299 | VirtualBox_HEADERS = \
|
---|
300 | $(wildcard include/*.h) \
|
---|
301 | $(VirtualBox_GENHDRS) \
|
---|
302 | $(VirtualBox_QT_UIHDRS)
|
---|
303 |
|
---|
304 | VirtualBox_SOURCES += $(VirtualBox_GENSRCS)
|
---|
305 | endif # !USE_KBUILD_QT3_UNIT
|
---|
306 |
|
---|
307 | VirtualBox_SOURCES += \
|
---|
308 | src/main.cpp \
|
---|
309 | src/COMDefs.cpp \
|
---|
310 | src/QIWidgetValidator.cpp \
|
---|
311 | src/QIHotKeyEdit.cpp \
|
---|
312 | src/QIStateIndicator.cpp \
|
---|
313 | src/QIStatusBar.cpp \
|
---|
314 | src/QIMessageBox.cpp \
|
---|
315 | src/QIRichLabel.cpp \
|
---|
316 | src/VBoxDefs.cpp \
|
---|
317 | src/VBoxGlobalSettings.cpp \
|
---|
318 | src/VBoxGlobal.cpp \
|
---|
319 | src/VBoxMediaComboBox.cpp \
|
---|
320 | src/VBoxProblemReporter.cpp \
|
---|
321 | src/VBoxSelectorWnd.cpp \
|
---|
322 | src/VBoxConsoleView.cpp \
|
---|
323 | src/VBoxConsoleWnd.cpp \
|
---|
324 | src/VBoxDownloaderWgt.cpp \
|
---|
325 | src/VBoxVMListBox.cpp \
|
---|
326 | src/VBoxFrameBuffer.cpp \
|
---|
327 | src/HappyHttp.cpp \
|
---|
328 | src/VBoxNetworkFramework.cpp
|
---|
329 |
|
---|
330 | ifeq ($(filter-out freebsd linux netbsd openbsd solaris,$(KBUILD_TARGET)),) # X11
|
---|
331 | VirtualBox_SOURCES += \
|
---|
332 | src/linux/XKeyboard-new.cpp
|
---|
333 | endif
|
---|
334 |
|
---|
335 | VirtualBox_SOURCES.win += \
|
---|
336 | src/VBoxFBDDRAW.cpp \
|
---|
337 | $(PATH_TARGET)/VirtualBox.rc
|
---|
338 |
|
---|
339 | VirtualBox_SOURCES.darwin = \
|
---|
340 | src/darwin/DarwinKeyboard.cpp \
|
---|
341 | src/darwin/DarwinCursor.cpp \
|
---|
342 | src/darwin/VBoxAquaStyle.cpp \
|
---|
343 | src/darwin/VBoxUtils-darwin.cpp \
|
---|
344 | src/VBoxFBQuartz2D.cpp
|
---|
345 |
|
---|
346 | ifdef VBOX_WITH_ICHAT_THEATER
|
---|
347 | VirtualBox_SOURCES.darwin += \
|
---|
348 | src/darwin/VBoxIChatTheaterWrapper.m
|
---|
349 | endif
|
---|
350 |
|
---|
351 | ifdef USE_KBUILD_QT3_UNIT
|
---|
352 | ## @todo deal with QT_IMAGES...
|
---|
353 | VirtualBox_SOURCES += \
|
---|
354 | $(PATH_VirtualBox)/ui/vbox_image_collection.cpp
|
---|
355 | VirtualBox_BLDDIRS += $(PATH_VirtualBox)/ui
|
---|
356 | endif
|
---|
357 |
|
---|
358 | ifndef VBOX_OSE
|
---|
359 | VirtualBox_SOURCES += src/VBoxAboutNonOSEDlg.cpp
|
---|
360 | VirtualBox_QT_MOCHDRS += include/VBoxAboutNonOSEDlg.h
|
---|
361 | endif
|
---|
362 | # OSE version is always necessary for lupdate/lrelease
|
---|
363 | VirtualBox_QT_UISRCS += ui/VBoxAboutDlg.ui
|
---|
364 |
|
---|
365 | VirtualBox_DEFS = VBOX_GUI_SEPARATE_VM_PROCESS
|
---|
366 | VirtualBox_DEFS.debug = VBOX_GUI_DEBUG VBOX_CHECK_STATE # QT_FATAL_ASSERT
|
---|
367 | VirtualBox_DEFS.darwin = VBOX_GUI_USE_QUARTZ2D VBOX_GUI_USE_QIMAGE VBOX_WITHOUT_QHTTP
|
---|
368 | VirtualBox_DEFS.freebsd = VBOX_GUI_USE_QIMAGE VBOX_GUI_USE_SDL
|
---|
369 | VirtualBox_DEFS.linux = VBOX_GUI_USE_QIMAGE #VBOX_GUI_USE_SDL
|
---|
370 | VirtualBox_DEFS.netbsd = VBOX_GUI_USE_QIMAGE VBOX_GUI_USE_SDL
|
---|
371 | VirtualBox_DEFS.openbsd = VBOX_GUI_USE_QIMAGE VBOX_GUI_USE_SDL
|
---|
372 | VirtualBox_DEFS.os2 = VBOX_GUI_USE_QIMAGE VBOX_GUI_USE_SDL QT_DLL
|
---|
373 | VirtualBox_DEFS.solaris = VBOX_GUI_USE_QIMAGE #VBOX_GUI_USE_SDL
|
---|
374 | VirtualBox_DEFS.win = VBOX_GUI_USE_QIMAGE UNICODE QT_DLL
|
---|
375 | VirtualBox_DEFS.win.amd64 = VBOX_WITHOUT_QHTTP
|
---|
376 | #ifndef VBOX_OSE
|
---|
377 | VirtualBox_DEFS.darwin += VBOX_WITH_HACKED_QT
|
---|
378 | #endif
|
---|
379 | ifdef VBOX_WITH_ICHAT_THEATER
|
---|
380 | VirtualBox_DEFS.darwin += VBOX_WITH_ICHAT_THEATER
|
---|
381 | endif
|
---|
382 | ifneq ($(KBUILD_TYPE),release)
|
---|
383 | # non-release builds has some extra features.
|
---|
384 | VirtualBox_DEFS.win += VBOX_GUI_USE_DDRAW
|
---|
385 | VirtualBox_DEFS.linux += VBOX_GUI_USE_QIMAGE
|
---|
386 | endif
|
---|
387 | ifdef VBOX_WITH_REGISTRATION
|
---|
388 | VirtualBox_DEFS += VBOX_WITH_REGISTRATION
|
---|
389 | endif
|
---|
390 | ifdef VBOX_WITH_REGISTRATION_REQUEST
|
---|
391 | VirtualBox_DEFS += VBOX_WITH_REGISTRATION_REQUEST
|
---|
392 | endif
|
---|
393 | ifdef VBOX_WITH_ALSA
|
---|
394 | VirtualBox_DEFS += VBOX_WITH_ALSA
|
---|
395 | endif
|
---|
396 | ifdef VBOX_WITH_PULSE
|
---|
397 | VirtualBox_DEFS += VBOX_WITH_PULSE
|
---|
398 | endif
|
---|
399 | ifdef VBOX_WITH_E1000
|
---|
400 | VirtualBox_DEFS += VBOX_WITH_E1000
|
---|
401 | endif
|
---|
402 | ifdef VBOX_OSE
|
---|
403 | VirtualBox_DEFS += VBOX_OSE
|
---|
404 | endif
|
---|
405 | ifdef VBOX_WITH_DEBUGGER_GUI
|
---|
406 | VirtualBox_DEFS += VBOX_WITH_DEBUGGER_GUI_MENU
|
---|
407 | endif
|
---|
408 | ifdef VBOX_WITH_NETFLT
|
---|
409 | VirtualBox_DEFS += VBOX_WITH_NETFLT
|
---|
410 | endif
|
---|
411 |
|
---|
412 | VirtualBox_INCS = \
|
---|
413 | ./include \
|
---|
414 | $(PATH_VirtualBox)/include
|
---|
415 | ifndef USE_KBUILD_QT3_UNIT
|
---|
416 | VirtualBox_INCS += \
|
---|
417 | $(PATH_VirtualBox)/ui \
|
---|
418 | $(PATH_VirtualBox)/moc
|
---|
419 | endif
|
---|
420 |
|
---|
421 | ifeq ($(KBUILD_TYPE),release)
|
---|
422 | VirtualBox_LDFLAGS.win += /SUBSYSTEM:windows
|
---|
423 | else
|
---|
424 | VirtualBox_LDFLAGS.linux+= -rdynamic # for backtrace_symbols()
|
---|
425 | ifeq ($(USERNAME),dmik)
|
---|
426 | VirtualBox_LDFLAGS.win += /SUBSYSTEM:windows
|
---|
427 | else
|
---|
428 | VirtualBox_LDFLAGS.win += /SUBSYSTEM:console
|
---|
429 | endif
|
---|
430 | endif
|
---|
431 | VirtualBox_LDFLAGS.os2 = -Zlinker /PM:PM -Zno-fork
|
---|
432 | VirtualBox_LDFLAGS.darwin = \
|
---|
433 | -framework IOKit -framework Carbon -framework QuickTime \
|
---|
434 | $(if $(VBOX_WITH_HARDENING),-install_name $(VBOX_DYLD_EXECUTABLE_PATH)/VirtualBox3.dylib)
|
---|
435 | ifdef VBOX_WITH_ICHAT_THEATER
|
---|
436 | VirtualBox_LDFLAGS.darwin += -framework Foundation -framework AppKit -framework InstantMessage -framework QuartzCore
|
---|
437 | endif
|
---|
438 | VirtualBox_LIBS.win = \
|
---|
439 | $(PATH_SDK_WINPSDK_LIB)/Htmlhelp.Lib \
|
---|
440 | $(PATH_SDK_DXSDK_LIB)/ddraw.lib \
|
---|
441 | $(PATH_SDK_DXSDK_LIB)/dxguid.lib
|
---|
442 | VirtualBox_LIBS.os2 += $(PATH_DLL)/VBoxHlp$(VBOX_SUFF_DLL)
|
---|
443 | ifeq ($(filter-out freebsd linux netbsd openbsd solaris,$(KBUILD_TARGET)),) # X11
|
---|
444 | VirtualBox_LIBS += $(PATH_DLL)/VBoxKeyboard3$(VBOX_SUFF_DLL)
|
---|
445 | endif
|
---|
446 |
|
---|
447 |
|
---|
448 | ifdef VBOX_WITH_DEBUGGER_GUI ## @todo make this dynamically loadable and ship with release builds too.
|
---|
449 | ifeq ($(KBUILD_TARGET),win)
|
---|
450 | VirtualBox_LIBS += $(PATH_LIB)/VBoxDbg3$(VBOX_SUFF_LIB)
|
---|
451 | else
|
---|
452 | VirtualBox_LIBS += $(PATH_DLL)/VBoxDbg3$(VBOX_SUFF_DLL)
|
---|
453 | endif
|
---|
454 | endif
|
---|
455 |
|
---|
456 | # Some flag hacks (should go away).
|
---|
457 | ifneq ($(KBUILD_TARGET),win)
|
---|
458 | src/HappyHttp.cpp_CXXFLAGS += -fexceptions
|
---|
459 | src/VBoxDownloaderWgt.cpp_CXXFLAGS += -fexceptions
|
---|
460 | src/VBoxNetworkFramework.cpp_CXXFLAGS += -fexceptions
|
---|
461 | endif
|
---|
462 | src/HappyHttp.cpp_CXXFLAGS.linux += -O2
|
---|
463 |
|
---|
464 | ## @todo how to detect what tool is used?
|
---|
465 | ## @todo GCC3 seems to lack -Wno-missing-base-class-initializer, so we use more generic -Wno-extra
|
---|
466 | ## @todo r=bird: see VirtualBox4.
|
---|
467 | ifdef VBOX_WITH_XPCOM
|
---|
468 | src/COMDefs.cpp_CXXFLAGS = $(VBOX_GCC_Wno-extra)
|
---|
469 | endif
|
---|
470 |
|
---|
471 |
|
---|
472 | #
|
---|
473 | # Other stuff
|
---|
474 | #
|
---|
475 | VBOX_WRAPPERS_FILE3 = $(PATH_VirtualBox)/include/COMWrappers.h
|
---|
476 | VirtualBox_BLDDIRS += $(PATH_VirtualBox)/include/
|
---|
477 | VirtualBox_INTERMEDIATES+= $(VBOX_WRAPPERS_FILE3)
|
---|
478 |
|
---|
479 | VBOX_WRAPPERS_INC_FILE3 := $(PATH_SUB_CURRENT)/include/COMDefs.h
|
---|
480 | VBOX_WRAPPERS_TEMPLATE3 := $(PATH_SUB_CURRENT)/include/COMWrappers.xsl
|
---|
481 | VBOX_WRAPPERS_XIDLFILE3 := $(PATH_SUB_CURRENT)/../../Main/idl/VirtualBox.xidl
|
---|
482 |
|
---|
483 |
|
---|
484 | # generated files we need to clean manually
|
---|
485 | OTHER_CLEAN += \
|
---|
486 | $(VirtualBox_GENSRCS) \
|
---|
487 | $(VirtualBox_GENHDRS) \
|
---|
488 | $(VBOX_WRAPPERS_FILE3) \
|
---|
489 | $(PATH_BIN)/vboxkeyboard3.tar.gz
|
---|
490 |
|
---|
491 |
|
---|
492 | #
|
---|
493 | # On Windows we'll have to generate/edit the resource file.
|
---|
494 | # The IDI_ICON1 name is Qt specific.
|
---|
495 | #
|
---|
496 | $(PATH_TARGET)/VirtualBox.rc: $(PATH_SUB_CURRENT)/Makefile.kmk $(VBOX_WINDOWS_ICON_FILE) | $$(call DIRDEP,$$(@D))
|
---|
497 | $(RM) -f $@
|
---|
498 | $(APPEND) $@ 'IDI_ICON1 ICON "$(subst /,\\,$(VBOX_WINDOWS_ICON_FILE))"'
|
---|
499 | $(CAT) $@
|
---|
500 |
|
---|
501 | OTHER_CLEAN.win += $(PATH_TARGET)/VirtualBox.rc
|
---|
502 |
|
---|
503 |
|
---|
504 | #
|
---|
505 | # On Mac OS X (darwin) we need to install icon resources and compulsory bundle contents.
|
---|
506 | #
|
---|
507 | INSTALLS.darwin += VirtualBox.app
|
---|
508 | VirtualBox.app_INST = $(INST_VIRTUALBOX)Contents/
|
---|
509 | VirtualBox.app_MODE = 644
|
---|
510 | VirtualBox.app_SOURCES = \
|
---|
511 | src/darwin/PkgInfo \
|
---|
512 | $(PATH_TARGET)/Info.plist \
|
---|
513 | $(VBOX_MACOSX_ICON_FILE)=>Resources/virtualbox.icns
|
---|
514 |
|
---|
515 | $(PATH_TARGET)/Info.plist: src/darwin/Info.plist $(VBOX_VERSION_MK) | $(call DIRDEP,$(PATH_TARGET))
|
---|
516 | $(call MSG_GENERATE,VirtualBox.app,$<,$@)
|
---|
517 | $(QUIET)$(RM) -f $@
|
---|
518 | $(QUIET)$(SED) \
|
---|
519 | -e 's/@VBOX_VERSION_STRING@/$(VBOX_VERSION_STRING)/g' \
|
---|
520 | -e 's/@VBOX_VERSION_MAJOR@/$(VBOX_VERSION_MAJOR)/g' \
|
---|
521 | -e 's/@VBOX_VERSION_MINOR@/$(VBOX_VERSION_MINOR)/g' \
|
---|
522 | -e 's/@VBOX_VERSION_BUILD@/$(VBOX_VERSION_BUILD)/g' \
|
---|
523 | $< > $@
|
---|
524 |
|
---|
525 | INSTALLS.darwin += VirtualBoxVM.app
|
---|
526 | VirtualBoxVM.app_INST = $(VirtualBox.app_INST)Resources/VirtualBoxVM.app/Contents/
|
---|
527 | VirtualBoxVM.app_MODE = 644
|
---|
528 | VirtualBoxVM.app_SOURCES = \
|
---|
529 | src/darwin/VM-PkgInfo=>PkgInfo \
|
---|
530 | $(PATH_TARGET)/VM-Info.plist=>Info.plist \
|
---|
531 | $(VBOX_MACOSX_ICON_FILE)=>Resources/virtualbox.icns
|
---|
532 | VirtualBoxVM.app_SYMLINKS = \
|
---|
533 | MacOS=>../../../MacOS/
|
---|
534 |
|
---|
535 | $(PATH_TARGET)/VM-Info.plist: src/darwin/VM-Info.plist $(VBOX_VERSION_MK) | $(call DIRDEP,$(PATH_TARGET))
|
---|
536 | $(call MSG_GENERATE,VirtualBoxVM.app,$<,$@)
|
---|
537 | $(QUIET)$(RM) -f $@
|
---|
538 | $(QUIET)$(SED) \
|
---|
539 | -e 's/@VBOX_VERSION_STRING@/$(VBOX_VERSION_STRING)/g' \
|
---|
540 | -e 's/@VBOX_VERSION_MAJOR@/$(VBOX_VERSION_MAJOR)/g' \
|
---|
541 | -e 's/@VBOX_VERSION_MINOR@/$(VBOX_VERSION_MINOR)/g' \
|
---|
542 | -e 's/@VBOX_VERSION_BUILD@/$(VBOX_VERSION_BUILD)/g' \
|
---|
543 | --output $@ $<
|
---|
544 |
|
---|
545 |
|
---|
546 | ifndef USE_KBUILD_QT3_UNIT
|
---|
547 | #
|
---|
548 | # Translation installation
|
---|
549 | #
|
---|
550 | VirtualBox.nls_INST = $(INST_BIN)nls3/
|
---|
551 | VirtualBox.nls_SOURCES = $(patsubst %.ts,$(PATH_VirtualBox)/nls/%.qm,$(notdir $(VirtualBox_QT_TRANSLATIONS)))
|
---|
552 | VirtualBox.nls_SOURCES += $(patsubst %.ts,$(PATH_VirtualBox)/nls/%.qm,$(notdir $(VirtualBox_QT_TRANSLATIONS_QT)))
|
---|
553 | VirtualBox.nls_MODE = 644
|
---|
554 | endif
|
---|
555 |
|
---|
556 |
|
---|
557 | ifdef VBOX_WITH_TESTCASES
|
---|
558 | #
|
---|
559 | # Testcase for the darwin keyboard routines.
|
---|
560 | #
|
---|
561 | PROGRAMS.darwin += tstDarwinKeyboard
|
---|
562 | tstDarwinKeyboard_TEMPLATE = VBOXR3TSTEXE
|
---|
563 | tstDarwinKeyboard_NAME = tstDarwinKeyboard3
|
---|
564 | tstDarwinKeyboard_INCS = include
|
---|
565 | tstDarwinKeyboard_SOURCES = \
|
---|
566 | src/darwin/tstDarwinKeyboard.cpp \
|
---|
567 | src/darwin/DarwinKeyboard.cpp
|
---|
568 | tstDarwinKeyboard_LDFLAGS = -framework IOKit -framework Carbon
|
---|
569 | tstDarwinKeyboard_LIBS = \
|
---|
570 | $(LIB_RUNTIME)
|
---|
571 | endif
|
---|
572 |
|
---|
573 |
|
---|
574 | #
|
---|
575 | # Restore / reset things to avoid possible conflicts with kBuild (VBoxUI.pro).
|
---|
576 | #
|
---|
577 | TEMPLATE := $(SAVED_TEMPLATE)
|
---|
578 | LANGUAGE :=
|
---|
579 | FORMS :=
|
---|
580 | TRANSLATIONS :=
|
---|
581 | IMAGES :=
|
---|
582 |
|
---|
583 |
|
---|
584 |
|
---|
585 | # Commit the magic.
|
---|
586 | # (note: before custom rules that make use of generated variables!).
|
---|
587 | include $(KBUILD_PATH)/footer.kmk
|
---|
588 |
|
---|
589 |
|
---|
590 |
|
---|
591 | ifndef USE_KBUILD_QT3_UNIT
|
---|
592 |
|
---|
593 | #
|
---|
594 | # Qt source file generation rules
|
---|
595 | #
|
---|
596 |
|
---|
597 | ## @todo move QT source generation macros to kBuild
|
---|
598 |
|
---|
599 | ## Generate a rule to create a MOC source file from a header containing
|
---|
600 | # classes that use the Q_OBJECT macro.
|
---|
601 | # @param $mochdr header file with Q_OBJECT
|
---|
602 | define def_qt_gen_src_moc
|
---|
603 |
|
---|
604 | $(eval mocsrc := $(PATH_$(target))/moc/moc_$(notdir $(basename $(mochdr))).cpp)
|
---|
605 |
|
---|
606 | $(target)_GENSRCS_REAL += $(mocsrc)
|
---|
607 |
|
---|
608 | $(mocsrc): $(mochdr)
|
---|
609 | $$(call MSG_TOOL,moc,$(target),$(mochdr),$$@)
|
---|
610 | $$(QUIET)$$(MKDIR) -p $$(@D)
|
---|
611 | $$(QUIET)$$(VBOX_MOC) $(mochdr) -o $$@
|
---|
612 |
|
---|
613 | endef
|
---|
614 |
|
---|
615 | ## Generate a rule to create a MOC include file from a source containing
|
---|
616 | # local classes that use the Q_OBJECT macro. This include is then included
|
---|
617 | # by that source, so it must be generated before the source gets compiled.
|
---|
618 | # @param $mocsrc source file with Q_OBJECT
|
---|
619 | define def_qt_gen_inc_moc
|
---|
620 |
|
---|
621 | $(eval mocobj := $(PATH_$(target)_$(mocsrc))/$(notdir $(basename $(mocsrc)))$(VBOX_SUFF_OBJ))
|
---|
622 | $(eval mocinc := $(PATH_$(target))/moc/$(notdir $(basename $(mocsrc))).moc)
|
---|
623 |
|
---|
624 | $(target)_GENHDRS_REAL += $(mocinc)
|
---|
625 | $(target)_INTERMEDIATES += $(mocinc)
|
---|
626 |
|
---|
627 | $(mocobj): $(mocinc)
|
---|
628 |
|
---|
629 | $(mocinc): $(mocsrc)
|
---|
630 | $$(call MSG_TOOL,moc,$(target),$(mocsrc),$$@)
|
---|
631 | $$(QUIET)$$(MKDIR) -p $$(@D)
|
---|
632 | $$(QUIET)$$(VBOX_MOC) -i $(mocsrc) -o $$@
|
---|
633 |
|
---|
634 | endef
|
---|
635 |
|
---|
636 | ## Generate a rule to create a MOC include file from a UI header (ui.h) containing
|
---|
637 | # local classes that use the Q_OBJECT macro. This include is then included
|
---|
638 | # by that header, so it must be generated before the UI source gets compiled.
|
---|
639 | # @param $mocuihdr UI header file with Q_OBJECT
|
---|
640 | define def_qt_gen_inc_mocuihdr
|
---|
641 |
|
---|
642 | $(eval uisrc := $(PATH_$(target))/ui/$(notdir $(basename $(basename $(mocuihdr)))).cpp)
|
---|
643 | $(eval mocuiinc := $(PATH_$(target))/moc/$(notdir $(basename $(mocuihdr))).moc)
|
---|
644 |
|
---|
645 | $(target)_GENHDRS_REAL += $(mocuiinc)
|
---|
646 | $(target)_INTERMEDIATES += $(mocuiinc)
|
---|
647 |
|
---|
648 | $(uisrc): $(mocuiinc)
|
---|
649 | $(mocuiinc): $(mocuihdr)
|
---|
650 | $$(call MSG_TOOL,moc,$(target),$(mocuihdr),$$@)
|
---|
651 | $$(QUIET)$$(MKDIR) -p $$(@D)
|
---|
652 | $$(QUIET)$$(VBOX_MOC) -i $(mocuihdr) -o $$@
|
---|
653 |
|
---|
654 | endef
|
---|
655 |
|
---|
656 | ## Generate a rule to create a header and source files from an UI
|
---|
657 | # definition source (.ui).
|
---|
658 | # @param $uifile UI definintion source file
|
---|
659 | define def_qt_gen_src_ui
|
---|
660 |
|
---|
661 | $(eval uihdr := $(PATH_$(target))/ui/$(notdir $(basename $(uifile))).h)
|
---|
662 | $(eval mocinc := $(PATH_$(target))/moc/$(notdir $(basename $(uifile))).moc)
|
---|
663 | $(eval uisrc := $(PATH_$(target))/ui/$(notdir $(basename $(uifile))).cpp)
|
---|
664 | $(eval mocsrc := $(PATH_$(target))/moc/moc_$(notdir $(basename $(uifile))).cpp)
|
---|
665 |
|
---|
666 | $(target)_GENSRCS_REAL += $(uisrc) $(mocsrc)
|
---|
667 | $(target)_GENHDRS_REAL += $(uihdr) $(mocinc)
|
---|
668 | $(target)_INTERMEDIATES += $(uihdr) $(mocinc)
|
---|
669 |
|
---|
670 | $(uihdr): $(uifile) | $$(call DIRDEP,$(dir $(uihdr)))
|
---|
671 | $$(call MSG_TOOL,uic,$(target),$(uifile),$$@)
|
---|
672 | $$(QUIET)$$(VBOX_UIC) $(uifile) -o $$@
|
---|
673 |
|
---|
674 | $(mocinc): $(uihdr) | $$(call DIRDEP,$(dir $(mocinc)))
|
---|
675 | $$(call MSG_TOOL,moc,$(target),$(uihdr),$$@)
|
---|
676 | $$(QUIET)$$(MKDIR) -p $$(@D)
|
---|
677 | $$(QUIET)$$(VBOX_MOC) -i $(uihdr) -o $$@
|
---|
678 |
|
---|
679 | $(uisrc): $(uihdr) $(uifile) $(mocinc) $(wildcard $(uifile).h) | $$(call DIRDEP,$(dir $(uisrc)))
|
---|
680 | $$(call MSG_TOOL,uic,$(target),$(uifile),$$@)
|
---|
681 | $$(QUIET)$$(VBOX_UIC) $(uifile) -i $(uihdr) -o $$@
|
---|
682 |
|
---|
683 | $(mocsrc): $(uihdr) $(mocinc) | $$(call DIRDEP,$(dir $(mocsrc)))
|
---|
684 | $$(call MSG_TOOL,moc,$(target),$(uihdr),$$@)
|
---|
685 | $$(QUIET)$$(VBOX_MOC) $(uihdr) -o $$@
|
---|
686 |
|
---|
687 | endef
|
---|
688 |
|
---|
689 | ## Generate a rule to create a .qm file from a NLS translation
|
---|
690 | # source (.ts).
|
---|
691 | # @param $tsfile Translation source file
|
---|
692 | define def_qt_gen_nls
|
---|
693 |
|
---|
694 | $(eval qmfile := $(PATH_$(target))/nls/$(notdir $(basename $(tsfile))).qm)
|
---|
695 |
|
---|
696 | OTHER_CLEAN += $(qmfile)
|
---|
697 |
|
---|
698 | # Note that we use -nocompress in lrelease to avoid stripping comments and
|
---|
699 | # other information from .qm files. If we don't do that, we get .qm files two
|
---|
700 | # times smaller, but QTranslator::findMessage() will start searching for
|
---|
701 | # translations in all existing contexts in case if it cannot find it in the
|
---|
702 | # original context (which is of course not acceptable, no matter if it's a
|
---|
703 | # special Qt "feature" or just a bug).
|
---|
704 |
|
---|
705 | $(qmfile): $(tsfile) | $$(call DIRDEP,$(dir $(qmfile)))
|
---|
706 | $$(call MSG_TOOLS,lrelease,$(target),$(tsfile),$$@)
|
---|
707 | $$(QUIET)$$(VBOX_LRELEASE) -nocompress $(tsfile) -qm $$@
|
---|
708 |
|
---|
709 | endef
|
---|
710 |
|
---|
711 | ## Generate rules for generating the Qt source for a target.
|
---|
712 | # @param $target Target name.
|
---|
713 | define def_qt_gen_src
|
---|
714 |
|
---|
715 | # moc srcs from hdrs with Q_OBJECT
|
---|
716 | $(foreach mochdr,$($(target)_QT_MOCHDRS),$(eval $(def_qt_gen_src_moc)))
|
---|
717 | # moc includes from srcs with Q_OBJECT
|
---|
718 | $(foreach mocsrc,$($(target)_QT_MOCSRCS),$(eval $(def_qt_gen_inc_moc)))
|
---|
719 | # moc includes from UI headers with Q_OBJECT
|
---|
720 | $(foreach mocuihdr,$($(target)_QT_MOCUIHDRS),$(eval $(def_qt_gen_inc_mocuihdr)))
|
---|
721 | # UI sources
|
---|
722 | $(foreach uifile,$($(target)_QT_UISRCS),$(eval $(def_qt_gen_src_ui)))
|
---|
723 | # NLS files
|
---|
724 | $(foreach tsfile,$($(target)_QT_TRANSLATIONS),$(eval $(def_qt_gen_nls)))
|
---|
725 | $(foreach tsfile,$($(target)_QT_TRANSLATIONS_QT),$(eval $(def_qt_gen_nls)))
|
---|
726 | # dirs
|
---|
727 | $$(call DIRDEP,$(PATH_$(target))/ui/) \
|
---|
728 | $$(call DIRDEP,$(PATH_$(target))/moc/) \
|
---|
729 | $$(call DIRDEP,$(PATH_$(target))/nls/):
|
---|
730 | $$(call MSG_MKDIR,$$@)
|
---|
731 | $$(QUIET)$$(MKDIR) -p $$@
|
---|
732 |
|
---|
733 | endef
|
---|
734 |
|
---|
735 | # Generate Qt source rules.
|
---|
736 | $(foreach target,VirtualBox,$(eval $(def_qt_gen_src)))
|
---|
737 |
|
---|
738 | endif # !USE_KBUILD_QT3_UNIT
|
---|
739 |
|
---|
740 | # static images imported from VBoxUI.pro as VirtualBox_QT_IMAGES
|
---|
741 | ## @todo figure out something for QT_IMAGES... (qt3 unit)
|
---|
742 | $(PATH_VirtualBox)/ui/vbox_image_collection.txt: VBoxUI.pro $(VirtualBox_QT_IMAGES) | $(call DIRDEP,$(PATH_VirtualBox)/ui)
|
---|
743 | $(RM) -f $@
|
---|
744 | $(APPEND) -v $@ VirtualBox_QT_IMAGES
|
---|
745 |
|
---|
746 | $(PATH_VirtualBox)/ui/vbox_image_collection.cpp: $(PATH_VirtualBox)/ui/vbox_image_collection.txt
|
---|
747 | $(call MSG_TOOL,uic,VirtualBox,$<,$@)
|
---|
748 | $(QUIET)$(VBOX_UIC) -o $@ -embed VBoxGUI -f $<
|
---|
749 |
|
---|
750 | VirtualBox_GENSRCS += $(PATH_VirtualBox)/ui/vbox_image_collection.cpp
|
---|
751 | OTHER_CLEAN += $(PATH_VirtualBox)/ui/vbox_image_collection.txt
|
---|
752 |
|
---|
753 |
|
---|
754 | #
|
---|
755 | # Generate COM Wrappers
|
---|
756 | #
|
---|
757 | $(VBOX_WRAPPERS_INC_FILE3): $(VBOX_WRAPPERS_FILE3)
|
---|
758 |
|
---|
759 | $(VBOX_WRAPPERS_FILE3): $(VBOX_WRAPPERS_XIDLFILE3) $(VBOX_WRAPPERS_TEMPLATE3) | $(call DIRDEP,$(PATH_VirtualBox)/include/)
|
---|
760 | $(call MSG_TOOL,xsltproc,VirtualBox,$<,$@)
|
---|
761 | $(QUIET)$(VBOX_XSLTPROC) -o $@ $(VBOX_WRAPPERS_TEMPLATE3) $<
|
---|
762 |
|
---|
763 | ifdef USE_KBUILD_QT3_UNIT
|
---|
764 | # alias for generating the COM Wrappers file.
|
---|
765 | testwrappers:: $(VBOX_WRAPPERS_FILE3)
|
---|
766 |
|
---|
767 |
|
---|
768 | #
|
---|
769 | # Update all known NLS translation (.ts) files in the nls/ subdirectory.
|
---|
770 | #
|
---|
771 | # NOTE: This target is intended to be run only by the GUI maintainer shortly
|
---|
772 | # before a new product release. VirtualBox_xx_YY.ts is a template for new
|
---|
773 | # languages and should never be actually translated or installed.
|
---|
774 | #
|
---|
775 | updatenls:: \
|
---|
776 | $(VirtualBox4_SOURCES) \
|
---|
777 | $(wildcard include/*.h)
|
---|
778 | $(call MSG_L1,lupdate all languages (nls/*.ts))
|
---|
779 | $(QUIET)$(TOOL_QT3_LUPDATE) \
|
---|
780 | $^ \
|
---|
781 | -ts \
|
---|
782 | $(filter-out nls/qt_%.ts,$(VirtualBox4_QT_TRANSLATIONS)) \
|
---|
783 | nls/VirtualBox_xx_YY.ts
|
---|
784 |
|
---|
785 |
|
---|
786 |
|
---|
787 |
|
---|
788 | else # !USE_KBUILD_QT3_UNIT
|
---|
789 |
|
---|
790 | #
|
---|
791 | # Hand made dependencies go here.
|
---|
792 | # Basically, here are dependencies for generated UI source files that
|
---|
793 | # include generated headers in turn.
|
---|
794 | #
|
---|
795 |
|
---|
796 | $(PATH_VirtualBox)/ui/VBoxDiskImageManagerDlg.cpp: \
|
---|
797 | $(PATH_VirtualBox)/ui/VBoxNewHDWzd.h
|
---|
798 |
|
---|
799 | # Make all generated UI sources dependent on all generated headers (since they
|
---|
800 | # may include them). This is safer than indifidual dependencies above but
|
---|
801 | # currently disabled, because will cause all UI sources to be rebuilt one a
|
---|
802 | # single one changes.
|
---|
803 | #$(patsubst %,$(PATH_VirtualBox)/ui/%.cpp,$(notdir $(basename $(VirtualBox_QT_UISRCS)))) : $(VirtualBox_GENHDRS)
|
---|
804 |
|
---|
805 |
|
---|
806 |
|
---|
807 |
|
---|
808 | #
|
---|
809 | # Custom targets
|
---|
810 | #
|
---|
811 |
|
---|
812 | # Update all known NLS translation (.ts) files in the nls/ subdirectory.
|
---|
813 | # NOTE: This target is intened to be run only by the GUI maintainer shortly
|
---|
814 | # before a new product release. VirtualBox_xx_YY.ts is a template for new
|
---|
815 | # languages and should never be actually translated or installed.
|
---|
816 | updatenls: $(VirtualBox_SOURCES) $(VirtualBox_HEADERS)
|
---|
817 | $(call MSG_L1,lupdate all languages (nls/*.ts))
|
---|
818 | $(QUIET)$(VBOX_LUPDATE) $^ -ts $(VirtualBox_QT_TRANSLATIONS) nls/VirtualBox_xx_YY.ts
|
---|
819 |
|
---|
820 |
|
---|
821 |
|
---|
822 | #
|
---|
823 | # Test targets
|
---|
824 | #
|
---|
825 |
|
---|
826 | test:
|
---|
827 | @echo ====================
|
---|
828 | @echo $(VirtualBox_GENSRCS) | $(SED) -e "s/ /\n/g"
|
---|
829 | @echo --------------------
|
---|
830 | @echo $(VirtualBox_GENSRCS_REAL) | $(SED) -e "s/ /\n/g"
|
---|
831 | @echo ====================
|
---|
832 | @echo $(VirtualBox_GENHDRS) | $(SED) -e "s/ /\n/g"
|
---|
833 | @echo --------------------
|
---|
834 | @echo $(VirtualBox_GENHDRS_REAL) | $(SED) -e "s/ /\n/g"
|
---|
835 | @echo ====================
|
---|
836 |
|
---|
837 | test2:
|
---|
838 | @echo $(OTHER_CLEAN) | $(SED) -e "s/ /\n/g"
|
---|
839 |
|
---|
840 | test3:
|
---|
841 | @echo $(VirtualBox_HEADERS) | $(SED) -e "s/ /\n/g"
|
---|
842 |
|
---|
843 | testwrappers: $(VBOX_WRAPPERS_FILE3)
|
---|
844 |
|
---|
845 | endif # !USE_KBUILD_QT3_UNIT
|
---|
846 |
|
---|