| OLD | NEW |
| (Empty) |
| 1 <?xml version='1.0' encoding='windows-1252'?> | |
| 2 <Wix xmlns='http://schemas.microsoft.com/wix/2006/wi'> | |
| 3 <?define CompanyFullName = 'Google, Inc.'?> | |
| 4 <?define Copyright = 'Copyright 2007-2010 Google Inc.'?> | |
| 5 <?define UpdateKeyPath = 'SOFTWARE\Google\Update' ?> | |
| 6 <?define InstallCommandBase='/silent /install "[ProductTag]" /installsource en
terprisemsi'?> | |
| 7 | |
| 8 <Product | |
| 9 Id='$(var.MsiProductId)' | |
| 10 Name='$(var.ProductName)' | |
| 11 Language='1033' | |
| 12 Codepage='1252' | |
| 13 UpgradeCode='$(var.MsiUpgradeCode)' | |
| 14 Version='$(var.ProductVersion)' | |
| 15 Manufacturer='$(var.CompanyFullName)'> | |
| 16 | |
| 17 <Package | |
| 18 Id='*' | |
| 19 Description='$(var.ProductName) Installer' | |
| 20 Comments='$(var.Copyright)' | |
| 21 Manufacturer='$(var.CompanyFullName)' | |
| 22 Languages='1033' | |
| 23 SummaryCodepage='1252' | |
| 24 InstallerVersion='150' | |
| 25 InstallPrivileges='elevated' | |
| 26 Compressed='yes' /> | |
| 27 | |
| 28 <Upgrade Id='$(var.MsiUpgradeCode)'> | |
| 29 <UpgradeVersion Property='UPGRADING' | |
| 30 OnlyDetect='no' | |
| 31 Minimum='0.0.0.0' IncludeMinimum='yes' | |
| 32 Maximum='$(var.ProductVersion)' IncludeMaximum='no' /> | |
| 33 <UpgradeVersion Property='NEWERVERSIONDETECTED' | |
| 34 OnlyDetect='yes' | |
| 35 Minimum='$(var.ProductVersion)' IncludeMinimum='yes' /> | |
| 36 </Upgrade> | |
| 37 | |
| 38 <!-- Per-machine installation - make sure product appears for all users. --> | |
| 39 <Property Id='ALLUSERS' Value='1' /> | |
| 40 | |
| 41 <?ifdef ProductIcon ?> | |
| 42 <!-- If var.ProductIcon is defined, use that as an icon in the ARP | |
| 43 dialog, otherwise rely on the ARP dialog's heuristics: | |
| 44 http://blogs.msdn.com/oldnewthing/archive/2004/07/09/178342.aspx --> | |
| 45 <Icon Id='icon.ico' SourceFile='$(var.ProductIcon)'/> | |
| 46 <Property Id='ARPPRODUCTICON' Value='icon.ico' /> | |
| 47 <?endif?> | |
| 48 | |
| 49 <!-- ARPNOMODIFY does two things: | |
| 50 1) Removes the 'Modify' button from the ARP dialog. | |
| 51 2) Causes the 'Remove' command to invoke msiexec /X instead of /I | |
| 52 (the intent being that WITH a Modify button, clicking either | |
| 53 Modify or Remove command will launch your installer UI). --> | |
| 54 <Property Id='ARPNOMODIFY' Value='1' /> | |
| 55 | |
| 56 <!-- Find the uninstall string to be used for the product. Only used for | |
| 57 uninstallation. --> | |
| 58 <Property Id='UNINSTALLCMDLINE'> | |
| 59 <RegistrySearch Id='UninstallCmdSearch' | |
| 60 Root='HKLM' | |
| 61 Type='raw' | |
| 62 Key='Software\Google\Update\ClientState\$(var.ProductGuid)
' | |
| 63 Name='UninstallString'/> | |
| 64 </Property> | |
| 65 <Property Id='UNINSTALLCMDARGS'> | |
| 66 <RegistrySearch Id='UninstallArgSearch' | |
| 67 Root='HKLM' | |
| 68 Type='raw' | |
| 69 Key='Software\Google\Update\ClientState\$(var.ProductGuid)
' | |
| 70 Name='UninstallArguments'/> | |
| 71 </Property> | |
| 72 | |
| 73 <UI> | |
| 74 <Error Id='4000'>A newer version of the $(var.ProductName) enterprise inst
aller is already installed.</Error> | |
| 75 </UI> | |
| 76 | |
| 77 <!-- Eliminates "warning LGHT1076 : ICE71: The Media table has no entries." | |
| 78 --> | |
| 79 <Media Id='1' /> | |
| 80 | |
| 81 <Directory Id='TARGETDIR' Name='SourceDir'> | |
| 82 <Directory Id='ProgramFilesFolder'> | |
| 83 <Directory Id='GoogleProgramDir' Name='Google'> | |
| 84 <Directory Id='UpdateDir' Name='Update'> | |
| 85 | |
| 86 <Component Id='ProductClientState' | |
| 87 Guid='6B528A57-0CD8-4b26-85F8-1CA05523B8F1'> | |
| 88 <!-- Clear the last UI string before running the installer so we k
now | |
| 89 that any value present upon rollback is fresh. --> | |
| 90 <RemoveRegistryValue Key='$(var.UpdateKeyPath)\ClientState\$(var.P
roductGuid)' | |
| 91 Name='LastInstallerResultUIString' | |
| 92 Root='HKLM' /> | |
| 93 <RemoveRegistryValue Key='$(var.UpdateKeyPath)' | |
| 94 Name='LastInstallerResultUIString' | |
| 95 Root='HKLM' /> | |
| 96 <RegistryValue Id='NonEmptyComponent' Action='write' | |
| 97 Root='HKLM' | |
| 98 Key='$(var.UpdateKeyPath)\ClientState\$(var.Product
Guid)' | |
| 99 Name='EnterpriseInstall' Type='string' Value='$(var
.ProductVersion)' /> | |
| 100 </Component> | |
| 101 | |
| 102 </Directory> | |
| 103 </Directory> | |
| 104 </Directory> | |
| 105 </Directory> | |
| 106 | |
| 107 <Feature Id='Complete' Level='1'> | |
| 108 <ComponentRef Id='ProductClientState' /> | |
| 109 </Feature> | |
| 110 | |
| 111 <!--TODO(omaha): Add "Standalone" after fixing the ProductName issue | |
| 112 in standalone_installer.py.--> | |
| 113 <Binary Id='$(var.ProductNameLegalIdentifier)Installer' | |
| 114 SourceFile='$(var.StandaloneInstallerPath)' /> | |
| 115 | |
| 116 <Binary Id='ShowInstallerResultUIStringDll' | |
| 117 SourceFile='$(var.ShowErrorCADll)' /> | |
| 118 | |
| 119 <CustomAction Id='NewerVersionError' Error='4000'/> | |
| 120 | |
| 121 <CustomAction Id='SetProductTagProperty' | |
| 122 Property='ProductTag' | |
| 123 Value='appguid=$(var.ProductGuid)&appname=$(var.ProductName)&needs
Admin=True' | |
| 124 Execute='immediate' | |
| 125 Return='check' /> | |
| 126 <CustomAction Id='AppendCustomParamsToProductTagProperty' | |
| 127 Property='ProductTag' | |
| 128 Value='[ProductTag]$(var.ProductCustomParams)' | |
| 129 Execute='immediate' | |
| 130 Return='check' /> | |
| 131 <CustomAction Id='AppendBrandToProductTagProperty' | |
| 132 Property='ProductTag' | |
| 133 Value='[ProductTag]&brand=[BRAND]' | |
| 134 Execute='immediate' | |
| 135 Return='check' /> | |
| 136 | |
| 137 <?ifdef ProductInstallerData ?> | |
| 138 <CustomAction Id='BuildInstallCommand' | |
| 139 Property='InstallCommand' | |
| 140 Value='$(var.InstallCommandBase) /appargs "appguid=$(var.P
roductGuid)&installerdata=$(var.ProductInstallerData)"' | |
| 141 Execute='immediate' | |
| 142 Return='check' /> | |
| 143 <?else?> | |
| 144 <CustomAction Id='BuildInstallCommand' | |
| 145 Property='InstallCommand' | |
| 146 Value='$(var.InstallCommandBase)' | |
| 147 Execute='immediate' | |
| 148 Return='check' /> | |
| 149 <?endif?> | |
| 150 | |
| 151 <!-- Send the ProductGuid to the ShowInstallerResultUIString custom action. | |
| 152 The value is accessed through the "CustomActionData" property from | |
| 153 within the action itself. --> | |
| 154 <CustomAction Id='SetAppGuidProperty' | |
| 155 Property='ShowInstallerResultUIString' | |
| 156 Value='$(var.ProductGuid)' /> | |
| 157 | |
| 158 <!-- A custom action to be executed on rollback to log and display the | |
| 159 LastInstallerResultUIString. --> | |
| 160 <CustomAction Id='ShowInstallerResultUIString' | |
| 161 BinaryKey='ShowInstallerResultUIStringDll' | |
| 162 DllEntry='ShowInstallerResultUIString' | |
| 163 Execute='rollback' | |
| 164 Impersonate='no' /> | |
| 165 | |
| 166 <CustomAction Id='DoInstall' | |
| 167 BinaryKey='$(var.ProductNameLegalIdentifier)Installer' | |
| 168 Impersonate='no' | |
| 169 Execute='deferred' | |
| 170 ExeCommand='[InstallCommand]' | |
| 171 Return='check' /> | |
| 172 <CustomAction Id='CallUninstaller.SetProperty' | |
| 173 Property='UninstallCmd' | |
| 174 Value='[UNINSTALLCMDLINE]' | |
| 175 Execute='immediate' | |
| 176 Return='check' /> | |
| 177 <CustomAction Id='CallUninstallerArgs.SetProperty' | |
| 178 Property='UninstallCmdArgs' | |
| 179 Value='[UNINSTALLCMDARGS]' | |
| 180 Execute='immediate' | |
| 181 Return='check' /> | |
| 182 <CustomAction Id='CallUninstaller' | |
| 183 Property='UninstallCmd' | |
| 184 ExeCommand='[UninstallCmdArgs] $(var.ProductUninstallerAdditionalArgs)' | |
| 185 Impersonate='no' | |
| 186 Execute='deferred' | |
| 187 Return='check' /> | |
| 188 | |
| 189 <InstallExecuteSequence> | |
| 190 <RemoveExistingProducts After='InstallValidate' /> | |
| 191 | |
| 192 <Custom Action='NewerVersionError' After='FindRelatedProducts'> | |
| 193 NEWERVERSIONDETECTED | |
| 194 </Custom> | |
| 195 | |
| 196 <!-- Build tag property. --> | |
| 197 <Custom Action='SetProductTagProperty' | |
| 198 Before='AppendCustomParamsToProductTagProperty'> | |
| 199 (($ProductClientState>2) OR REINSTALL) | |
| 200 </Custom> | |
| 201 <Custom Action='AppendCustomParamsToProductTagProperty' | |
| 202 Before='AppendBrandToProductTagProperty'> | |
| 203 (($ProductClientState>2) OR REINSTALL) | |
| 204 </Custom> | |
| 205 <Custom Action='AppendBrandToProductTagProperty' | |
| 206 Before='BuildInstallCommand'> | |
| 207 (($ProductClientState>2) OR REINSTALL) AND (BRAND <> "") | |
| 208 </Custom> | |
| 209 <Custom Action='BuildInstallCommand' | |
| 210 Before='SetAppGuidProperty'> | |
| 211 (($ProductClientState>2) OR REINSTALL) | |
| 212 </Custom> | |
| 213 <Custom Action='SetAppGuidProperty' | |
| 214 Before='ShowInstallerResultUIString'> | |
| 215 (($ProductClientState>2) OR REINSTALL) | |
| 216 </Custom> | |
| 217 <Custom Action='ShowInstallerResultUIString' | |
| 218 Before='DoInstall'> | |
| 219 (($ProductClientState>2) OR REINSTALL) | |
| 220 </Custom> | |
| 221 | |
| 222 <!-- TODO(omaha): Support Rollback? I do not think so because there are | |
| 223 very few cases where the app could be installed but Omaha would | |
| 224 report a failure. If we support rollback, need to determine whether | |
| 225 Product was installed before and only add the rollback then. | |
| 226 <Custom Action='Rollback$(var.ProductNameLegalIdentifier)' | |
| 227 After='InstallFiles'> | |
| 228 (($ProductClientState>2) OR REINSTALL) AND (NOT $(var.ProductNameLegalId
entifier)_INSTALLED) | |
| 229 </Custom> | |
| 230 Change After='InstallFiles' below to | |
| 231 After='Rollback$(var.ProductNameLegalIdentifier)'. --> | |
| 232 | |
| 233 <Custom Action='DoInstall' | |
| 234 After='InstallFiles'> | |
| 235 (($ProductClientState>2) OR REINSTALL) | |
| 236 </Custom> | |
| 237 | |
| 238 <Custom Action='CallUninstallerArgs.SetProperty' | |
| 239 Before='CallUninstaller.SetProperty'> | |
| 240 $ProductClientState=2 | |
| 241 </Custom> | |
| 242 <Custom Action='CallUninstaller.SetProperty' | |
| 243 Before='CallUninstaller'> | |
| 244 $ProductClientState=2 | |
| 245 </Custom> | |
| 246 <Custom Action='CallUninstaller' | |
| 247 Before='RemoveFiles'> | |
| 248 $ProductClientState=2 | |
| 249 </Custom> | |
| 250 | |
| 251 <!-- Google Update will uninstall itself if the product is the only app it | |
| 252 so no need to have an uninstall operation. --> | |
| 253 | |
| 254 </InstallExecuteSequence> | |
| 255 | |
| 256 </Product> | |
| 257 </Wix> | |
| OLD | NEW |