1 | # $Id: Makefile.kmk 96614 2022-09-06 18:00:40Z vboxsync $
|
---|
2 | ## @file
|
---|
3 | # Makefile for the Windows installer.
|
---|
4 | #
|
---|
5 |
|
---|
6 | #
|
---|
7 | # Copyright (C) 2006-2022 Oracle and/or its affiliates.
|
---|
8 | #
|
---|
9 | # This file is part of VirtualBox base platform packages, as
|
---|
10 | # available from https://www.virtualbox.org.
|
---|
11 | #
|
---|
12 | # This program is free software; you can redistribute it and/or
|
---|
13 | # modify it under the terms of the GNU General Public License
|
---|
14 | # as published by the Free Software Foundation, in version 3 of the
|
---|
15 | # License.
|
---|
16 | #
|
---|
17 | # This program is distributed in the hope that it will be useful, but
|
---|
18 | # WITHOUT ANY WARRANTY; without even the implied warranty of
|
---|
19 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
---|
20 | # General Public License for more details.
|
---|
21 | #
|
---|
22 | # You should have received a copy of the GNU General Public License
|
---|
23 | # along with this program; if not, see <https://www.gnu.org/licenses>.
|
---|
24 | #
|
---|
25 | # SPDX-License-Identifier: GPL-3.0-only
|
---|
26 | #
|
---|
27 |
|
---|
28 | SUB_DEPTH = ../../../..
|
---|
29 | include $(KBUILD_PATH)/subheader.kmk
|
---|
30 |
|
---|
31 | ifneq ($(KBUILD_HOST),win)
|
---|
32 | $(error "The Windows installer can only be built on Windows!")
|
---|
33 | endif
|
---|
34 |
|
---|
35 |
|
---|
36 | #
|
---|
37 | # Include Sub-Makefiles.
|
---|
38 | #
|
---|
39 | include $(PATH_SUB_CURRENT)/InstallHelper/Makefile.kmk
|
---|
40 |
|
---|
41 | include $(PATH_SUB_CURRENT)/Stub/Makefile.kmk
|
---|
42 | include $(PATH_SUB_CURRENT)/StubBld/Makefile.kmk
|
---|
43 | include $(PATH_SUB_CURRENT)/Resources/Makefile.kmk
|
---|
44 | ifdef VBOX_WITH_MSI_HACK
|
---|
45 | include $(PATH_SUB_CURRENT)/MsiHack/Makefile.kmk
|
---|
46 | endif
|
---|
47 |
|
---|
48 | #
|
---|
49 | # Profile for quickly testing the actual mechanisms of our installer.
|
---|
50 | # This leaves out most of the optional stuff to make compilation / linking much
|
---|
51 | # faster for development cycles. Tweak to your likings if needed.
|
---|
52 | #
|
---|
53 | # Note! Rather hacky approach -- this *only* works when 'packing' is executed
|
---|
54 | # directly in the VBox\Installer directory; otherwise with WILL break the
|
---|
55 | # build mostly likely, as we mess with dependencies between components.
|
---|
56 | #
|
---|
57 | # A better appraoch would be to define separate packing defines for dependencies
|
---|
58 | # to decouple the building process from the packing more in such a scenario.
|
---|
59 | #
|
---|
60 | # Use with care!
|
---|
61 | #
|
---|
62 | ifdef VBOX_INSTALLER_QUICK
|
---|
63 | VBOX_INSTALLER_LANGUAGES := en_US
|
---|
64 | VBOX_WITH_LICENSE_DISPLAY :=
|
---|
65 | VBOX_WITH_SERIALNUMBER_INSTALL :=
|
---|
66 | VBOX_WITH_ADDITIONS_PACKING :=
|
---|
67 | VBOX_WITH_DEBUGGER_GUI :=
|
---|
68 | VBOX_WITH_EFIFW_PACKING :=
|
---|
69 | VBOX_WITH_EXTPACK :=
|
---|
70 | VBOX_WITH_NETADP :=
|
---|
71 | VBOX_WITH_NETFLT :=
|
---|
72 | VBOX_WITH_PYTHON :=
|
---|
73 | VBOX_WITH_SDS :=
|
---|
74 | VBOX_WITH_WEBSERVICES :=
|
---|
75 | VBOX_WITH_UNATTENDED :=
|
---|
76 | VBOX_WITH_DOCS_PACKING :=
|
---|
77 | VBOX_WITH_QTGUI :=
|
---|
78 | VBOX_WITH_USB :=
|
---|
79 | VBOX_WITH_VBOX_IMG :=
|
---|
80 | VBOX_WITH_VBOXSDL :=
|
---|
81 | VBOX_CAB_COMPRESSION_LEVEL := none
|
---|
82 | endif
|
---|
83 |
|
---|
84 | #
|
---|
85 | # Globals.
|
---|
86 | #
|
---|
87 | # Tip: Use VBOX_CAB_COMPRESSION_LEVEL=none on the kmk command line when working
|
---|
88 | # on the installer.
|
---|
89 | #
|
---|
90 | VBOX_WIN_INST_MAKEFILE_DEP := $(MAKEFILE_CURRENT)
|
---|
91 | ifndef VBOX_CAB_COMPRESSION_LEVEL
|
---|
92 | VBOX_CAB_COMPRESSION_LEVEL := high
|
---|
93 | endif
|
---|
94 |
|
---|
95 | VBOX_PATH_WIN_INST_SRC := $(PATH_SUB_CURRENT)
|
---|
96 | VBOX_WIN_INST_OUT_DIR := $(PATH_TARGET)/Installer/win
|
---|
97 | VBOX_WIN_INST_REPACK_DIR := $(PATH_OUT)/repack
|
---|
98 |
|
---|
99 | # Note: en_US *must* come first for the dependency file generation.
|
---|
100 | ifndef VBOX_INSTALLER_LANGUAGES
|
---|
101 | VBOX_INSTALLER_LANGUAGES = en_US de_DE el_GR fr_FR it_IT tr_TR zh_TW zh_CN
|
---|
102 | VBOX_INSTALLER_LANGUAGES += $(VBOX_INSTALLER_ADD_LANGUAGES)
|
---|
103 | endif
|
---|
104 |
|
---|
105 | # Aliases for VBOX_SIGN_FILE_FN that allows better control of the MSI and MSM signing.
|
---|
106 | VBOX_SIGN_MSI_FN ?= $(VBOX_SIGN_FILE_FN)
|
---|
107 | VBOX_SIGN_MSM_FN ?= $(VBOX_SIGN_FILE_FN)
|
---|
108 | VBOX_SIGN_CAB_FN ?= $(VBOX_SIGN_FILE_FN)
|
---|
109 |
|
---|
110 | #
|
---|
111 | # List of merge modules to use.
|
---|
112 | #
|
---|
113 | ifndef VBOX_INSTALLER_MERGE_MODULES
|
---|
114 | VBOX_INSTALLER_MERGE_MODULES = App
|
---|
115 | ifdef VBOX_WITH_NETADP
|
---|
116 | VBOX_INSTALLER_MERGE_MODULES += NetAdp NetAdp6
|
---|
117 | endif
|
---|
118 | ifdef VBOX_WITH_NETFLT
|
---|
119 | VBOX_INSTALLER_MERGE_MODULES += NetLwf NetFlt
|
---|
120 | endif
|
---|
121 | ifdef VBOX_WITH_USB
|
---|
122 | VBOX_INSTALLER_MERGE_MODULES += USB
|
---|
123 | endif
|
---|
124 | ifdef VBOX_WITH_PYTHON
|
---|
125 | VBOX_INSTALLER_MERGE_MODULES += Python
|
---|
126 | endif
|
---|
127 | endif
|
---|
128 | ifeq ($(KBUILD_TARGET_ARCH),amd64)
|
---|
129 | VBOX_INSTALLER_MERGE_MODULES += COM32On64
|
---|
130 | endif
|
---|
131 |
|
---|
132 | # We only ship the merge modules in locale en_US for the moment.
|
---|
133 | ifdef VBOX_WITH_MSM_INSTALL
|
---|
134 | VBOX_INSTALLER_LANGUAGES := en_US
|
---|
135 | VBOX_INSTALLER_MERGE_LANGUAGES = $(VBOX_INSTALLER_LANGUAGES)
|
---|
136 | endif
|
---|
137 |
|
---|
138 | #
|
---|
139 | # Language IDs (LCID, decimal)
|
---|
140 | #
|
---|
141 | VBOX_BRAND_en_US_LANG_ID ?= 1033
|
---|
142 | VBOX_BRAND_de_DE_LANG_ID ?= 1031
|
---|
143 | VBOX_BRAND_el_GR_LANG_ID ?= 1032
|
---|
144 | VBOX_BRAND_fa_IR_LANG_ID ?= 1065
|
---|
145 | VBOX_BRAND_fr_FR_LANG_ID ?= 1036
|
---|
146 | VBOX_BRAND_it_IT_LANG_ID ?= 1040
|
---|
147 | VBOX_BRAND_tr_TR_LANG_ID ?= 1055
|
---|
148 | VBOX_BRAND_zh_TW_LANG_ID ?= 1028
|
---|
149 | VBOX_BRAND_zh_CN_LANG_ID ?= 2052
|
---|
150 |
|
---|
151 | # Standard language names (in the native language), to be extended as we go.
|
---|
152 | # VBOX_BRAND_$(lang)_LANG_NAME must be defined for each language which occurs
|
---|
153 | # in either VBOX_LICENSE_ADD_LANGUAGES or VBOX_MANUAL_ADD_LANGUAGES.
|
---|
154 | VBOX_BRAND_en_US_LANG_NAME := English
|
---|
155 | VBOX_BRAND_de_DE_LANG_NAME := Deutsch
|
---|
156 | VBOX_BRAND_el_GR_LANG_NAME := Ελληνικά
|
---|
157 | VBOX_BRAND_fr_FR_LANG_NAME := Français
|
---|
158 | VBOX_BRAND_it_IT_LANG_NAME := Italiano
|
---|
159 | VBOX_BRAND_tr_TR_LANG_NAME := Türkçe
|
---|
160 | VBOX_BRAND_zh_TW_LANG_NAME := 正體中文
|
---|
161 | VBOX_BRAND_zh_CN_LANG_NAME := 简体中文
|
---|
162 |
|
---|
163 |
|
---|
164 | #
|
---|
165 | # We don't have the license text in another language than English yet,
|
---|
166 | # so just define the branding targets to use the English one for now.
|
---|
167 | # The installer generation assumes that there is a translation for each
|
---|
168 | # of VBOX_INSTALLER_LANGUAGES.
|
---|
169 | #
|
---|
170 | $(foreach lang,$(VBOX_INSTALLER_LANGUAGES), \
|
---|
171 | $(eval VBOX_BRAND_$(lang)_LICENSE_RTF := $(VBOX_BRAND_LICENSE_RTF)))
|
---|
172 |
|
---|
173 | #
|
---|
174 | # Set the codepage for all languages to 1252, covers most cases.
|
---|
175 | #
|
---|
176 | $(foreach lang,$(sort $(VBOX_INSTALLER_LANGUAGES) $(VBOX_LICENSE_ADD_LANGUAGES) $(VBOX_MANUAL_ADD_LANGUAGES)), \
|
---|
177 | $(eval VBOX_BRAND_$(lang)_LANGUAGE_CODEPAGE := 1252))
|
---|
178 | # Exceptions:
|
---|
179 | VBOX_BRAND_zh_TW_LANGUAGE_CODEPAGE := 950
|
---|
180 | VBOX_BRAND_zh_CN_LANGUAGE_CODEPAGE := 936
|
---|
181 | VBOX_BRAND_fa_IR_LANGUAGE_CODEPAGE := 1256
|
---|
182 | VBOX_BRAND_tr_TR_LANGUAGE_CODEPAGE := 1254
|
---|
183 |
|
---|
184 | #
|
---|
185 | # If we want to build a combined package, we separate all common stuff
|
---|
186 | # (that is all 100% identical content between 32-/64-bit builds)
|
---|
187 | # into an own .cab file to save space. This .cab file then gets included
|
---|
188 | # and used by the 32-/64-bit installers.
|
---|
189 | #
|
---|
190 | ifdef VBOX_WITH_COMBINED_PACKAGE
|
---|
191 | VBOX_INSTALLER_COMMON_DISKID := 2
|
---|
192 | else
|
---|
193 | VBOX_INSTALLER_COMMON_DISKID := 1
|
---|
194 | endif
|
---|
195 |
|
---|
196 | ## @todo VBOX_ prefixes!
|
---|
197 | PACKAGE_BASE := VirtualBox-$(VBOX_VERSION_STRING)
|
---|
198 | PACKAGE_NAME_LANG := $(PACKAGE_BASE)-r$(VBOX_SVN_REV)
|
---|
199 | PACKAGE_NAME_FINAL := $(PATH_STAGE_BIN)/$(PACKAGE_NAME_LANG).msi
|
---|
200 |
|
---|
201 | ifdef VBOX_WITH_COMBINED_PACKAGE
|
---|
202 | PATH_MULTIARCH_TEMP := $(PATH_OUT_BASE)/win.x86/$(KBUILD_TYPE)/obj/Installer
|
---|
203 | PATH_MULTIARCH_GUEST_ADDITIONS_ISO := $(PATH_OUT_BASE)/win.amd64/$(KBUILD_TYPE)/bin/additions
|
---|
204 | PACKAGE_NAME_MULTIARCH := $(PACKAGE_NAME_LANG)-MultiArch
|
---|
205 | PACKAGE_NAME_MULTIARCH.x86 := $(PACKAGE_NAME_MULTIARCH)_x86.msi
|
---|
206 | PACKAGE_NAME_MULTIARCH.amd64 := $(PACKAGE_NAME_MULTIARCH)_amd64.msi
|
---|
207 | PACKAGE_NAME_FINAL := $(PATH_MULTIARCH_TEMP)/$(PACKAGE_NAME_MULTIARCH.$(KBUILD_TARGET_ARCH))
|
---|
208 | PACKAGE_NAME_MULTIARCH_FINAL := $(PACKAGE_NAME_MULTIARCH).exe
|
---|
209 | # Always take the common.cab from the amd64 build, as it
|
---|
210 | # might contain certain files for x86 compatibility such
|
---|
211 | # as our 32-on-64-bit COM stuff.
|
---|
212 | PACKAGE_NAME_MULTIARCH_COMMONCAB := $(PATH_OUT_BASE)/win.amd64/$(KBUILD_TYPE)/obj/Installer/win/common.cab
|
---|
213 |
|
---|
214 | BLDDIRS += $(PATH_MULTIARCH_TEMP)
|
---|
215 | PACKING += $(PACKAGE_NAME_FINAL)
|
---|
216 | ifeq ($(KBUILD_TARGET_ARCH),x86)
|
---|
217 | PACKING += $(PATH_STAGE_BIN)/$(PACKAGE_NAME_MULTIARCH_FINAL)
|
---|
218 | endif
|
---|
219 | else
|
---|
220 | PACKAGE_NAME_MULTIARCH := $(PACKAGE_NAME_LANG)-MultiArch
|
---|
221 | PACKAGE_NAME_MULTIARCH_FINAL := $(PACKAGE_NAME_MULTIARCH).exe
|
---|
222 | PACKING += $(PACKAGE_NAME_FINAL) $(PATH_STAGE_BIN)/$(PACKAGE_NAME_MULTIARCH_FINAL)
|
---|
223 | endif
|
---|
224 | BLDDIRS += \
|
---|
225 | $(VBOX_WIN_INST_OUT_DIR) \
|
---|
226 | $(VBOX_WIN_INST_REPACK_DIR)/ \
|
---|
227 | $(foreach lang,$(VBOX_INSTALLER_LANGUAGES), \
|
---|
228 | $(VBOX_WIN_INST_OUT_DIR)/$(lang)/ \
|
---|
229 | $(VBOX_WIN_INST_REPACK_DIR)/files-VirtualBox_$(lang)/ )\
|
---|
230 | $(VBOX_WIN_INST_OUT_DIR)/NLS/
|
---|
231 |
|
---|
232 | OTHER_CLEAN += \
|
---|
233 | $(VBOX_WIN_INST_OUT_DIR)/VirtualBox.wixobj \
|
---|
234 | $(VBOX_WIN_INST_OUT_DIR)/VirtualBox.wix \
|
---|
235 | $(VBOX_WIN_INST_REPACK_DIR)/VirtualBox.wix \
|
---|
236 | $(VBOX_WIN_INST_OUT_DIR)/VirtualBox.wixobj.dep \
|
---|
237 | $(VBOX_WIN_INST_OUT_DIR)/VirtualBox_TypeLib.wxi \
|
---|
238 | $(VBOX_WIN_INST_OUT_DIR)/VirtualBox_TypeLib_x86.wxi \
|
---|
239 | $(VBOX_WIN_INST_OUT_DIR)/VirtualBox_ProxyStub.wxi \
|
---|
240 | $(if $(VBOX_WITH_QTGUI),$(VBOX_WIN_INST_OUT_DIR)/VBoxGuiNLS.wxi) \
|
---|
241 | $(VBOX_WIN_INST_OUT_DIR)/VBoxKey.wxi \
|
---|
242 | $(VBOX_WIN_INST_OUT_DIR)/VBoxUnattendedTemplateComponent.wxi \
|
---|
243 | $(foreach lang,$(VBOX_INSTALLER_LANGUAGES), \
|
---|
244 | $(VBOX_WIN_INST_OUT_DIR)/NLS/Language_$(lang).wxl \
|
---|
245 | $(VBOX_WIN_INST_OUT_DIR)/NLS/License_$(lang).wxl \
|
---|
246 | $(VBOX_WIN_INST_OUT_DIR)/$(lang)/$(lang).mst \
|
---|
247 | $(VBOX_WIN_INST_OUT_DIR)/$(lang)/$(PACKAGE_NAME_LANG)_$(lang).wixpdb \
|
---|
248 | $(VBOX_WIN_INST_OUT_DIR)/$(lang)/$(PACKAGE_NAME_LANG)_$(lang).msi \
|
---|
249 | $(VBOX_WIN_INST_OUT_DIR)/$(lang)/VirtualBox_$(lang).wix \
|
---|
250 | $(VBOX_WIN_INST_OUT_DIR)/$(lang)/VirtualBox_$(lang).wixobj \
|
---|
251 | $(VBOX_WIN_INST_OUT_DIR)/$(lang)/VirtualBox_$(lang).wixobj.dep \
|
---|
252 | $(VBOX_WIN_INST_REPACK_DIR)/VirtualBox_$(lang).wix \
|
---|
253 | $(VBOX_WIN_INST_REPACK_DIR)/VirtualBox_$(lang).files \
|
---|
254 | $(VBOX_WIN_INST_REPACK_DIR)/2-link-$(PACKAGE_NAME_LANG).cmd \
|
---|
255 | $(VBOX_WIN_INST_REPACK_DIR)/files-VirtualBox_$(lang)/Language_$(lang).wxl \
|
---|
256 | $(VBOX_WIN_INST_REPACK_DIR)/files-VirtualBox_$(lang)/License_$(lang).wxl )\
|
---|
257 | $(VBOX_WIN_INST_OUT_DIR)/DirComponentsAndFiles_DTrace.wxi \
|
---|
258 | $(VBOX_WIN_INST_OUT_DIR)/Files_Main.wxi \
|
---|
259 | $(VBOX_WIN_INST_OUT_DIR)/Files_Doc.wxi \
|
---|
260 | $(VBOX_WIN_INST_OUT_DIR)/Files_License.wxi \
|
---|
261 | $(VBOX_WIN_INST_OUT_DIR)/Shortcuts_StartMenu.wxi \
|
---|
262 | $(VBOX_WIN_INST_OUT_DIR)/$(PACKAGE_NAME_LANG).msi \
|
---|
263 | $(VBOX_WIN_INST_REPACK_DIR)/3-multilingual-$(PACKAGE_NAME_LANG).cmd \
|
---|
264 | $(PATH_STAGE_BIN)/$(PACKAGE_NAME_MULTIARCH_FINAL)
|
---|
265 |
|
---|
266 | ifdef VBOX_WITH_COMBINED_PACKAGE
|
---|
267 | ifeq ($(KBUILD_TARGET_ARCH),x86)
|
---|
268 | OTHER_CLEAN += \
|
---|
269 | $(VBOX_WIN_INST_REPACK_DIR)/4-multiarch-$(PACKAGE_NAME_MULTIARCH_FINAL).cmd \
|
---|
270 | $(PATH_MULTIARCH_TEMP)/$(PACKAGE_NAME_MULTIARCH.x86)
|
---|
271 | endif
|
---|
272 | ifndef VBOX_WITH_MSM_INSTALL
|
---|
273 | OTHER_CLEAN += \
|
---|
274 | $(VBOX_WIN_INST_OUT_DIR)/common.cab
|
---|
275 | endif
|
---|
276 | else
|
---|
277 | OTHER_CLEAN += \
|
---|
278 | $(VBOX_WIN_INST_REPACK_DIR)/4-multiarch-$(PACKAGE_NAME_MULTIARCH_FINAL).cmd \
|
---|
279 | $(PACKAGE_NAME_FINAL)
|
---|
280 | endif
|
---|
281 |
|
---|
282 | ifdef VBOX_WITH_MSM_INSTALL
|
---|
283 | OTHER_CLEAN += \
|
---|
284 | $(foreach module,$(VBOX_INSTALLER_MERGE_MODULES), \
|
---|
285 | $(foreach lang,$(VBOX_INSTALLER_MERGE_LANGUAGES), \
|
---|
286 | $(VBOX_WIN_INST_OUT_DIR)/VBoxMerge$(module)_$(lang)_$(KBUILD_TARGET_ARCH).msm \
|
---|
287 | $(VBOX_WIN_INST_OUT_DIR)/VBoxMerge$(module)_$(lang).wixobj \
|
---|
288 | $(VBOX_WIN_INST_OUT_DIR)/VBoxMerge$(module)_$(lang).wixobj.dep \
|
---|
289 | $(VBOX_WIN_INST_OUT_DIR)/VBoxMerge$(module)_$(lang).wixpdb \
|
---|
290 | $(VBOX_WIN_INST_REPACK_DIR)/VBoxMerge$(module)_$(lang).wix \
|
---|
291 | $(VBOX_WIN_INST_REPACK_DIR)/VBoxMerge$(module)_$(lang).files)
|
---|
292 | BLDDIRS += $foreach lang,$(VBOX_INSTALLER_MERGE_LANGUAGES), \
|
---|
293 | $(VBOX_WIN_INST_REPACK_DIR)/files-VBoxMerge$(module)_$(lang)/)
|
---|
294 | endif
|
---|
295 |
|
---|
296 | #
|
---|
297 | # Suppress/skip the following ICE (Internal Consistency Evaluators):
|
---|
298 | # - ICE64: Checks that new directories in the user profile are removed correctly in roaming scenarios.
|
---|
299 | # -> We don't want to remove system folders (like "Microsoft/Internet Explorer/Quick Launch").
|
---|
300 | # - ICE69: Checks if file references are within the same component.
|
---|
301 | # -> We reference to files within different components, but these components are installed using
|
---|
302 | # the same feature, so that's fine.
|
---|
303 | #
|
---|
304 | VBOX_MSI_ICE_IGNORE := \
|
---|
305 | -ice:64 \
|
---|
306 | -ice:69
|
---|
307 |
|
---|
308 | #
|
---|
309 | # Create intermediate XML file for languages (needed for .MSI linking).
|
---|
310 | #
|
---|
311 | # Note: The double escaping of $(dir $@) in the prereq/dep list is because we first have
|
---|
312 | # to escape the expansion of the $(eval ) argument and then the definition of the
|
---|
313 | # rule. The statement is finally expanded during second dependency expansion, which
|
---|
314 | # takes place after all makefiles has been loaded and with the @ variable defined.
|
---|
315 | #
|
---|
316 | define def_vbox_lang_xml
|
---|
317 | $(VBOX_WIN_INST_OUT_DIR)/NLS/Language_$(lang).wxl: $(VBOX_PATH_WIN_INST_SRC)/NLS/$(lang).wxl | $$$$(dir $$$$@)
|
---|
318 | $$(call MSG_GENERATE,,$$@,$$<)
|
---|
319 | $(QUIET)$(INSTALL) -m 0644 $$< $$@
|
---|
320 | endef
|
---|
321 |
|
---|
322 | $(foreach lang,$(VBOX_INSTALLER_LANGUAGES), \
|
---|
323 | $(eval $(def_vbox_lang_xml)))
|
---|
324 |
|
---|
325 | #
|
---|
326 | # Create intermediate XML file for licenses (needed for .MSI linking).
|
---|
327 | # These files are created from the original .RTF files in the /docs directory.
|
---|
328 | #
|
---|
329 | # Note: The redirect command below will open $$@ as stdout in append+text mode
|
---|
330 | # and then exec cat, thus appending the license file to the result file.
|
---|
331 | #
|
---|
332 | # Note: The license_file variable has to be created before def_vbox_license_xml
|
---|
333 | # is expanded by the 2nd eval because we rely on the that expansion
|
---|
334 | # replacing all $(license_file) (and $(lang)) references before evaluation.
|
---|
335 | #
|
---|
336 | # Note: The REDIRECT + ECHO_EXT is because WiX gets upset if there a newline
|
---|
337 | # between the tag and the RTF license text.
|
---|
338 | #
|
---|
339 | define def_vbox_license_xml
|
---|
340 | $(VBOX_WIN_INST_OUT_DIR)/NLS/License_$(lang).wxl: $(license_file) $(VBOX_WIN_INST_MAKEFILE_DEP) | $$$$(dir $$$$@)
|
---|
341 | $$(call MSG_GENERATE,,$$@,$$<)
|
---|
342 | $(APPEND) -t $$@ '<?xml version="1.0" encoding="utf-8"?>'
|
---|
343 | $(APPEND) $$@ '<WixLocalization xmlns="http://schemas.microsoft.com/wix/2006/localization" Codepage="$(VBOX_BRAND_$(lang)_LANGUAGE_CODEPAGE)" Culture="$(lang)">'
|
---|
344 |
|
---|
345 | $(REDIRECT) -a+to $$@ -- $(ECHO_EXT) -n '<String Id="LicenseText">'
|
---|
346 | $(REDIRECT) -a+to $$@ -- $(SED) -e "s|<|\<|g" -e "s|>|\>|g" $(license_file)
|
---|
347 | $(APPEND) $$@ '</String>'
|
---|
348 |
|
---|
349 | $(APPEND) $$@ '<String Id="LicenseFile">$(license_file)</String>'
|
---|
350 | $(APPEND) $$@ '<String Id="LicenseInstallFileLong">License_$(lang).rtf</String>'
|
---|
351 | $(APPEND) $$@ '<String Id="LicenseInstallFileShort">L_$(lang).rtf</String>'
|
---|
352 |
|
---|
353 | $(APPEND) $$@ '</WixLocalization>'
|
---|
354 | endef
|
---|
355 |
|
---|
356 | $(foreach lang,$(VBOX_INSTALLER_LANGUAGES), \
|
---|
357 | $(eval local license_file := $(VBOX_BRAND_$(subst en_US_,,$(lang)_)LICENSE_RTF)) \
|
---|
358 | $(eval $(def_vbox_license_xml)))
|
---|
359 |
|
---|
360 | #
|
---|
361 | # Create one intermediate WXI (Windows Installer Include) file for all installers (needed for .MSI compiling).
|
---|
362 | # This file includes all language-specific files (PDFs, CHMs, ...) to install.
|
---|
363 | #
|
---|
364 | # Note: When using the -n switch, append will append a new line after each
|
---|
365 | # argument. The -t switch makes it truncate the file.
|
---|
366 | #
|
---|
367 | $(VBOX_WIN_INST_OUT_DIR)/Files_Main.wxi: $(VBOX_WIN_INST_MAKEFILE_DEP) | $$(dir $$@)
|
---|
368 | $(call MSG_GENERATE,,$@,$<)
|
---|
369 | $(APPEND) -t $@ '<?xml version="1.0" ?>'
|
---|
370 | $(APPEND) $@ '<Include xmlns="http://schemas.microsoft.com/wix/2006/wi">'
|
---|
371 | ifdef VBOX_WITH_DOCS_PACKING
|
---|
372 | ifdef VBOX_WITH_DOCS_CHM_PACKING
|
---|
373 | $(APPEND) $@ ' <File Id="file_VirtualBox.chm" Name="VirtualBox.chm" DiskId="$(VBOX_INSTALLER_COMMON_DISKID)" Vital="yes" Source="$(subst /,\,$(PATH_STAGE_BIN)/VirtualBox.chm)"></File>'
|
---|
374 | $(APPEND) -n $@ $(foreach lang,$(VBOX_MANUAL_ADD_LANGUAGES), \
|
---|
375 | ' <File Id="file_VirtualBox_$(lang).chm" Name="VirtualBox_$(lang).chm" DiskId="$(VBOX_INSTALLER_COMMON_DISKID)" Vital="yes" Source="$(subst /,\,$(PATH_STAGE_BIN)/VirtualBox_$(lang).chm)"></File>')
|
---|
376 | endif
|
---|
377 | ifdef VBOX_WITH_DOCS_QHELP_PACKING
|
---|
378 | $(APPEND) $@ ' <File Id="file_UserManual.qch" Name="UserManual.qch" DiskId="$(VBOX_INSTALLER_COMMON_DISKID)" Vital="yes" Source="$(subst /,\,$(PATH_STAGE_BIN)/UserManual.qch)"></File>'
|
---|
379 | $(APPEND) $@ ' <File Id="file_UserManual.qhc" Name="UserManual.qhc" DiskId="$(VBOX_INSTALLER_COMMON_DISKID)" Vital="yes" Source="$(subst /,\,$(PATH_STAGE_BIN)/UserManual.qhc)"></File>'
|
---|
380 | $(APPEND) -n $@ $(foreach lang,$(VBOX_MANUAL_ADD_LANGUAGES), \
|
---|
381 | ' <File Id="file_UserManual_$(lang).qch" Name="UserManual_$(lang).qch" DiskId="$(VBOX_INSTALLER_COMMON_DISKID)" Vital="yes" Source="$(subst /,\,$(PATH_STAGE_BIN)/UserManual_$(lang).qch)"></File>' \
|
---|
382 | ' <File Id="file_UserManual_$(lang).qhc" Name="UserManual_$(lang).qhc" DiskId="$(VBOX_INSTALLER_COMMON_DISKID)" Vital="yes" Source="$(subst /,\,$(PATH_STAGE_BIN)/UserManual_$(lang).qhc)"></File>')
|
---|
383 | endif
|
---|
384 | endif
|
---|
385 | $(APPEND) $@ '</Include>'
|
---|
386 |
|
---|
387 | $(VBOX_WIN_INST_OUT_DIR)/Files_Doc.wxi: $(VBOX_WIN_INST_MAKEFILE_DEP) | $$(dir $$@)
|
---|
388 | $(call MSG_GENERATE,,$@,$<)
|
---|
389 | $(APPEND) -t $@ '<?xml version="1.0" ?>'
|
---|
390 | $(APPEND) $@ '<Include xmlns="http://schemas.microsoft.com/wix/2006/wi">'
|
---|
391 | ifdef VBOX_WITH_DOCS_PACKING
|
---|
392 | $(APPEND) $@ ' <File Id="file_UserManual.pdf" Name="UserManual.pdf" DiskId="$(VBOX_INSTALLER_COMMON_DISKID)" Vital="yes" Source="$(subst /,\,$(PATH_STAGE_BIN)/UserManual.pdf)">'
|
---|
393 | $(APPEND) $@ ' </File>'
|
---|
394 | $(APPEND) -n $@ $(foreach lang,$(VBOX_MANUAL_ADD_LANGUAGES), \
|
---|
395 | ' <File Id="file_UserManual_$(lang).pdf" Name="UserManual_$(lang).pdf" DiskId="$(VBOX_INSTALLER_COMMON_DISKID)" Vital="yes" Source="$(subst /,\,$(PATH_STAGE_BIN)/UserManual_$(lang).pdf)">' \
|
---|
396 | ' </File>')
|
---|
397 | endif
|
---|
398 | $(APPEND) $@ '</Include>'
|
---|
399 |
|
---|
400 | $(VBOX_WIN_INST_OUT_DIR)/Files_License.wxi: $(VBOX_WIN_INST_MAKEFILE_DEP) | $$(dir $$@)
|
---|
401 | $(call MSG_GENERATE,,$@,$<)
|
---|
402 | $(APPEND) -t $@ '<?xml version="1.0" ?>'
|
---|
403 | $(APPEND) $@ '<Include xmlns="http://schemas.microsoft.com/wix/2006/wi">'
|
---|
404 | $(APPEND) $@ ' <File Id="file_License_en_US.rtf" Name="License_en_US.rtf" DiskId="$(VBOX_INSTALLER_COMMON_DISKID)" Vital="yes" Source="$(subst /,\,$(VBOX_BRAND_LICENSE_RTF))">' \
|
---|
405 | ' </File>'
|
---|
406 | $(APPEND) -n $@ $(foreach lang,$(VBOX_LICENSE_ADD_LANGUAGES), \
|
---|
407 | ' <File Id="file_License_$(lang).rtf" Name="License_$(lang).rtf" DiskId="$(VBOX_INSTALLER_COMMON_DISKID)" Vital="yes" Source="$(subst /,\,$(VBOX_BRAND_$(lang)_LICENSE_RTF))">' \
|
---|
408 | ' </File>')
|
---|
409 | $(APPEND) $@ '</Include>'
|
---|
410 |
|
---|
411 | $(VBOX_WIN_INST_OUT_DIR)/DirComponentsAndFiles_DTrace.wxi: $(VBOX_WIN_INST_MAKEFILE_DEP) $(PATH_SUB_CURRENT)/../Config.kmk | $$(dir $$@)
|
---|
412 | $(call MSG_GENERATE,,$@,$<)
|
---|
413 | $(QUIET)$(APPEND) -nt "$@" \
|
---|
414 | '<?xml version="1.0" ?>' \
|
---|
415 | '<Include xmlns="http://schemas.microsoft.com/wix/2006/wi">'
|
---|
416 | ifdef VBOX_WITH_DTRACE
|
---|
417 | $(QUIET)$(APPEND) -n "$@" \
|
---|
418 | '<Directory Id="dir_DTrace" Name="dtrace">' \
|
---|
419 | ' <Directory Id="dir_DTrace_lib" Name="lib">' \
|
---|
420 | ' <Directory Id="dir_DTrace_lib_arch" Name="$(KBUILD_TARGET_ARCH)">' \
|
---|
421 | ' <Component Id="cp_dir_DTrace_lib_arch" Guid="7476CDF6-4157-2E17-5CCC-FF92528D2854" Win64="$$(var.Property_Win64)">' \
|
---|
422 | $(foreach file, $(VBOXINST_DTRACE_LIB_ARCH_FILES) \
|
---|
423 | , ' <File Id="file_dtrace_lib_arch_$(subst -,_,$(file))" Name="$(file)" Vital="yes" ' \
|
---|
424 | ' Source="$(subst /,\,$(PATH_STAGE_BIN)/dtrace/lib/$(KBUILD_TARGET_ARCH)/$(file))" />' ) \
|
---|
425 | ' </Component>' \
|
---|
426 | ' </Directory>' \
|
---|
427 | ' </Directory>' \
|
---|
428 | $(if $(VBOXINST_DTRACE_TESTCASE_ARCH_FILES), \
|
---|
429 | ' <Directory Id="dir_DTrace_testcase" Name="testcase">' \
|
---|
430 | ' <Directory Id="dir_DTrace_testcase_arch" Name="$(KBUILD_TARGET_ARCH)">' \
|
---|
431 | ' <Component Id="cp_dir_DTrace_testcase_arch" Guid="45DF7014-4431-6C40-6DB0-35AF7C690EE1" Win64="$$(var.Property_Win64)">' \
|
---|
432 | $(foreach file, $(VBOXINST_DTRACE_TESTCASE_ARCH_FILES) \
|
---|
433 | , ' <File Id="file_dtrace_testcase_arch_$(subst -,_,$(file))" Name="$(file)" Vital="yes" ' \
|
---|
434 | ' Source="$(subst /,\,$(PATH_STAGE_BIN)/dtrace/testcase/$(KBUILD_TARGET_ARCH)/$(file))" />' ) \
|
---|
435 | ' </Component>' \
|
---|
436 | ' </Directory>' \
|
---|
437 | ' </Directory>') \
|
---|
438 | $(if $(VBOXINST_DTRACE_SCRIPTS_FILES), \
|
---|
439 | ' <Directory Id="dir_DTrace_scripts" Name="scripts">' \
|
---|
440 | ' <Component Id="cp_dir_DTrace_scripts" Guid="AE07F9D5-4FD9-ACC7-C760-E9923CE01E16" Win64="$$(var.Property_Win64)">' \
|
---|
441 | $(foreach file, $(VBOXINST_DTRACE_SCRIPTS_FILES) \
|
---|
442 | , ' <File Id="file_dtrace_scripts_$(subst -,_,$(file))" Name="$(file)" Vital="yes" ' \
|
---|
443 | ' Source="$(subst /,\,$(PATH_STAGE_BIN)/dtrace/scripts/$(file))" />' ) \
|
---|
444 | ' </Component>' \
|
---|
445 | ' </Directory>') \
|
---|
446 | '</Directory>'
|
---|
447 | endif
|
---|
448 | $(QUIET)$(APPEND) "$@" '</Include>'
|
---|
449 |
|
---|
450 |
|
---|
451 | $(VBOX_WIN_INST_OUT_DIR)/Shortcuts_StartMenu.wxi: $(VBOX_WIN_INST_MAKEFILE_DEP) | $$(dir $$@)
|
---|
452 | $(call MSG_GENERATE,,$@,$<)
|
---|
453 | $(APPEND) -t $@ '<?xml version="1.0" ?>'
|
---|
454 | $(APPEND) $@ '<Include xmlns="http://schemas.microsoft.com/wix/2006/wi">'
|
---|
455 | #
|
---|
456 | # Documentation (PDF/CHM)
|
---|
457 | #
|
---|
458 | ifdef VBOX_WITH_DOCS_PACKING
|
---|
459 | ifdef VBOX_WITH_DOCS_CHM_PACKING
|
---|
460 | $(APPEND) $@ ' <Shortcut Id="sc_StartMenu_ManualCHM_en_US" Directory="dir_StartMenuVBox" Name="!(loc.StartMenu_UserManual) (CHM, English)" Description="!(loc.StartMenu_UserManual)"' \
|
---|
461 | ' Target="[INSTALLDIR]\VirtualBox.chm" WorkingDirectory="dir_Documents" Advertise="no"/>'
|
---|
462 | $(APPEND) -n $@ $(foreach lang,$(VBOX_MANUAL_ADD_LANGUAGES), \
|
---|
463 | ' <Shortcut Id="sc_StartMenu_ManualCHM_$(lang)" Directory="dir_StartMenuVBox" Name="!(loc.StartMenu_UserManual) (CHM, $(VBOX_BRAND_$(lang)_LANG_NAME))"' \
|
---|
464 | ' Description="!(loc.StartMenu_UserManual) ($(VBOX_BRAND_$(lang)_LANG_NAME))" Target="[INSTALLDIR]\VirtualBox_$(lang).chm" WorkingDirectory="dir_Documents"/>')
|
---|
465 | endif
|
---|
466 | $(APPEND) $@ ' <Shortcut Id="sc_StartMenu_ManualPDF_en_US" Directory="dir_StartMenuVBox" Name="!(loc.StartMenu_UserManual) (PDF, English)" Description="!(loc.StartMenu_UserManual)"' \
|
---|
467 | ' Target="[INSTALLDIR]\doc\UserManual.pdf" WorkingDirectory="dir_Documents" Advertise="no"/>'
|
---|
468 | $(APPEND) -n $@ $(foreach lang,$(VBOX_MANUAL_ADD_LANGUAGES), \
|
---|
469 | ' <Shortcut Id="sc_StartMenu_ManualPDF_$(lang)" Directory="dir_StartMenuVBox" Name="!(loc.StartMenu_UserManual) (PDF, $(VBOX_BRAND_$(lang)_LANG_NAME))"' \
|
---|
470 | ' Description="!(loc.StartMenu_UserManual) ($(VBOX_BRAND_$(lang)_LANG_NAME))" Target="[INSTALLDIR]\doc\UserManual_$(lang).pdf" WorkingDirectory="dir_Documents"/>')
|
---|
471 | endif
|
---|
472 | #
|
---|
473 | # License(s) (RTF)
|
---|
474 | #
|
---|
475 | $(APPEND) $@ ' <Shortcut Id="sc_StartMenu_License_en_US" Directory="dir_StartMenuVBox" Name="!(loc.StartMenu_License) (English)" Description="!(loc.StartMenu_License)"' \
|
---|
476 | ' Target="[INSTALLDIR]License_en_US.rtf" WorkingDirectory="INSTALLDIR" Advertise="no"/>'
|
---|
477 | $(APPEND) -n $@ $(foreach lang,$(VBOX_LICENSE_ADD_LANGUAGES), \
|
---|
478 | ' <Shortcut Id="sc_StartMenu_License_$(lang)" Directory="dir_StartMenuVBox" Name="!(loc.StartMenu_License) ($(VBOX_BRAND_$(lang)_LANG_NAME))"' \
|
---|
479 | ' Description="!(loc.StartMenu_License) ($(VBOX_BRAND_$(lang)_LANG_NAME))" Target="License_$(lang).rtf" WorkingDirectory="INSTALLDIR"/>')
|
---|
480 | $(APPEND) $@ '</Include>'
|
---|
481 |
|
---|
482 | #
|
---|
483 | # .MSI linking of the main installer (en_US).
|
---|
484 | #
|
---|
485 | # Note: This will clean up any previous .msi and .wixpdb files to prevent dep
|
---|
486 | # build boxes from filling up with old files.
|
---|
487 | #
|
---|
488 | define def_vbox_link_msi
|
---|
489 | $(VBOX_WIN_INST_OUT_DIR)/$(lang)/$(PACKAGE_NAME_LANG)_$(lang).msi \
|
---|
490 | $(if-expr defined(VBOX_WITH_COMBINED_PACKAGE) && !defined(VBOX_WITH_MSM_INSTALL), + $(VBOX_WIN_INST_OUT_DIR)/common.cab,): \
|
---|
491 | $(VBOX_WIN_INST_OUT_DIR)/$(lang)/VirtualBox_$(lang).wixobj \
|
---|
492 | $(VBOX_WIN_INST_OUT_DIR)/NLS/Language_$(lang).wxl \
|
---|
493 | $(VBOX_WIN_INST_OUT_DIR)/NLS/License_$(lang).wxl \
|
---|
494 | $(PATH_STAGE_BIN)/VBoxInstallHelper.dll \
|
---|
495 | $(VBOX_SVN_REV_KMK) \
|
---|
496 | $(VBOX_WIN_INST_MAKEFILE_DEP) \
|
---|
497 | $(if-expr defined(VBOX_WITH_MSI_HACK),$(MsiHack_0_OUTDIR)/MsiHack.dll,) \
|
---|
498 | $(if-expr defined(VBOX_WITH_MSI_HACK),$(MsiHack_0_OUTDIR)/MsiHackExtension.dll,) \
|
---|
499 | | $$$$(dir $$$$@)
|
---|
500 | $$(call MSG_L1,Linking installer $$@)
|
---|
501 | $(QUIET)$(RM) -f $$(wildcard $$(subst r$$(VBOX_SVN_REV),r*,\
|
---|
502 | $$@ \
|
---|
503 | $$(basename $$@).wixpdb \
|
---|
504 | $$(VBOX_WIN_INST_REPACK_DIR)/2-link-$$(PACKAGE_NAME_LANG).cmd ))
|
---|
505 | kmk_time $$(REDIRECT_EXT) -E WIX_TEMP='$$(subst /,\,$$(@D))' -- $(VBOX_PATH_WIX)/light.exe -v -nologo \
|
---|
506 | -loc $(VBOX_WIN_INST_OUT_DIR)/NLS/Language_$(lang).wxl \
|
---|
507 | -loc $(VBOX_WIN_INST_OUT_DIR)/NLS/License_$(lang).wxl \
|
---|
508 | -ext $(VBOX_PATH_WIX)/WixUIExtension.dll \
|
---|
509 | -ext $(VBOX_PATH_WIX)/WixDifxAppExtension.dll \
|
---|
510 | -ext $(VBOX_PATH_WIX)/WixUtilExtension.dll \
|
---|
511 | $(if-expr defined(VBOX_WITH_MSI_HACK),-ext $(MsiHack_0_OUTDIR)/MsiHackExtension.dll,) \
|
---|
512 | $(VBOX_MSI_ICE_IGNORE) \
|
---|
513 | -out $$@ \
|
---|
514 | $$< \
|
---|
515 | $(VBOX_PATH_WIX)/difxapp_$(if-expr "$(KBUILD_TARGET_ARCH)" == "x86",x86,x64).wixlib
|
---|
516 | if defined(VBOX_WITH_COMBINED_PACKAGE) && !defined(VBOX_WITH_MSM_INSTALL)
|
---|
517 | $(MV) -f -- $$(@D)/common.cab $$(@D)/../common.cab
|
---|
518 | endif
|
---|
519 | ifeq ($(lang),en_US)
|
---|
520 | $(CP) -f -- "$(VBOX_WIN_INST_OUT_DIR)/NLS/Language_$(lang).wxl" "$(VBOX_WIN_INST_OUT_DIR)/NLS/License_$(lang).wxl" \
|
---|
521 | "$(VBOX_WIN_INST_REPACK_DIR)/files-VirtualBox_$(lang)/"
|
---|
522 | # Create repack script for this step.
|
---|
523 | $(APPEND) -tn "$$(VBOX_WIN_INST_REPACK_DIR)/2-link-$$(PACKAGE_NAME_LANG).cmd" \
|
---|
524 | 'if ".%KBUILD_DEVTOOLS%" == "." (echo KBUILD_DEVTOOLS is not set & exit /b1)' \
|
---|
525 | $(subst $(KBUILD_DEVTOOLS),%KBUILD_DEVTOOLS%,\
|
---|
526 | '$(VBOX_PATH_WIX)/light.exe -v -nologo ^' \
|
---|
527 | ' -loc files-VirtualBox_$(lang)/Language_$(lang).wxl ^' \
|
---|
528 | ' -loc files-VirtualBox_$(lang)/License_$(lang).wxl ^' \
|
---|
529 | ' -ext $(VBOX_PATH_WIX)/WixUIExtension.dll ^' \
|
---|
530 | ' -ext $(VBOX_PATH_WIX)/WixDifxAppExtension.dll ^' \
|
---|
531 | ' -ext $(VBOX_PATH_WIX)/WixUtilExtension.dll ^' \
|
---|
532 | $(if-expr defined(VBOX_WITH_MSI_HACK),'-ext $(MsiHack_0_OUTDIR)/MsiHackExtension.dll ^',) \
|
---|
533 | ' $(VBOX_MSI_ICE_IGNORE) ^' \
|
---|
534 | ' -out $$(@F) ^' \
|
---|
535 | ' $$(<F) ^' \
|
---|
536 | ' $(VBOX_PATH_WIX)/difxapp_$(if-expr "$(KBUILD_TARGET_ARCH)" == "x86",x86,x64).wixlib ^' \
|
---|
537 | ' || exit /b1' \
|
---|
538 | ) \
|
---|
539 | '@echo Created MSI installer: $$(@F)' \
|
---|
540 | $(if-expr defined(VBOX_WITH_COMBINED_PACKAGE) && !defined(VBOX_WITH_MSM_INSTALL),'@echo Created: common.cab',)
|
---|
541 |
|
---|
542 | endif
|
---|
543 | endef
|
---|
544 |
|
---|
545 | $(foreach lang, en_US, $(eval $(def_vbox_link_msi)))
|
---|
546 |
|
---|
547 |
|
---|
548 | #
|
---|
549 | # Merge module linking (all languages).
|
---|
550 | #
|
---|
551 | # Note: This will clean up any previous .msm to prevent dep build boxes from
|
---|
552 | # filling up with old files.
|
---|
553 | #
|
---|
554 | define def_vbox_link_msm
|
---|
555 | $(VBOX_WIN_INST_OUT_DIR)/VBoxMerge$(module)_$(lang)_$(KBUILD_TARGET_ARCH).msm: \
|
---|
556 | $(VBOX_WIN_INST_OUT_DIR)/VBoxMerge$(module)_$(lang).wixobj \
|
---|
557 | $(VBOX_WIN_INST_OUT_DIR)/NLS/Language_$(lang).wxl \
|
---|
558 | $(VBOX_WIN_INST_OUT_DIR)/NLS/License_$(lang).wxl \
|
---|
559 | $(PATH_STAGE_BIN)/VBoxInstallHelper.dll \
|
---|
560 | $(VBOX_SVN_REV_KMK) \
|
---|
561 | $(VBOX_WIN_INST_MAKEFILE_DEP) \
|
---|
562 | | $$$$(dir $$$$@)
|
---|
563 | $$(call MSG_L1,Linking installer $$@)
|
---|
564 | $(QUIET)$(RM) -f $$(wildcard $(VBOX_WIN_INST_OUT_DIR)/$(PACKAGE_BASE)-r*_$(lang).msi)
|
---|
565 | kmk_time $$(REDIRECT_EXT) -E WIX_TEMP='$$(subst /,\,$$(@D))' -- $(VBOX_PATH_WIX)/light.exe -v -nologo \
|
---|
566 | -loc $(VBOX_WIN_INST_OUT_DIR)/NLS/Language_$(lang).wxl \
|
---|
567 | -loc $(VBOX_WIN_INST_OUT_DIR)/NLS/License_$(lang).wxl \
|
---|
568 | -ext $(VBOX_PATH_WIX)/WixDifxAppExtension.dll \
|
---|
569 | -ext $(VBOX_PATH_WIX)/WixUtilExtension.dll \
|
---|
570 | $(VBOX_MSI_ICE_IGNORE) \
|
---|
571 | -out $$@ \
|
---|
572 | $$< \
|
---|
573 | $(VBOX_PATH_WIX)/difxapp_$(if-expr "$(KBUILD_TARGET_ARCH)" == "x86",x86,x64).wixlib
|
---|
574 | $(RM) -f $(VBOX_WIN_INST_OUT_DIR)/NLS/$(lang).mst
|
---|
575 | $(call VBOX_SIGN_MSM_FN,$$@,$(VBOX_PRODUCT) $(VBOX_VERSION_STRING)r$(VBOX_SVN_REV) ($(KBUILD_TARGET_ARCH)),,,disable-dual-signing)
|
---|
576 | # Create repack script for this step.
|
---|
577 | $(APPEND) -tn "$$(VBOX_WIN_INST_REPACK_DIR)/2-link-VBoxMerge$(module)_$(lang).cmd" \
|
---|
578 | 'if ".%KBUILD_DEVTOOLS%" == "." (echo KBUILD_DEVTOOLS is not set & exit /b1)' \
|
---|
579 | $(subst $(KBUILD_DEVTOOLS),%KBUILD_DEVTOOLS%,\
|
---|
580 | '$(VBOX_PATH_WIX)/light.exe -v -nologo ^' \
|
---|
581 | ' -loc files-VirtualBox_$(lang)/Language_$(lang).wxl ^' \
|
---|
582 | ' -loc files-VirtualBox_$(lang)/License_$(lang).wxl ^' \
|
---|
583 | ' -ext $(VBOX_PATH_WIX)/WixDifxAppExtension.dll ^' \
|
---|
584 | ' -ext $(VBOX_PATH_WIX)/WixUtilExtension.dll ^' \
|
---|
585 | ' $(VBOX_MSI_ICE_IGNORE) ^' \
|
---|
586 | ' -out $$(@F) ^' \
|
---|
587 | ' $$(<F) ^' \
|
---|
588 | ' $(VBOX_PATH_WIX)/difxapp_$(if-expr "$(KBUILD_TARGET_ARCH)" == "x86",x86,x64).wixlib ^' \
|
---|
589 | ' || exit /b1' \
|
---|
590 | 'call sign-sha1.cmd $$(@F) || exit /b1' \
|
---|
591 | ) \
|
---|
592 | '@echo Created MSM module: $$(@F)'
|
---|
593 | endef
|
---|
594 |
|
---|
595 | $(if-expr defined(VBOX_WITH_MSM_INSTALL), \
|
---|
596 | $(foreach module,$(VBOX_INSTALLER_MERGE_MODULES), \
|
---|
597 | $(foreach lang,$(VBOX_INSTALLER_MERGE_LANGUAGES), \
|
---|
598 | $(eval $(def_vbox_link_msm)))),)
|
---|
599 |
|
---|
600 |
|
---|
601 | #
|
---|
602 | # Add dependencies that makes sure necessary bits gets built.
|
---|
603 | # For combined packages we always use the .ISO from the amd64 build.
|
---|
604 | #
|
---|
605 | ifdef VBOX_WITH_COMBINED_PACKAGE
|
---|
606 | VBOX_MSI_DEPENDENCIES := \
|
---|
607 | $(if $(VBOX_WITH_ADDITIONS_PACKING),$(PATH_MULTIARCH_GUEST_ADDITIONS_ISO)/VBoxGuestAdditions.iso)
|
---|
608 | else
|
---|
609 | VBOX_MSI_DEPENDENCIES := \
|
---|
610 | $(if $(VBOX_WITH_ADDITIONS_PACKING),$(VBOX_PATH_ADDITIONS_ISO)/VBoxGuestAdditions.iso)
|
---|
611 | endif
|
---|
612 |
|
---|
613 | #
|
---|
614 | # A few manual dependencies to make sure everything is rebuilt when they should.
|
---|
615 | #
|
---|
616 | $(PATH_SUB_CURRENT)/VirtualBox.wxs: \
|
---|
617 | $(PATH_SUB_CURRENT)/CommonProperties.wxi \
|
---|
618 | $(PATH_SUB_CURRENT)/Defines.wxi \
|
---|
619 | $(PATH_SUB_CURRENT)/VBoxMergeApp.wxi
|
---|
620 |
|
---|
621 | $(PATH_SUB_CURRENT)/VBoxMergeApp.wxi $(PATH_SUB_CURRENT)/VirtualBox.wxs: \
|
---|
622 | $(VBOX_WIN_INST_OUT_DIR)/Files_Doc.wxi \
|
---|
623 | $(VBOX_WIN_INST_OUT_DIR)/DirComponentsAndFiles_DTrace.wxi \
|
---|
624 | $(VBOX_WIN_INST_OUT_DIR)/Files_License.wxi \
|
---|
625 | $(VBOX_WIN_INST_OUT_DIR)/Files_Main.wxi \
|
---|
626 | $(VBOX_WIN_INST_OUT_DIR)/VBoxKey.wxi \
|
---|
627 | $(VBOX_WIN_INST_OUT_DIR)/VBoxGuiNLS.wxi \
|
---|
628 | $(VBOX_WIN_INST_OUT_DIR)/VirtualBox_TypeLib.wxi \
|
---|
629 | $(VBOX_WIN_INST_OUT_DIR)/VBoxUnattendedTemplateComponent.wxi
|
---|
630 |
|
---|
631 | #
|
---|
632 | # MSI compile.
|
---|
633 | # We've separated the processing from the compilation for repacking reasons.
|
---|
634 | #
|
---|
635 | define def_vbox_compile_wixobj
|
---|
636 | includedep $(VBOX_WIN_INST_OUT_DIR)/$(lang)/VirtualBox_$(lang).wixobj.dep
|
---|
637 | $(VBOX_WIN_INST_OUT_DIR)/$(lang)/VirtualBox_$(lang).wixobj \
|
---|
638 | + $(VBOX_WIN_INST_OUT_DIR)/$(lang)/VirtualBox_$(lang).wix \
|
---|
639 | $(if-expr "$(lang)" != "en_US",, \
|
---|
640 | + $(VBOX_WIN_INST_REPACK_DIR)/VirtualBox_$(lang).wix $(VBOX_WIN_INST_REPACK_DIR)/VirtualBox_$(lang).files ): \
|
---|
641 | $(PATH_SUB_CURRENT)/VirtualBox.wxs \
|
---|
642 | $(PATH_SUB_CURRENT)/UserInterface.wxi \
|
---|
643 | $(if-expr defined(VBOX_WITH_MSM_INSTALL), \
|
---|
644 | $(foreach module,$(VBOX_INSTALLER_MERGE_MODULES), \
|
---|
645 | $(VBOX_WIN_INST_OUT_DIR)/VBoxMerge$(module)_$(lang)_$(KBUILD_TARGET_ARCH).msm), \
|
---|
646 | $(VBOX_WIN_INST_OUT_DIR)/Shortcuts_StartMenu.wxi \
|
---|
647 | $(VBOX_WIN_INST_OUT_DIR)/VirtualBox_TypeLib.wxi \
|
---|
648 | $(if $(VBOX_WITH_32_ON_64_MAIN_API),$(VBOX_WIN_INST_OUT_DIR)/VirtualBox_TypeLib_x86.wxi,) \
|
---|
649 | $(VBOX_WIN_INST_OUT_DIR)/VBoxKey.wxi \
|
---|
650 | $(if $(VBOX_WITH_CRT_PACKING),$(VBOX_WIN_INST_OUT_DIR)/VBoxCrtDlls.wxi,) \
|
---|
651 | $(if $(VBOX_WITH_CRT_PACKING),$(VBOX_WIN_INST_OUT_DIR)/VBoxCrtDlls32.wxi,) \
|
---|
652 | $(VBOX_WIN_INST_OUT_DIR)/VBoxUnattendedTemplateComponent.wxi \
|
---|
653 | $(if $(VBOX_WITH_QTGUI),$(VBOX_WIN_INST_OUT_DIR)/VBoxGuiNLS.wxi) \
|
---|
654 | $(VBOX_MSI_DEPENDENCIES)) \
|
---|
655 | $(VBOX_VERSION_STAMP) \
|
---|
656 | | $$$$(dir $$$$@) $(if-expr "$(lang)" != "en_US",, \
|
---|
657 | $(VBOX_WIN_INST_REPACK_DIR)/ $(VBOX_WIN_INST_REPACK_DIR)/files-VirtualBox_$(lang)/ )
|
---|
658 | $(QUIET)$(RM) -f -- "$$@" "$(VBOX_WIN_INST_OUT_DIR)/$(lang)/VirtualBox_$(lang).wix" "$(VBOX_WIN_INST_REPACK_DIR)/VirtualBox_$(lang).wix"
|
---|
659 | $(REDIRECT) \
|
---|
660 | -E 'PATH_OUT=$(subst /,\,$(PATH_OUT))' \
|
---|
661 | -E 'PATH_TARGET=$(subst /,\,$(VBOX_WIN_INST_OUT_DIR))' \
|
---|
662 | -E 'PATH_ROOT=$(subst /,\,$(PATH_ROOT))' \
|
---|
663 | -E 'PATH_MULTIARCH_GUEST_ADDITIONS_ISO=$(subst /,\,$(PATH_MULTIARCH_GUEST_ADDITIONS_ISO))' \
|
---|
664 | -E 'VBOX_PATH_WIN_INST_SRC=$(subst /,\,$(VBOX_PATH_WIN_INST_SRC))' \
|
---|
665 | -E 'VBOX_BRAND_WIN_INST_DLGJPG=$(subst /,\,$(VBOX_BRAND_WIN_INST_DLGJPG))' \
|
---|
666 | -E 'VBOX_ADD_LANGUAGES=$(VBOX_INSTALLER_ADD_LANGUAGES)' \
|
---|
667 | -E 'VBOX_BRAND_LICENSE_RTF=$(subst /,\,$(VBOX_BRAND_LICENSE_RTF))' \
|
---|
668 | $(foreach lang,$(VBOX_INSTALLER_LANGUAGES), \
|
---|
669 | -E 'VBOX_BRAND_$(lang)_LICENSE_RTF=$(subst /,\,$(VBOX_BRAND_$(subst en_US_,,$(lang)_)LICENSE_RTF))') \
|
---|
670 | -E 'VBOX_BUILD_NR_FOR_INST=$(VBOX_VERSION_BUILD)' \
|
---|
671 | -E 'VBOX_VENDOR=$(VBOX_VENDOR)' \
|
---|
672 | -E 'VBOX_VENDOR_SHORT=$(VBOX_VENDOR_SHORT)' \
|
---|
673 | -E 'VBOX_PRODUCT=$(VBOX_PRODUCT)' \
|
---|
674 | -E 'VBOX_C_YEAR=$(VBOX_C_YEAR)' \
|
---|
675 | -E 'VBOX_VERSION_STRING=$(VBOX_VERSION_STRING)' \
|
---|
676 | -E 'VBOX_VERSION_STRING_RAW=$(VBOX_VERSION_STRING_RAW)' \
|
---|
677 | -E 'VBOX_VERSION_MAJOR_INST=$(VBOX_VERSION_MAJOR)' \
|
---|
678 | -E 'VBOX_VERSION_MINOR_INST=$(VBOX_VERSION_MINOR)' \
|
---|
679 | -E 'VBOX_SIGNING_MODE=$(strip $(if $(VBOX_SIGNING_MODE),$(VBOX_SIGNING_MODE),none))' \
|
---|
680 | -E 'VBOX_CAB_COMPRESSION_LEVEL=$(if-expr $(lang) == "en_US",$(VBOX_CAB_COMPRESSION_LEVEL),none)' \
|
---|
681 | -E 'VBOX_CAB_COMPRESSION_LEVEL_COMMON=$(if-expr $(lang) == "en_US" && $(KBUILD_TARGET_ARCH) == "amd64",$(VBOX_CAB_COMPRESSION_LEVEL),none)' \
|
---|
682 | -E 'VBOX_GUI_USE_QGL=$(if $(VBOX_GUI_USE_QGL),yes,no)' \
|
---|
683 | -E 'VBOX_MIDL_PROXY_CLSID=$(VBOX_MIDL_PROXY_CLSID)' \
|
---|
684 | $(if-expr defined(VBOX_WITH_MSM_INSTALL), \
|
---|
685 | $(foreach module,$(VBOX_INSTALLER_MERGE_MODULES), \
|
---|
686 | -E 'VBOX_WIN_INST_MERGE_$(toupper $(module))=$(subst /,\,$(VBOX_WIN_INST_OUT_DIR)/VBoxMerge$(module)_$(lang)_$(KBUILD_TARGET_ARCH).msm')),) \
|
---|
687 | -E 'VBOX_WINDOWS_ICON_FILE=$(subst /,\,$(VBOX_WINDOWS_ICON_FILE))' \
|
---|
688 | -E 'VBOX_QT_INFIX=$(VBOX_QT_INFIX)' \
|
---|
689 | -E 'VBOX_WITH_32_ON_64_MAIN_API=$(if $(VBOX_WITH_32_ON_64_MAIN_API),yes,no)' \
|
---|
690 | -E 'VBOX_WITH_ADDITIONS_PACKING=$(if $(VBOX_WITH_ADDITIONS_PACKING),yes,no)' \
|
---|
691 | -E 'VBOX_WITH_COMBINED_PACKAGE=$(if-expr defined(VBOX_WITH_COMBINED_PACKAGE),yes,no)' \
|
---|
692 | -E 'VBOX_WITH_CRT_PACKING=$(if-expr defined(VBOX_WITH_CRT_PACKING),yes,no)' \
|
---|
693 | -E 'VBOX_WITH_DEBUGGER_GUI=$(if-expr defined(VBOX_WITH_DEBUGGER_GUI) && defined(VBOX_WITH_QTGUI),yes,no)' \
|
---|
694 | -E 'VBOX_WITH_DOCS_PACKING=$(if $(VBOX_WITH_DOCS_PACKING),yes,no)' \
|
---|
695 | -E 'VBOX_WITH_DRAG_AND_DROP=$(if $(VBOX_WITH_DRAG_AND_DROP),yes,no)' \
|
---|
696 | -E 'VBOX_WITH_DTRACE=$(if $(VBOX_WITH_DTRACE),yes,no)' \
|
---|
697 | -E 'VBOX_WITH_HOST_SHIPPING_AUDIO_TEST=$(if $(VBOX_WITH_HOST_SHIPPING_AUDIO_TEST),yes,no)' \
|
---|
698 | -E 'VBOX_WITH_EFIFW_PACKING=$(if $(VBOX_WITH_EFIFW_PACKING),yes,no)' \
|
---|
699 | -E 'VBOX_WITH_EXTPACK=$(if $(VBOX_WITH_EXTPACK),yes,no)' \
|
---|
700 | -E 'VBOX_WITH_GUEST_CONTROL=$(if $(VBOX_WITH_GUEST_CONTROL),yes,no)' \
|
---|
701 | -E 'VBOX_WITH_GUEST_PROPS=$(if $(VBOX_WITH_GUEST_PROPS),yes,no)' \
|
---|
702 | -E 'VBOX_WITH_HARDENING=$(if $(VBOX_WITH_HARDENING),yes,no)' \
|
---|
703 | -E 'VBOX_WITH_HEADLESS=$(if $(VBOX_WITH_HEADLESS),yes,no)' \
|
---|
704 | -E 'VBOX_WITH_FE_BALLOONCTRL=$(if $(VBOX_WITH_FE_BALLOONCTRL),yes,no)' \
|
---|
705 | -E 'VBOX_WITH_FE_AUTOSTART=$(if $(VBOX_WITH_FE_AUTOSTART),yes,no)' \
|
---|
706 | -E 'VBOX_WITH_FE_BUGREPORT=$(if $(VBOX_WITH_FE_BUGREPORT),yes,no)' \
|
---|
707 | -E 'VBOX_WITH_LICENSE_DISPLAY=$(if $(VBOX_WITH_LICENSE_DISPLAY),yes,no)' \
|
---|
708 | -E 'VBOX_WITH_MIDL_PROXY_STUB=$(if $(VBOX_WITH_MIDL_PROXY_STUB),yes,no)' \
|
---|
709 | -E 'VBOX_WITH_MSM_INSTALL=$(if-expr defined(VBOX_WITH_MSM_INSTALL),yes,no)' \
|
---|
710 | -E 'VBOX_WITH_NETADP=$(if $(VBOX_WITH_NETADP),yes,no)' \
|
---|
711 | -E 'VBOX_WITH_NETFLT=$(if $(VBOX_WITH_NETFLT),yes,no)' \
|
---|
712 | -E 'VBOX_WITH_PYTHON=$(if $(VBOX_WITH_PYTHON),yes,no)' \
|
---|
713 | -E 'VBOX_WITH_QTGUI=$(if $(VBOX_WITH_QTGUI),yes,no)' \
|
---|
714 | -E 'VBOX_WITH_RAW_MODE=$(if $(VBOX_WITH_RAW_MODE),yes,no)' \
|
---|
715 | -E 'VBOX_WITH_SECURELABEL=$(if $(VBOX_WITH_SECURELABEL),yes,no)' \
|
---|
716 | -E 'VBOX_WITH_SERIALNUMBER_INSTALL=$(if $(VBOX_WITH_SERIALNUMBER_INSTALL),yes,no)' \
|
---|
717 | -E 'VBOX_WITH_VIDEOHWACCEL=$(if $(VBOX_WITH_VIDEOHWACCEL),yes,no)' \
|
---|
718 | -E 'VBOX_WITH_VRDP=$(if-expr defined(VBOX_WITH_VRDP) && !defined(VBOX_WITH_EXTPACK_PUEL),yes,no)' \
|
---|
719 | -E 'VBOX_WITH_WEBSERVICES=$(if $(VBOX_WITH_WEBSERVICES),yes,no)' \
|
---|
720 | -E 'VBOX_WITH_SDS=$(if $(VBOX_WITH_SDS),yes,no)' \
|
---|
721 | -E 'VBOX_WITH_UNATTENDED=$(if $(VBOX_WITH_UNATTENDED),yes,no)' \
|
---|
722 | -E 'VBOX_WITH_USB=$(if $(VBOX_WITH_USB),yes,no)' \
|
---|
723 | -E 'VBOX_WITH_VBOX_IMG=$(if $(VBOX_WITH_VBOX_IMG)$(VBOX_WITH_TESTCASES),yes,no)' \
|
---|
724 | -E 'VBOX_WITH_VBOXSDL=$(if $(VBOX_WITH_VBOXSDL),yes,no)' \
|
---|
725 | -E 'VBOX_WITH_VMSVGA3D=$(if $(VBOX_WITH_VMSVGA3D),yes,no)' \
|
---|
726 | -E 'VBOX_WITH_VIDEOHWACCEL=$(if $(VBOX_WITH_VIDEOHWACCEL),yes,no)' \
|
---|
727 | -E 'KBUILD_TYPE=$(KBUILD_TYPE)' \
|
---|
728 | -E 'KBUILD_TARGET_ARCH=$(KBUILD_TARGET_ARCH)' \
|
---|
729 | -E 'VBOX_INSTALLER_QUICK=$(VBOX_INSTALLER_QUICK)' \
|
---|
730 | -E 'VBOX_VCC_TOOL_STEM=$(VBOX_VCC_TOOL_STEM)' \
|
---|
731 | -- \
|
---|
732 | $(VBOX_PATH_WIX)/candle.exe $(filter-out $(VBOX_VERSION_STAMP),$$<) \
|
---|
733 | -ext $(VBOX_PATH_WIX)/WixUIExtension.dll \
|
---|
734 | -ext $(VBOX_PATH_WIX)/WixDifxAppExtension.dll \
|
---|
735 | -ext $(VBOX_PATH_WIX)/WixUtilExtension.dll \
|
---|
736 | -p$(VBOX_WIN_INST_OUT_DIR)/$(lang)/VirtualBox_$(lang).wix
|
---|
737 | $(VBOX_PATH_WIX)/candle.exe $(VBOX_WIN_INST_OUT_DIR)/$(lang)/VirtualBox_$(lang).wix \
|
---|
738 | -ext $(VBOX_PATH_WIX)/WixUIExtension.dll \
|
---|
739 | -ext $(VBOX_PATH_WIX)/WixDifxAppExtension.dll \
|
---|
740 | -ext $(VBOX_PATH_WIX)/WixUtilExtension.dll \
|
---|
741 | -out $$@
|
---|
742 | ifeq ($(lang),en_US)
|
---|
743 | # Copy preprocessed wix and change source paths to be relative. Stuff not in ../bin needs copying.
|
---|
744 | $(SED) -e 's,$(subst /,\\,$(PATH_OUT))\\bin,..\\bin,g' \
|
---|
745 | -e 's,$(subst /,\\,$(PATH_OUT_BASE))\\win.amd64\\$(KBUILD_TYPE)\\bin,..\\..\\..\\win.amd64\\$(KBUILD_TYPE)\\bin,g' \
|
---|
746 | -e 's,$(subst /,\\,$(PATH_OUT_BASE))\\win.x86\\$(KBUILD_TYPE)\\bin,..\\..\\..\\win.x86\\$(KBUILD_TYPE)\\bin,g' \
|
---|
747 | \
|
---|
748 | -e 's,$(subst /,\\,$(PATH_ROOT))\\doc\\,files-VirtualBox_$(lang)\\,g' \
|
---|
749 | -e 's,$(subst /,\\,$(VBOX_PATH_WIN_INST_SRC))\\Binary\\,files-VirtualBox_$(lang)\\,g' \
|
---|
750 | -e 's,$(subst /,\\,$(VBOX_WIN_INST_OUT_DIR))\\,,g' \
|
---|
751 | -e 's,$(subst /,\\,$(dir $(VBOX_WINDOWS_ICON_FILE))),files-VirtualBox_$(lang)\\,g' \
|
---|
752 | --output "$(VBOX_WIN_INST_REPACK_DIR)/VirtualBox_$(lang).wix" \
|
---|
753 | "$(VBOX_WIN_INST_OUT_DIR)/$(lang)/VirtualBox_$(lang).wix"
|
---|
754 | $(SED) -n \
|
---|
755 | -e '/<\?ln /d' \
|
---|
756 | -e '/$(subst /,\\,$(PATH_ROOT))/p' \
|
---|
757 | -e '/$(subst /,\\,$(PATH_ROOT))/q2' \
|
---|
758 | "$(VBOX_WIN_INST_REPACK_DIR)/VirtualBox_$(lang).wix"
|
---|
759 | $(SED) -n \
|
---|
760 | -e '/<\?ln /d' \
|
---|
761 | -e 's/\\/\//g' \
|
---|
762 | -e 's,^.*"\($(PATH_ROOT)/doc/[^"]*\)".*$$(DOLLAR),\1,p' \
|
---|
763 | -e 's,^.*"\($(VBOX_PATH_WIN_INST_SRC)/Binary/[^"]*\)".*$$(DOLLAR),\1,p' \
|
---|
764 | -e 's,^.*"\($(dir $(VBOX_WINDOWS_ICON_FILE))[^"]*\)".*$$(DOLLAR),\1,p' \
|
---|
765 | --output "$(VBOX_WIN_INST_REPACK_DIR)/VirtualBox_$(lang).files" \
|
---|
766 | "$(VBOX_WIN_INST_OUT_DIR)/$(lang)/VirtualBox_$(lang).wix"
|
---|
767 | set -xe && for file in `$(CAT_EXT) "$(VBOX_WIN_INST_REPACK_DIR)/VirtualBox_$(lang).files"`; \
|
---|
768 | do $(CP_EXT) -f -- "$$(DOLLAR){file}" "$(VBOX_WIN_INST_REPACK_DIR)/files-VirtualBox_$(lang)/"; done
|
---|
769 | # Create repack script for this step.
|
---|
770 | $(APPEND) -tn "$(VBOX_WIN_INST_REPACK_DIR)/1-compile-VirtualBox_$(lang).cmd" \
|
---|
771 | 'if ".%KBUILD_DEVTOOLS%" == "." (echo KBUILD_DEVTOOLS is not set & exit /b1)' \
|
---|
772 | $(subst $(KBUILD_DEVTOOLS),%KBUILD_DEVTOOLS%,\
|
---|
773 | '$(VBOX_PATH_WIX)/candle.exe VirtualBox_$(lang).wix ^' \
|
---|
774 | ' -ext $(VBOX_PATH_WIX)/WixUIExtension.dll ^' \
|
---|
775 | ' -ext $(VBOX_PATH_WIX)/WixDifxAppExtension.dll ^' \
|
---|
776 | ' -ext $(VBOX_PATH_WIX)/WixUtilExtension.dll ^' \
|
---|
777 | ' -out $$(@F) || exit /b1' \
|
---|
778 | ) \
|
---|
779 | '@echo Created: $$(@F)'
|
---|
780 | endif
|
---|
781 | # Generate wxi dependencies based on the sourceLineNumber references in the output. Add repack file list for cleanup.
|
---|
782 | $(QUIET)$(APPEND) -t '$$@.dep' '$$@: \'
|
---|
783 | $(QUIET)$(VBOX_XSLTPROC) $(VBOX_PATH_WIN_INST_SRC)/dep.xsl "$$@" >> "$$@.dep"
|
---|
784 | $(QUIET)$(VBOX_XSLTPROC) $(VBOX_PATH_WIN_INST_SRC)/dep2.xsl "$$@" | sort | $(SED) '$!N; /^\(.*\)\n\1$$$$/!P; D' >> "$$@.dep"
|
---|
785 | $(QUIET)$(APPEND) -n '$$@.dep' '' ''
|
---|
786 | ifeq ($(lang),en_US)
|
---|
787 | $(QUIET)$(APPEND) -n '$$@.dep' 'define VBOX_REPACK_FILES_VirtualBox_$(lang)'
|
---|
788 | $(QUIET)$(CAT_EXT) "$(VBOX_WIN_INST_REPACK_DIR)/VirtualBox_$(lang).files" >> '$$@.dep'
|
---|
789 | $(QUIET)$(APPEND) -n '$$@.dep' '' 'endef'
|
---|
790 | endif
|
---|
791 |
|
---|
792 | $(eval OTHER_CLEAN += $(VBOX_REPACK_FILES_VirtualBox_$(lang)))
|
---|
793 | endef
|
---|
794 |
|
---|
795 | $(foreach lang,$(VBOX_INSTALLER_LANGUAGES), \
|
---|
796 | $(eval $(def_vbox_compile_wixobj)))
|
---|
797 |
|
---|
798 | #
|
---|
799 | # MSM (merge module) compile.
|
---|
800 | #
|
---|
801 | define def_vbox_compile_msm
|
---|
802 | includedep $(VBOX_WIN_INST_OUT_DIR)/VBoxMerge$(module)_$(lang).wixobj.dep
|
---|
803 | $(VBOX_WIN_INST_OUT_DIR)/VBoxMerge$(module)_$(lang).wixobj \
|
---|
804 | + $(VBOX_WIN_INST_OUT_DIR)/VBoxMerge$(module)_$(lang).wix \
|
---|
805 | $(if-expr "$(lang)" != "en_US",, \
|
---|
806 | + $(VBOX_WIN_INST_REPACK_DIR)/VBoxMerge$(module)_$(lang).wix): \
|
---|
807 | $(PATH_SUB_CURRENT)/VBoxMerge$(module).wxs \
|
---|
808 | $(PATH_SUB_CURRENT)/VBoxMerge$(module).wxi \
|
---|
809 | $(PATH_SUB_CURRENT)/VBoxMerge$(module)CA.wxi \
|
---|
810 | $(PATH_SUB_CURRENT)/VBoxMerge$(module)Seq.wxi \
|
---|
811 | $(PATH_SUB_CURRENT)/UserInterface.wxi \
|
---|
812 | $(VBOX_WIN_INST_OUT_DIR)/Shortcuts_StartMenu.wxi \
|
---|
813 | $(VBOX_WIN_INST_OUT_DIR)/VirtualBox_TypeLib.wxi \
|
---|
814 | $(if $(VBOX_WITH_32_ON_64_MAIN_API),$(VBOX_WIN_INST_OUT_DIR)/VirtualBox_TypeLib_x86.wxi,) \
|
---|
815 | $(VBOX_WIN_INST_OUT_DIR)/VBoxKey.wxi \
|
---|
816 | $(if $(VBOX_WITH_CRT_PACKING),$(VBOX_WIN_INST_OUT_DIR)/VBoxCrtDlls.wxi,) \
|
---|
817 | $(if $(VBOX_WITH_CRT_PACKING),$(VBOX_WIN_INST_OUT_DIR)/VBoxCrtDlls32.wxi,) \
|
---|
818 | $(VBOX_WIN_INST_OUT_DIR)/VBoxUnattendedTemplateComponent.wxi \
|
---|
819 | $(if $(VBOX_WITH_QTGUI),$(VBOX_WIN_INST_OUT_DIR)/VBoxGuiNLS.wxi) \
|
---|
820 | $(VBOX_MSI_DEPENDENCIES) \
|
---|
821 | $(VBOX_VERSION_STAMP) \
|
---|
822 | | $$$$(dir $$$$@) $(VBOX_WIN_INST_REPACK_DIR)/
|
---|
823 | $(QUIET)$(RM) -f -- "$$@" "$(VBOX_WIN_INST_OUT_DIR)/VBoxMerge$(module)_$(lang).wix" "$(VBOX_WIN_INST_REPACK_DIR)/VBoxMerge$(module)_$(lang).wix"
|
---|
824 | $(REDIRECT) \
|
---|
825 | -E 'PATH_OUT=$(subst /,\,$(PATH_OUT))' \
|
---|
826 | -E 'PATH_TARGET=$(subst /,\,$(VBOX_WIN_INST_OUT_DIR))' \
|
---|
827 | -E 'PATH_ROOT=$(subst /,\,$(PATH_ROOT))' \
|
---|
828 | -E 'PATH_MULTIARCH_GUEST_ADDITIONS_ISO=$(subst /,\,$(PATH_MULTIARCH_GUEST_ADDITIONS_ISO))' \
|
---|
829 | -E 'VBOX_PATH_WIN_INST_SRC=$(subst /,\,$(VBOX_PATH_WIN_INST_SRC))' \
|
---|
830 | -E 'VBOX_BRAND_WIN_INST_DLGJPG=$(subst /,\,$(VBOX_BRAND_WIN_INST_DLGJPG))' \
|
---|
831 | -E 'VBOX_ADD_LANGUAGES=$(VBOX_INSTALLER_ADD_LANGUAGES)' \
|
---|
832 | -E 'VBOX_BRAND_LICENSE_RTF=$(subst /,\,$(VBOX_BRAND_LICENSE_RTF))' \
|
---|
833 | $(foreach lang,$(VBOX_INSTALLER_LANGUAGES), \
|
---|
834 | -E 'VBOX_BRAND_$(lang)_LICENSE_RTF=$(subst /,\,$(VBOX_BRAND_$(subst en_US_,,$(lang)_)LICENSE_RTF))') \
|
---|
835 | -E 'VBOX_BUILD_NR_FOR_INST=$(VBOX_VERSION_BUILD)' \
|
---|
836 | -E 'VBOX_VENDOR=$(VBOX_VENDOR)' \
|
---|
837 | -E 'VBOX_VENDOR_SHORT=$(VBOX_VENDOR_SHORT)' \
|
---|
838 | -E 'VBOX_PRODUCT=$(VBOX_PRODUCT)' \
|
---|
839 | -E 'VBOX_C_YEAR=$(VBOX_C_YEAR)' \
|
---|
840 | -E 'VBOX_VERSION_STRING=$(VBOX_VERSION_STRING)' \
|
---|
841 | -E 'VBOX_VERSION_STRING_RAW=$(VBOX_VERSION_STRING_RAW)' \
|
---|
842 | -E 'VBOX_VERSION_MAJOR_INST=$(VBOX_VERSION_MAJOR)' \
|
---|
843 | -E 'VBOX_VERSION_MINOR_INST=$(VBOX_VERSION_MINOR)' \
|
---|
844 | -E 'VBOX_SIGNING_MODE=$(strip $(if $(VBOX_SIGNING_MODE),$(VBOX_SIGNING_MODE),none))' \
|
---|
845 | -E 'VBOX_CAB_COMPRESSION_LEVEL=$(VBOX_CAB_COMPRESSION_LEVEL)' \
|
---|
846 | -E 'VBOX_CAB_COMPRESSION_LEVEL_COMMON=$(VBOX_CAB_COMPRESSION_LEVEL)' \
|
---|
847 | -E 'VBOX_GUI_USE_QGL=$(if $(VBOX_GUI_USE_QGL),yes,no)' \
|
---|
848 | -E 'VBOX_MIDL_PROXY_CLSID=$(VBOX_MIDL_PROXY_CLSID)' \
|
---|
849 | -E 'VBOX_WINDOWS_ICON_FILE=$(subst /,\,$(VBOX_WINDOWS_ICON_FILE))' \
|
---|
850 | -E 'VBOX_QT_INFIX=$(VBOX_QT_INFIX)' \
|
---|
851 | -E 'VBOX_WITH_32_ON_64_MAIN_API=$(if $(VBOX_WITH_32_ON_64_MAIN_API),yes,no)' \
|
---|
852 | -E 'VBOX_WITH_ADDITIONS_PACKING=$(if $(VBOX_WITH_ADDITIONS_PACKING),yes,no)' \
|
---|
853 | -E 'VBOX_WITH_COMBINED_PACKAGE=$(if-expr defined(VBOX_WITH_COMBINED_PACKAGE),yes,no)' \
|
---|
854 | -E 'VBOX_WITH_CRT_PACKING=$(if-expr defined(VBOX_WITH_CRT_PACKING),yes,no)' \
|
---|
855 | -E 'VBOX_WITH_DEBUGGER_GUI=$(if-expr defined(VBOX_WITH_DEBUGGER_GUI) && defined(VBOX_WITH_QTGUI),yes,no)' \
|
---|
856 | -E 'VBOX_WITH_DOCS_PACKING=$(if $(VBOX_WITH_DOCS_PACKING),yes,no)' \
|
---|
857 | -E 'VBOX_WITH_DRAG_AND_DROP=$(if $(VBOX_WITH_DRAG_AND_DROP),yes,no)' \
|
---|
858 | -E 'VBOX_WITH_DTRACE=$(if $(VBOX_WITH_DTRACE),yes,no)' \
|
---|
859 | -E 'VBOX_WITH_HOST_SHIPPING_AUDIO_TEST=$(if $(VBOX_WITH_HOST_SHIPPING_AUDIO_TEST),yes,no)' \
|
---|
860 | -E 'VBOX_WITH_EFIFW_PACKING=$(if $(VBOX_WITH_EFIFW_PACKING),yes,no)' \
|
---|
861 | -E 'VBOX_WITH_EXTPACK=$(if $(VBOX_WITH_EXTPACK),yes,no)' \
|
---|
862 | -E 'VBOX_WITH_GUEST_CONTROL=$(if $(VBOX_WITH_GUEST_CONTROL),yes,no)' \
|
---|
863 | -E 'VBOX_WITH_GUEST_PROPS=$(if $(VBOX_WITH_GUEST_PROPS),yes,no)' \
|
---|
864 | -E 'VBOX_WITH_HARDENING=$(if $(VBOX_WITH_HARDENING),yes,no)' \
|
---|
865 | -E 'VBOX_WITH_HEADLESS=$(if $(VBOX_WITH_HEADLESS),yes,no)' \
|
---|
866 | -E 'VBOX_WITH_FE_BALLOONCTRL=$(if $(VBOX_WITH_FE_BALLOONCTRL),yes,no)' \
|
---|
867 | -E 'VBOX_WITH_FE_AUTOSTART=$(if $(VBOX_WITH_FE_AUTOSTART),yes,no)' \
|
---|
868 | -E 'VBOX_WITH_FE_BUGREPORT=$(if $(VBOX_WITH_FE_BUGREPORT),yes,no)' \
|
---|
869 | -E 'VBOX_WITH_LICENSE_DISPLAY=$(if $(VBOX_WITH_LICENSE_DISPLAY),yes,no)' \
|
---|
870 | -E 'VBOX_WITH_MIDL_PROXY_STUB=$(if $(VBOX_WITH_MIDL_PROXY_STUB),yes,no)' \
|
---|
871 | -E 'VBOX_WITH_MSM_INSTALL=$(if-expr defined(VBOX_WITH_MSM_INSTALL),yes,no)' \
|
---|
872 | -E 'VBOX_WITH_NETADP=$(if $(VBOX_WITH_NETADP),yes,no)' \
|
---|
873 | -E 'VBOX_WITH_NETFLT=$(if $(VBOX_WITH_NETFLT),yes,no)' \
|
---|
874 | -E 'VBOX_WITH_PYTHON=$(if $(VBOX_WITH_PYTHON),yes,no)' \
|
---|
875 | -E 'VBOX_WITH_QTGUI=$(if $(VBOX_WITH_QTGUI),yes,no)' \
|
---|
876 | -E 'VBOX_WITH_RAW_MODE=$(if $(VBOX_WITH_RAW_MODE),yes,no)' \
|
---|
877 | -E 'VBOX_WITH_SECURELABEL=$(if $(VBOX_WITH_SECURELABEL),yes,no)' \
|
---|
878 | -E 'VBOX_WITH_SERIALNUMBER_INSTALL=$(if $(VBOX_WITH_SERIALNUMBER_INSTALL),yes,no)' \
|
---|
879 | -E 'VBOX_WITH_VIDEOHWACCEL=$(if $(VBOX_WITH_VIDEOHWACCEL),yes,no)' \
|
---|
880 | -E 'VBOX_WITH_VRDP=$(if-expr defined(VBOX_WITH_VRDP) && !defined(VBOX_WITH_EXTPACK_PUEL),yes,no)' \
|
---|
881 | -E 'VBOX_WITH_WEBSERVICES=$(if $(VBOX_WITH_WEBSERVICES),yes,no)' \
|
---|
882 | -E 'VBOX_WITH_SDS=$(if $(VBOX_WITH_SDS),yes,no)' \
|
---|
883 | -E 'VBOX_WITH_UNATTENDED=$(if $(VBOX_WITH_UNATTENDED),yes,no)' \
|
---|
884 | -E 'VBOX_WITH_VBOX_IMG=$(if $(VBOX_WITH_VBOX_IMG),yes,no)' \
|
---|
885 | -E 'VBOX_WITH_VBOXSDL=$(if $(VBOX_WITH_VBOXSDL),yes,no)' \
|
---|
886 | -E 'VBOX_WITH_VMSVGA3D=$(if $(VBOX_WITH_VMSVGA3D),yes,no)' \
|
---|
887 | -E 'VBOX_WITH_VIDEOHWACCEL=$(if $(VBOX_WITH_VIDEOHWACCEL),yes,no)' \
|
---|
888 | -E 'KBUILD_TYPE=$(KBUILD_TYPE)' \
|
---|
889 | -E 'KBUILD_TARGET_ARCH=$(KBUILD_TARGET_ARCH)' \
|
---|
890 | -E 'VBOX_INSTALLER_QUICK=$(VBOX_INSTALLER_QUICK)' \
|
---|
891 | -E 'VBOX_VCC_TOOL_STEM=$(VBOX_VCC_TOOL_STEM)' \
|
---|
892 | -- \
|
---|
893 | $(VBOX_PATH_WIX)/candle.exe $(filter-out $(VBOX_VERSION_STAMP),$$<) \
|
---|
894 | -ext $(VBOX_PATH_WIX)/WixUIExtension.dll \
|
---|
895 | -ext $(VBOX_PATH_WIX)/WixDifxAppExtension.dll \
|
---|
896 | -ext $(VBOX_PATH_WIX)/WixUtilExtension.dll \
|
---|
897 | -p$(VBOX_WIN_INST_OUT_DIR)/VBoxMerge$(module)_$(lang).wix
|
---|
898 | $(VBOX_PATH_WIX)/candle.exe $(VBOX_WIN_INST_OUT_DIR)/VBoxMerge$(module)_$(lang).wix \
|
---|
899 | -ext $(VBOX_PATH_WIX)/WixUIExtension.dll \
|
---|
900 | -ext $(VBOX_PATH_WIX)/WixDifxAppExtension.dll \
|
---|
901 | -ext $(VBOX_PATH_WIX)/WixUtilExtension.dll \
|
---|
902 | -out $$@
|
---|
903 | ifeq ($(lang),en_US)
|
---|
904 | # Copy preprocessed wix and change source paths to be relative. Stuff not in ../bin needs copying.
|
---|
905 | $(SED) -e 's,$(subst /,\\,$(PATH_OUT))\\bin,..\\bin,g' \
|
---|
906 | -e 's,$(subst /,\\,$(PATH_OUT_BASE))\\win.amd64\\$(KBUILD_TYPE)\\bin,..\\..\\..\\win.amd64\\$(KBUILD_TYPE)\\bin,g' \
|
---|
907 | -e 's,$(subst /,\\,$(PATH_OUT_BASE))\\win.x86\\$(KBUILD_TYPE)\\bin,..\\..\\..\\win.x86\\$(KBUILD_TYPE)\\bin,g' \
|
---|
908 | -e 's,$(subst /,\\,$(PATH_ROOT))\\doc\\,files-VBoxMerge$(module)_$(lang)\\,g' \
|
---|
909 | -e 's,$(subst /,\\,$(VBOX_PATH_WIN_INST_SRC))\\Binary\\,files-VBoxMerge$(module)_$(lang)\\,g' \
|
---|
910 | -e 's,$(subst /,\\,$(dir $(VBOX_WINDOWS_ICON_FILE))),files-VBoxMerge$(module)_$(lang)\\,g' \
|
---|
911 | -e 's,$(subst /,\\,$(VBOX_PATH_WIN_INST_SRC))\\,,g' \
|
---|
912 | --output "$(VBOX_WIN_INST_REPACK_DIR)/VBoxMerge$(module)_$(lang).wix" \
|
---|
913 | "$(VBOX_WIN_INST_OUT_DIR)/VBoxMerge$(module)_$(lang).wix"
|
---|
914 | $(SED) -n \
|
---|
915 | -e '/<\?ln /d' \
|
---|
916 | -e '/$(subst /,\\,$(PATH_ROOT))/p' \
|
---|
917 | -e '/$(subst /,\\,$(PATH_ROOT))/q2' \
|
---|
918 | "$(VBOX_WIN_INST_REPACK_DIR)/VBoxMerge$(module)_$(lang).wix"
|
---|
919 | $(SED) -n \
|
---|
920 | -e '/<\?ln /d' \
|
---|
921 | -e 's/\\/\//g' \
|
---|
922 | -e 's,^.*"\($(PATH_ROOT)/doc/[^"]*\)".*$$(DOLLAR),\1,p' \
|
---|
923 | -e 's,^.*"\($(VBOX_PATH_WIN_INST_SRC)/Binary/[^"]*\)".*$$(DOLLAR),\1,p' \
|
---|
924 | -e 's,^.*"\($(dir $(VBOX_WINDOWS_ICON_FILE))[^"]*\)".*$$(DOLLAR),\1,p' \
|
---|
925 | --output "$(VBOX_WIN_INST_REPACK_DIR)/VBoxMerge$(module)_$(lang).files" \
|
---|
926 | "$(VBOX_WIN_INST_OUT_DIR)/VBoxMerge$(module)_$(lang).wix"
|
---|
927 | $(MKDIR) -p -- "$(VBOX_WIN_INST_REPACK_DIR)/files-VBoxMerge$(module)_$(lang)/"
|
---|
928 | set -xe && for file in `$(CAT_EXT) "$(VBOX_WIN_INST_REPACK_DIR)/VBoxMerge$(module)_$(lang).files"`; \
|
---|
929 | do $(CP_EXT) -f -- "$$(DOLLAR){file}" "$(VBOX_WIN_INST_REPACK_DIR)/files-VBoxMerge$(module)_$(lang)/"; done
|
---|
930 | # Create repack script for this step.
|
---|
931 | $(APPEND) -tn "$(VBOX_WIN_INST_REPACK_DIR)/1-compile-VBoxMerge$(module)_$(lang).cmd" \
|
---|
932 | 'if ".%KBUILD_DEVTOOLS%" == "." (echo KBUILD_DEVTOOLS is not set & exit /b1)' \
|
---|
933 | $(subst $(KBUILD_DEVTOOLS),%KBUILD_DEVTOOLS%,\
|
---|
934 | '$(VBOX_PATH_WIX)/candle.exe VBoxMerge$(module)_$(lang).wix ^' \
|
---|
935 | ' -ext $(VBOX_PATH_WIX)/WixUIExtension.dll ^'\
|
---|
936 | ' -ext $(VBOX_PATH_WIX)/WixDifxAppExtension.dll ^' \
|
---|
937 | ' -ext $(VBOX_PATH_WIX)/WixUtilExtension.dll ^' \
|
---|
938 | ' -out $$(@F) || exit /b1' \
|
---|
939 | ) \
|
---|
940 | '@echo Created: $$(@F)'
|
---|
941 | endif
|
---|
942 | # Generate wxi dependencies based on the sourceLineNumber references in the output. Add repack file list for cleanup.
|
---|
943 | $(QUIET)$(APPEND) -t '$$@.dep' '$$@: \'
|
---|
944 | $(QUIET)$(VBOX_XSLTPROC) $(VBOX_PATH_WIN_INST_SRC)/dep.xsl "$$@" >> "$$@.dep"
|
---|
945 | $(QUIET)$(VBOX_XSLTPROC) $(VBOX_PATH_WIN_INST_SRC)/dep2.xsl "$$@" | sort | $(SED) '$!N; /^\(.*\)\n\1$$$$/!P; D' >> "$$@.dep"
|
---|
946 | $(QUIET)$(APPEND) -n '$$@.dep' '' ''
|
---|
947 | ifeq ($(lang),en_US)
|
---|
948 | $(QUIET)$(APPEND) -n '$$@.dep' 'define VBOX_REPACK_FILES_VBoxMerge$(module)_$(lang)'
|
---|
949 | $(QUIET)$(CAT_EXT) "$(VBOX_WIN_INST_REPACK_DIR)/VBoxMerge$(module)_$(lang).files" >> '$$@.dep'
|
---|
950 | $(QUIET)$(APPEND) -n '$$@.dep' '' 'endef'
|
---|
951 | endif
|
---|
952 |
|
---|
953 | $(eval OTHER_CLEAN += $(VBOX_REPACK_FILES_VBoxMerge$(module)_$(lang)))
|
---|
954 | endef
|
---|
955 |
|
---|
956 | $(foreach module,$(VBOX_INSTALLER_MERGE_MODULES), \
|
---|
957 | $(foreach lang,$(VBOX_INSTALLER_MERGE_LANGUAGES), \
|
---|
958 | $(eval $(def_vbox_compile_msm))))
|
---|
959 |
|
---|
960 | #
|
---|
961 | # VirtualBox Type Library definition.
|
---|
962 | #
|
---|
963 | $(VBOX_WIN_INST_OUT_DIR)/VirtualBox_TypeLib.wxi: \
|
---|
964 | $(PATH_SUB_CURRENT)/$(if-expr defined(VBOX_WITH_MIDL_PROXY_STUB),VirtualBox_TypeLibWithInterfaces.xsl,VirtualBox_TypeLib.xsl) \
|
---|
965 | $(VBOX_XIDL_FILE) \
|
---|
966 | $(MAKEFILE) \
|
---|
967 | | $$(dir $$@)
|
---|
968 | $(VBOX_XSLTPROC) \
|
---|
969 | $(if-expr defined(VBOX_WITH_MIDL_PROXY_STUB),--stringparam "a_sProxyStubClsid" "$(VBOX_MIDL_PROXY_CLSID)",) \
|
---|
970 | $(if-expr defined(VBOX_WITH_SDS),--stringparam "a_sWithSDS" "yes",) \
|
---|
971 | -o $@ $< $(VBOX_XIDL_FILE)
|
---|
972 |
|
---|
973 | $(VBOX_WIN_INST_OUT_DIR)/VirtualBox_TypeLib_x86.wxi: \
|
---|
974 | $(PATH_SUB_CURRENT)/$(if-expr defined(VBOX_WITH_MIDL_PROXY_STUB),VirtualBox_TypeLibWithInterfaces.xsl,VirtualBox_TypeLib.xsl) \
|
---|
975 | $(VBOX_XIDL_FILE) \
|
---|
976 | | $$(dir $$@)
|
---|
977 | $(VBOX_XSLTPROC) --stringparam "a_sTarget" "VBoxClient-x86" \
|
---|
978 | $(if-expr defined(VBOX_WITH_MIDL_PROXY_STUB),--stringparam "a_sProxyStubClsid" "$(VBOX_MIDL_PROXY_CLSID)",) \
|
---|
979 | $(if-expr defined(VBOX_WITH_SDS),--stringparam "a_sWithSDS" "yes",) \
|
---|
980 | -o $@ $< $(VBOX_XIDL_FILE)
|
---|
981 |
|
---|
982 | #
|
---|
983 | # Construct the list of GUI translations.
|
---|
984 | # ('-t' -- truncate file; '-n' -- new line between arguments)
|
---|
985 | #
|
---|
986 | include $(PATH_ROOT)/src/VBox/Frontends/VirtualBox/nls/ApprovedLanguages.kmk
|
---|
987 | $(call KB_FN_AUTO_CMD_DEPS,$(VBOX_WIN_INST_OUT_DIR)/VBoxGuiNLS.wxi)
|
---|
988 | $(VBOX_WIN_INST_OUT_DIR)/VBoxGuiNLS.wxi: $(PATH_ROOT)/src/VBox/Frontends/VirtualBox/nls/ApprovedLanguages.kmk | $$(dir $$@)
|
---|
989 | $(APPEND) -t $@ '<?xml version="1.0" ?>'
|
---|
990 | $(APPEND) $@ '<Include>'
|
---|
991 | $(APPEND) -n $@ $(foreach lang,$(VBOX_APPROVED_GUI_LANGUAGES), \
|
---|
992 | ' <File Id="nlsqt${lang}" Name="qt_${lang}.qm" DiskId="$(VBOX_INSTALLER_COMMON_DISKID)" Vital="yes" Source="$$(env.PATH_OUT)\bin\nls\qt_${lang}.qm" />' \
|
---|
993 | ' <File Id="nlsgui${lang}" Name="VirtualBox_${lang}.qm" DiskId="$(VBOX_INSTALLER_COMMON_DISKID)" Vital="yes" Source="$$(env.PATH_OUT)\bin\nls\VirtualBox_${lang}.qm" />')
|
---|
994 | $(APPEND) $@ '</Include>'
|
---|
995 |
|
---|
996 | #
|
---|
997 | # Edit the version stored in the registry.
|
---|
998 | #
|
---|
999 | $(call KB_FN_AUTO_CMD_DEPS,$(VBOX_WIN_INST_OUT_DIR)/VBoxKey.wxi)
|
---|
1000 | $(VBOX_WIN_INST_OUT_DIR)/VBoxKey.wxi: $(PATH_SUB_CURRENT)/VBoxKey.wxi $(VBOX_VERSION_STAMP) | $$(dir $$@)
|
---|
1001 | $(SED) -e 's/%VER%/$(VBOX_VERSION_STRING_RAW)/' \
|
---|
1002 | -e 's/%VER_EXT%/$(VBOX_VERSION_STRING)/' \
|
---|
1003 | --output $@ $<
|
---|
1004 |
|
---|
1005 | #
|
---|
1006 | # Generate the list of CRT DLLs.
|
---|
1007 | #
|
---|
1008 | ifndef TOOL_$(VBOX_VCC_TOOL)
|
---|
1009 | include $(KBUILD_PATH)/tools/$(VBOX_VCC_TOOL).kmk
|
---|
1010 | endif
|
---|
1011 | $(call KB_FN_AUTO_CMD_DEPS,$(VBOX_WIN_INST_OUT_DIR)/VBoxCrtDlls.wxi)
|
---|
1012 | $(VBOX_WIN_INST_OUT_DIR)/VBoxCrtDlls.wxi: | $$(dir $$@)
|
---|
1013 | $(APPEND) -t -n $@ \
|
---|
1014 | '<?xml version="1.0" ?>' \
|
---|
1015 | '<Include>' \
|
---|
1016 | $(foreach dll \
|
---|
1017 | ,$(if-expr "$(VBOX_VCC_TOOL_STEM)"=="VCC100",msvcr100.dll msvcp100.dll \
|
---|
1018 | ,$(if-expr "$(VBOX_VCC_TOOL_STEM)"=="VCC110",msvcr110.dll msvcp110.dll \
|
---|
1019 | ,$(TOOL_$(VBOX_VCC_TOOL)_REDIST_CRT_DLLS) $(TOOL_$(VBOX_VCC_TOOL)_REDIST_CPP_DLLS))) \
|
---|
1020 | $(if-expr "$(KBUILD_TYPE)"=="asan",clang_rt.asan_dynamic-x86_64.dll,) \
|
---|
1021 | ,' <File Id="file_$(translate $(dll),-,_)" Name="$(dll)" Source="$$(env.PATH_OUT)\bin\$(dll)" />') \
|
---|
1022 | '</Include>'
|
---|
1023 |
|
---|
1024 | #
|
---|
1025 | # Generate the list of 32-bit CRT DLLs.
|
---|
1026 | #
|
---|
1027 | ifndef TOOL_$(VBOX_VCC_TOOL_STEM)X86
|
---|
1028 | include $(KBUILD_PATH)/tools/$(VBOX_VCC_TOOL_STEM)X86.kmk
|
---|
1029 | endif
|
---|
1030 | $(call KB_FN_AUTO_CMD_DEPS,$(VBOX_WIN_INST_OUT_DIR)/VBoxCrtDlls32.wxi)
|
---|
1031 | $(VBOX_WIN_INST_OUT_DIR)/VBoxCrtDlls32.wxi: | $$(dir $$@)
|
---|
1032 | $(APPEND) -t -n $@ \
|
---|
1033 | '<?xml version="1.0" ?>' \
|
---|
1034 | '<Include>' \
|
---|
1035 | $(foreach dll \
|
---|
1036 | ,$(if-expr "$(VBOX_VCC_TOOL_STEM)"=="VCC100",msvcr100.dll msvcp100.dll \
|
---|
1037 | ,$(if-expr "$(VBOX_VCC_TOOL_STEM)"=="VCC110",msvcr110.dll msvcp110.dll \
|
---|
1038 | ,$(TOOL_$(VBOX_VCC_TOOL_STEM)X86_REDIST_CRT_DLLS) $(TOOL_$(VBOX_VCC_TOOL_STEM)X86_REDIST_CPP_DLLS))) \
|
---|
1039 | $(if-expr "$(KBUILD_TYPE)"=="asan",clang_rt.asan_dynamic-i386.dll,) \
|
---|
1040 | ,' <File Id="file_$(translate $(dll),-,_)_x86" Name="$(dll)" Source="$$(env.PATH_OUT)\bin\x86\$(dll)" DiskId="$$(var.Property_DiskIdCommon)" />') \
|
---|
1041 | '</Include>'
|
---|
1042 | #
|
---|
1043 | # Generate the list of unattended template script files.
|
---|
1044 | #
|
---|
1045 | $(call KB_FN_AUTO_CMD_DEPS,$(VBOX_WIN_INST_OUT_DIR)/VBoxUnattendedTemplateComponent.wxi)
|
---|
1046 | $(VBOX_WIN_INST_OUT_DIR)/VBoxUnattendedTemplateComponent.wxi: | $$(dir $$@)
|
---|
1047 | $(APPEND) -t -n $@ \
|
---|
1048 | '<?xml version="1.0" ?>' \
|
---|
1049 | '<Include>'
|
---|
1050 | ifdef VBOX_UNATTENDED_TEMPLATES
|
---|
1051 | $(APPEND) -n $@ \
|
---|
1052 | ' <Directory Id="dir_VBoxUnattendedTemplates" Name="UnattendedTemplates">' \
|
---|
1053 | ' <Component Id="cp_UnattendedTemplates" Guid="0571550d-aaa5-4723-c17b-5ddcc29f5686" Win64="$$(var.Property_Win64)">' \
|
---|
1054 | $(foreach file,$(VBOX_UNATTENDED_TEMPLATES), \
|
---|
1055 | ' <File Id="$(file)" Name="$(file)" Source="$$(env.PATH_OUT)\bin\UnattendedTemplates\$(file)" />') \
|
---|
1056 | ' </Component>' \
|
---|
1057 | ' </Directory>'
|
---|
1058 | endif
|
---|
1059 | $(APPEND) $@ '</Include>'
|
---|
1060 |
|
---|
1061 |
|
---|
1062 | #
|
---|
1063 | # Build the multi-language version of the .MSI installer (final installer).
|
---|
1064 | #
|
---|
1065 | # This is done by creating binary .MST diffs of all the language-specific installers
|
---|
1066 | # against the en_US one, and then merging the diffs into the en_US one using tools
|
---|
1067 | # from the MS Installer SDK.
|
---|
1068 | #
|
---|
1069 | define def_vbox_create_mst
|
---|
1070 | $(VBOX_WIN_INST_OUT_DIR)/$(lang)/$(lang).mst \
|
---|
1071 | + $(VBOX_WIN_INST_REPACK_DIR)/$(lang).mst: \
|
---|
1072 | $(VBOX_WIN_INST_OUT_DIR)/en_US/$(PACKAGE_NAME_LANG)_en_US.msi \
|
---|
1073 | $(VBOX_WIN_INST_OUT_DIR)/$(lang)/VirtualBox_$(lang).wixobj \
|
---|
1074 | $(VBOX_WIN_INST_OUT_DIR)/NLS/Language_$(lang).wxl \
|
---|
1075 | $(VBOX_WIN_INST_OUT_DIR)/NLS/License_$(lang).wxl \
|
---|
1076 | $(PATH_STAGE_BIN)/VBoxInstallHelper.dll \
|
---|
1077 | $(VBOX_SVN_REV_KMK) \
|
---|
1078 | $(VBOX_WIN_INST_MAKEFILE_DEP) \
|
---|
1079 | $(if-expr defined(VBOX_WITH_MSI_HACK),$(MsiHack_0_OUTDIR)/MsiHack.dll,) \
|
---|
1080 | $(if-expr defined(VBOX_WITH_MSI_HACK),$(MsiHack_0_OUTDIR)/MsiHackExtension.dll,) \
|
---|
1081 | | $$$$(dir $$$$@) $(VBOX_WIN_INST_REPACK_DIR)/
|
---|
1082 | $(call MSG_L1,Creating language diff for $(lang))
|
---|
1083 | kmk_time $$(REDIRECT_EXT) -E WIX_TEMP='$$(subst /,\,$$(@D))' -- $(VBOX_PATH_WIX)/light.exe -v -nologo \
|
---|
1084 | -loc $(VBOX_WIN_INST_OUT_DIR)/NLS/Language_$(lang).wxl \
|
---|
1085 | -loc $(VBOX_WIN_INST_OUT_DIR)/NLS/License_$(lang).wxl \
|
---|
1086 | -ext $(VBOX_PATH_WIX)/WixUIExtension.dll \
|
---|
1087 | -ext $(VBOX_PATH_WIX)/WixDifxAppExtension.dll \
|
---|
1088 | -ext $(VBOX_PATH_WIX)/WixUtilExtension.dll \
|
---|
1089 | $(if-expr defined(VBOX_WITH_MSI_HACK),-ext $(MsiHack_0_OUTDIR)/MsiHackExtension.dll,) \
|
---|
1090 | $(VBOX_MSI_ICE_IGNORE) \
|
---|
1091 | -out $$(@D)/$(PACKAGE_NAME_LANG)_$(lang).msi \
|
---|
1092 | $$(@D)/VirtualBox_$(lang).wixobj \
|
---|
1093 | $(VBOX_PATH_WIX)/difxapp_$(if-expr "$(KBUILD_TARGET_ARCH)" == "x86",x86,x64).wixlib
|
---|
1094 | $(REDIRECT) -C $$(@D) -- $$(VBOX_PATH_MSITRAN) -g $$< $(PACKAGE_NAME_LANG)_$(lang).msi $(lang).mst
|
---|
1095 | $(CP) -f -- "$(VBOX_WIN_INST_OUT_DIR)/$(lang)/$(lang).mst" "$(VBOX_WIN_INST_REPACK_DIR)/$(lang).mst"
|
---|
1096 | $(RM) -f -- $$(@D)/$(PACKAGE_NAME_LANG)_$(lang).msi \
|
---|
1097 | $$(@D)/$(PACKAGE_NAME_LANG)_$(lang).wixpdb \
|
---|
1098 | $$(@D)/common.cab
|
---|
1099 |
|
---|
1100 | endef
|
---|
1101 |
|
---|
1102 | $(foreach lang,$(filter-out en_US, $(VBOX_INSTALLER_LANGUAGES)), \
|
---|
1103 | $(eval local lang_id := $(VBOX_BRAND_$(lang)_LANG_ID)) \
|
---|
1104 | $(eval $(def_vbox_create_mst)))
|
---|
1105 |
|
---|
1106 |
|
---|
1107 | # Create WISUMINFO argument.
|
---|
1108 | VBOX_INS_PROD_ARCH.amd64 = x64
|
---|
1109 | VBOX_INS_PROD_ARCH.x86 = Intel
|
---|
1110 | VBOX_INS_PROD_ARCH := $(VBOX_INS_PROD_ARCH.$(KBUILD_TARGET_ARCH))
|
---|
1111 | $(if $(VBOX_INS_PROD_ARCH),,$(error VBOX_INS_PROD_ARCH is empty!))
|
---|
1112 | VBOX_INS_PROD_LANG := 7="$(VBOX_INS_PROD_ARCH);1033
|
---|
1113 | $(foreach lang, $(filter-out en_US,$(VBOX_INSTALLER_LANGUAGES))\
|
---|
1114 | , $(eval VBOX_INS_PROD_LANG := $(VBOX_INS_PROD_LANG)$(COMMA)$(VBOX_BRAND_$(lang)_LANG_ID)))
|
---|
1115 | VBOX_INS_PROD_LANG := $(VBOX_INS_PROD_LANG)"
|
---|
1116 |
|
---|
1117 | # The multilingual installer rule.
|
---|
1118 | $(VBOX_WIN_INST_OUT_DIR)/$(PACKAGE_NAME_LANG).msi \
|
---|
1119 | + $(VBOX_WIN_INST_REPACK_DIR)/3-multilingual-$(PACKAGE_NAME_LANG).cmd: \
|
---|
1120 | $(VBOX_WIN_INST_OUT_DIR)/en_US/$(PACKAGE_NAME_LANG)_en_US.msi \
|
---|
1121 | $(foreach lang,$(filter-out en_US,$(VBOX_INSTALLER_LANGUAGES)),$(VBOX_WIN_INST_OUT_DIR)/$(lang)/$(lang).mst)
|
---|
1122 | $(call MSG_L1,Creating final multilingual MSI)
|
---|
1123 | $(QUIET)$(RM) -f -- \
|
---|
1124 | $(wildcard $(@D)/$(PACKAGE_BASE)-r*.msi $(VBOX_WIN_INST_REPACK_DIR)/3-multilingual-$(PACKAGE_BASE)-r*.cmd )
|
---|
1125 | $(CP) -f -- "$<" "$@"
|
---|
1126 |
|
---|
1127 | $(foreach lang,$(filter-out en_US,$(VBOX_INSTALLER_LANGUAGES)), \
|
---|
1128 | $(NLTAB)$(REDIRECT) -C $(@D)/$(lang) -- $(VBOX_PATH_MSIDB) -d $@ -r $(lang).mst \
|
---|
1129 | $(NLTAB)$(REDIRECT) -C $(@D)/$(lang) -- cscript.exe /nologo $(VBOX_PATH_WISUBSTG) $@ $(lang).mst $(VBOX_BRAND_$(lang)_LANG_ID) )
|
---|
1130 |
|
---|
1131 | $(REDIRECT) -C $(@D) -- cscript.exe /nologo $(VBOX_PATH_WISUBSTG) $(@F)
|
---|
1132 | $(REDIRECT) -C $(@D) -- cscript.exe /nologo $(VBOX_PATH_WISUMINFO) $@ $(VBOX_INS_PROD_LANG)
|
---|
1133 | $(call VBOX_SIGN_MSI_FN,$@,$(VBOX_PRODUCT) $(VBOX_VERSION_STRING)r$(VBOX_SVN_REV) ($(KBUILD_TARGET_ARCH)),,,disable-dual-signing)
|
---|
1134 |
|
---|
1135 | # Create repack script for this step.
|
---|
1136 | $(APPEND) -nt "$(VBOX_WIN_INST_REPACK_DIR)/3-multilingual-$(PACKAGE_NAME_LANG).cmd" \
|
---|
1137 | 'if ".%KBUILD_DEVTOOLS%" == "." (echo KBUILD_DEVTOOLS is not set & exit /b1)' \
|
---|
1138 | 'if ".%KBUILD_BIN_PATH%" == "." (echo KBUILD_BIN_PATH is not set & exit /b1)' \
|
---|
1139 | 'copy /y "$(<F)" "$(@F)" || exit /b1' \
|
---|
1140 | $(subst $(KBUILD_BIN_PATH),%KBUILD_BIN_PATH%,$(subst $(KBUILD_DEVTOOLS),%KBUILD_DEVTOOLS%,\
|
---|
1141 | $(foreach lang,$(filter-out en_US,$(VBOX_INSTALLER_LANGUAGES)), \
|
---|
1142 | '$(VBOX_PATH_MSIDB) -d $(@F) -r $(lang).mst || exit /b1' \
|
---|
1143 | 'cscript.exe /nologo $(VBOX_PATH_WISUBSTG) $(@F) $(lang).mst $(VBOX_BRAND_$(lang)_LANG_ID) || exit /b1') \
|
---|
1144 | 'cscript.exe /nologo $(VBOX_PATH_WISUBSTG) $(@F) || exit /b1' \
|
---|
1145 | 'cscript.exe /nologo $(VBOX_PATH_WISUMINFO) $(@F) $(VBOX_INS_PROD_LANG) || exit /b1' \
|
---|
1146 | 'call sign-sha1.cmd $(@F) || exit /b1' \
|
---|
1147 | ) ) \
|
---|
1148 | $(if-expr defined(VBOX_WITH_COMBINED_PACKAGE),'copy /y "$(@F)" "$(notdir $(PACKAGE_NAME_FINAL))" || exit /b1',) \
|
---|
1149 | '@echo Created multilanguage MSI: $(notdir $(PACKAGE_NAME_FINAL))'
|
---|
1150 |
|
---|
1151 | # Copy multilingual installer to bin.
|
---|
1152 | $(PACKAGE_NAME_FINAL): $(VBOX_WIN_INST_OUT_DIR)/$(PACKAGE_NAME_LANG).msi | $$(dir $$@)
|
---|
1153 | $(QUIET)$(RM) -f $(wildcard $(@D)/$(PACKAGE_BASE)-r*$(if-expr defined(VBOX_WITH_COMBINED_PACKAGE),_$(KBUILD_TARGET_ARCH),).msi)
|
---|
1154 | $(INSTALL_STAGING) -- $< $@
|
---|
1155 |
|
---|
1156 |
|
---|
1157 | if defined(VBOX_WITH_COMBINED_PACKAGE) && "$(KBUILD_TARGET_ARCH)" == "x86"
|
---|
1158 | #
|
---|
1159 | # Make the multi-architecture installer by calling our stub builder
|
---|
1160 | # with both platform installers (x86 and amd64) + common cab. The common
|
---|
1161 | # cab only is needed when we don't use merge modules. We only
|
---|
1162 | # need to do this once; so do it on x86 only.
|
---|
1163 | #
|
---|
1164 | $(PATH_STAGE_BIN)/$(PACKAGE_NAME_MULTIARCH_FINAL) \
|
---|
1165 | + $(VBOX_WIN_INST_REPACK_DIR)/4-multiarch-$(PACKAGE_NAME_MULTIARCH_FINAL).cmd: \
|
---|
1166 | $(PATH_MULTIARCH_TEMP)/$(PACKAGE_NAME_MULTIARCH.x86) \
|
---|
1167 | $(PATH_MULTIARCH_TEMP)/$(PACKAGE_NAME_MULTIARCH.amd64) \
|
---|
1168 | $(PATH_STAGE_BIN)/VBoxStub.exe \
|
---|
1169 | $$(VBoxStubBld_1_TARGET)
|
---|
1170 | $(call MSG_L1,Building Windows combined package)
|
---|
1171 | $(QUIET)$(RM) -f -- $(wildcard $(subst r$(VBOX_SVN_REV),r*, \
|
---|
1172 | $@ \
|
---|
1173 | $(VBOX_WIN_INST_REPACK_DIR)/4-multiarch-$(PACKAGE_NAME_MULTIARCH_FINAL).cmd ) )
|
---|
1174 | $(if-expr defined(VBOX_WITH_MSM_INSTALL),,$(call VBOX_SIGN_CAB_FN,$(PACKAGE_NAME_MULTIARCH_COMMONCAB)))
|
---|
1175 | $(REDIRECT) -C $(@D) -- \
|
---|
1176 | $(VBoxStubBld_1_TARGET) -out $@ \
|
---|
1177 | -target-x86 $(PATH_MULTIARCH_TEMP)/$(PACKAGE_NAME_MULTIARCH.x86) \
|
---|
1178 | -target-amd64 $(PATH_MULTIARCH_TEMP)/$(PACKAGE_NAME_MULTIARCH.amd64) \
|
---|
1179 | $(if-expr defined(VBOX_WITH_MSM_INSTALL),,-target-all $(PACKAGE_NAME_MULTIARCH_COMMONCAB)) \
|
---|
1180 | -stub $(PATH_STAGE_BIN)/VBoxStub.exe
|
---|
1181 | $(VBOX_VCC_EDITBIN) /IntegrityCheck:NO $@
|
---|
1182 | $(call VBOX_SIGN_FILE_FN,$@)
|
---|
1183 | # Create repack script for this step.
|
---|
1184 | $(APPEND) -nt "$(VBOX_WIN_INST_REPACK_DIR)/4-multiarch-$(@F).cmd" \
|
---|
1185 | 'if ".%KBUILD_DEVTOOLS%" == "." (echo KBUILD_DEVTOOLS is not set & exit /b1)' \
|
---|
1186 | 'if ".%KBUILD_BIN_PATH%" == "." (echo KBUILD_BIN_PATH is not set & exit /b1)' \
|
---|
1187 | $(subst $(KBUILD_BIN_PATH),%KBUILD_BIN_PATH%,$(subst $(KBUILD_DEVTOOLS),%KBUILD_DEVTOOLS%, \
|
---|
1188 | $(if-expr defined(VBOX_WITH_MSM_INSTALL), \
|
---|
1189 | ,'call sign-dual.cmd ../../../win.amd64/$(KBUILD_TYPE)/repack/$(notdir $(PACKAGE_NAME_MULTIARCH_COMMONCAB)) || exit /b1') \
|
---|
1190 | '..\bin\VBoxStubBld.exe ^' \
|
---|
1191 | ' -out $(@F) ^' \
|
---|
1192 | ' -target-x86 $(PACKAGE_NAME_MULTIARCH.x86) ^' \
|
---|
1193 | ' -target-amd64 ../../../win.amd64/$(KBUILD_TYPE)/repack/$(PACKAGE_NAME_MULTIARCH.amd64) ^' \
|
---|
1194 | $(if-expr defined(VBOX_WITH_MSM_INSTALL),\
|
---|
1195 | ,' -target-all ../../../win.amd64/$(KBUILD_TYPE)/repack/$(notdir $(PACKAGE_NAME_MULTIARCH_COMMONCAB)) ^' ) \
|
---|
1196 | ' -stub ../bin/VBoxStub.exe || exit /b1' \
|
---|
1197 | '$(VBOX_VCC_EDITBIN) /IntegrityCheck:NO $(@F) || exit /b1' \
|
---|
1198 | 'call sign-dual.cmd $(@F) || exit /b1' \
|
---|
1199 | ) ) \
|
---|
1200 | '@echo Created multiarch EXE: $(@F)'
|
---|
1201 | else
|
---|
1202 | #
|
---|
1203 | # We still do the installer stub thing even if we only ship 64-bit, because we've
|
---|
1204 | # gotten used to having it around to install the certificate and such.
|
---|
1205 | #
|
---|
1206 | $(PATH_STAGE_BIN)/$(PACKAGE_NAME_MULTIARCH_FINAL) \
|
---|
1207 | + $(VBOX_WIN_INST_REPACK_DIR)/4-multiarch-$(PACKAGE_NAME_MULTIARCH_FINAL).cmd: \
|
---|
1208 | $(PACKAGE_NAME_FINAL) \
|
---|
1209 | $(PATH_STAGE_BIN)/VBoxStub.exe \
|
---|
1210 | $$(VBoxStubBld_1_TARGET)
|
---|
1211 | $(call MSG_L1,Building Windows package w/ installer stub)
|
---|
1212 | $(QUIET)$(RM) -f -- $(wildcard $(subst r$(VBOX_SVN_REV),r*, \
|
---|
1213 | $@ \
|
---|
1214 | $(VBOX_WIN_INST_REPACK_DIR)/4-multiarch-$(PACKAGE_NAME_MULTIARCH_FINAL).cmd ) )
|
---|
1215 | $(REDIRECT) -C $(@D) -- \
|
---|
1216 | $(VBoxStubBld_1_TARGET) -out $@ \
|
---|
1217 | -target-$(KBUILD_TARGET_ARCH) $(PACKAGE_NAME_FINAL) \
|
---|
1218 | -stub $(PATH_STAGE_BIN)/VBoxStub.exe
|
---|
1219 | $(VBOX_VCC_EDITBIN) /IntegrityCheck:NO $@
|
---|
1220 | $(call VBOX_SIGN_FILE_FN,$@)
|
---|
1221 | # Create repack script for this step.
|
---|
1222 | $(APPEND) -nt "$(VBOX_WIN_INST_REPACK_DIR)/4-multiarch-$(@F).cmd" \
|
---|
1223 | 'if ".%KBUILD_DEVTOOLS%" == "." (echo KBUILD_DEVTOOLS is not set & exit /b1)' \
|
---|
1224 | 'if ".%KBUILD_BIN_PATH%" == "." (echo KBUILD_BIN_PATH is not set & exit /b1)' \
|
---|
1225 | $(subst $(KBUILD_BIN_PATH),%KBUILD_BIN_PATH%,$(subst $(KBUILD_DEVTOOLS),%KBUILD_DEVTOOLS%, \
|
---|
1226 | '..\bin\VBoxStubBld.exe ^' \
|
---|
1227 | ' -out $(@F) ^' \
|
---|
1228 | ' -target-$(KBUILD_TARGET_ARCH) $(notdir $(PACKAGE_NAME_FINAL)) ^' \
|
---|
1229 | ' -stub ../bin/VBoxStub.exe || exit /b1' \
|
---|
1230 | '$(VBOX_VCC_EDITBIN) /IntegrityCheck:NO $(@F) || exit /b1' \
|
---|
1231 | 'call sign-dual.cmd $(@F) || exit /b1' \
|
---|
1232 | ) ) \
|
---|
1233 | '@echo Created multiarch EXE: $(@F)'
|
---|
1234 | endif
|
---|
1235 |
|
---|
1236 | #
|
---|
1237 | # Repackaging scripts and files.
|
---|
1238 | #
|
---|
1239 | INSTALLS += RePackScripts
|
---|
1240 | RePackScripts_TEMPLATE = DUMMY
|
---|
1241 | RePackScripts_INST = repack/
|
---|
1242 | RePackScripts_INSTTYPE = stage
|
---|
1243 | RePackScripts_SOURCES = \
|
---|
1244 | Scripts/UnpackBlessedDrivers.cmd \
|
---|
1245 | $(RePackScripts_0_OUTDIR)/PackDriversForSubmission.cmd \
|
---|
1246 | $(RePackScripts_0_OUTDIR)/sign-dual.cmd \
|
---|
1247 | $(RePackScripts_0_OUTDIR)/sign-sha1.cmd \
|
---|
1248 | $(if-expr defined(VBOX_SIGN_EV_FILE_FN),$(RePackScripts_0_OUTDIR)/sign-ev.cmd,) \
|
---|
1249 | $(RePackScripts_0_OUTDIR)/VMMR0.inf \
|
---|
1250 | $(RePackScripts_0_OUTDIR)/VBoxExtPackPuel.inf
|
---|
1251 | if !defined(VBOX_WITH_COMBINED_PACKAGE) || "$(KBUILD_TARGET_ARCH)" == "x86"
|
---|
1252 | RePackScripts_SOURCES += \
|
---|
1253 | $(RePackScripts_0_OUTDIR)/RepackExtPack.cmd
|
---|
1254 | endif
|
---|
1255 | ifdef VBOX_WITH_COMBINED_PACKAGE
|
---|
1256 | if "$(KBUILD_TARGET_ARCH)" == "x86"
|
---|
1257 | RePackScripts_SOURCES += \
|
---|
1258 | $(RePackScripts_0_OUTDIR)/Combined-1-Prepare.cmd \
|
---|
1259 | $(RePackScripts_0_OUTDIR)/Combined-3-Repack.cmd \
|
---|
1260 | $(RePackScripts_0_OUTDIR)/Combined-3-RepackAdditions.cmd
|
---|
1261 | endif
|
---|
1262 | else
|
---|
1263 | RePackScripts_SOURCES += \
|
---|
1264 | $(RePackScripts_0_OUTDIR)/Single-1-Prepare.cmd \
|
---|
1265 | $(RePackScripts_0_OUTDIR)/Single-3-Repack.cmd
|
---|
1266 |
|
---|
1267 | ifndef VBOX_OSE
|
---|
1268 | RePackScripts_SOURCES += \
|
---|
1269 | $(RePackScripts_0_OUTDIR)/Single-0-All.cmd \
|
---|
1270 | Scripts/sign-attestation.sh
|
---|
1271 | endif
|
---|
1272 |
|
---|
1273 | endif
|
---|
1274 | RePackScripts_CLEAN = \
|
---|
1275 | $(RePackScripts_0_OUTDIR)/PackDriversForSubmission.cmd \
|
---|
1276 | $(RePackScripts_0_OUTDIR)/sign-dual.cmd \
|
---|
1277 | $(RePackScripts_0_OUTDIR)/sign-sha1.cmd \
|
---|
1278 | $(RePackScripts_0_OUTDIR)/sign-ev.cmd \
|
---|
1279 | $(RePackScripts_0_OUTDIR)/VMMR0.inf \
|
---|
1280 | $(RePackScripts_0_OUTDIR)/VBoxExtPackPuel.inf
|
---|
1281 |
|
---|
1282 | $(call VBOX_EDIT_VERSION_AND_BUILD_RULE_FN,RePackScripts,Scripts/PackDriversForSubmission.cmd,PackDriversForSubmission.cmd)
|
---|
1283 | $(call VBOX_EDIT_VERSION_AND_BUILD_RULE_FN,RePackScripts,Scripts/RepackExtPack.cmd,RepackExtPack.cmd)
|
---|
1284 | ifdef VBOX_WITH_COMBINED_PACKAGE
|
---|
1285 | $(call VBOX_EDIT_VERSION_AND_BUILD_RULE_FN,RePackScripts,Scripts/Combined-1-Prepare.cmd,Combined-1-Prepare.cmd)
|
---|
1286 | $(call VBOX_EDIT_VERSION_AND_BUILD_RULE_FN,RePackScripts,Scripts/Combined-3-Repack.cmd,Combined-3-Repack.cmd)
|
---|
1287 | $(call VBOX_EDIT_VERSION_AND_BUILD_RULE_FN,RePackScripts,Scripts/Combined-3-RepackAdditions.cmd,Combined-3-RepackAdditions.cmd)
|
---|
1288 | else
|
---|
1289 | ifndef VBOX_OSE
|
---|
1290 | $(call VBOX_EDIT_VERSION_AND_BUILD_RULE_FN,RePackScripts,Scripts/Single-0-All.cmd,Single-0-All.cmd)
|
---|
1291 | endif
|
---|
1292 | $(call VBOX_EDIT_VERSION_AND_BUILD_RULE_FN,RePackScripts,Scripts/Single-1-Prepare.cmd,Single-1-Prepare.cmd)
|
---|
1293 | $(call VBOX_EDIT_VERSION_AND_BUILD_RULE_FN,RePackScripts,Scripts/Single-3-Repack.cmd,Single-3-Repack.cmd)
|
---|
1294 | endif
|
---|
1295 |
|
---|
1296 | $$(RePackScripts_0_OUTDIR)/sign-dual.cmd: | $$(dir $$@)
|
---|
1297 | $(APPEND) -nt "$@" \
|
---|
1298 | 'if ".%KBUILD_DEVTOOLS%" == "." (echo KBUILD_DEVTOOLS is not set & exit /b 1)' \
|
---|
1299 | 'if ".%KBUILD_BIN_PATH%" == "." (echo KBUILD_BIN_PATH is not set & exit /b 1)' \
|
---|
1300 | 'if ".%1" == "." (echo No .cat file specified & exit /b 1)' \
|
---|
1301 | $(subst /win-6.1/,/win-rel/,$(subst $(KBUILD_BIN_PATH),%KBUILD_BIN_PATH%,$(subst $(KBUILD_DEVTOOLS),%KBUILD_DEVTOOLS%, \
|
---|
1302 | '( $(call VBOX_SIGN_FILE_FN,%1,$(VBOX_PRODUCT) $(VBOX_VERSION_STRING)r$(VBOX_SVN_REV) ($(KBUILD_TARGET_ARCH)),,,,&&) ) || exit /b1' \
|
---|
1303 | ) ) )
|
---|
1304 |
|
---|
1305 | $$(RePackScripts_0_OUTDIR)/sign-sha1.cmd: | $$(dir $$@)
|
---|
1306 | $(APPEND) -nt "$@" \
|
---|
1307 | 'if ".%KBUILD_DEVTOOLS%" == "." (echo KBUILD_DEVTOOLS is not set & exit /b 1)' \
|
---|
1308 | 'if ".%KBUILD_BIN_PATH%" == "." (echo KBUILD_BIN_PATH is not set & exit /b 1)' \
|
---|
1309 | 'if ".%1" == "." (echo No .cat file specified & exit /b 1)' \
|
---|
1310 | $(subst $(KBUILD_BIN_PATH),%KBUILD_BIN_PATH%,$(subst $(KBUILD_DEVTOOLS),%KBUILD_DEVTOOLS%, \
|
---|
1311 | '( $(call VBOX_SIGN_FILE_FN,%1,$(VBOX_PRODUCT) $(VBOX_VERSION_STRING)r$(VBOX_SVN_REV) ($(KBUILD_TARGET_ARCH)),,,disable-dual-signing,&&) ) || exit /b1' \
|
---|
1312 | ) )
|
---|
1313 |
|
---|
1314 | # The %~dp1\ oddity is working around otherwise ending with \" during
|
---|
1315 | # expansion of the CCS command line which for a reason I cannot immediately
|
---|
1316 | # understand appends a " to the path.
|
---|
1317 | $$(RePackScripts_0_OUTDIR)/sign-ev.cmd: | $$(dir $$@)
|
---|
1318 | $(APPEND) -nt "$@" \
|
---|
1319 | 'if ".%KBUILD_DEVTOOLS%" == "." (echo KBUILD_DEVTOOLS is not set & exit /b 1)' \
|
---|
1320 | 'if ".%KBUILD_BIN_PATH%" == "." (echo KBUILD_BIN_PATH is not set & exit /b 1)' \
|
---|
1321 | 'if ".%1" == "." (echo No .cab file specified & exit /b 1)' \
|
---|
1322 | $(subst $(KBUILD_BIN_PATH),%KBUILD_BIN_PATH%,$(subst $(KBUILD_DEVTOOLS),%KBUILD_DEVTOOLS%, \
|
---|
1323 | '( $(call VBOX_SIGN_EV_FILE_FN,%1,%~dp1\) ) || exit /b1' \
|
---|
1324 | ) )
|
---|
1325 |
|
---|
1326 | $$(RePackScripts_0_OUTDIR)/VMMR0.inf: $(PATH_SUB_CURRENT)/Scripts/VMMR0.inf $(MAKEFILE_CURRENT) | $$(dir $$@)
|
---|
1327 | $(call MSG_GENERATE,RePackScripts,$@,$<)
|
---|
1328 | $(call VBOX_EDIT_INF_FN,$<,$@)
|
---|
1329 |
|
---|
1330 | $$(RePackScripts_0_OUTDIR)/VBoxExtPackPuel.inf: $(PATH_SUB_CURRENT)/Scripts/VBoxExtPackPuel.inf $(MAKEFILE_CURRENT) | $$(dir $$@)
|
---|
1331 | $(call MSG_GENERATE,RePackScripts,$@,$<)
|
---|
1332 | $(call VBOX_EDIT_INF_FN,$<,$@)
|
---|
1333 |
|
---|
1334 |
|
---|
1335 | include $(FILE_KBUILD_SUB_FOOTER)
|
---|