Files
pilotclient/installer/installbuilder/vcredist.xml
Roland Winklmeier e8235a0f53 Don't abort installation if vcredist returns non zero return code
In case, vcredist returns a non zero return code, don't automatically
abort the installation, but tell the user the error code, the consequences
and continue.

ref T344
2018-09-17 18:28:21 +02:00

88 lines
4.0 KiB
XML

<component>
<name>vcruntime</name>
<description>Visual Studio 2017 Redistributables</description>
<canBeEdited>0</canBeEdited>
<selected>1</selected>
<show>1</show>
<folderList>
<folder>
<description>vcredist</description>
<destination>${installdir}/vcredist</destination>
<name>vcredist</name>
<platforms>windows</platforms>
<actionList>
<registryGet>
<key>HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\VisualStudio\14.0\VC\Runtimes\x86</key>
<name>Version</name>
<variable>vcruntimeversionx86</variable>
</registryGet>
<registryGet>
<key>HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\VisualStudio\14.0\VC\Runtimes\x64</key>
<name>Version</name>
<variable>vcruntimeversionx64</variable>
</registryGet>
<runProgram>
<abortOnError>0</abortOnError>
<program>${installdir}/vcredist/vcredist_x86.exe</program>
<programArguments>/install /quiet /norestart</programArguments>
<progressText>Installing VC++ 2017 32 Bit Runtime</progressText>
<showMessageOnError>0</showMessageOnError>
<ruleList>
<fileExists>
<path>${installdir}/vcredist/vcredist_x86.exe</path>
</fileExists>
<compareVersions>
<logic>greater</logic>
<version1>v14.15.26706.0</version1>
<version2>${vcruntimeversionx86}</version2>
</compareVersions>
</ruleList>
</runProgram>
<runProgram>
<abortOnError>0</abortOnError>
<program>${installdir}/vcredist/vcredist_x64.exe</program>
<programArguments>/install /quiet /norestart</programArguments>
<progressText>Installing VC++ 2017 64 Bit Runtime</progressText>
<showMessageOnError>0</showMessageOnError>
<ruleList>
<fileExists>
<path>${installdir}/vcredist/vcredist_x64.exe</path>
</fileExists>
<compareVersions>
<logic>greater</logic>
<version1>v14.15.26706.0</version1>
<version2>${vcruntimeversionx64}</version2>
</compareVersions>
</ruleList>
</runProgram>
<showWarning>
<text>Installation of MS Visual Studio 2017 Redistributables failed!
Error Code: ${program_exit_code}
Check if another version was already installed and if not, try to run the installer manually from
${installdir}\vcredist\
The installation will now continue, but swift might not work properly. If this is the case, raise a bugreport on https://dev.swift-project.org with the error code, you received.</text>
<ruleList>
<compareValues>
<logic>does_not_equal</logic>
<value1>${program_exit_code}</value1>
<value2>0</value2>
</compareValues>
</ruleList>
</showWarning>
</actionList>
<distributionFileList>
<distributionFile>
<allowWildcards>1</allowWildcards>
<origin>../../dist/vcredist/vcredist_*.exe</origin>
</distributionFile>
</distributionFileList>
</folder>
</folderList>
<shouldPackRuleList>
<platformTest>
<type>windows</type>
</platformTest>
</shouldPackRuleList>
</component>