2 <Wix xmlns='http://schemas.microsoft.com/wix/2003/01/wi'>
4 <!-- See config.wxi for the symbols that it defines/asserts -->
7 <!-- See language_config for localization options. -->
8 <?include language_config.wxi?>
11 We autogenerate a new product code for each build. According to MSDN we have
12 to change the product code whenever we change the name of the MSI file. Each
13 version of OpenAFS has a different MSI name. Thus, each version needs a
17 Id="????????-????-????-????-????????????"
18 Codepage="$(var.Codepage)"
19 Language="$(var.LanguageCode)"
20 Manufacturer="$(var.Manufacturer)"
21 Name="$(var.ProductName)"
22 UpgradeCode="6823EEDD-84FC-4204-ABB3-A80D25779833"
23 Version="$(var.NumericVersion)"
27 Note that we are not specifying an explicit Package Code below. That way WiX will
28 generate a new one for each build. If an explicit one needs to be specified, use :
29 Id="$(var.PackageCode)"
32 Id="????????-????-????-????-????????????"
34 Comments="$(var.PackageComments)"
36 Description="$(var.ProductName)"
37 InstallerVersion="$(var.InstallerVersion)"
38 Keywords="Installer,OpenAFS,$(var.Manufacturer)"
39 Languages="$(var.Languages)"
40 Manufacturer="$(var.Manufacturer)"
41 Platforms="$(var.Platform)"
43 SummaryCodepage="1252"
46 <!-- Launch conditions -->
47 <Condition Message="$(loc.StrLaunchCond)">
48 <![CDATA[VersionNT >= 500]]>
50 <Condition Message="$(loc.AdminRequired)">Privileged</Condition>
51 <?if $(var.Platform) = "x64" ?>
52 <Condition Message="$(loc.StrPlatform64)">
53 <![CDATA[VersionNT64]]>
56 <Condition Message="$(loc.StrPlatformNot64)">
57 <![CDATA[NOT VersionNT64]]>
61 <!-- Global Properties -->
62 <?include property.wxi?>
64 <!-- File system and registry settings -->
65 <Directory Id="TARGETDIR" Name="SourceDir">
66 <?include platform.wxi?>
67 <?include registry.wxi?>
72 <?include feature.wxi?>
74 <!-- User interface -->
75 <?include lang\$(var.Language)\ui.wxi?>
77 <!-- Custom actions -->
78 <?ifndef UseDllLoopbackInstaller?>
81 src="$(var.MediaBinDir)instloop.exe"/>
85 src="$(var.MediaBinDir)afsloopback.dll"/>
89 src="$(var.MediaDllDir)afscustom.dll"/>
90 <?ifdef UseDllLoopbackInstaller?>
93 BinaryKey="BIN_afsLoopback"
94 DllEntry="installLoopbackMSI"
98 <?ifdef RemoveLoopback?>
101 BinaryKey="BIN_afsLoopback"
102 DllEntry="uninstallLoopbackMSI"
107 Id="RollbackLoopback"
108 BinaryKey="BIN_afsLoopback"
109 DllEntry="uninstallLoopbackMSI"
117 BinaryKey="BIN_instloop"
122 <?ifdef RemoveLoopback?>
124 Id="RollbackLoopback"
125 BinaryKey="BIN_instloop"
132 BinaryKey="BIN_instloop"
140 Id="InstallNetProvider"
141 BinaryKey="BIN_afsCustom"
142 DllEntry="InstallNetProvider"
147 Id="RemoveNetProvider"
148 BinaryKey="BIN_afsCustom"
149 DllEntry="UninstallNetProvider"
155 Id="RollbackNetProvider"
156 BinaryKey="BIN_afsCustom"
157 DllEntry="UninstallNetProvider"
159 Execute="rollback" />
162 BinaryKey="BIN_afsCustom"
163 DllEntry="ConfigureClientService"
165 Execute="deferred" />
168 BinaryKey="BIN_afsCustom"
169 DllEntry="ConfigureServerService"
171 Execute="deferred" />
173 Id="RemoveNsisInstallation"
174 BinaryKey="BIN_afsCustom"
175 DllEntry="UninstallNsisInstallation"
176 Execute="immediate" />
178 Id="CreateAFSAdminGroup"
179 BinaryKey="BIN_afsCustom"
180 DllEntry="CreateAFSClientAdminGroup"
182 Execute="deferred" />
184 Id="RemoveAFSAdminGroup"
185 BinaryKey="BIN_afsCustom"
186 DllEntry="RemoveAFSClientAdminGroup"
188 Execute="deferred" />
190 Id="RollbackAFSAdminGroup"
191 BinaryKey="BIN_afsCustom"
192 DllEntry="RemoveAFSClientAdminGroup"
194 Execute="rollback" />
196 Id="AbortInstallationA"
197 BinaryKey="BIN_afsCustom"
198 DllEntry="AbortMsiImmediate"
199 Execute="immediate" />
201 Id="AbortInstallationB"
202 BinaryKey="BIN_afsCustom"
203 DllEntry="AbortMsiImmediate"
204 Execute="immediate" />
206 <!-- Installation Sequences -->
207 <AdvertiseExecuteSequence />
208 <AdminExecuteSequence />
209 <InstallExecuteSequence>
210 <RemoveExistingProducts After="InstallValidate">IBMAFS_UPGRADE OR OPENAFS_UPGRADE</RemoveExistingProducts>
211 <Custom Action="RemoveNsisInstallation" Before="AbortInstallationA">NSISUNINSTALL <> "" AND UILevel >= 4</Custom>
212 <Custom Action="AbortInstallationA" Before="CostInitialize">NSISUNINSTALL <> "" AND UILevel < 4</Custom>
213 <!-- Assert that if the server is going to be installed locally after this session, control center and client are also local -->
214 <Custom Action="AbortInstallationB" After="MigrateFeatureStates">
215 <![CDATA[((&feaServer=3 OR (!feaServer=3 AND &feaServer<1)) AND (&feaClient=2 OR (&feaClient<>3 AND !feaClient<>3) OR &feaControlCenter=2 OR (&feaControlCenter<>3 AND !feaControlCenter<>3) ))]]>
217 <?ifdef RemoveLoopback?>
218 <Custom Action="RemoveLoopback" After="SelfRegModules">&feaLoopback=2 OR &feaLoopback=3</Custom>
219 <Custom Action="RollbackLoopback" After="RemoveLoopback">&feaLoopback=3</Custom>
220 <Custom Action="InstallLoopback" After="RollbackLoopback">&feaLoopback=3</Custom>
222 <Custom Action="InstallLoopback" After="SelfRegModules">&feaLoopback=3</Custom>
224 <Custom Action="RollbackNetProvider" After="WriteRegistryValues">&feaClient=3</Custom>
225 <Custom Action="InstallNetProvider" After="RollbackNetProvider">&feaClient=3</Custom>
226 <Custom Action="RemoveNetProvider" After="InstallNetProvider">&feaClient=2</Custom>
227 <Custom Action="ConfigureClient" After="InstallServices">&feaClient=3</Custom>
228 <Custom Action="ConfigureServer" After="ConfigureClient">&feaServer=3</Custom>
229 <!-- <Custom Action="RemoveAFSAdminGroup" Before="">&feaClient=2</Custom> -->
230 <Custom Action="RollbackAFSAdminGroup" Before="CreateAFSAdminGroup">&feaClient=3</Custom>
231 <Custom Action="CreateAFSAdminGroup" Before="CreateFolders">&feaClient=3</Custom>
232 <ScheduleReboot After="PublishProduct">&feaClient=3 OR &feaServer=3 OR &feaClient=2 OR &feaServer=2</ScheduleReboot>
233 </InstallExecuteSequence>
235 <!-- Related producs -->
236 <!-- MIT's OpenAFS MSI installer -->
237 <Upgrade Id="6823EEDD-84FC-4204-ABB3-A80D25779833">
238 <UpgradeVersion IgnoreRemoveFailure="no" IncludeMaximum="no" Maximum="$(var.NumericVersion)" MigrateFeatures="yes" Property="OPENAFS_UPGRADE" />
241 <!-- MIT's Transarc AFS MSI Installer -->
242 <Upgrade Id="5332B94F-DE38-4927-9EAB-51F4A64193A7">
243 <UpgradeVersion IgnoreRemoveFailure="no" IncludeMaximum="yes" Maximum="3.6.2" MigrateFeatures="no" Property="IBMAFS_UPGRADE" />
246 <!-- openafs.org NSIS installer is detected using other means -->
247 <!-- Please let us know if you want other Installers to be detected and upgraded/removed -->
250 <Media Id="1" Cabinet="disk1.cab" CompressionLevel="high" EmbedCab="yes" />