Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save mcarbonneaux/78d7ebc723caf42d4ad12fcca50682a8 to your computer and use it in GitHub Desktop.
Save mcarbonneaux/78d7ebc723caf42d4ad12fcca50682a8 to your computer and use it in GitHub Desktop.
Visual C++ 2015-2022 Redistributable - 14.34.31931
<?xml version="1.0" encoding="utf-8"?>
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi"
xmlns:bal="http://schemas.microsoft.com/wix/BalExtension"
xmlns:util="http://schemas.microsoft.com/wix/UtilExtension">
<Bundle
Name="Example Product"
Version="1.2.3.4"
Manufacturer="John Doe"
Copyright="© 2022 John Doe"
AboutUrl="https://example.net/"
UpgradeCode="01234567-89AB-CDEF-0123-456789ABCDEF"
Condition="VersionNT >= v6.1">
<BootstrapperApplicationRef
Id="WixStandardBootstrapperApplication.HyperlinkLargeLicense">
<bal:WixStandardBootstrapperApplication
LicenseUrl="https://example.net/license.html"
ShowVersion="yes"
SuppressOptionsUI="yes" />
</BootstrapperApplicationRef>
<!-- v6.1 Service Pack 1 -->
<bal:Condition Message="This application requires Service Pack 1 for Windows 7 / Server 2008 R2.">
<![CDATA[NOT ((VersionNT = v6.1) AND (ServicePackLevel < 1))]]>
</bal:Condition>
<!-- v6.3 KB2919355 -->
<util:FileSearch
Id="HAL.DLL"
Path="[WindowsFolder]System32\hal.dll"
Result="version"
Variable="NT603HALVER"
Condition="VersionNT = v6.3" />
<bal:Condition Message="This application requires S14 Update (KB2919355) for Windows 8.1 / Server 2012 R2.">
<![CDATA[NOT ((VersionNT = v6.3) AND (NT603HALVER < v6.3.9600.17031))]]>
</bal:Condition>
<!-- processor architecture -->
<util:RegistrySearch
Id="REG_ARCH"
Root="HKLM"
Key="SYSTEM\CurrentControlSet\Control\Session Manager\Environment"
Value="PROCESSOR_ARCHITECTURE"
Result="value"
Variable="ARCH_NAME" />
<!-- Visual C++ 2015-2022 Redistributable (x86) runtime minimum msi package version -->
<util:ProductSearch
Id="VCRUNTIME_X86"
Result="version"
Variable="VCRUNTIME_X86_VER"
UpgradeCode="65E5BD06-6392-3027-8C26-853107D3CF1A"
Condition="VersionNT" />
<!-- Visual C++ 2015-2022 Redistributable (x64) runtime minimum msi package version -->
<util:ProductSearch
Id="VCRUNTIME_X64"
Result="version"
Variable="VCRUNTIME_X64_VER"
UpgradeCode="36F68A90-239C-34DF-B58C-64B30153CE35"
Condition="VersionNT64 AND (ARCH_NAME = &quot;AMD64&quot;)"
After="REG_ARCH" />
<!-- Visual C++ 2015-2022 Redistributable (Arm64) runtime msi package version -->
<util:ProductSearch
Id="VCRUNTIME_ARM64"
Result="version"
Variable="VCRUNTIME_ARM64_VER"
UpgradeCode="DC9BAE42-810B-423A-9E25-E4073F1C7B00"
Condition="(ARCH_NAME = &quot;ARM64&quot;)"
After="REG_ARCH" />
<!-- Visual C++ 2015-2022 Redistributable runtime msi package version -->
<Variable Name="VCRUNTIME_VER" Type="version" Value="14.34.31931.0" />
<Chain>
<!-- use heat command to get RemotePayload attributes -->
<!-- example: heat payload vc_redist.x86.exe -o x86.wxs -->
<!-- Visual C++ 2015-2022 Redistributable (x86) - 14.34.31931 -->
<ExePackage
Id="VC_REDIST_X86"
Name="vc_redist.x86.exe"
DisplayName="Microsoft Visual C++ 2015-2022 Redistributable (x86) - 14.34.31931"
Cache="no"
Compressed="no"
PerMachine="yes"
Permanent="yes"
Protocol="burn"
InstallCondition="VersionNT"
DetectCondition="(VCRUNTIME_X86_VER &gt;= VCRUNTIME_VER) AND VersionNT"
DownloadUrl="https://download.visualstudio.microsoft.com/download/pr/6a4c74cd-8ee0-4757-9620-a11a5b48b1a7/CE4843A946EE3732EB2BFC098DB5741DC5495C7BEA204E11D379336DCC68E875/VC_redist.x86.exe"
InstallCommand="/install /quiet /norestart"
RepairCommand="/repair /quiet /norestart"
UninstallCommand="/uninstall /quiet /norestart" >
<RemotePayload
ProductName="Microsoft Visual C++ 2015-2022 Redistributable (x86) - 14.34.31931"
Description="Microsoft Visual C++ 2015-2022 Redistributable (x86) - 14.34.31931"
Version="14.34.31931.0"
CertificatePublicKey="3817D8244394FF98A606975C9B28760FBA3D9250"
CertificateThumbprint="6D216F47522FBABB5F0E1846DB42AE800A885B6A"
Hash="17AD0FFA87EBB1EF27210061577A9AD9D5592430"
Size="13833056" />
</ExePackage>
<!-- Visual C++ 2015-2022 Redistributable (x64) - 14.34.31931 -->
<ExePackage
Id="VC_REDIST_X64"
Name="vc_redist.x64.exe"
DisplayName="Microsoft Visual C++ 2015-2022 Redistributable (x64) - 14.34.31931"
Cache="no"
Compressed="no"
PerMachine="yes"
Permanent="yes"
Protocol="burn"
InstallCondition="VersionNT64 AND (ARCH_NAME = &quot;AMD64&quot;)"
DetectCondition="(VCRUNTIME_X64_VER &gt;= VCRUNTIME_VER) AND VersionNT64 AND (ARCH_NAME = &quot;AMD64&quot;)"
DownloadUrl="https://download.visualstudio.microsoft.com/download/pr/bcb0cef1-f8cb-4311-8a5c-650a5b694eab/2257B3FBE3C7559DE8B31170155A433FAF5B83829E67C589D5674FF086B868B9/VC_redist.x64.exe"
InstallCommand="/install /quiet /norestart"
RepairCommand="/repair /quiet /norestart"
UninstallCommand="/uninstall /quiet /norestart" >
<RemotePayload
ProductName="Microsoft Visual C++ 2015-2022 Redistributable (x64) - 14.34.31931"
Description="Microsoft Visual C++ 2015-2022 Redistributable (x64) - 14.34.31931"
Version="14.34.31931.0"
CertificatePublicKey="3817D8244394FF98A606975C9B28760FBA3D9250"
CertificateThumbprint="6D216F47522FBABB5F0E1846DB42AE800A885B6A"
Hash="A176F140E942920B777F80DE89E16EA57EE32BE8"
Size="25466016" />
</ExePackage>
<!-- Visual C++ 2015-2022 Redistributable (Arm64) - 14.34.31931 -->
<ExePackage
Id="VC_REDIST_ARM64"
Name="vc_redist.arm64.exe"
DisplayName="Microsoft Visual C++ 2015-2022 Redistributable (Arm64) - 14.34.31931"
Cache="no"
Compressed="no"
PerMachine="yes"
Permanent="yes"
Protocol="burn"
InstallCondition="(ARCH_NAME = &quot;ARM64&quot;)"
DetectCondition="(VCRUNTIME_ARM64_VER &gt;= VCRUNTIME_VER) AND (ARCH_NAME = &quot;ARM64&quot;)"
DownloadUrl="https://download.visualstudio.microsoft.com/download/pr/bcb0cef1-f8cb-4311-8a5c-650a5b694eab/85759E1CA11B0DB71C9DC9D825ACC68AF0E6D74415A4D4BA5BAB2DEDEFB65628/VC_redist.arm64.exe"
InstallCommand="/install /quiet /norestart"
RepairCommand="/repair /quiet /norestart"
UninstallCommand="/uninstall /quiet /norestart" >
<RemotePayload
ProductName="Microsoft Visual C++ 2022 Redistributable (Arm64) - 14.34.31931"
Description="Microsoft Visual C++ 2022 Redistributable (Arm64) - 14.34.31931"
Version="14.34.31931.0"
CertificatePublicKey="3817D8244394FF98A606975C9B28760FBA3D9250"
CertificateThumbprint="6D216F47522FBABB5F0E1846DB42AE800A885B6A"
Hash="0DF983C38B66F46A79FABD324D36BB45BD7B26DE"
Size="11653512" />
</ExePackage>
</Chain>
</Bundle>
</Wix>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment