1 | # $Id: Makefile.kmk 37289 2011-06-01 11:59:23Z vboxsync $
|
---|
2 | ## @file
|
---|
3 | # Makefile for the Windows installer.
|
---|
4 | #
|
---|
5 |
|
---|
6 | #
|
---|
7 | # Copyright (C) 2006-2011 Oracle Corporation
|
---|
8 | #
|
---|
9 | # This file is part of VirtualBox Open Source Edition (OSE), as
|
---|
10 | # available from http://www.virtualbox.org. This file is free software;
|
---|
11 | # you can redistribute it and/or modify it under the terms of the GNU
|
---|
12 | # General Public License (GPL) as published by the Free Software
|
---|
13 | # Foundation, in version 2 as it comes in the "COPYING" file of the
|
---|
14 | # VirtualBox OSE distribution. VirtualBox OSE is distributed in the
|
---|
15 | # hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
|
---|
16 | #
|
---|
17 |
|
---|
18 | SUB_DEPTH = ../../../..
|
---|
19 | include $(KBUILD_PATH)/subheader.kmk
|
---|
20 |
|
---|
21 | ifneq ($(KBUILD_HOST),win)
|
---|
22 | $(error "The Windows installer can only be built on Windows!")
|
---|
23 | endif
|
---|
24 |
|
---|
25 |
|
---|
26 | #
|
---|
27 | # Include Sub-Makefiles.
|
---|
28 | #
|
---|
29 | include $(PATH_SUB_CURRENT)/InstallHelper/Makefile.kmk
|
---|
30 |
|
---|
31 | ifdef VBOX_WITH_BUNDLED_INSTALLER
|
---|
32 | ifeq ($(KBUILD_TARGET_ARCH),x86)
|
---|
33 | include $(PATH_SUB_CURRENT)/BundleMachine/Makefile.kmk
|
---|
34 | endif
|
---|
35 | endif
|
---|
36 |
|
---|
37 | ifeq ($(KBUILD_TARGET_ARCH),x86)
|
---|
38 | include $(PATH_SUB_CURRENT)/Stub/Makefile.kmk
|
---|
39 | include $(PATH_SUB_CURRENT)/StubBld/Makefile.kmk
|
---|
40 | ifdef VBOX_BRAND_WIN_AS_MENU
|
---|
41 | include $(PATH_SUB_CURRENT)/AutoStartMenu/Makefile.kmk
|
---|
42 | endif
|
---|
43 | endif
|
---|
44 |
|
---|
45 | include $(PATH_SUB_CURRENT)/Resources/Makefile.kmk
|
---|
46 |
|
---|
47 |
|
---|
48 | #
|
---|
49 | # Globals and targets.
|
---|
50 | #
|
---|
51 | VBOX_INSTALLER_LANGUAGES = en_US
|
---|
52 | VBOX_INSTALLER_LANGUAGES += $(VBOX_INSTALLER_ADD_LANGUAGES)
|
---|
53 |
|
---|
54 | VBOX_PATH_WIN_INST_SRC := $(PATH_SUB_CURRENT)
|
---|
55 | VBOX_WIN_INST_OUT_DIR := $(PATH_TARGET)/Installer/win
|
---|
56 |
|
---|
57 | #
|
---|
58 | # If we want to build a combined package, we separate all common stuff
|
---|
59 | # (that is all 100% identical content between 32-/64-bit builds)
|
---|
60 | # into an own .cab file to save space. This .cab file then gets included
|
---|
61 | # and used by the 32-/64-bit installers.
|
---|
62 | #
|
---|
63 | ifdef VBOX_WITH_COMBINED_PACKAGE
|
---|
64 | VBOX_INSTALLER_COMMON_DISKID := 2
|
---|
65 | else
|
---|
66 | VBOX_INSTALLER_COMMON_DISKID := 1
|
---|
67 | endif
|
---|
68 |
|
---|
69 | ## @todo VBOX_ prefixes!
|
---|
70 | PACKAGE_BASE := VirtualBox-$(VBOX_VERSION_STRING)
|
---|
71 | PACKAGE_NAME_LANG := $(PACKAGE_BASE)-r$(VBOX_SVN_REV)
|
---|
72 | PACKAGE_NAME_FINAL := $(PATH_BIN)/$(PACKAGE_NAME_LANG).msi
|
---|
73 |
|
---|
74 | ifdef VBOX_WITH_COMBINED_PACKAGE
|
---|
75 | PATH_MULTIARCH_TEMP := $(PATH_OUT_BASE)/win.x86/$(KBUILD_TYPE)/obj/Installer
|
---|
76 | PATH_MULTIARCH_GUEST_ADDITIONS_ISO := $(PATH_OUT_BASE)/win.amd64/$(KBUILD_TYPE)/bin/additions
|
---|
77 | PACKAGE_NAME_MULTIARCH := $(PACKAGE_NAME_LANG)-MultiArch
|
---|
78 | PACKAGE_NAME_MULTIARCH.x86 := $(PACKAGE_NAME_MULTIARCH)_x86.msi
|
---|
79 | PACKAGE_NAME_MULTIARCH.amd64 := $(PACKAGE_NAME_MULTIARCH)_amd64.msi
|
---|
80 | PACKAGE_NAME_FINAL := $(PATH_MULTIARCH_TEMP)/$(PACKAGE_NAME_MULTIARCH.$(KBUILD_TARGET_ARCH))
|
---|
81 | PACKAGE_NAME_MULTIARCH_FINAL := $(PACKAGE_NAME_MULTIARCH).exe
|
---|
82 | PACKAGE_NAME_MULTIARCH_COMMONCAB := common.cab
|
---|
83 |
|
---|
84 | BLDDIRS += $(PATH_MULTIARCH_TEMP)
|
---|
85 | PACKING += $(PACKAGE_NAME_FINAL)
|
---|
86 | ifeq ($(KBUILD_TARGET_ARCH),x86)
|
---|
87 | PACKING += $(PATH_BIN)/$(PACKAGE_NAME_MULTIARCH_FINAL)
|
---|
88 | endif
|
---|
89 | else
|
---|
90 | PACKING += $(PACKAGE_NAME_FINAL)
|
---|
91 | endif
|
---|
92 | BLDDIRS += \
|
---|
93 | $(VBOX_WIN_INST_OUT_DIR) \
|
---|
94 | $(VBOX_WIN_INST_OUT_DIR)/Languages/
|
---|
95 |
|
---|
96 | OTHER_CLEAN += \
|
---|
97 | $(VBOX_WIN_INST_OUT_DIR)/VirtualBox.wixobj \
|
---|
98 | $(VBOX_WIN_INST_OUT_DIR)/VirtualBox.wixobj.dep \
|
---|
99 | $(VBOX_WIN_INST_OUT_DIR)/VirtualBox_TypeLib.wxi \
|
---|
100 | $(VBOX_WIN_INST_OUT_DIR)/VBoxGuiNLS.wxi \
|
---|
101 | $(VBOX_WIN_INST_OUT_DIR)/VBoxKey.wxi \
|
---|
102 | $(foreach lang,$(VBOX_INSTALLER_LANGUAGES), \
|
---|
103 | $(VBOX_WIN_INST_OUT_DIR)/Languages/Language_$(lang).wxl \
|
---|
104 | $(VBOX_WIN_INST_OUT_DIR)/Languages/License_$(lang).wxl \
|
---|
105 | $(VBOX_WIN_INST_OUT_DIR)/Languages/$(lang).mst \
|
---|
106 | $(VBOX_WIN_INST_OUT_DIR)/VirtualBox_$(lang).wixobj \
|
---|
107 | $(VBOX_WIN_INST_OUT_DIR)/$(PACKAGE_NAME_LANG)_$(lang).msi) \
|
---|
108 | $(VBOX_WIN_INST_OUT_DIR)/Files_Doc.wxi \
|
---|
109 | $(VBOX_WIN_INST_OUT_DIR)/Files_License.wxi \
|
---|
110 | $(VBOX_WIN_INST_OUT_DIR)/Shortcuts_StartMenu.wxi
|
---|
111 |
|
---|
112 | ifdef VBOX_WITH_COMBINED_PACKAGE
|
---|
113 | ifeq ($(KBUILD_TARGET_ARCH),x86)
|
---|
114 | OTHER_CLEAN += \
|
---|
115 | $(PATH_BIN)/$(PACKAGE_NAME_MULTIARCH_FINAL) \
|
---|
116 | $(PATH_MULTIARCH_TEMP)/$(PACKAGE_NAME_MULTIARCH.x86) \
|
---|
117 | $(PATH_MULTIARCH_TEMP)/$(PACKAGE_NAME_MULTIARCH.am64) \
|
---|
118 | $(VBOX_WIN_INST_OUT_DIR)/$(PACKAGE_NAME_MULTIARCH_COMMONCAB)
|
---|
119 | else
|
---|
120 | # Nothing to do here yet.
|
---|
121 | endif
|
---|
122 | else
|
---|
123 | OTHER_CLEAN += \
|
---|
124 | $(PACKAGE_NAME_FINAL)
|
---|
125 | endif
|
---|
126 |
|
---|
127 | ifdef VBOX_WITH_BUNDLED_INSTALLER
|
---|
128 | ifeq ($(KBUILD_TARGET),darwin)
|
---|
129 | VBOX_TMP_DIR ?= /VBox
|
---|
130 | ZIP = /usr/bin/zip
|
---|
131 | else
|
---|
132 | VBOX_TMP_DIR ?= c:\Temp
|
---|
133 | ZIP = zip
|
---|
134 | endif
|
---|
135 |
|
---|
136 | ifndef VBOX_PATH_PACK_TMP
|
---|
137 | VBOX_PATH_PACK_TMP := $(VBOX_WIN_INST_OUT_DIR)
|
---|
138 | endif
|
---|
139 |
|
---|
140 | VBOX_PATH_PACK_BUNDLE_TMP = $(PATH_BIN)/VBoxWinBundleInstaller
|
---|
141 | VBOX_PATH_PACK_BUNDLE_ZIP = $(PATH_BIN)/VBoxWinBundleInstaller-$(KBUILD_TARGET_ARCH).zip
|
---|
142 |
|
---|
143 | VBOX_BRAND_WIN_INST_NAME.x86 = $(PACKAGE_BASE)-Win_x86$(VBOX_BRAND_WIN_INST_EXT).msi
|
---|
144 | VBOX_BRAND_WIN_INST_NAME.amd64 = $(PACKAGE_BASE)-Win_amd64$(VBOX_BRAND_WIN_INST_EXT).msi
|
---|
145 |
|
---|
146 | PACKING.win += $(VBOX_PATH_PACK_BUNDLE_ZIP)
|
---|
147 | endif
|
---|
148 |
|
---|
149 | #
|
---|
150 | # Surpress/skip the following ICE (internal consistency evaluators):
|
---|
151 | # - ICE64: Checks that new directories in the user profile are removed correctly in roaming scenarios.
|
---|
152 | # -> We don't want to remove system folders (like "Microsoft/Internet Explorer/Quick Launch").
|
---|
153 | #
|
---|
154 | VBOX_MSI_ICE_IGNORE := \
|
---|
155 | -ice:64
|
---|
156 |
|
---|
157 | #
|
---|
158 | # Create intermediate XML file for languages (needed for .MSI linking).
|
---|
159 | #
|
---|
160 | # Note: The double escaping of $(dir $@) in the prereq/dep list is because we first have
|
---|
161 | # to escape the expansion of the $(eval ) argument and then the definition of the
|
---|
162 | # rule. The statement is finally expanded during second dependency expansion, which
|
---|
163 | # takes place after all makefiles has been loaded and with the @ variable defined.
|
---|
164 | #
|
---|
165 | define def_vbox_lang_xml
|
---|
166 | $(VBOX_WIN_INST_OUT_DIR)/Languages/Language_$(lang).wxl: $(VBOX_PATH_WIN_INST_SRC)/Languages/$(lang).wxl | $$$$(dir $$$$@)
|
---|
167 | $$(call MSG_GENERATE,,$$@,$$<)
|
---|
168 | $(QUIET)$(INSTALL) -m 0644 $$< $$@
|
---|
169 | endef
|
---|
170 |
|
---|
171 | $(foreach lang,$(VBOX_INSTALLER_LANGUAGES),$(eval $(def_vbox_lang_xml)))
|
---|
172 |
|
---|
173 |
|
---|
174 | #
|
---|
175 | # Create intermediate XML file for licenses (needed for .MSI linking).
|
---|
176 | # These files are created from the original .RTF files in the /docs directory.
|
---|
177 | #
|
---|
178 | # Note: The redirect command below will open $$@ as stdout in append+text mode
|
---|
179 | # and then exec cat, thus appending the license file to the result file.
|
---|
180 | #
|
---|
181 | # Note: The license_file variable has to be created before def_vbox_license_xml
|
---|
182 | # is expanded by the 2nd eval because we rely on the that expansion
|
---|
183 | # replacing all $(license_file) (and $(lang)) references before evaluation.
|
---|
184 | #
|
---|
185 | # Note: The REDIRECT + ECHO_EXT is because WiX gets upset if there a newline
|
---|
186 | # between the tag and the RTF license text.
|
---|
187 | #
|
---|
188 | define def_vbox_license_xml
|
---|
189 | $(VBOX_WIN_INST_OUT_DIR)/Languages/License_$(lang).wxl: $(license_file) $(MAKEFILE_CURRENT) | $$$$(dir $$$$@)
|
---|
190 | $$(call MSG_GENERATE,,$$@,$$<)
|
---|
191 | $(APPEND) -t $$@ '<?xml version="1.0" encoding="utf-8"?>'
|
---|
192 | $(APPEND) $$@ '<WixLocalization xmlns="http://schemas.microsoft.com/wix/2006/localization" Codepage="1252" Culture="$(lang)">'
|
---|
193 |
|
---|
194 | $(REDIRECT) -a+to $$@ -- $(ECHO_EXT) -n '<String Id=\"LicenseText\">'
|
---|
195 | $(REDIRECT) -a+to $$@ -- $(SED) -e "s|<|\<|g" -e "s|>|\>|g" $(license_file)
|
---|
196 | $(APPEND) $$@ '</String>'
|
---|
197 |
|
---|
198 | $(APPEND) $$@ '<String Id="LicenseFile">$(license_file)</String>'
|
---|
199 | $(APPEND) $$@ '<String Id="LicenseInstallFileLong">License_$(lang).rtf</String>'
|
---|
200 | $(APPEND) $$@ '<String Id="LicenseInstallFileShort">L_$(lang).rtf</String>'
|
---|
201 |
|
---|
202 | $(APPEND) $$@ '</WixLocalization>'
|
---|
203 | endef
|
---|
204 |
|
---|
205 | $(foreach lang,$(VBOX_INSTALLER_LANGUAGES), \
|
---|
206 | $(eval local license_file := $(VBOX_BRAND_$(subst en_US_,,$(lang)_)LICENSE_RTF)) \
|
---|
207 | $(eval $(def_vbox_license_xml)))
|
---|
208 |
|
---|
209 |
|
---|
210 | #
|
---|
211 | # Create one intermediate WXI (Windows Installer Include) file for all installers (needed for .MSI compiling).
|
---|
212 | # This file includes all language-specific files (PDFs, CHMs, ...) to install.
|
---|
213 | #
|
---|
214 | # Note: When using the -n switch, append will append a new line after each
|
---|
215 | # argument. The -t switch makes it truncate the file.
|
---|
216 | #
|
---|
217 | $(VBOX_WIN_INST_OUT_DIR)/Files_Main.wxi: $(MAKEFILE_CURRENT) | $$(dir $$@)
|
---|
218 | $(call MSG_GENERATE,,$@,$<)
|
---|
219 | $(APPEND) -t $@ '<?xml version="1.0" ?>'
|
---|
220 | $(APPEND) $@ '<Include xmlns="http://schemas.microsoft.com/wix/2006/wi">'
|
---|
221 | ifdef VBOX_WITH_DOCS_CHM
|
---|
222 | $(APPEND) $@ ' <File Id="file_VirtualBox.chm" Name="VirtualBox.chm" DiskId="$(VBOX_INSTALLER_COMMON_DISKID)" Vital="yes" Source="$(PATH_BIN)/VirtualBox.chm"></File>'
|
---|
223 | $(APPEND) -n $@ $(foreach lang,$(VBOX_MANUAL_ADD_LANGUAGES), \
|
---|
224 | ' <File Id="file_VirtualBox_$(lang).chm" Name="VirtualBox_$(lang).chm" DiskId="$(VBOX_INSTALLER_COMMON_DISKID)" Vital="yes" Source="$(PATH_BIN)/VirtualBox_$(lang).chm"></File>')
|
---|
225 | endif
|
---|
226 | $(APPEND) $@ '</Include>'
|
---|
227 |
|
---|
228 | $(VBOX_WIN_INST_OUT_DIR)/Files_Doc.wxi: $(MAKEFILE_CURRENT) | $$(dir $$@)
|
---|
229 | $(call MSG_GENERATE,,$@,$<)
|
---|
230 | $(APPEND) -t $@ '<?xml version="1.0" ?>'
|
---|
231 | $(APPEND) $@ '<Include xmlns="http://schemas.microsoft.com/wix/2006/wi">'
|
---|
232 | $(APPEND) $@ ' <File Id="file_UserManual.pdf" Name="UserManual.pdf" DiskId="$(VBOX_INSTALLER_COMMON_DISKID)" Vital="yes" Source="$(PATH_BIN)/UserManual.pdf">'
|
---|
233 | $(APPEND) $@ ' </File>'
|
---|
234 | $(APPEND) -n $@ $(foreach lang,$(VBOX_MANUAL_ADD_LANGUAGES), \
|
---|
235 | ' <File Id="file_UserManual_$(lang).pdf" Name="UserManual_$(lang).pdf" DiskId="$(VBOX_INSTALLER_COMMON_DISKID)" Vital="yes" Source="$(PATH_BIN)/UserManual_$(lang).pdf">' \
|
---|
236 | ' </File>')
|
---|
237 | $(APPEND) $@ '</Include>'
|
---|
238 |
|
---|
239 | $(VBOX_WIN_INST_OUT_DIR)/Files_License.wxi: $(MAKEFILE_CURRENT) | $$(dir $$@)
|
---|
240 | $(call MSG_GENERATE,,$@,$<)
|
---|
241 | $(APPEND) -t $@ '<?xml version="1.0" ?>'
|
---|
242 | $(APPEND) $@ '<Include xmlns="http://schemas.microsoft.com/wix/2006/wi">'
|
---|
243 | $(APPEND) $@ ' <File Id="file_License_en_US.rtf" Name="License_en_US.rtf" DiskId="$(VBOX_INSTALLER_COMMON_DISKID)" Vital="yes" Source="$(VBOX_BRAND_LICENSE_RTF)">' \
|
---|
244 | ' </File>'
|
---|
245 | $(APPEND) -n $@ $(foreach lang,$(VBOX_MANUAL_ADD_LANGUAGES), \
|
---|
246 | ' <File Id="file_License_$(lang).rtf" Name="License_$(lang).rtf" DiskId="$(VBOX_INSTALLER_COMMON_DISKID)" Vital="yes" Source="$(VBOX_BRAND_$(lang)_LICENSE_RTF)"/>' \
|
---|
247 | ' </File>')
|
---|
248 | $(APPEND) $@ '</Include>'
|
---|
249 |
|
---|
250 | $(VBOX_WIN_INST_OUT_DIR)/Shortcuts_StartMenu.wxi: $(MAKEFILE_CURRENT) | $$(dir $$@)
|
---|
251 | $(call MSG_GENERATE,,$@,$<)
|
---|
252 | $(APPEND) -t $@ '<?xml version="1.0" ?>'
|
---|
253 | $(APPEND) $@ '<Include xmlns="http://schemas.microsoft.com/wix/2006/wi">'
|
---|
254 | #
|
---|
255 | # Documentation (PDF/CHM)
|
---|
256 | #
|
---|
257 | ifdef VBOX_WITH_DOCS_CHM
|
---|
258 | $(APPEND) $@ ' <Shortcut Id="sc_StartMenu_ManualCHM_en_US" Directory="dir_StartMenuVBox" Name="!(loc.StartMenu_UserManual) (CHM, English)" Description="!(loc.StartMenu_UserManual)"' \
|
---|
259 | ' Target="[INSTALLDIR]VirtualBox.chm" WorkingDirectory="INSTALLDIR" Advertise="no"/>'
|
---|
260 | $(APPEND) -n $@ $(foreach lang,$(VBOX_MANUAL_ADD_LANGUAGES), \
|
---|
261 | ' <Shortcut Id="sc_StartMenu_ManualCHM_$(lang)" Directory="dir_StartMenuVBox" Name="$!(loc.StartMenu_UserManual) (CHM, $(VBOX_BRAND_$(lang)_LANG_NAME))"' \
|
---|
262 | ' Description="$!(loc.StartMenu_UserManual) ($(VBOX_BRAND_$(lang)_LANG_NAME))" Target="VirtualBox_$(lang).chm" WorkingDirectory="INSTALLDIR"/>')
|
---|
263 | endif
|
---|
264 | $(APPEND) $@ ' <Shortcut Id="sc_StartMenu_ManualPDF_en_US" Directory="dir_StartMenuVBox" Name="!(loc.StartMenu_UserManual) (PDF, English)" Description="!(loc.StartMenu_UserManual)"' \
|
---|
265 | ' Target="[INSTALLDIR]UserManual.pdf" WorkingDirectory="INSTALLDIR" Advertise="no"/>'
|
---|
266 | $(APPEND) -n $@ $(foreach lang,$(VBOX_MANUAL_ADD_LANGUAGES), \
|
---|
267 | ' <Shortcut Id="sc_StartMenu_ManualPDF_$(lang)" Directory="dir_StartMenuVBox" Name="$!(loc.StartMenu_UserManual) (PDF, $(VBOX_BRAND_$(lang)_LANG_NAME))"' \
|
---|
268 | ' Description="$!(loc.StartMenu_UserManual) ($(VBOX_BRAND_$(lang)_LANG_NAME))" Target="UserManual_$(lang).pdf" WorkingDirectory="INSTALLDIR"/>')
|
---|
269 | #
|
---|
270 | # License(s) (RTF)
|
---|
271 | #
|
---|
272 | $(APPEND) $@ ' <Shortcut Id="sc_StartMenu_License_en_US" Directory="dir_StartMenuVBox" Name="!(loc.StartMenu_License) (English)" Description="!(loc.StartMenu_License)"' \
|
---|
273 | ' Target="[INSTALLDIR]License_en_US.rtf" WorkingDirectory="INSTALLDIR" Advertise="no"/>'
|
---|
274 | $(APPEND) -n $@ $(foreach lang,$(VBOX_MANUAL_ADD_LANGUAGES), \
|
---|
275 | ' <Shortcut Id="sc_StartMenu_License_$(lang)" Directory="dir_StartMenuVBox" Name="$!(loc.StartMenu_License) ($(VBOX_BRAND_$(lang)_LANG_NAME))"' \
|
---|
276 | ' Description="$!(loc.StartMenu_License) ($(VBOX_BRAND_$(lang)_LANG_NAME))" Target="License_$(lang).rtf" WorkingDirectory="INSTALLDIR"/>')
|
---|
277 | $(APPEND) $@ '</Include>'
|
---|
278 |
|
---|
279 | #
|
---|
280 | # .MSI link (all languages).
|
---|
281 | #
|
---|
282 | # Note: This will clean up any previous .msi to prevent dep build boxes from
|
---|
283 | # filling up with old files.
|
---|
284 | #
|
---|
285 | define def_vbox_link_msi
|
---|
286 | $(VBOX_WIN_INST_OUT_DIR)/$(PACKAGE_NAME_LANG)_$(lang).msi: \
|
---|
287 | $(VBOX_WIN_INST_OUT_DIR)/VirtualBox_$(lang).wixobj \
|
---|
288 | $(VBOX_WIN_INST_OUT_DIR)/Languages/Language_$(lang).wxl \
|
---|
289 | $(VBOX_WIN_INST_OUT_DIR)/Languages/License_$(lang).wxl \
|
---|
290 | $(PATH_BIN)/VBoxInstallHelper.dll \
|
---|
291 | $(MAKEFILE_CURRENT) \
|
---|
292 | | $$$$(dir $$$$@)
|
---|
293 | $$(call MSG_L1,Linking installer $$@)
|
---|
294 | $(QUIET)$(RM) -f $$(wildcard $(VBOX_WIN_INST_OUT_DIR)/$(PACKAGE_BASE)-r*_$(lang).msi)
|
---|
295 | $(VBOX_PATH_WIX)/light.exe -nologo \
|
---|
296 | -loc $(VBOX_WIN_INST_OUT_DIR)/Languages/Language_$(lang).wxl \
|
---|
297 | -loc $(VBOX_WIN_INST_OUT_DIR)/Languages/License_$(lang).wxl \
|
---|
298 | -ext $(VBOX_PATH_WIX)/WixUIExtension.dll \
|
---|
299 | -ext $(VBOX_PATH_WIX)/WixDifxAppExtension.dll \
|
---|
300 | $(VBOX_MSI_ICE_IGNORE) \
|
---|
301 | -out $$@ \
|
---|
302 | $$< \
|
---|
303 | $(if-expr "$(KBUILD_TARGET_ARCH)" == "x86", \
|
---|
304 | $(VBOX_PATH_WIX)/difxapp_x86.wixlib, \
|
---|
305 | $(VBOX_PATH_WIX)/difxapp_x64.wixlib)
|
---|
306 | $(RM) -f $(VBOX_WIN_INST_OUT_DIR)/Languages/$(lang).mst
|
---|
307 | $(call VBOX_SIGN_FILE_FN,$$@)
|
---|
308 | endef
|
---|
309 |
|
---|
310 | $(foreach lang,$(VBOX_INSTALLER_LANGUAGES), $(eval $(def_vbox_link_msi)))
|
---|
311 |
|
---|
312 |
|
---|
313 | #
|
---|
314 | # Load and adjust the MSI compile step dependencies.
|
---|
315 | #
|
---|
316 | -include $(VBOX_WIN_INST_OUT_DIR)/VirtualBox.wixobj.dep
|
---|
317 |
|
---|
318 | # Filter out some files depending on build type and compiler.
|
---|
319 | ifeq ($(KBUILD_TYPE),release)
|
---|
320 | VBOX_MSI_DEPENDENCIES := $(filer-out $(PATH_OUT)/bin/VBoxDbg3.dll, $(VBOX_MSI_DEPENDENCIES))
|
---|
321 | endif
|
---|
322 | ifndef VBOX_SIGNING_MODE
|
---|
323 | VBOX_MSI_DEPENDENCIES := $(filer-out %.cat, $(VBOX_MSI_DEPENDENCIES))
|
---|
324 | endif
|
---|
325 | ifdef VBOX_USE_VCC80
|
---|
326 | VBOX_MSI_DEPENDENCIES := $(filter-out \
|
---|
327 | $(PATH_OUT)/bin/msvcrt.dll \
|
---|
328 | $(PATH_OUT)/bin/msvcr71.dll \
|
---|
329 | $(PATH_OUT)/bin/msvcp71.dll \
|
---|
330 | $(PATH_OUT)/bin/SDL_ttf.dll \
|
---|
331 | , $(VBOX_MSI_DEPENDENCIES))
|
---|
332 | else
|
---|
333 | VBOX_MSI_DEPENDENCIES := $(filter-out \
|
---|
334 | $(PATH_OUT)/bin/Microsoft.VC80.CRT/Microsoft.VC80.CRT.manifest \
|
---|
335 | $(PATH_OUT)/bin/Microsoft.VC80.CRT/msvcr80.dll \
|
---|
336 | $(PATH_OUT)/bin/Microsoft.VC80.CRT/msvcp80.dll \
|
---|
337 | $(PATH_OUT)/bin/Microsoft.VC80.CRT/msvcm80.dll \
|
---|
338 | , $(VBOX_MSI_DEPENDENCIES))
|
---|
339 | endif
|
---|
340 | # TODO: Add filtering out more dependencies here!
|
---|
341 | ifndef VBOX_WITH_QTGUI
|
---|
342 | $(PATH_OUT)/bin/VirtualBox.exe \
|
---|
343 | $(PATH_OUT)/bin/VBoxTestOGL.exe \
|
---|
344 | $(PATH_OUT)/bin/QtCoreVBox4.dll \
|
---|
345 | $(PATH_OUT)/bin/QtGuiVBox4.dll \
|
---|
346 | $(PATH_OUT)/bin/QtNetworkVBox4.dll \
|
---|
347 | $(PATH_OUT)/bin/QtOpenGLVBox4.dll \
|
---|
348 | $(PATH_OUT)/bin/accessible/qtaccessiblewidgets4.dll \
|
---|
349 | , $(VBOX_MSI_DEPENDENCIES))
|
---|
350 | endif
|
---|
351 | ifndef VBOX_WITH_PYTHON
|
---|
352 | VBOX_MSI_DEPENDENCIES := $(filer-out $ \
|
---|
353 | $(PATH_OUT)/bin/sdk/installer/vboxapisetup.py \
|
---|
354 | $(PATH_OUT)/bin/sdk/installer/vboxapi/__init__.py \
|
---|
355 | $(PATH_OUT)/bin/sdk/installer/vboxapi/VirtualBox_constants.py \
|
---|
356 | , $(VBOX_MSI_DEPENDENCIES))
|
---|
357 | endif
|
---|
358 | ifndef VBOX_WITH_CROGL
|
---|
359 | VBOX_MSI_DEPENDENCIES := $(filer-out $ \
|
---|
360 | $(PATH_OUT)/bin/VBoxOGLhostcrutil.dll \
|
---|
361 | $(PATH_OUT)/bin/VBoxOGLhosterrorspu.dll \
|
---|
362 | $(PATH_OUT)/bin/VBoxOGLrenderspu.dll \
|
---|
363 | $(PATH_OUT)/bin/VBoxSharedCrOpenGL.dll \
|
---|
364 | , $(VBOX_MSI_DEPENDENCIES))
|
---|
365 | endif
|
---|
366 | ifndef VBOX_WITH_SECURELABEL
|
---|
367 | VBOX_MSI_DEPENDENCIES := $(filer-out $(PATH_OUT)/bin/SDL_ttf.dll, $(VBOX_MSI_DEPENDENCIES))
|
---|
368 | endif
|
---|
369 | ifndef VBOX_WITH_WEBSERVICES
|
---|
370 | VBOX_MSI_DEPENDENCIES := $(filer-out $(PATH_OUT)/bin/vboxwebsrv.exe, $(VBOX_MSI_DEPENDENCIES))
|
---|
371 | endif
|
---|
372 |
|
---|
373 | ifneq ($(KBUILD_TARGET_ARCH),amd64)
|
---|
374 | VBOX_MSI_DEPENDENCIES := $(filter-out \
|
---|
375 | $(PATH_OUT)/bin/VBoxREM2.rel \
|
---|
376 | , $(VBOX_MSI_DEPENDENCIES))
|
---|
377 | else
|
---|
378 | VBOX_MSI_DEPENDENCIES := $(filter-out \
|
---|
379 | $(PATH_OUT)/bin/VBoxREM32.dll \
|
---|
380 | $(PATH_OUT)/bin/VBoxREM64.dll \
|
---|
381 | , $(VBOX_MSI_DEPENDENCIES))
|
---|
382 | endif
|
---|
383 |
|
---|
384 | # Add dependencies that makes sure necessary bits gets built since
|
---|
385 | # VBOX_MSI_DEPENDENCIES will be zero the first time around.
|
---|
386 | # For combined packages we always use the .ISO from the amd64 build.
|
---|
387 | ifdef VBOX_WITH_COMBINED_PACKAGE
|
---|
388 | VBOX_MSI_DEPENDENCIES += \
|
---|
389 | $(if $(VBOX_WITH_ADDITIONS_PACKING),$(PATH_MULTIARCH_GUEST_ADDITIONS_ISO)/VBoxGuestAdditions.iso)
|
---|
390 | else
|
---|
391 | VBOX_MSI_DEPENDENCIES += \
|
---|
392 | $(if $(VBOX_WITH_ADDITIONS_PACKING),$(VBOX_PATH_ADDITIONS)/VBoxGuestAdditions.iso)
|
---|
393 | endif
|
---|
394 |
|
---|
395 | #
|
---|
396 | # MSI compile.
|
---|
397 | #
|
---|
398 | define def_vbox_compile_wixobj
|
---|
399 | $(VBOX_WIN_INST_OUT_DIR)/VirtualBox_$(lang).wixobj: \
|
---|
400 | $(PATH_SUB_CURRENT)/VirtualBox.wxs \
|
---|
401 | $(PATH_SUB_CURRENT)/UserInterface.wxi \
|
---|
402 | $(VBOX_WIN_INST_OUT_DIR)/VirtualBox_TypeLib.wxi \
|
---|
403 | $(VBOX_WIN_INST_OUT_DIR)/VBoxKey.wxi \
|
---|
404 | $(VBOX_WIN_INST_OUT_DIR)/VBoxGuiNLS.wxi \
|
---|
405 | $(VBOX_MSI_DEPENDENCIES) \
|
---|
406 | $(VBOX_VERSION_STAMP) \
|
---|
407 | | $$$$(dir $$$$@)
|
---|
408 | $(QUIET)$(RM) -f $@
|
---|
409 | $(REDIRECT) \
|
---|
410 | -E 'PATH_OUT=$(subst /,\\,$(PATH_OUT))' \
|
---|
411 | -E 'PATH_TARGET=$(subst /,\\,$(VBOX_WIN_INST_OUT_DIR))' \
|
---|
412 | -E 'PATH_ROOT=$(subst /,\\,$(PATH_ROOT))' \
|
---|
413 | -E 'PATH_MULTIARCH_GUEST_ADDITIONS_ISO=$(subst /,\\,$(PATH_MULTIARCH_GUEST_ADDITIONS_ISO))' \
|
---|
414 | -E 'VBOX_PATH_WIN_INST_SRC=$(subst /,\\,$(VBOX_PATH_WIN_INST_SRC))' \
|
---|
415 | -E 'VBOX_BRAND_WIN_INST_DLGJPG=$(subst /,\\,$(VBOX_BRAND_WIN_INST_DLGJPG))' \
|
---|
416 | -E 'VBOX_ADD_LANGUAGES=$(VBOX_INSTALLER_ADD_LANGUAGES)' \
|
---|
417 | -E 'VBOX_BRAND_LICENSE_RTF=$(subst /,\\,$(VBOX_BRAND_LICENSE_RTF))' \
|
---|
418 | $(foreach lang,$(VBOX_INSTALLER_LANGUAGES), \
|
---|
419 | -E 'VBOX_BRAND_$(lang)_LICENSE_RTF=$(subst /,\\,$(VBOX_BRAND_$(subst en_US_,,$(lang)_)LICENSE_RTF))') \
|
---|
420 | -E 'VBOX_BUILD_NR_FOR_INST=$(VBOX_VERSION_BUILD)' \
|
---|
421 | -E 'VBOX_VENDOR=$(VBOX_VENDOR)' \
|
---|
422 | -E 'VBOX_VENDOR_SHORT=$(VBOX_VENDOR_SHORT)' \
|
---|
423 | -E 'VBOX_PRODUCT=$(VBOX_PRODUCT)' \
|
---|
424 | -E 'VBOX_C_YEAR=$(VBOX_C_YEAR)' \
|
---|
425 | -E 'VBOX_VERSION_STRING=$(VBOX_VERSION_STRING)' \
|
---|
426 | -E 'VBOX_VERSION_STRING_RAW=$(VBOX_VERSION_STRING_RAW)' \
|
---|
427 | -E 'VBOX_VERSION_MAJOR_INST=$(VBOX_VERSION_MAJOR)' \
|
---|
428 | -E 'VBOX_VERSION_MINOR_INST=$(VBOX_VERSION_MINOR)' \
|
---|
429 | -E 'VBOX_SIGNING_MODE=$(strip $(if $(VBOX_SIGNING_MODE),$(VBOX_SIGNING_MODE),none))' \
|
---|
430 | -E 'VBOX_GUI_USE_QGL=$(if $(VBOX_GUI_USE_QGL),yes,no)' \
|
---|
431 | -E 'VBOX_WITH_ADDITIONS_PACKING=$(if $(VBOX_WITH_ADDITIONS_PACKING),yes,no)' \
|
---|
432 | -E 'VBOX_WITH_COMBINED_PACKAGE=$(if $(VBOX_WITH_COMBINED_PACKAGE),yes,no)' \
|
---|
433 | -E 'VBOX_WITH_CROGL=$(if $(VBOX_WITH_CROGL),yes,no)' \
|
---|
434 | -E 'VBOX_WITH_DEBUGGER_GUI=$(if-expr defined(VBOX_WITH_DEBUGGER_GUI) && defined(VBOX_WITH_QTGUI),yes,no)' \
|
---|
435 | -E 'VBOX_WITH_DOCS_PACKING=$(if $(VBOX_WITH_DOCS_PACKING),yes,no)' \
|
---|
436 | -E 'VBOX_WITH_EFIFW_PACKING=$(if $(VBOX_WITH_EFIFW_PACKING),yes,no)' \
|
---|
437 | -E 'VBOX_WITH_EXTPACK=$(if $(VBOX_WITH_EXTPACK),yes,no)' \
|
---|
438 | -E 'VBOX_WITH_GUEST_CONTROL=$(if $(VBOX_WITH_GUEST_CONTROL),yes,no)' \
|
---|
439 | -E 'VBOX_WITH_GUEST_PROPS=$(if $(VBOX_WITH_GUEST_PROPS),yes,no)' \
|
---|
440 | -E 'VBOX_WITH_NETFLT=$(if $(VBOX_WITH_NETFLT),yes,no)' \
|
---|
441 | -E 'VBOX_WITH_PYTHON=$(if $(VBOX_WITH_PYTHON),yes,no)' \
|
---|
442 | -E 'VBOX_WITH_QTGUI=$(if $(VBOX_WITH_QTGUI),yes,no)' \
|
---|
443 | -E 'VBOX_WITH_VIDEOHWACCEL=$(if $(VBOX_WITH_VIDEOHWACCEL),yes,no)' \
|
---|
444 | -E 'VBOX_WITH_VRDP=$(if-expr defined(VBOX_WITH_VRDP) && !defined(VBOX_WITH_EXTPACK_PUEL),yes,no)' \
|
---|
445 | -E 'VBOX_WITH_WEBSERVICES=$(if $(VBOX_WITH_WEBSERVICES),yes,no)' \
|
---|
446 | -E 'VBOX_WITH_SECURELABEL=$(if $(VBOX_WITH_SECURELABEL),yes,no)' \
|
---|
447 | -E 'VBOX_WITH_SERIALNUMBER_INSTALL=$(if $(VBOX_WITH_SERIALNUMBER_INSTALL),yes,no)' \
|
---|
448 | -E 'VBOX_WITH_LICENSE_DISPLAY=$(if $(VBOX_WITH_LICENSE_DISPLAY),yes,no)' \
|
---|
449 | -E 'VBOX_WINDOWS_ICON_FILE=$(subst /,\\,$(VBOX_WINDOWS_ICON_FILE))' \
|
---|
450 | -E 'BUILD_TYPE=$(KBUILD_TYPE)' \
|
---|
451 | -E 'BUILD_TARGET_ARCH=$(KBUILD_TARGET_ARCH)' \
|
---|
452 | -E 'VBOX_USE_VCC80=$(if $(VBOX_USE_VCC80),yes,no)' \
|
---|
453 | -- \
|
---|
454 | $(VBOX_PATH_WIX)/candle.exe $(filter-out $(VBOX_VERSION_STAMP),$$<) \
|
---|
455 | -ext $(VBOX_PATH_WIX)/WixUIExtension.dll \
|
---|
456 | -ext $(VBOX_PATH_WIX)/WixDifxAppExtension.dll \
|
---|
457 | -out $$@
|
---|
458 | ifeq ($(lang),en_US)
|
---|
459 | #
|
---|
460 | # Generate dependency file, we share this between all the languages.
|
---|
461 | #
|
---|
462 | $(APPEND) -t $(VBOX_WIN_INST_OUT_DIR)/VirtualBox.wixobj.dep 'VBOX_MSI_DEPENDENCIES = \'
|
---|
463 | $(SED) -f $(VBOX_PATH_WIN_INST_SRC)/dep.sed \
|
---|
464 | --append $(VBOX_WIN_INST_OUT_DIR)/VirtualBox.wixobj.dep \
|
---|
465 | $(VBOX_PATH_WIN_INST_SRC)/VirtualBox.wxs \
|
---|
466 | $(VBOX_PATH_WIN_INST_SRC)/UserInterface.wxi \
|
---|
467 | $(VBOX_WIN_INST_OUT_DIR)/VirtualBox_TypeLib.wxi
|
---|
468 | $(APPEND) $(VBOX_WIN_INST_OUT_DIR)/VirtualBox.wixobj.dep ''
|
---|
469 | endif
|
---|
470 | endef
|
---|
471 |
|
---|
472 | $(foreach lang,$(VBOX_INSTALLER_LANGUAGES), \
|
---|
473 | $(eval $(def_vbox_compile_wixobj)))
|
---|
474 |
|
---|
475 | #
|
---|
476 | # VirtualBox Type Library definition.
|
---|
477 | #
|
---|
478 | $(VBOX_WIN_INST_OUT_DIR)/VirtualBox_TypeLib.wxi: \
|
---|
479 | $(PATH_SUB_CURRENT)/VirtualBox_TypeLib.xsl \
|
---|
480 | $(VBOX_XIDL_FILE) \
|
---|
481 | | $$(dir $$@)
|
---|
482 | $(VBOX_XSLTPROC) -o $@ $< $(VBOX_XIDL_FILE)
|
---|
483 |
|
---|
484 | #
|
---|
485 | # Construct the list of GUI translations.
|
---|
486 | # ('-t' -- truncate file; '-n' -- new line between arguments)
|
---|
487 | #
|
---|
488 | include $(PATH_ROOT)/src/VBox/Frontends/VirtualBox/nls/ApprovedLanguages.kmk
|
---|
489 | $(VBOX_WIN_INST_OUT_DIR)/VBoxGuiNLS.wxi: $(PATH_ROOT)/src/VBox/Frontends/VirtualBox/nls/ApprovedLanguages.kmk $(MAKEFILE_CURRENT) | $$(dir $$@)
|
---|
490 | $(APPEND) -t $@ '<?xml version="1.0" ?>'
|
---|
491 | $(APPEND) $@ '<Include>'
|
---|
492 | $(APPEND) -n $@ $(foreach lang,$(VBOX_APPROVED_GUI_LANGUAGES), \
|
---|
493 | ' <File Id="nlsqt${lang}" Name="qt_${lang}.qm" DiskId="$(VBOX_INSTALLER_COMMON_DISKID)" Vital="yes" Source="$$(env.PATH_OUT)\bin\nls\qt_${lang}.qm" />' \
|
---|
494 | ' <File Id="nlsgui${lang}" Name="VirtualBox_${lang}.qm" DiskId="$(VBOX_INSTALLER_COMMON_DISKID)" Vital="yes" Source="$$(env.PATH_OUT)\bin\nls\VirtualBox_${lang}.qm" />')
|
---|
495 | $(APPEND) $@ '</Include>'
|
---|
496 |
|
---|
497 | #
|
---|
498 | # Edit the version stored in the registry.
|
---|
499 | #
|
---|
500 | $(VBOX_WIN_INST_OUT_DIR)/VBoxKey.wxi: $(PATH_SUB_CURRENT)/VBoxKey.wxi $(VBOX_VERSION_STAMP) | $$(dir $$@)
|
---|
501 | $(SED) -e 's/%VER%/$(VBOX_VERSION_STRING_RAW)/' --output $@ $<
|
---|
502 | $(SED) -e 's/%VER_EXT%/$(VBOX_VERSION_STRING)/' --output $@ $<
|
---|
503 |
|
---|
504 | #
|
---|
505 | # Build the multi-language version of the .MSI installer (final installer).
|
---|
506 | # This is done by creating binary .MST diffs of all the language-specific installers
|
---|
507 | # and then merging the diffs into the existing .MSI using tools from the MS Installer SDK.
|
---|
508 | #
|
---|
509 | # .MSI link (all languages).
|
---|
510 | #
|
---|
511 | # Note: Prereqs of the special .NOTPARALLEL target will be executed with parallel
|
---|
512 | # make jobs temporarily disabled. This is a hack to work around what seems
|
---|
513 | # to be a problem with the sharing mode set by one or more of the three
|
---|
514 | # programs / scripts involved in this step.
|
---|
515 | #
|
---|
516 | define def_vbox_create_mst
|
---|
517 | .NOTPARALLEL: $(VBOX_WIN_INST_OUT_DIR)/Languages/$(lang).mst
|
---|
518 | $(VBOX_WIN_INST_OUT_DIR)/Languages/$(lang).mst: \
|
---|
519 | $(VBOX_WIN_INST_OUT_DIR)/$(PACKAGE_NAME_LANG)_en_US.msi \
|
---|
520 | $(VBOX_WIN_INST_OUT_DIR)/$(PACKAGE_NAME_LANG)_$(lang).msi \
|
---|
521 | | $$$$(dir $$$$@)
|
---|
522 | $(call MSG_L1,Integrating language ($(lang)))
|
---|
523 | $(REDIRECT) -C $$(@D) -- $(VBOX_PATH_MSITRAN) -g $$< $(VBOX_WIN_INST_OUT_DIR)/$(PACKAGE_NAME_LANG)_$(lang).msi $(lang).mst
|
---|
524 | $(REDIRECT) -C $$(@D) -- $(VBOX_PATH_MSIDB) -d $$< -r $(lang).mst
|
---|
525 | $(REDIRECT) -C $$(@D) -- wscript.exe $(VBOX_PATH_WISUBSTG) $$< $(lang).mst $(lang_id)
|
---|
526 | endef
|
---|
527 |
|
---|
528 | $(foreach lang,$(VBOX_INSTALLER_ADD_LANGUAGES), \
|
---|
529 | $(eval local lang_id := $(VBOX_BRAND_$(lang)_LANG_ID)) \
|
---|
530 | $(eval $(def_vbox_create_mst)))
|
---|
531 |
|
---|
532 | #
|
---|
533 | # Create all xxx_<Lang>.msi installers and prepare the final xxx_MultiLang.msi installer.
|
---|
534 | #
|
---|
535 | ## @todo this rule must not modify $(VBOX_WIN_INST_OUT_DIR)/$(PACKAGE_NAME_LANG)_en_US.msi but a copy of it. def_vbox_compile_wixobj is
|
---|
536 | # where en_US.msi is created, it shouldn't be changed after that (if possible). Also, document the path length issue.
|
---|
537 | VBOX_INS_PROD_ARCH.amd64 = x64
|
---|
538 | VBOX_INS_PROD_ARCH.x86 = Intel
|
---|
539 | VBOX_INS_PROD_ARCH := $(VBOX_INS_PROD_ARCH.$(KBUILD_TARGET_ARCH))
|
---|
540 | $(if $(VBOX_INS_PROD_ARCH),,$(error VBOX_INS_PROD_ARCH is empty!))
|
---|
541 | VBOX_INS_PROD_LANG := 7="$(VBOX_INS_PROD_ARCH);1033
|
---|
542 | $(foreach lang, $(VBOX_INSTALLER_ADD_LANGUAGES), $(eval VBOX_INS_PROD_LANG := $(VBOX_INS_PROD_LANG)$(COMMA)$(VBOX_BRAND_$(lang)_LANG_ID)))
|
---|
543 | VBOX_INS_PROD_LANG := $(VBOX_INS_PROD_LANG)"
|
---|
544 |
|
---|
545 | $(PACKAGE_NAME_FINAL): \
|
---|
546 | $(VBOX_WIN_INST_OUT_DIR)/Files_Main.wxi \
|
---|
547 | $(VBOX_WIN_INST_OUT_DIR)/Files_Doc.wxi \
|
---|
548 | $(VBOX_WIN_INST_OUT_DIR)/Files_License.wxi \
|
---|
549 | $(VBOX_WIN_INST_OUT_DIR)/Shortcuts_StartMenu.wxi \
|
---|
550 | $(foreach lang,$(VBOX_INSTALLER_LANGUAGES), $(VBOX_WIN_INST_OUT_DIR)/$(PACKAGE_NAME_LANG)_$(lang).msi) \
|
---|
551 | $(foreach lang,$(VBOX_INSTALLER_ADD_LANGUAGES), $(VBOX_WIN_INST_OUT_DIR)/Languages/$(lang).mst) \
|
---|
552 | | $$(dir $$@)
|
---|
553 | $(QUIET)$(RM) -f $(wildcard $(PATH_BIN)/$(PACKAGE_BASE)-r*.msi)
|
---|
554 | $(REDIRECT) -C $(@D) -- \
|
---|
555 | wscript.exe $(VBOX_PATH_WISUMINFO) $(VBOX_WIN_INST_OUT_DIR)/$(PACKAGE_NAME_LANG)_en_US.msi $(VBOX_INS_PROD_LANG)
|
---|
556 | $(CP) -f $(VBOX_WIN_INST_OUT_DIR)/$(PACKAGE_NAME_LANG)_en_US.msi $@
|
---|
557 | $(call VBOX_SIGN_FILE_FN,$@)
|
---|
558 |
|
---|
559 |
|
---|
560 | if defined(VBOX_WITH_COMBINED_PACKAGE) && "$(KBUILD_TARGET_ARCH)" == "x86"
|
---|
561 | #
|
---|
562 | # Make the multi-architecture installer by calling our stub builder
|
---|
563 | # with both platform installers (x86 and amd64) + common cab. We only
|
---|
564 | # need to do this once; so do it on x86 only.
|
---|
565 | #
|
---|
566 | $(PATH_BIN)/$(PACKAGE_NAME_MULTIARCH_FINAL): \
|
---|
567 | $(PATH_MULTIARCH_TEMP)/$(PACKAGE_NAME_MULTIARCH.x86) \
|
---|
568 | $(PATH_MULTIARCH_TEMP)/$(PACKAGE_NAME_MULTIARCH.amd64)
|
---|
569 | $(call MSG_L1,Building Windows combined package)
|
---|
570 | $(call VBOX_SIGN_FILE_FN,$(VBOX_WIN_INST_OUT_DIR)/$(PACKAGE_NAME_MULTIARCH_COMMONCAB))
|
---|
571 | $(REDIRECT) -C $(@D) -- \
|
---|
572 | VBoxStubBld -out $@ \
|
---|
573 | -target-x86 $(PATH_MULTIARCH_TEMP)/$(PACKAGE_NAME_MULTIARCH.x86) \
|
---|
574 | -target-amd64 $(PATH_MULTIARCH_TEMP)/$(PACKAGE_NAME_MULTIARCH.amd64) \
|
---|
575 | -target-all $(VBOX_WIN_INST_OUT_DIR)/$(PACKAGE_NAME_MULTIARCH_COMMONCAB) \
|
---|
576 | -stub $(PATH_BIN)/VBoxStub.exe
|
---|
577 | $(call VBOX_SIGN_FILE_FN,$@)
|
---|
578 | endif
|
---|
579 |
|
---|
580 |
|
---|
581 | #
|
---|
582 | # Make the bundle installer (for retail ISOs) (zip-file).
|
---|
583 | #
|
---|
584 | $(VBOX_PATH_PACK_BUNDLE_ZIP): \
|
---|
585 | $(PACKAGE_NAME_FINAL) \
|
---|
586 | $(if-expr "$(KBUILD_TARGET_ARCH)" == "x86", \
|
---|
587 | $(PATH_BIN)/VBoxBundleMachine.exe \
|
---|
588 | $(if $(VBOX_BRAND_WIN_AS_MENU), $(PATH_BIN)/AutoStartMenu.exe) \
|
---|
589 | $(if $(VBOX_WITH_COMBINED_PACKAGE), $(PATH_BIN)/$(PACKAGE_NAME_MULTIARCH_FINAL)),)
|
---|
590 | $(RM) -Rf -- $(VBOX_PATH_PACK_BUNDLE_TMP)/
|
---|
591 | $(MKDIR) -p $(VBOX_PATH_PACK_BUNDLE_TMP)/
|
---|
592 | ifndef VBOX_WITH_COMBINED_PACKAGE
|
---|
593 | $(CP) $(PACKAGE_NAME_FINAL) $(VBOX_PATH_PACK_BUNDLE_TMP)/$(VBOX_BRAND_WIN_INST_NAME.$(KBUILD_TARGET_ARCH))
|
---|
594 | endif
|
---|
595 | ifeq ($(KBUILD_TARGET_ARCH),x86)
|
---|
596 | ifdef VBOX_WITH_COMBINED_PACKAGE
|
---|
597 | $(CP) $(PATH_BIN)/$(PACKAGE_NAME_MULTIARCH_FINAL) $(VBOX_PATH_PACK_BUNDLE_TMP)/$(PACKAGE_NAME_MULTIARCH_FINAL)
|
---|
598 | endif
|
---|
599 | $(CP) $(PATH_BIN)/VBoxBundleMachine.exe $(VBOX_PATH_PACK_BUNDLE_TMP)/
|
---|
600 | $(CP) $(PATH_BIN)/AutoStartMenu.exe $(VBOX_PATH_PACK_BUNDLE_TMP)/
|
---|
601 | ifdef VBOX_BRAND_WIN_AS_MENU
|
---|
602 | $(MKDIR) -p $(VBOX_PATH_PACK_BUNDLE_TMP)/Menu/Graphics/
|
---|
603 | $(CP) $(VBOX_BRAND_WIN_AS_CONTENT) $(VBOX_PATH_PACK_BUNDLE_TMP)/
|
---|
604 | $(CP) $(VBOX_BRAND_WIN_AS_MENU_CONTENT) $(VBOX_PATH_PACK_BUNDLE_TMP)/Menu/
|
---|
605 | $(CP) $(VBOX_BRAND_WIN_AS_MENU_CONTENT_GFX) $(VBOX_PATH_PACK_BUNDLE_TMP)/Menu/Graphics/
|
---|
606 | ifdef VBOX_WITH_COMBINED_PACKAGE
|
---|
607 | $(SED) -e 's/VBOXEXE/$(PACKAGE_NAME_MULTIARCH_FINAL)/g' \
|
---|
608 | --output $(VBOX_PATH_PACK_BUNDLE_TMP)/Menu/index.html \
|
---|
609 | $(VBOX_BRAND_WIN_AS_MENU)/index_combined.html
|
---|
610 | else
|
---|
611 | $(SED) -e 's/VBOX32EXE/$(VBOX_BRAND_WIN_INST_NAME.x86)/g' \
|
---|
612 | -e 's/VBOX64EXE/$(VBOX_BRAND_WIN_INST_NAME.amd64)/g' \
|
---|
613 | --output $(VBOX_PATH_PACK_BUNDLE_TMP)/Menu/index.html \
|
---|
614 | $(VBOX_BRAND_WIN_AS_MENU)/index.html
|
---|
615 | endif
|
---|
616 | endif
|
---|
617 | endif
|
---|
618 | ifeq ($(KBUILD_TARGET_ARCH),amd64)
|
---|
619 | ifndef VBOX_WITH_COMBINED_PACKAGE
|
---|
620 | # Only needed if *not* combined package -- otherwise the 64-bit build
|
---|
621 | # has nothing to do here since the one and only amd64 .MSI file is already
|
---|
622 | # included in the x86 combined package.
|
---|
623 | $(REDIRECT) -C $(VBOX_PATH_PACK_BUNDLE_TMP) -- $(ZIP) -9r $@ .
|
---|
624 | endif
|
---|
625 | else
|
---|
626 | # Do a bundle .zip in every case on x86. On a combined package this also
|
---|
627 | # will include the amd64 installer we left out in the block above (see comment).
|
---|
628 | $(REDIRECT) -C $(VBOX_PATH_PACK_BUNDLE_TMP) -- $(ZIP) -9r $@ .
|
---|
629 | endif
|
---|
630 |
|
---|
631 | include $(KBUILD_PATH)/subfooter.kmk
|
---|