We have merge modules that will install PDB files when a certain conditional variable is true however we need this condition to be set.
Can I set this condition in the WiX installer and pass it to the merge module somehow?
We have merge modules that will install PDB files when a certain conditional variable is true however we need this condition to be set.
Can I set this condition in the WiX installer and pass it to the merge module somehow?
You can set installer properties in merge modules by using this format:
<property_name>.<module_GUID>
For example:
CONDITION_PROPERTY.32D73316_E513_43C3_99F5_381A4B5F0A78
In your installer you can try using a custom action to set the property used in the merge module condition.
The custom action element can look like this:
<CustomAction Id="SetMsmProperty" Return="check" Property="CONDITION_PROPERTY.32D73316_E513_43C3_99F5_381A4B5F0A78" Value="myValue" />
You can schedule the action after InstallExecuteSequence -> AppSearch, so you can add this InstallExecuteSequence element:
<InstallExecuteSequence>
<Custom Action="SetMsmProperty" After="AppSearch">NOT Installed</Custom>
</InstallExecuteSequence>
You can read more about wix custom actions here:
I just typically create a subfeature to create a variation point in the installer. You can then put a feature condition on it to control whether the components brought in by the merge modules get installed or not. This is a lot simpler then putting a condition on each component and gives you more flexibility of whether you want to show the "debug symbols" feature to the end user or not.