Issue #24585: Enables build-to-build upgrades that preserve settings.
Rather than using Burn "Persisted" variables we now add registry keys for each added feature. These can be detected by the installer regardless of which version installed them, and we use this for Modify and Upgrade. In particular, Upgrades can't access the Persisted variables, but can find well-known registry keys.
There are also some changes to the bootstrap app to properly handle upgrades.
Finally, a few minor improvements to the Windows build to keep things tidier.
diff --git a/Tools/msi/doc/doc.wxs b/Tools/msi/doc/doc.wxs
index 22b0213..bbe30a1 100644
--- a/Tools/msi/doc/doc.wxs
+++ b/Tools/msi/doc/doc.wxs
@@ -9,13 +9,16 @@
<Feature Id="DefaultFeature" AllowAdvertise="no" Title="!(loc.Title)" Description="!(loc.Description)">
<ComponentGroupRef Id="doc" Primary="yes" />
+ <ComponentRef Id="OptionalFeature" />
</Feature>
<Feature Id="Shortcuts" AllowAdvertise="no" Title="!(loc.Title)" Description="!(loc.Description)">
<ComponentGroupRef Id="doc" />
<?ifdef DocFilename ?>
<Component Id="doc_shortcut" Directory="MenuDir" Guid="*">
- <RegistryValue Root="HKMU" Key="[REGISTRYKEY]\DocShortcuts" Type="integer" Value="1" KeyPath="yes" />
+ <RegistryKey Root="HKMU" Key="[OPTIONALFEATURESREGISTRYKEY]">
+ <RegistryValue Name="$(var.OptionalFeatureName)_shortcut" Type="string" Value="$(var.Version)" KeyPath="yes" />
+ </RegistryKey>
<Shortcut Id="python.chm"
Target="[#python.chm]"
Name="!(loc.ShortcutName)"