1 | <!--
|
---|
2 | VirtualBox Windows Installation Script (WiX)
|
---|
3 | -->
|
---|
4 | <!--
|
---|
5 | Copyright (C) 2014-2024 Oracle and/or its affiliates.
|
---|
6 |
|
---|
7 | This file is part of VirtualBox base platform packages, as
|
---|
8 | available from https://www.virtualbox.org.
|
---|
9 |
|
---|
10 | This program is free software; you can redistribute it and/or
|
---|
11 | modify it under the terms of the GNU General Public License
|
---|
12 | as published by the Free Software Foundation, in version 3 of the
|
---|
13 | License.
|
---|
14 |
|
---|
15 | This program is distributed in the hope that it will be useful, but
|
---|
16 | WITHOUT ANY WARRANTY; without even the implied warranty of
|
---|
17 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
---|
18 | General Public License for more details.
|
---|
19 |
|
---|
20 | You should have received a copy of the GNU General Public License
|
---|
21 | along with this program; if not, see <https://www.gnu.org/licenses>.
|
---|
22 |
|
---|
23 | SPDX-License-Identifier: GPL-3.0-only
|
---|
24 | -->
|
---|
25 |
|
---|
26 | <Wix xmlns="http://wixtoolset.org/schemas/v4/wxs">
|
---|
27 |
|
---|
28 | <?include Defines.wxi ?>
|
---|
29 |
|
---|
30 | <?if $(env.VBOX_WITH_MSM_INSTALL) = "yes" ?>
|
---|
31 | <!-- The merge module file names -->
|
---|
32 | <?define Property_VBoxMergeApp = "$(env.VBOX_WIN_INST_MERGE_APP)" ?>
|
---|
33 | <?if $(env.VBOX_WITH_32_ON_64_MAIN_API) = "yes" ?>
|
---|
34 | <?define Property_VBoxMergeCOM32On64 = "$(env.VBOX_WIN_INST_MERGE_COM32ON64)" ?>
|
---|
35 | <?endif?>
|
---|
36 | <?if $(env.VBOX_WITH_USB) = "yes" ?>
|
---|
37 | <?define Property_VBoxMergeUSB = "$(env.VBOX_WIN_INST_MERGE_USB)" ?>
|
---|
38 | <?endif?>
|
---|
39 | <?if $(env.VBOX_WITH_NETFLT) = "yes" ?>
|
---|
40 | <?define Property_VBoxMergeNetworkFlt = "$(env.VBOX_WIN_INST_MERGE_NETFLT)" ?>
|
---|
41 | <?endif?>
|
---|
42 | <?if $(env.VBOX_WITH_NETADP) = "yes" ?>
|
---|
43 | <?define Property_VBoxMergeNetworkAdp = "$(env.VBOX_WIN_INST_MERGE_NETADP)" ?>
|
---|
44 | <?define Property_VBoxMergeNetworkAdp6 = "$(env.VBOX_WIN_INST_MERGE_NETADP6)" ?>
|
---|
45 | <?endif?>
|
---|
46 | <?if $(env.VBOX_WITH_NETFLT) = "yes" ?>
|
---|
47 | <?define Property_VBoxMergeNetworkLwf = "$(env.VBOX_WIN_INST_MERGE_NETLWF)" ?>
|
---|
48 | <?endif?>
|
---|
49 | <?if $(env.VBOX_WITH_PYTHON) = "yes" ?>
|
---|
50 | <?define Property_VBoxMergePython = "$(env.VBOX_WIN_INST_MERGE_PYTHON)" ?>
|
---|
51 | <?endif?>
|
---|
52 | <?endif?>
|
---|
53 |
|
---|
54 | <Package UpgradeCode="C4BAD770-BFE8-4D2C-A592-693028A7215B" Name="$(env.VBOX_PRODUCT) $(env.VBOX_VERSION_STRING)" Language="!(loc.LANG)" Version="$(var.Property_Version)" Manufacturer="$(env.VBOX_VENDOR)" InstallerVersion="200"><SummaryInformation Keywords="Installer" Description="$(env.VBOX_PRODUCT) $(var.Property_VersionExt) installation package" Manufacturer="$(env.VBOX_VENDOR)" />
|
---|
55 |
|
---|
56 | <?include CommonProperties.wxi ?>
|
---|
57 |
|
---|
58 | <!-- Global properties -->
|
---|
59 | <Property Id="ARPPRODUCTICON" Value="IconVirtualBox" />
|
---|
60 | <Property Id="ARPURLINFOABOUT" Value="http://www.virtualbox.org" />
|
---|
61 | <Property Id="ARPURLUPDATEINFO" Value="http://www.virtualbox.org" />
|
---|
62 |
|
---|
63 | <Property Id="NETWORKTYPE" Value="NDIS6" Secure="yes" />
|
---|
64 |
|
---|
65 | <?if $(env.VBOX_WITH_MSM_INSTALL) = "no" ?>
|
---|
66 | <!-- Force NDIS5 on pre-Vista -->
|
---|
67 | <SetProperty Id="NETWORKTYPE" After="LaunchConditions" Value="NDIS5" Condition="(VersionNT < 600)" />
|
---|
68 | <?endif?>
|
---|
69 |
|
---|
70 | <!-- Whether or not registering of known desktop shortcut for the Quick Launch Bar should be created -->
|
---|
71 | <Property Id="VBOX_REGISTERFILEEXTENSIONS" Value="1" Secure="yes" />
|
---|
72 |
|
---|
73 | <SetProperty Id="VBOX_REGISTERFILEEXTENSIONS" After="AppSearch" Sequence="both" Value="{}" Condition="VBOX_REGISTERFILEEXTENSIONS="0"" />
|
---|
74 |
|
---|
75 | <!-- Force overwriting all files and re-create shortcuts to guarantee a working environment -->
|
---|
76 | <Property Id="REINSTALLMODE" Value="amus" />
|
---|
77 |
|
---|
78 | <?include PublicProperties.wxi ?>
|
---|
79 |
|
---|
80 | <!-- Make sure installation will not start on anything other but the NT family -->
|
---|
81 | <?if $(env.KBUILD_TARGET_ARCH) = "amd64" ?>
|
---|
82 | <Launch Condition="VersionNT64" Message="!(loc.Only64Bit)" />
|
---|
83 | <?else?>
|
---|
84 | <Launch Condition="NOT VersionNT64" Message="!(loc.Only32Bit)" />
|
---|
85 |
|
---|
86 | <Launch Condition="NOT VersionNT=500 AND NOT Version9X AND NOT VersionNT64" Message="!(loc.WrongOS)" />
|
---|
87 |
|
---|
88 | <?endif?>
|
---|
89 |
|
---|
90 | <Launch Condition="Privileged" Message="!(loc.NeedAdmin)" />
|
---|
91 |
|
---|
92 | <?if $(env.VBOX_WITH_CRT_PACKING) = "no" ?>
|
---|
93 | <!-- Check if we have the required MS CRT(s) installed when we're not shipping those. -->
|
---|
94 | <Launch Condition="Installed OR (VBOX_MSCRT_INSTALLED)" Message="!(loc.NeedMSCRT)" />
|
---|
95 | <?endif?>
|
---|
96 | <!-- Check if the current INSTALLDIR is valid or not, or if VBox already is installed.
|
---|
97 | Thight might be handed-in via command line (MSI properties) or through a customized merge module. See @bugref{10616} -->
|
---|
98 | <Launch Condition="Installed OR (VBox_Target_Dir_Is_Valid="1")" Message="!(loc.InvalidTargetDir)" />
|
---|
99 |
|
---|
100 | <!-- Detect old innotek installation -->
|
---|
101 | <!-- Force a manual uninstall of an already installed innotek VirtualBox version first -->
|
---|
102 | <Property Id="VBOXINNOTEK">
|
---|
103 | <RegistrySearch Id="RegSearchInnotekVersion" Root="HKLM" Key="SOFTWARE\Innotek\VirtualBox" Name="Version" Type="raw" Bitness="$(var.Property_Bitness)" />
|
---|
104 | </Property>
|
---|
105 | <Launch Condition="NOT VBOXINNOTEK" Message="!(loc.InnotekFound)" />
|
---|
106 |
|
---|
107 |
|
---|
108 | <!-- *************************** Upgrade packages only ******************************* -->
|
---|
109 | <!-- Minimum and Maximum specify the range of versions we are supposed to update with this upgrade.
|
---|
110 | IncludeMaximum and IncludeMinimum specify whether the bound value is actually included in the range or not
|
---|
111 | (IncludeMaximum = yes meaning to find versions below or equal to the version specified in Maximum while
|
---|
112 | IncludeMaximum = no only finds those below the Maximum).
|
---|
113 | OnlyDetect tells the installer not to remove the previous product. This is useful as long as we
|
---|
114 | only change files in the package -->
|
---|
115 |
|
---|
116 | <Upgrade Id="C4BAD770-BFE8-4D2C-A592-693028A7215B"> <!-- Upgrade of Sun xVM VirtualBox >= v1.6.0 -->
|
---|
117 |
|
---|
118 | <!-- Upgrade is flagged if current-install is newer than or equal to package - TODO: should make a dialog appear asking user to confirm downgrade -->
|
---|
119 | <!-- Setting "OnlyDetect" to "no" makes the installer uninstall an already newer installed version -->
|
---|
120 | <UpgradeVersion Property="NEWERVERSIONDETECTED" Minimum="$(var.Property_Version)" IncludeMinimum="no" OnlyDetect="no" />
|
---|
121 |
|
---|
122 | <!-- Flag is set if the install will trigger an upgrade of an existing install -->
|
---|
123 | <UpgradeVersion Property="PREVIOUSVERSIONSINSTALLED" Minimum="1.0.0.0" Maximum="$(var.Property_Version)" IncludeMaximum="yes" />
|
---|
124 |
|
---|
125 | </Upgrade>
|
---|
126 |
|
---|
127 | <!-- The product's icon table -->
|
---|
128 | <Icon Id="IconVirtualBox" SourceFile="$(env.VBOX_WINDOWS_ICON_FILE)" />
|
---|
129 |
|
---|
130 | <!-- The media/binary IDs -->
|
---|
131 | <!--
|
---|
132 | The effects of CompressionLevel options:
|
---|
133 | default/mszip, high: 32.54s
|
---|
134 | -rw-rw-rw- 1 bird 0 53 591 221 2016-09-25 03:56 common.cab
|
---|
135 | -rw-rw-rw- 1 bird 0 41 560 082 2016-09-25 03:56 VirtualBox-5.1.51-r110887_en_US.msi
|
---|
136 | high, high: 46.76s
|
---|
137 | -rw-rw-rw- 1 bird 0 53 591 221 2016-09-25 03:49 common.cab
|
---|
138 | -rw-rw-rw- 1 bird 0 34 056 210 2016-09-25 03:49 VirtualBox-5.1.51-r110887_en_US.msi
|
---|
139 | medium, medium: 29.95s
|
---|
140 | -rw-rw-rw- 1 bird 0 56 293 089 2016-09-25 03:53 common.cab
|
---|
141 | -rw-rw-rw- 1 bird 0 35 498 002 2016-09-25 03:54 VirtualBox-5.1.51-r110887_en_US.msi
|
---|
142 | low, low: 25.41s
|
---|
143 | -rw-rw-rw- 1 bird 0 57 616 155 2016-09-25 03:52 common.cab
|
---|
144 | -rw-rw-rw- 1 bird 0 37 181 458 2016-09-25 03:52 VirtualBox-5.1.51-r110887_en_US.msi
|
---|
145 | mszip/default, mszip/default: 16.13s
|
---|
146 | -rw-rw-rw- 1 bird 0 58 751 954 2016-09-25 03:49 common.cab
|
---|
147 | -rw-rw-rw- 1 bird 0 41 560 082 2016-09-25 03:50 VirtualBox-5.1.51-r110887_en_US.msi
|
---|
148 | none, none: 2.37s
|
---|
149 | -rw-rw-rw- 1 bird 0 92 470 301 2016-09-25 03:47 common.cab
|
---|
150 | -rw-rw-rw- 1 bird 0 135 874 578 2016-09-25 03:47 VirtualBox-5.1.51-r110887_en_US.msi
|
---|
151 |
|
---|
152 | We set the level in the VBOX_CAB_COMPRESSION_LEVEL and VBOX_CAB_COMPRESSION_LEVEL_COMMON
|
---|
153 | environment variables so we don't waste time compressing and decompressing the intermediate
|
---|
154 | language MSIs and the common.cab that we're not going to use (x86).
|
---|
155 | -->
|
---|
156 | <Media Id="1" Cabinet="product.cab" EmbedCab="yes" CompressionLevel="$(env.VBOX_CAB_COMPRESSION_LEVEL)" />
|
---|
157 | <?if $(env.VBOX_WITH_MSM_INSTALL) = "no" ?>
|
---|
158 | <?if $(env.VBOX_WITH_COMBINED_PACKAGE) = "yes" ?>
|
---|
159 | <Media Id="2" Cabinet="common.cab" EmbedCab="no" CompressionLevel="$(env.VBOX_CAB_COMPRESSION_LEVEL_COMMON)" />
|
---|
160 | <?endif?>
|
---|
161 | <?endif?>
|
---|
162 | <Binary Id="VBoxInstallHelper" SourceFile="$(env.PATH_OUT)\bin\VBoxInstallHelper.dll" />
|
---|
163 |
|
---|
164 | <!-- Custom actions -->
|
---|
165 |
|
---|
166 | <!-- Figure out where a previous installation was, if any -->
|
---|
167 | <?if $(env.KBUILD_TARGET_ARCH) = "amd64" ?>
|
---|
168 | <CustomAction Id="ca_OriginalTargetDir" Execute="firstSequence" Property="INSTALLDIR" Value="[ProgramFiles64Folder]\$(env.VBOX_VENDOR_SHORT)\VirtualBox" />
|
---|
169 |
|
---|
170 | <Property Id="EXISTINGINSTALLDIR" Secure="yes">
|
---|
171 | <RegistrySearch Id="RegistryGetInstallPath" Root="HKLM" Key="$(var.Property_RegKey)" Name="InstallDir" Type="raw" Bitness="$(var.Property_Bitness)" />
|
---|
172 | </Property>
|
---|
173 | <CustomAction Id="ca_DefaultTargetDir" Execute="firstSequence" Property="INSTALLDIR" Value="[EXISTINGINSTALLDIR]" />
|
---|
174 | <?else?>
|
---|
175 | <CustomAction Id="ca_OriginalTargetDir" Execute="firstSequence" Property="INSTALLDIR" Value="[ProgramFilesFolder]\$(env.VBOX_VENDOR_SHORT)\VirtualBox" />
|
---|
176 |
|
---|
177 | <Property Id="EXISTINGINSTALLDIR" Secure="yes">
|
---|
178 | <RegistrySearch Id="RegistryGetInstallPath" Root="HKLM" Key="$(var.Property_RegKey)" Name="InstallDir" Type="raw" Bitness="$(var.Property_Bitness)" />
|
---|
179 | </Property>
|
---|
180 | <CustomAction Id="ca_DefaultTargetDir" Execute="firstSequence" Property="INSTALLDIR" Value="[EXISTINGINSTALLDIR]" />
|
---|
181 | <?endif?>
|
---|
182 | <CustomAction Id="ca_UninstallTAPInstances" DllEntry="UninstallTAPInstances" Execute="deferred" Return="check" Impersonate="no" BinaryRef="VBoxInstallHelper" />
|
---|
183 |
|
---|
184 | <CustomAction Id="ca_UninstallVBoxDrv" DllEntry="UninstallVBoxDrv" Execute="deferred" Return="ignore" Impersonate="no" BinaryRef="VBoxInstallHelper" />
|
---|
185 |
|
---|
186 | <Property Id="VBOXDEPENDENCY" Secure="yes">
|
---|
187 | <DirectorySearch Id="VBoxInstallDir" Path="[EXISTINGINSTALLDIR]">
|
---|
188 | <FileSearch Name="dependency.dep" />
|
---|
189 | </DirectorySearch>
|
---|
190 | </Property>
|
---|
191 |
|
---|
192 | <?if $(env.VBOX_WITH_PYTHON) = "yes" ?>
|
---|
193 | <Property Id="EXISTING_PYTHON_API_FOLDER" Secure="yes">
|
---|
194 | <RegistrySearch Id="RegistryGetPythonApiInstallPath" Root="HKLM" Key="$(var.Property_RegKey)" Name="PythonApiInstallDir" Type="raw" Bitness="$(var.Property_Bitness)" />
|
---|
195 | </Property>
|
---|
196 | <?endif?>
|
---|
197 |
|
---|
198 | <!--
|
---|
199 | install upgrade uninstall
|
---|
200 | VBOXDEPENDENCY 0 1/0 1/0
|
---|
201 | UPGRADINGPRODUCTCODE 0 1 0
|
---|
202 | final 0 1 0
|
---|
203 | not final 1 0 1
|
---|
204 | -->
|
---|
205 |
|
---|
206 | <Launch Condition="NOT (VBOXDEPENDENCY AND UPGRADINGPRODUCTCODE)"
|
---|
207 | Message="It was detected an application which has been using currently installed VirtualBox version.
|
---|
208 | You must remove this application before continuing installation.
|
---|
209 | See the file dependency.dep in the VirtualBox installation directory for details. " />
|
---|
210 |
|
---|
211 | <!-- Detect old Sun installation -->
|
---|
212 | <!-- Force a manual uninstall of an already installed Sun VirtualBox version first -->
|
---|
213 | <!--<Property Id="VBOXSUN">
|
---|
214 | <RegistrySearch Id="RegSearchSunVersion" Root="HKLM" Key="SOFTWARE\Sun\VirtualBox" Name="Version" Type="raw" Bitness="$(var.Property_Bitness)"/>
|
---|
215 | </Property>
|
---|
216 | <Condition Message="!(loc.SunFound)">
|
---|
217 | NOT VBOXSUN
|
---|
218 | </Condition>-->
|
---|
219 |
|
---|
220 | <!-- Note: Only if we include FE/Qt, we offer to start VirtualBox at the end of a successful installation. -->
|
---|
221 | <?if $(env.VBOX_WITH_QTGUI) = "yes" ?>
|
---|
222 | <!-- Note: Make sure to set the CWD (via 'Directory' attribute) to not run off a possibly temporary directory or some such (see @bugref{10203}). -->
|
---|
223 | <CustomAction Id="ca_StartVBox" Directory="INSTALLDIR" ExeCommand="[INSTALLDIR]VirtualBox.exe" Return="asyncNoWait" Impersonate="yes" />
|
---|
224 | <?endif?>
|
---|
225 |
|
---|
226 | <CustomAction Id="ca_CheckSerial" DllEntry="CheckSerial" Impersonate="no" BinaryRef="VBoxInstallHelper" />
|
---|
227 |
|
---|
228 | <CustomAction Id="ca_InstallBranding" DllEntry="InstallBranding" Execute="deferred" Return="check" Impersonate="no" BinaryRef="VBoxInstallHelper" />
|
---|
229 | <CustomAction Id="ca_InstallBrandingArgs" Property="ca_InstallBranding" Value="[INSTALLDIR]" Execute="immediate" />
|
---|
230 |
|
---|
231 | <CustomAction Id="ca_UninstallBranding" DllEntry="UninstallBranding" Execute="deferred" Return="check" Impersonate="no" BinaryRef="VBoxInstallHelper" />
|
---|
232 | <CustomAction Id="ca_UninstallBrandingArgs" Property="ca_UninstallBranding" Value="[INSTALLDIR]" Execute="immediate" />
|
---|
233 |
|
---|
234 | <?include VBoxMergeAppCA.wxi ?>
|
---|
235 | <?if $(env.VBOX_WITH_MSM_INSTALL) = "no" ?>
|
---|
236 | <?if $(env.VBOX_WITH_32_ON_64_MAIN_API) = "yes" ?>
|
---|
237 | <?include VBoxMergeCOM32On64CA.wxi ?>
|
---|
238 | <?endif?>
|
---|
239 | <?if $(env.VBOX_WITH_NETFLT) = "yes" ?>
|
---|
240 | <?include VBoxMergeNetFltCA.wxi ?>
|
---|
241 | <?include VBoxMergeNetLwfCA.wxi ?>
|
---|
242 | <?endif?>
|
---|
243 | <?include VBoxMergeNetAdpCA.wxi ?>
|
---|
244 | <?include VBoxMergeNetAdp6CA.wxi ?>
|
---|
245 | <?include VBoxMergeUSBCA.wxi ?>
|
---|
246 | <?if $(env.VBOX_WITH_PYTHON) = "yes" ?>
|
---|
247 | <?include VBoxMergePythonCA.wxi ?>
|
---|
248 | <?endif?>
|
---|
249 | <?endif?>
|
---|
250 |
|
---|
251 | <!-- TARGETDIR -->
|
---|
252 |
|
---|
253 | <!-- Note: Feature IDs *must not* be renamed to use any prefixes or such,
|
---|
254 | otherwise this will break manual selection using the ADDLOCAL= syntax
|
---|
255 | when using the command line / scripts (see VBox manual). -->
|
---|
256 | <Feature Id="VBoxApplication" Title="VirtualBox Application" Level="1" Description="!(loc.VB_App)" ConfigurableDirectory="INSTALLDIR" TypicalDefault="install" Display="expand" AllowAdvertise="no" AllowAbsent="no">
|
---|
257 |
|
---|
258 | <?if $(env.VBOX_WITH_QTGUI) = "yes" ?>
|
---|
259 | <!-- Components which are handled only by this installer itself -->
|
---|
260 | <ComponentRef Id="cp_StartMenuVBox" />
|
---|
261 | <ComponentRef Id="cp_DesktopShortcut" />
|
---|
262 | <ComponentRef Id="cp_QuickLaunchVBox" />
|
---|
263 | <?endif?>
|
---|
264 | <!-- Components for removing empty folders after cleaning traces -->
|
---|
265 | <ComponentRef Id="cp_INSTALLDIR" />
|
---|
266 | <ComponentRef Id="cp_SDK" />
|
---|
267 |
|
---|
268 | <!-- Components handled either by the installer itself or
|
---|
269 | the merge module -->
|
---|
270 | <?if $(env.VBOX_WITH_MSM_INSTALL) = "yes" ?>
|
---|
271 | <MergeRef Id="msm_VBoxApp" />
|
---|
272 | <?if $(env.VBOX_WITH_32_ON_64_MAIN_API) = "yes" ?>
|
---|
273 | <MergeRef Id="msm_VBoxCOM32On64" />
|
---|
274 | <?endif?>
|
---|
275 | <?else?>
|
---|
276 | <!-- Make sure to reference the permissions component, which takes care of setting
|
---|
277 | the required ACLs for our files / folders. -->
|
---|
278 | <ComponentRef Id="cp_Permissions" />
|
---|
279 | <?if $(env.VBOX_WITH_QTGUI) = "yes" ?>
|
---|
280 | <ComponentRef Id="cp_RegisterExtensions" />
|
---|
281 | <?endif?>
|
---|
282 | <?if $(env.VBOX_WITH_DOCS_PACKING) = "yes" ?>
|
---|
283 | <ComponentRef Id="cp_Docs" />
|
---|
284 | <?endif?>
|
---|
285 | <?if $(env.VBOX_WITH_QTGUI) = "yes" ?>
|
---|
286 | <ComponentRef Id="cp_NLS" />
|
---|
287 | <?endif?>
|
---|
288 | <?if $(env.VBOX_WITH_32_ON_64_MAIN_API) = "yes" ?>
|
---|
289 | <ComponentRef Id="cp_MainCOM_x86" />
|
---|
290 | <?endif?>
|
---|
291 | <ComponentRef Id="cp_MainCOM" />
|
---|
292 | <?if $(env.VBOX_WITH_SDS) = "yes" ?>
|
---|
293 | <ComponentRef Id="cp_VBoxSDS" />
|
---|
294 | <?endif?>
|
---|
295 | <?if $(env.VBOX_WITH_MIDL_PROXY_STUB) = "yes" ?>
|
---|
296 | <ComponentRef Id="cp_ProxyStub" />
|
---|
297 | <ComponentRef Id="cp_ProxyStubLegacy" />
|
---|
298 | <?endif?>
|
---|
299 | <?if $(env.VBOX_WITH_DTRACE) = "yes" ?>
|
---|
300 | <ComponentRef Id="cp_dir_DTrace_lib_arch" />
|
---|
301 | <ComponentRef Id="cp_dir_DTrace_testcase_arch" />
|
---|
302 | <?endif?>
|
---|
303 | <?if $(env.VBOX_WITH_UNATTENDED_TEMPLATES) = "yes" ?>
|
---|
304 | <ComponentRef Id="cp_UnattendedTemplates" />
|
---|
305 | <?endif?>
|
---|
306 | <ComponentRef Id="cp_MainBinaries" />
|
---|
307 | <?if $(env.VBOX_WITH_QTGUI) = "yes" ?>
|
---|
308 | <ComponentRef Id="cp_QtPlatforms" />
|
---|
309 | <ComponentRef Id="cp_QtSqldrivers" />
|
---|
310 | <ComponentRef Id="cp_QtStyles" />
|
---|
311 | <?endif?>
|
---|
312 | <?if $(env.VBOX_WITH_PYTHON) = "yes" ?>
|
---|
313 | <ComponentRef Id="cp_VBoxPyInst" />
|
---|
314 | <ComponentRef Id="cp_VBoxPySetup" />
|
---|
315 | <ComponentRef Id="cp_VBoxPyMod" />
|
---|
316 | <ComponentRef Id="cp_VBoxPyDel" />
|
---|
317 | <?endif?>
|
---|
318 | <?if $(env.VBOX_WITH_VBOXSDL) = "yes" ?>
|
---|
319 | <ComponentRef Id="cp_VBoxSDLBinaries" />
|
---|
320 | <?endif?>
|
---|
321 | <?if $(env.VBOX_WITH_WEBSERVICES) = "yes" ?>
|
---|
322 | <ComponentRef Id="cp_VBoxWebService" />
|
---|
323 | <?endif?>
|
---|
324 | <ComponentRef Id="cp_VBoxCAPI" />
|
---|
325 | <?if $(env.VBOX_SIGNING_MODE) != none ?>
|
---|
326 | <ComponentRef Id="cp_VBoxSupCat_PreW10" />
|
---|
327 | <ComponentRef Id="cp_VBoxSupCat_W10" />
|
---|
328 | <?endif?>
|
---|
329 | <ComponentRef Id="cp_VBoxSup" />
|
---|
330 | <?endif?>
|
---|
331 |
|
---|
332 | <?if $(env.VBOX_WITH_USB) = "yes" ?>
|
---|
333 | <Feature Id="VBoxUSB" Title="VirtualBox USB Support" Level="1" Description="!(loc.VB_USBDriver)" ConfigurableDirectory="INSTALLDIR" TypicalDefault="install" Display="expand" AllowAdvertise="no">
|
---|
334 | <?if $(env.VBOX_WITH_MSM_INSTALL) = "yes" ?>
|
---|
335 | <MergeRef Id="msm_VBoxUSB" />
|
---|
336 | <?else?>
|
---|
337 | <?if $(env.VBOX_SIGNING_MODE) != none ?>
|
---|
338 | <ComponentRef Id="cp_USBFilterDriverCat_PreW10" />
|
---|
339 | <ComponentRef Id="cp_USBFilterDriverCat_W10" />
|
---|
340 | <?endif?>
|
---|
341 | <ComponentRef Id="cp_USBFilterDriver" />
|
---|
342 | <?if $(env.VBOX_SIGNING_MODE) != none ?>
|
---|
343 | <ComponentRef Id="cp_USBDeviceDriverCat_PreW10" />
|
---|
344 | <ComponentRef Id="cp_USBDeviceDriverCat_W10" />
|
---|
345 | <?endif?>
|
---|
346 | <ComponentRef Id="cp_USBDeviceDriver" />
|
---|
347 | <?endif?>
|
---|
348 | </Feature>
|
---|
349 | <?endif?>
|
---|
350 |
|
---|
351 | <?if $(env.VBOX_WITH_NETFLT) = "yes" ?>
|
---|
352 | <Feature Id="VBoxNetwork" Title="VirtualBox Networking" Level="1" Description="!(loc.VB_Network)" ConfigurableDirectory="INSTALLDIR" TypicalDefault="install" Display="expand" AllowAdvertise="no">
|
---|
353 | <Feature Id="VBoxNetworkFlt" Title="VirtualBox Bridged Networking" Level="1" Description="!(loc.VB_NetFltDriver)" ConfigurableDirectory="INSTALLDIR" TypicalDefault="install" Display="expand" AllowAdvertise="no">
|
---|
354 | <?if $(env.VBOX_WITH_MSM_INSTALL) = "yes" ?>
|
---|
355 | <MergeRef Id="msm_VBoxNetworkFlt" />
|
---|
356 | <MergeRef Id="msm_VBoxNetworkLwf" />
|
---|
357 | <?else?>
|
---|
358 | <ComponentRef Id="cp_NetFltDriver" />
|
---|
359 | <?if $(env.VBOX_SIGNING_MODE) != none ?>
|
---|
360 | <ComponentRef Id="cp_NetLwfDriverCat_PreW10" />
|
---|
361 | <ComponentRef Id="cp_NetLwfDriverCat_W10" />
|
---|
362 | <?endif?>
|
---|
363 | <ComponentRef Id="cp_NetLwfDriver" />
|
---|
364 | <?endif?>
|
---|
365 | </Feature>
|
---|
366 | <Feature Id="VBoxNetworkAdp" Title="VirtualBox Host-Only Networking" Level="1" Description="!(loc.VB_NetAdpDriver)" ConfigurableDirectory="INSTALLDIR" TypicalDefault="install" Display="expand" AllowAdvertise="no">
|
---|
367 | <?if $(env.VBOX_WITH_MSM_INSTALL) = "yes" ?>
|
---|
368 | <MergeRef Id="msm_VBoxNetworkAdp" />
|
---|
369 | <MergeRef Id="msm_VBoxNetworkAdp6" />
|
---|
370 | <?else?>
|
---|
371 | <ComponentRef Id="cp_NetAdpDriver" />
|
---|
372 | <?if $(env.VBOX_SIGNING_MODE) != none ?>
|
---|
373 | <ComponentRef Id="cp_NetAdp6DriverCat_PreW10" />
|
---|
374 | <ComponentRef Id="cp_NetAdp6DriverCat_W10" />
|
---|
375 | <?endif?>
|
---|
376 | <ComponentRef Id="cp_NetAdp6Driver" />
|
---|
377 | <?endif?>
|
---|
378 | </Feature>
|
---|
379 |
|
---|
380 | </Feature>
|
---|
381 | <?endif?>
|
---|
382 |
|
---|
383 | <?if $(env.VBOX_WITH_PYTHON) = "yes" ?>
|
---|
384 | <Feature Id="VBoxPython" Title="VirtualBox Python Support" Level="1" Description="!(loc.VB_Python)" ConfigurableDirectory="INSTALLDIR" TypicalDefault="install" Display="expand" AllowAdvertise="no">
|
---|
385 | <?if $(env.VBOX_WITH_MSM_INSTALL) = "yes" ?>
|
---|
386 | <MergeRef Id="msm_VBoxPython" />
|
---|
387 | <?else?>
|
---|
388 | <ComponentRef Id="cp_VBoxPythonBinding" />
|
---|
389 | <?endif?>
|
---|
390 | </Feature>
|
---|
391 | <?endif?>
|
---|
392 | </Feature>
|
---|
393 |
|
---|
394 | <!-- Include user interface definition -->
|
---|
395 | <?include UserInterface.wxi ?>
|
---|
396 |
|
---|
397 | <InstallExecuteSequence>
|
---|
398 |
|
---|
399 | <!--
|
---|
400 | To debug the action sequences, do: "msiexec /i <VBox.msi> /lar <Logfile>"
|
---|
401 |
|
---|
402 | InstallUISequence (client side) is:
|
---|
403 | AppSearch
|
---|
404 | LaunchConditions
|
---|
405 | ValidateProductID
|
---|
406 | CostInitialize
|
---|
407 | FileCost
|
---|
408 | CostFinalize
|
---|
409 | ExecuteAction -> will pass control over to "InstallExecuteSequence"
|
---|
410 |
|
---|
411 | The first six actions above will be repeated but skipped on the server
|
---|
412 | side if already run on the client side.
|
---|
413 |
|
---|
414 | InstallExecuteSequence (server side) is:
|
---|
415 | <First six action from InstallUISequence>
|
---|
416 | .
|
---|
417 | InstallInitialize
|
---|
418 | .
|
---|
419 | InstallFinalize
|
---|
420 |
|
---|
421 | The actions between InstallInitialize and InstallFinalize will be gone through twice:
|
---|
422 | - The first time the installer creates an installation script containing all actions in the right
|
---|
423 | sequence which need to get executed in a batch later. At this point the launch conditions for
|
---|
424 | custom actions must be met already!
|
---|
425 | - The second time the generated installation script will be run as-is.
|
---|
426 |
|
---|
427 | Also, the InstallUISequence and InstallExecuteSequence tables run in different sessions which
|
---|
428 | need public properties (that is, UPPERCASE properties).
|
---|
429 | -->
|
---|
430 |
|
---|
431 | <!-- AppSearch must be done before "RemoveExistingProducts" and before "FindRelatedProducts" -->
|
---|
432 | <AppSearch Sequence="1"></AppSearch>
|
---|
433 | <LaunchConditions After="AppSearch" />
|
---|
434 |
|
---|
435 | <!-- First install the new version and then remove the old version. This is more efficient -->
|
---|
436 | <RemoveExistingProducts After="InstallValidate" Condition="PREVIOUSVERSIONSINSTALLED OR NEWERVERSIONDETECTED" />
|
---|
437 |
|
---|
438 | <Custom Action="ca_OriginalTargetDir" After="FileCost" Condition="(NOT INSTALLDIR)" />
|
---|
439 | <Custom Action="ca_DefaultTargetDir" Before="FileCost" Condition="NOT INSTALLDIR AND EXISTINGINSTALLDIR" />
|
---|
440 |
|
---|
441 | <!-- Check + unininstall old TAP instances - we don't need them anymore -->
|
---|
442 | <Custom Action="ca_UninstallTAPInstances" Before="InstallFiles" Condition="1" />
|
---|
443 |
|
---|
444 | <!-- Check + uninstall old VBoxDrv service - it was renamed to VBoxSup. -->
|
---|
445 | <Custom Action="ca_UninstallVBoxDrv" Before="InstallFiles" Condition="1" />
|
---|
446 |
|
---|
447 | <Custom Action="ca_InstallBrandingArgs" Before="ca_InstallBranding" Condition="NOT REMOVE" />
|
---|
448 | <Custom Action="ca_InstallBranding" Before="InstallFinalize" Condition="NOT REMOVE" />
|
---|
449 |
|
---|
450 | <!-- Uninstall branding on complete uninstall, not on update -->
|
---|
451 | <Custom Action="ca_UninstallBrandingArgs" Before="ca_UninstallBranding" Condition="(NOT UPGRADINGPRODUCTCODE) AND (REMOVE="ALL")" />
|
---|
452 | <Custom Action="ca_UninstallBranding" Before="InstallFinalize" Condition="(NOT UPGRADINGPRODUCTCODE) AND (REMOVE="ALL")" />
|
---|
453 |
|
---|
454 | <?if $(env.VBOX_WITH_MSM_INSTALL) = "no" ?>
|
---|
455 | <?include VBoxMergeAppSeq.wxi ?>
|
---|
456 | <?if $(env.VBOX_WITH_32_ON_64_MAIN_API) = "yes" ?>
|
---|
457 | <?include VBoxMergeCOM32On64Seq.wxi ?>
|
---|
458 | <?endif?>
|
---|
459 | <?if $(env.VBOX_WITH_NETFLT) = "yes" ?>
|
---|
460 | <?include VBoxMergeNetFltSeq.wxi ?>
|
---|
461 | <?include VBoxMergeNetLwfSeq.wxi ?>
|
---|
462 | <?endif?>
|
---|
463 | <?include VBoxMergeNetAdpSeq.wxi ?>
|
---|
464 | <?include VBoxMergeNetAdp6Seq.wxi ?>
|
---|
465 | <?include VBoxMergeUSBSeq.wxi ?>
|
---|
466 | <?if $(env.VBOX_WITH_PYTHON) = "yes" ?>
|
---|
467 | <?include VBoxMergePythonSeq.wxi ?>
|
---|
468 | <?endif?>
|
---|
469 | <?endif?>
|
---|
470 |
|
---|
471 | </InstallExecuteSequence>
|
---|
472 |
|
---|
473 | <?if $(env.VBOX_WITH_QTGUI) = "yes" ?>
|
---|
474 | <!-- Set up special directory IDs for referencing to the start menu
|
---|
475 | or the Quick Launch bar.
|
---|
476 | See: http://msdn.microsoft.com/en-us/library/aa368276.aspx
|
---|
477 | http://wix.mindcapers.com/wiki/Shortcuts_in_WiX -->
|
---|
478 | <StandardDirectory Id="ProgramMenuFolder">
|
---|
479 | <Directory Id="dir_StartMenuVBox" Name="$(env.VBOX_PRODUCT)" />
|
---|
480 | </StandardDirectory>
|
---|
481 |
|
---|
482 | <StandardDirectory Id="DesktopFolder" />
|
---|
483 |
|
---|
484 | <StandardDirectory Id="AppDataFolder">
|
---|
485 | <Directory Id="dir_AppDataMicrosoft" Name="Microsoft">
|
---|
486 | <Directory Id="dir_AppDataMSIE" Name="Internet Explorer">
|
---|
487 | <Directory Id="dir_QuicklaunchFolder" Name="Quick Launch" />
|
---|
488 | </Directory>
|
---|
489 | </Directory>
|
---|
490 | </StandardDirectory>
|
---|
491 | <?endif?>
|
---|
492 |
|
---|
493 | <Directory Id="$(var.Property_ProgramFiles)" Name="PFiles">
|
---|
494 | <Directory Id="VENDOR" Name="$(env.VBOX_VENDOR_SHORT)">
|
---|
495 | <Directory Id="INSTALLDIR" Name="VirtualBox">
|
---|
496 | <!-- Components for removing empty folder after cleaning traces -->
|
---|
497 | <Component Id="cp_INSTALLDIR" Guid="374723AF-5990-4552-A1B0-82C72EFA360F">
|
---|
498 | <RemoveFolder Id="INSTALLDIR" On="uninstall" />
|
---|
499 | </Component>
|
---|
500 | <?if $(env.VBOX_WITH_MSM_INSTALL) = "yes" ?>
|
---|
501 | <Merge Id="msm_VBoxApp" Language="0" SourceFile="$(var.Property_VBoxMergeApp)" DiskId="1">
|
---|
502 | <ConfigurationData Name="argRegisterExtensions" Value="[VBOX_REGISTERFILEEXTENSIONS]" />
|
---|
503 | </Merge>
|
---|
504 | <?if $(env.VBOX_WITH_32_ON_64_MAIN_API) = "yes" ?>
|
---|
505 | <Merge Id="msm_VBoxCOM32On64" Language="0" SourceFile="$(var.Property_VBoxMergeCOM32On64)" DiskId="1" />
|
---|
506 | <?endif?>
|
---|
507 | <?else?>
|
---|
508 | <Directory Id="msm_VBoxApplicationFolder" FileSource=".">
|
---|
509 | <?include VBoxMergeApp.wxi ?>
|
---|
510 | <?if $(env.VBOX_WITH_32_ON_64_MAIN_API) = "yes" ?>
|
---|
511 | <?include VBoxMergeCOM32On64.wxi ?>
|
---|
512 | <?endif?>
|
---|
513 | </Directory>
|
---|
514 | <?endif?>
|
---|
515 | <Directory Id="dir_Drivers" Name="drivers">
|
---|
516 | <?if $(env.VBOX_WITH_USB) = "yes" ?>
|
---|
517 | <Directory Id="dir_USB" Name="USB">
|
---|
518 | <?if $(env.VBOX_WITH_MSM_INSTALL) = "yes" ?>
|
---|
519 | <Merge Id="msm_VBoxUSB" Language="0" SourceFile="$(var.Property_VBoxMergeUSB)" DiskId="1" />
|
---|
520 | <?else?>
|
---|
521 | <Directory Id="msm_VBoxUSBFolder" FileSource=".">
|
---|
522 | <?include VBoxMergeUSB.wxi ?>
|
---|
523 | </Directory>
|
---|
524 | <?endif?>
|
---|
525 | </Directory>
|
---|
526 | <?endif?>
|
---|
527 | <Directory Id="dir_Network" Name="network">
|
---|
528 | <?if $(env.VBOX_WITH_NETFLT) = "yes" ?>
|
---|
529 | <Directory Id="dir_NetFlt" Name="netflt">
|
---|
530 | <?if $(env.VBOX_WITH_MSM_INSTALL) = "yes" ?>
|
---|
531 | <Merge Id="msm_VBoxNetworkFlt" Language="0" SourceFile="$(var.Property_VBoxMergeNetworkFlt)" DiskId="1">
|
---|
532 | <ConfigurationData Name="passedNetworkType" Value="[NETWORKTYPE]" />
|
---|
533 | </Merge>
|
---|
534 | <?else?>
|
---|
535 | <Directory Id="msm_VBoxNetworkFltFolder" FileSource=".">
|
---|
536 | <?include VBoxMergeNetFlt.wxi ?>
|
---|
537 | </Directory>
|
---|
538 | <?endif?>
|
---|
539 | </Directory>
|
---|
540 | <?endif?>
|
---|
541 | <?if $(env.VBOX_WITH_NETADP) = "yes" ?>
|
---|
542 | <Directory Id="dir_NetAdp" Name="netadp">
|
---|
543 | <?if $(env.VBOX_WITH_MSM_INSTALL) = "yes" ?>
|
---|
544 | <Merge Id="msm_VBoxNetworkAdp" Language="!(loc.LANG)" SourceFile="$(var.Property_VBoxMergeNetworkAdp)" DiskId="1">
|
---|
545 | <ConfigurationData Name="passedNetworkType" Value="[NETWORKTYPE]" />
|
---|
546 | </Merge>
|
---|
547 | <?else?>
|
---|
548 | <Directory Id="msm_VBoxNetworkAdpFolder" FileSource=".">
|
---|
549 | <?include VBoxMergeNetAdp.wxi ?>
|
---|
550 | </Directory>
|
---|
551 | <?endif?>
|
---|
552 | </Directory>
|
---|
553 | <?endif?>
|
---|
554 |
|
---|
555 | <?if $(env.VBOX_WITH_NETFLT) = "yes" ?>
|
---|
556 | <Directory Id="dir_NetLwf" Name="netlwf">
|
---|
557 | <?if $(env.VBOX_WITH_MSM_INSTALL) = "yes" ?>
|
---|
558 | <Merge Id="msm_VBoxNetworkLwf" Language="!(loc.LANG)" SourceFile="$(var.Property_VBoxMergeNetworkLwf)" DiskId="1">
|
---|
559 | <ConfigurationData Name="passedNetworkType" Value="[NETWORKTYPE]" />
|
---|
560 | </Merge>
|
---|
561 | <?else?>
|
---|
562 | <Directory Id="msm_VBoxNetworkLwfFolder" FileSource=".">
|
---|
563 | <?include VBoxMergeNetLwf.wxi ?>
|
---|
564 | </Directory>
|
---|
565 | <?endif?>
|
---|
566 | </Directory>
|
---|
567 | <?endif?>
|
---|
568 |
|
---|
569 | <?if $(env.VBOX_WITH_NETADP) = "yes" ?>
|
---|
570 | <Directory Id="dir_NetAdp6" Name="netadp6">
|
---|
571 | <?if $(env.VBOX_WITH_MSM_INSTALL) = "yes" ?>
|
---|
572 | <Merge Id="msm_VBoxNetworkAdp6" Language="!(loc.LANG)" SourceFile="$(var.Property_VBoxMergeNetworkAdp6)" DiskId="1">
|
---|
573 | <ConfigurationData Name="passedNetworkType" Value="[NETWORKTYPE]" />
|
---|
574 | </Merge>
|
---|
575 | <?else?>
|
---|
576 | <Directory Id="msm_VBoxNetworkAdp6Folder" FileSource=".">
|
---|
577 | <?include VBoxMergeNetAdp6.wxi ?>
|
---|
578 | </Directory>
|
---|
579 | <?endif?>
|
---|
580 | </Directory>
|
---|
581 | <?endif?>
|
---|
582 | </Directory>
|
---|
583 | </Directory>
|
---|
584 | <Directory Id="dir_SDK" Name="sdk">
|
---|
585 | <?if $(env.VBOX_WITH_PYTHON) = "yes" ?>
|
---|
586 | <Directory Id="dir_SDKInstaller" Name="installer"> <!-- Note: For < VBox 7.1 this folder was called 'install'. -->
|
---|
587 | <Directory Id="dir_SDKInstallerPython" Name="python">
|
---|
588 | <?if $(env.VBOX_WITH_MSM_INSTALL) = "yes" ?>
|
---|
589 | <Merge Id="msm_VBoxPython" Language="!(loc.LANG)" SourceFile="$(var.Property_VBoxMergePython)" DiskId="1" />
|
---|
590 | <?else?>
|
---|
591 | <Directory Id="msm_VBoxPythonFolder" FileSource=".">
|
---|
592 | <?include VBoxMergePython.wxi ?>
|
---|
593 | </Directory>
|
---|
594 | <?endif?>
|
---|
595 | </Directory>
|
---|
596 | </Directory>
|
---|
597 | <?endif?>
|
---|
598 | <!-- Component for removing empty folder after cleaning traces -->
|
---|
599 | <Component Id="cp_SDK" Guid="ACA59290-B2D6-4E96-B164-C45F70A90219">
|
---|
600 | <RemoveFolder Id="dir_SDK" On="uninstall" />
|
---|
601 | </Component>
|
---|
602 | </Directory>
|
---|
603 |
|
---|
604 | <?if $(env.VBOX_WITH_QTGUI) = "yes" ?>
|
---|
605 | <!-- Start menu entries. -->
|
---|
606 | <Component Id="cp_StartMenuVBox" Guid="C2DC321A-CE63-40EE-8A98-724DF8BD12FB" Condition="VBOX_INSTALLSTARTMENUENTRIES" Bitness="$(var.Property_Bitness)">
|
---|
607 |
|
---|
608 | <Shortcut Id="sc_StartMenuVBox" Directory="dir_StartMenuVBox" Name="$(env.VBOX_PRODUCT)" Description="$(env.VBOX_PRODUCT)" Target="[INSTALLDIR]VirtualBox.exe" WorkingDirectory="INSTALLDIR" />
|
---|
609 | <RegistryValue Root="HKCU" Key="$(var.Property_RegKeyInstall)" Type="string" Value="installed" KeyPath="yes" />
|
---|
610 | <?include $(env.PATH_TARGET)\Shortcuts_StartMenu.wxi ?>
|
---|
611 | </Component>
|
---|
612 |
|
---|
613 | <!-- Desktop shortcut. -->
|
---|
614 | <Component Id="cp_DesktopShortcut" Guid="668F8A1A-F5CE-48B3-BB1A-3042EE27B279" Condition="VBOX_INSTALLDESKTOPSHORTCUT" Bitness="$(var.Property_Bitness)">
|
---|
615 |
|
---|
616 | <Shortcut Id="sc_DesktopVBox" Directory="DesktopFolder" Name="$(env.VBOX_PRODUCT)" Description="$(env.VBOX_PRODUCT)" Target="[INSTALLDIR]VirtualBox.exe" WorkingDirectory="INSTALLDIR" />
|
---|
617 | <RegistryValue Root="HKCU" Key="$(var.Property_RegKeyInstall)" Type="string" Value="installed" KeyPath="yes" />
|
---|
618 | </Component>
|
---|
619 |
|
---|
620 | <!-- QuickLaunch shortcut. -->
|
---|
621 | <Component Id="cp_QuickLaunchVBox" Guid="CC19E026-938A-41CB-8E77-3F33296244B6" Condition="VBOX_INSTALLQUICKLAUNCHSHORTCUT" Bitness="$(var.Property_Bitness)">
|
---|
622 | <CreateFolder />
|
---|
623 |
|
---|
624 | <Shortcut Id="sc_QuickLaunchVBox" Directory="dir_QuicklaunchFolder" Name="$(env.VBOX_PRODUCT)" Description="$(env.VBOX_PRODUCT)" Target="[INSTALLDIR]VirtualBox.exe" WorkingDirectory="INSTALLDIR" />
|
---|
625 | <RegistryValue Root="HKCU" Key="$(var.Property_RegKeyInstall)" Type="string" Value="installed" KeyPath="yes" />
|
---|
626 | </Component>
|
---|
627 | <?endif?>
|
---|
628 | </Directory>
|
---|
629 | </Directory>
|
---|
630 | </Directory>
|
---|
631 | </Package>
|
---|
632 | </Wix>
|
---|