VirtualBox

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

Last change on this file since 4584 was 4584, checked in by vboxsync, 17 years ago

bin/VirtualBox predepends License-n.n.html

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 17.2 KB
Line 
1# $Id: Makefile.kmk 4584 2007-09-06 15:52:15Z vboxsync $
2## @file
3# Makefile for the VirtualBox Qt GUI.
4#
5
6#
7# Copyright (C) 2006-2007 innotek GmbH
8#
9# This file is part of VirtualBox Open Source Edition (OSE), as
10# available from http://www.virtualbox.org. This file is free software;
11# you can redistribute it and/or modify it under the terms of the GNU
12# General Public License as published by the Free Software Foundation,
13# in version 2 as it comes in the "COPYING" file of the VirtualBox OSE
14# distribution. VirtualBox OSE is distributed in the hope that it will
15# be useful, but WITHOUT ANY WARRANTY of any kind.
16
17# include qmake project file
18include VBoxUI.pro
19
20# Import QDesigner UI sources
21VirtualBox_QT_UISRCS := $(FORMS)
22# Import translation sources
23VirtualBox_QT_TRANSLATIONS := $(TRANSLATIONS)
24# Import images
25VirtualBox_QT_IMAGES := $(IMAGES)
26
27# reset things to avoid possible conflicts with kBuild
28TEMPLATE :=
29LANGUAGE :=
30FORMS :=
31TRANSLATIONS :=
32IMAGES :=
33
34DEPTH = ../../../..
35include $(PATH_KBUILD)/header.kmk
36
37PROGRAMS = VirtualBox
38DLLS.linux = VBoxKeyboard
39
40INSTALLS = VirtualBox.nls
41
42VBoxKeyboard_TEMPLATE = VBOXR3
43VBoxKeyboard_SOURCES = \
44 src/linux/keyboard.c
45
46VirtualBox_TEMPLATE = VBOXQTGUIEXE
47VirtualBox_SDKS.win = WINPSDK DXSDK
48VirtualBox_SDKS.linux = LIBSDL
49VirtualBox_SDKS.os2 = LIBSDL
50
51ifeq ($(BUILD_TARGET),darwin)
52# For the launch trick we need different inode numbers.
53VirtualBox_INST = $(INST_BIN)VirtualBox $(INST_BIN)VirtualBoxVM
54endif
55
56ifeq ($(BUILD_TARGET),linux)
57$(PATH_BIN)/VirtualBox: $(VBOX_LICENSE_BIN)
58endif
59
60# Each nls/VirtualBox_xx_YY.ts file must have a qt_xx_YY.ts counterpart
61VirtualBox_QT_TRANSLATIONS_QT := \
62 $(patsubst nls/VirtualBox_%.ts,nls/qt_%.ts,\
63 $(filter nls/VirtualBox_%.ts,$(VirtualBox_QT_TRANSLATIONS)))
64
65# QDesigner UI sources are imported from VBoxUI.pro as VirtualBox_QT_UISRC
66
67# Headers containing definitions of classes that use the Q_OBJECT macro
68VirtualBox_QT_MOCHDRS = \
69 include/QIWidgetValidator.h \
70 include/QIHotKeyEdit.h \
71 include/QIStatusBar.h \
72 include/QIStateIndicator.h \
73 include/QIMessageBox.h \
74 include/QIRichLabel.h \
75 include/VBoxGlobalSettings.h \
76 include/VBoxUtils.h \
77 include/VBoxGlobal.h \
78 include/VBoxVMListBox.h \
79 include/VBoxMediaComboBox.h \
80 include/VBoxSelectorWnd.h \
81 include/VBoxConsoleWnd.h \
82 include/VBoxConsoleView.h \
83 include/VBoxProblemReporter.h \
84 include/VBoxDownloaderWgt.h
85
86# Sources containing local definitions of classes that use the Q_OBJECT macro
87VirtualBox_QT_MOCSRCS = src/VBoxSelectorWnd.cpp
88ifeq ($(BUILD_TARGET),linux)
89VirtualBox_QT_MOCSRCS += src/VBoxGlobal.cpp
90endif
91ifdef VBOX_WITH_XPCOM
92VirtualBox_QT_MOCSRCS += src/COMDefs.cpp
93endif
94
95# UI headers (ui.h) containing local definitions of classes that use the Q_OBJECT macro
96VirtualBox_QT_MOCUIHDRS = \
97 ui/VBoxVMSettingsDlg.ui.h \
98 ui/VBoxVMLogViewer.ui.h \
99 ui/VBoxSharedFoldersSettings.ui.h
100
101
102# All generated sources. Note: this list MUST be in sync with Qt source
103# generation rules defined somewhere below!
104VirtualBox_GENSRCS = \
105 $(foreach moc,$(notdir $(basename $(VirtualBox_QT_MOCHDRS))), $(PATH_VirtualBox)/moc/moc_$(moc).cpp) \
106 $(foreach ui,$(notdir $(basename $(VirtualBox_QT_UISRCS))), $(PATH_VirtualBox)/ui/$(ui).cpp $(PATH_VirtualBox)/moc/moc_$(ui).cpp) \
107 $(PATH_VirtualBox)/ui/vbox_image_collection.cpp
108
109# All generated headers. Note: this list MUST be in sync with Qt source
110# generation rules defined somewhere below!
111VirtualBox_GENHDRS = \
112 $(foreach mocui,$(notdir $(basename $(VirtualBox_QT_MOCUIHDRS))), $(PATH_VirtualBox)/moc/$(mocui).moc) \
113 $(foreach moc,$(notdir $(basename $(VirtualBox_QT_MOCSRCS))), $(PATH_VirtualBox)/moc/$(moc).moc) \
114 $(foreach ui,$(notdir $(basename $(VirtualBox_QT_UISRCS))), $(PATH_VirtualBox)/ui/$(ui).h)
115
116# All existing .ui.h files for known .ui sources
117VirtualBox_QT_UIHDRS = \
118 $(wildcard $(addsuffix .h,$(VirtualBox_QT_UISRCS)))
119
120# All header files
121VirtualBox_HEADERS = \
122 $(wildcard include/*.h) \
123 $(VirtualBox_GENHDRS) \
124 $(VirtualBox_QT_UIHDRS)
125
126
127VirtualBox_SOURCES = \
128 $(VirtualBox_GENSRCS) \
129 src/main.cpp \
130 src/COMDefs.cpp \
131 src/QIWidgetValidator.cpp \
132 src/QIHotKeyEdit.cpp \
133 src/QIStateIndicator.cpp \
134 src/QIStatusBar.cpp \
135 src/QIMessageBox.cpp \
136 src/QIRichLabel.cpp \
137 src/VBoxDefs.cpp \
138 src/VBoxGlobalSettings.cpp \
139 src/VBoxGlobal.cpp \
140 src/VBoxMediaComboBox.cpp \
141 src/VBoxProblemReporter.cpp \
142 src/VBoxSelectorWnd.cpp \
143 src/VBoxConsoleView.cpp \
144 src/VBoxConsoleWnd.cpp \
145 src/VBoxDownloaderWgt.cpp \
146 src/VBoxVMListBox.cpp \
147 src/VBoxFrameBuffer.cpp \
148 src/HappyHttp.cpp
149
150VirtualBox_SOURCES.win += \
151 src/win32/VirtualBox.rc
152
153VirtualBox_SOURCES.win += \
154 src/VBoxFBDDRAW.cpp
155
156VirtualBox_SOURCES.linux = \
157 src/linux/XKeyboard.cpp
158
159VirtualBox_SOURCES.darwin = \
160 src/darwin/DarwinKeyboard.cpp \
161 src/darwin/DarwinCursor.cpp \
162 src/darwin/VBoxAquaStyle.cpp \
163 src/darwin/VBoxUtils-darwin.cpp
164
165src/HappyHttp.cpp_CXXFLAGS.linux += -fexceptions -O2
166src/HappyHttp.cpp_CXXFLAGS.darwin += -fexceptions
167src/HappyHttp.cpp_CXXFLAGS.os2 += -fexceptions
168src/VBoxDownloaderWgt.cpp_CXXFLAGS.linux += -fexceptions
169src/VBoxDownloaderWgt.cpp_CXXFLAGS.darwin += -fexceptions
170src/VBoxDownloaderWgt.cpp_CXXFLAGS.os2 += -fexceptions
171
172## @todo how to detect what tool is used?
173## @todo GCC3 seems to lack -Wno-missing-base-class-initializer, so we use
174# more generic -Wno-extra
175ifdef VBOX_WITH_XPCOM
176src/COMDefs.cpp_CXXFLAGS = $(VBOX_GCC_Wno-extra)
177endif
178
179VirtualBox_DEFS = VBOX_GUI_SEPARATE_VM_PROCESS
180VirtualBox_DEFS.debug = VBOX_GUI_DEBUG VBOX_CHECK_STATE # QT_FATAL_ASSERT
181VirtualBox_DEFS.darwin = VBOX_GUI_USE_QIMAGE VBOX_WITHOUT_QHTTP
182VirtualBox_DEFS.linux = VBOX_GUI_USE_SDL
183VirtualBox_DEFS.win = VBOX_GUI_USE_QIMAGE UNICODE QT_DLL
184VirtualBox_DEFS.win.amd64 = VBOX_WITHOUT_QHTTP
185VirtualBox_DEFS.os2 = VBOX_GUI_USE_QIMAGE VBOX_GUI_USE_SDL QT_DLL
186#ifndef VBOX_OSE
187 VirtualBox_DEFS.darwin += VBOX_WITH_HACKED_QT
188#endif
189ifneq ($(BUILD_TYPE),release)
190 # non-release builds has some extra features.
191 VirtualBox_DEFS += VBOX_GUI_USE_REFRESH_TIMER
192 VirtualBox_DEFS.win += VBOX_GUI_USE_DDRAW
193 VirtualBox_DEFS.linux += VBOX_GUI_USE_QIMAGE
194endif
195ifdef VBOX_WITH_ALSA
196 VirtualBox_DEFS += VBOX_WITH_ALSA
197endif
198ifdef VBOX_OSE
199 VirtualBox_DEFS += VBOX_OSE
200endif
201ifdef VBOX_WITH_DEBUGGER_GUI
202 VirtualBox_DEFS += VBOX_WITH_DEBUGGER_GUI_MENU
203endif
204
205VirtualBox_INCS = \
206 ./include \
207 $(PATH_VirtualBox)/ui \
208 $(PATH_VirtualBox)/moc \
209 $(PATH_VirtualBox)/include \
210
211
212ifeq ($(BUILD_TYPE),release)
213 VirtualBox_LDFLAGS.win += /SUBSYSTEM:windows
214else
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
221endif
222VirtualBox_LDFLAGS.darwin = -framework IOKit
223VirtualBox_LIBS.win = \
224 $(PATH_SDK_WINPSDK_LIB)/Htmlhelp.Lib \
225 $(PATH_SDK_DXSDK_LIB)/ddraw.lib \
226 $(PATH_SDK_DXSDK_LIB)/dxguid.lib
227VirtualBox_LIBS.linux = $(PATH_DLL)/VBoxKeyboard$(VBOX_SUFF_DLL)
228
229
230ifdef VBOX_WITH_DEBUGGER_GUI
231 ifeq ($(BUILD_TARGET),win)
232 VirtualBox_LIBS += $(PATH_LIB)/VBoxDbg$(VBOX_SUFF_LIB)
233 else
234 VirtualBox_LIBS += $(PATH_DLL)/VBoxDbg$(VBOX_SUFF_DLL)
235 endif
236endif
237
238WRAPPERSFILE = $(PATH_VirtualBox)/include/COMWrappers.h
239WRAPPERSINCFILE = include/COMDefs.h
240WRAPPERSTEMPLATE = include/COMWrappers.xsl
241XIDLFILE = ../../Main/idl/VirtualBox.xidl
242
243
244# generated files we need to clean manually
245OTHER_CLEAN = \
246 $(VirtualBox_GENSRCS) \
247 $(VirtualBox_GENHDRS) \
248 $(WRAPPERSFILE)
249
250
251#
252# On Mac OS X (darwin) we need to install icon resources and compusory bundle contents.
253#
254INSTALLS.darwin += VirtualBox.app
255VirtualBox.app_INST = $(INST_VIRTUALBOX)Contents/
256VirtualBox.app_MODE = 644
257VirtualBox.app_SOURCES = \
258 src/darwin/PkgInfo \
259 $(PATH_TARGET)/Info.plist \
260 images/VirtualBox.icns=>Resources/virtualbox.icns
261
262$(PATH_TARGET)/Info.plist: src/darwin/Info.plist $(VBOX_VERSION_MK) | $(call DIRDEP,$(PATH_TARGET))
263 $(call MSG_GENERATE,VirtualBox.app,$<,$@)
264 $(QUIET)$(RM) -f $@
265 $(QUIET)$(SED) \
266 -e 's/@VBOX_VERSION_STRING@/$(VBOX_VERSION_STRING)/g' \
267 -e 's/@VBOX_VERSION_MAJOR@/$(VBOX_VERSION_MAJOR)/g' \
268 -e 's/@VBOX_VERSION_MINOR@/$(VBOX_VERSION_MINOR)/g' \
269 -e 's/@VBOX_VERSION_BUILD@/$(VBOX_VERSION_BUILD)/g' \
270 $< > $@
271
272INSTALLS.darwin += VirtualBoxVM.app
273VirtualBoxVM.app_INST = $(VirtualBox.app_INST)Resources/VirtualBoxVM.app/Contents/
274VirtualBoxVM.app_MODE = 644
275VirtualBoxVM.app_SOURCES = \
276 src/darwin/VM-PkgInfo=>PkgInfo \
277 $(PATH_TARGET)/VM-Info.plist=>Info.plist \
278 images/VirtualBox.icns=>Resources/virtualbox.icns
279VirtualBoxVM.app_SYMLINKS = \
280 MacOS=>../../../MacOS/
281
282$(PATH_TARGET)/VM-Info.plist: src/darwin/VM-Info.plist $(VBOX_VERSION_MK) | $(call DIRDEP,$(PATH_TARGET))
283 $(call MSG_GENERATE,VirtualBoxVM.app,$<,$@)
284 $(QUIET)$(RM) -f $@
285 $(QUIET)$(SED) \
286 -e 's/@VBOX_VERSION_STRING@/$(VBOX_VERSION_STRING)/g' \
287 -e 's/@VBOX_VERSION_MAJOR@/$(VBOX_VERSION_MAJOR)/g' \
288 -e 's/@VBOX_VERSION_MINOR@/$(VBOX_VERSION_MINOR)/g' \
289 -e 's/@VBOX_VERSION_BUILD@/$(VBOX_VERSION_BUILD)/g' \
290 $< > $@
291
292#
293# Translation installation
294#
295
296VirtualBox.nls_INST = $(INST_BIN)nls/
297VirtualBox.nls_SOURCES = $(patsubst %.ts,$(PATH_VirtualBox)/nls/%.qm,$(notdir $(VirtualBox_QT_TRANSLATIONS)))
298VirtualBox.nls_SOURCES += $(patsubst %.ts,$(PATH_VirtualBox)/nls/%.qm,$(notdir $(VirtualBox_QT_TRANSLATIONS_QT)))
299VirtualBox.nls_MODE = 644
300
301
302#
303# Testcase for the darwin keyboard routines.
304#
305ifdef VBOX_WITH_TESTCASES
306PROGRAMS.darwin += tstDarwinKeyboard
307tstDarwinKeyboard_TEMPLATE = VBOXR3TSTEXE
308tstDarwinKeyboard_INCS = include
309tstDarwinKeyboard_SOURCES = \
310 src/darwin/tstDarwinKeyboard.cpp \
311 src/darwin/DarwinKeyboard.cpp
312tstDarwinKeyboard_LDFLAGS = -framework IOKit -framework Carbon
313tstDarwinKeyboard_LIBS = \
314 $(LIB_RUNTIME)
315endif
316
317
318
319# Commit the magic.
320# (note: before custom rules that make usage of generated variables!).
321include $(PATH_KBUILD)/footer.kmk
322
323
324
325#
326# Qt source file generation rules
327#
328
329## @todo move QT source generation macros to kBuild
330
331## Generate a rule to create a MOC source file from a header containing
332# classes that use the Q_OBJECT macro.
333# @param $mochdr header file with Q_OBJECT
334define def_qt_gen_src_moc
335
336$(eval mocsrc := $(PATH_$(target))/moc/moc_$(notdir $(basename $(mochdr))).cpp)
337
338$(target)_GENSRCS_REAL += $(mocsrc)
339
340$(mocsrc): $(mochdr)
341 $$(call MSG_TOOL,moc,$(target),$(mochdr),$$@)
342 $$(QUIET)$$(MKDIR) -p $$(@D)
343 $$(QUIET)$$(VBOX_MOC) $(mochdr) -o $$@
344
345endef
346
347## Generate a rule to create a MOC include file from a source containing
348# local classes that use the Q_OBJECT macro. This include is then included
349# by that source, so it must be generated before the source gets compiled.
350# @param $mocsrc source file with Q_OBJECT
351define def_qt_gen_inc_moc
352
353$(eval mocobj := $(PATH_$(target)_$(mocsrc))/$(notdir $(basename $(mocsrc)))$(VBOX_SUFF_OBJ))
354$(eval mocinc := $(PATH_$(target))/moc/$(notdir $(basename $(mocsrc))).moc)
355
356$(target)_GENHDRS_REAL += $(mocinc)
357
358$(mocobj): $(mocinc)
359
360.NOTPARALLEL: $(mocinc)
361$(mocinc): $(mocsrc)
362 $$(call MSG_TOOL,moc,$(target),$(mocsrc),$$@)
363 $$(QUIET)$$(MKDIR) -p $$(@D)
364 $$(QUIET)$$(VBOX_MOC) -i $(mocsrc) -o $$@
365
366endef
367
368## Generate a rule to create a MOC include file from a UI header (ui.h) containing
369# local classes that use the Q_OBJECT macro. This include is then included
370# by that header, so it must be generated before the UI source gets compiled.
371# @param $mocuihdr UI header file with Q_OBJECT
372define def_qt_gen_inc_mocuihdr
373
374$(eval uisrc := $(PATH_$(target))/ui/$(notdir $(basename $(basename $(mocuihdr)))).cpp)
375$(eval uiobj := $(PATH_$(target)_$$(uisrc))/$(notdir $(basename $$(uisrc)))$(VBOX_SUFF_OBJ))
376$(eval mocuiinc := $(PATH_$(target))/moc/$(notdir $(basename $(mocuihdr))).moc)
377
378$(target)_GENHDRS_REAL += $(mocuiinc)
379
380.NOTPARALLEL: $(mocuiinc)
381$(uisrc): $(mocuiinc)
382$(mocuiinc): $(mocuihdr)
383 $$(call MSG_TOOL,moc,$(target),$(mocuihdr),$$@)
384 $$(QUIET)$$(MKDIR) -p $$(@D)
385 $$(QUIET)$$(VBOX_MOC) -i $(mocuihdr) -o $$@
386
387endef
388
389## Generate a rule to create a header and source files from an UI
390# definition source (.ui).
391# @param $uifile UI definintion source file
392define def_qt_gen_src_ui
393
394$(eval uisrc := $(PATH_$(target))/ui/$(notdir $(basename $(uifile))).cpp)
395$(eval uihdr := $(PATH_$(target))/ui/$(notdir $(basename $(uifile))).h)
396$(eval mocsrc := $(PATH_$(target))/moc/moc_$(notdir $(basename $(uifile))).cpp)
397
398$(target)_GENSRCS_REAL += $(uisrc) $(mocsrc)
399$(target)_GENHDRS_REAL += $(uihdr)
400
401.NOTPARALLEL: $(uihdr)
402$(uihdr): $(uifile) | $$(call DIRDEP,$(dir $(uihdr)))
403 $$(call MSG_TOOL,uic,$(target),$(uifile),$$@)
404 $$(QUIET)$$(VBOX_UIC) $(uifile) -o $$@
405
406$(uisrc): $(uihdr) $(uifile) $(wildcard $(uifile).h) | $$(call DIRDEP,$(dir $(uisrc)))
407 $$(call MSG_TOOL,uic,$(target),$(uifile),$$@)
408 $$(QUIET)$$(VBOX_UIC) $(uifile) -i $(uihdr) -o $$@
409
410$(mocsrc): $(uihdr) | $$(call DIRDEP,$(dir $(mocsrc)))
411 $$(call MSG_TOOL,moc,$(target),$(uihdr),$$@)
412 $$(QUIET)$$(VBOX_MOC) $(uihdr) -o $$@
413
414endef
415
416## Generate a rule to create a .qm file from a NLS translation
417# source (.ts).
418# @param $tsfile Translation source file
419define def_qt_gen_nls
420
421$(eval qmfile := $(PATH_$(target))/nls/$(notdir $(basename $(tsfile))).qm)
422
423OTHER_CLEAN += $(qmfile)
424
425# Note that we use -nocompress in lrelease to avoid stripping comments and
426# other information from .qm files. If we don't do that, we get .qm files two
427# times smaller, but QTranslator::findMessage() will start searching for
428# translations in all existing contexts in case if it cannot find it in the
429# original context (which is of course not acceptable, no matter if it's a
430# special Qt "feature" or just a bug).
431
432$(qmfile): $(tsfile) | $$(call DIRDEP,$(dir $(qmfile)))
433 $$(call MSG_TOOLS,lrelease,$(target),$(tsfile),$$@)
434 $$(QUIET)$$(VBOX_LRELEASE) -nocompress $(tsfile) -qm $$@
435
436endef
437
438## Generate rules for generating the Qt source for a target.
439# @param $target Target name.
440define def_qt_gen_src
441
442# moc srcs from hdrs with Q_OBJECT
443$(foreach mochdr,$($(target)_QT_MOCHDRS),$(eval $(def_qt_gen_src_moc)))
444# moc includes from srcs with Q_OBJECT
445$(foreach mocsrc,$($(target)_QT_MOCSRCS),$(eval $(def_qt_gen_inc_moc)))
446# moc includes from UI headers with Q_OBJECT
447$(foreach mocuihdr,$($(target)_QT_MOCUIHDRS),$(eval $(def_qt_gen_inc_mocuihdr)))
448# UI sources
449$(foreach uifile,$($(target)_QT_UISRCS),$(eval $(def_qt_gen_src_ui)))
450# NLS files
451$(foreach tsfile,$($(target)_QT_TRANSLATIONS),$(eval $(def_qt_gen_nls)))
452$(foreach tsfile,$($(target)_QT_TRANSLATIONS_QT),$(eval $(def_qt_gen_nls)))
453# dirs
454$$(call DIRDEP,$(PATH_$(target))/ui/) \
455$$(call DIRDEP,$(PATH_$(target))/moc/) \
456$$(call DIRDEP,$(PATH_$(target))/nls/):
457 $$(call MSG_MKDIR,$$@)
458 $$(QUIET)$$(MKDIR) -p $$@
459
460endef
461
462# Generate Qt source rules.
463$(foreach target,VirtualBox,$(eval $(def_qt_gen_src)))
464
465
466# Generate COM Wrappers
467.NOTPARALLEL: $(WRAPPERSFILE) $(WRAPPERSINCFILE)
468
469$(WRAPPERSINCFILE): $(WRAPPERSFILE)
470
471$(WRAPPERSFILE): $(XIDLFILE) $(WRAPPERSTEMPLATE) | $(call DIRDEP,$(PATH_VirtualBox)/include/)
472 $(call MSG_TOOL,xsltproc,VirtualBox,$<,$@)
473 $(QUIET)$(VBOX_XSLTPROC) -o $@ $(WRAPPERSTEMPLATE) $<
474
475$(call DIRDEP,$(PATH_VirtualBox)/include/):
476 $(call MSG_MKDIR,$@)
477 $(QUIET)$(MKDIR) -p $@
478
479# this is actually necessary only for Win32 target with disabled dependencies
480define def_wrapper_deps
481$(src): $(WRAPPERSFILE) $(WRAPPERSINCFILE)
482endef
483
484$(foreach src,$(VirtualBox_SOURCES),$(eval $(def_wrapper_deps)))
485
486# static images imported from VBoxUI.pro as VirtualBox_QT_IMAGES
487
488$(PATH_VirtualBox)/ui/vbox_image_collection.txt: VBoxUI.pro $(VirtualBox_QT_IMAGES)
489 @echo " \
490 $(VirtualBox_QT_IMAGES) \
491 " > $@
492
493$(PATH_VirtualBox)/ui/vbox_image_collection.cpp: $(PATH_VirtualBox)/ui/vbox_image_collection.txt
494 $(call MSG_TOOL,uic,VirtualBox,$<,$@)
495 $(QUIET)$(VBOX_UIC) -o $@ -embed VBoxGUI -f $<
496
497VirtualBox_GENSRCS += $(PATH_VirtualBox)/ui/vbox_image_collection.cpp
498OTHER_CLEAN += $(PATH_VirtualBox)/ui/vbox_image_collection.txt
499
500
501#
502# Hand made dependencies go here.
503# Basically, here are dependencies for generated UI source files that
504# include generated headers in turn.
505#
506
507$(PATH_VirtualBox)/ui/VBoxDiskImageManagerDlg.cpp: \
508 $(PATH_VirtualBox)/ui/VBoxNewHDWzd.h
509
510# Make all generated UI sources dependent on all generated headers (since they
511# may include them). This is safer than indifidual dependencies above but
512# currently disabled, because will cause all UI sources to be rebuilt one a
513# single one changes.
514#$(patsubst %,$(PATH_VirtualBox)/ui/%.cpp,$(notdir $(basename $(VirtualBox_QT_UISRCS)))) : $(VirtualBox_GENHDRS)
515
516
517#
518# Custom targets
519#
520
521# Update all known NLS translation (.ts) files in the nls/ subdirectory.
522# NOTE: This target is intened to be run only by the GUI maintainer shortly
523# before a new product release. VirtualBox_xx_YY.ts is a template for new
524# languages and should never be actually translated or installed.
525updatenls: $(VirtualBox_SOURCES) $(VirtualBox_HEADERS)
526 $(call MSG_L1,lupdate all languages (nls/*.ts))
527 $(QUIET)$(VBOX_LUPDATE) $^ -ts $(VirtualBox_QT_TRANSLATIONS) nls/VirtualBox_xx_YY.ts
528
529
530#
531# Test targets
532#
533
534test:
535 @echo ====================
536 @echo $(VirtualBox_GENSRCS) | $(SED) -e "s/ /\n/g"
537 @echo --------------------
538 @echo $(VirtualBox_GENSRCS_REAL) | $(SED) -e "s/ /\n/g"
539 @echo ====================
540 @echo $(VirtualBox_GENHDRS) | $(SED) -e "s/ /\n/g"
541 @echo --------------------
542 @echo $(VirtualBox_GENHDRS_REAL) | $(SED) -e "s/ /\n/g"
543 @echo ====================
544
545test2:
546 @echo $(OTHER_CLEAN) | $(SED) -e "s/ /\n/g"
547
548test3:
549 @echo $(VirtualBox_HEADERS) | $(SED) -e "s/ /\n/g"
550
551testwrappers: $(WRAPPERSFILE)
552
Note: See TracBrowser for help on using the repository browser.

© 2023 Oracle
ContactPrivacy policyTerms of Use