In my WiX project I need to install different content for the same file name, based on the OS.
- If the OS is Windows 7 then the file needs to have content X.
- If the OS is Windows Vista the file needs to have content Y.
I have thought through a few approaches:
Define two components, one with the content for windows 7 and another with the contents for Vista. Run a custom action based on the OS that overwrites the content for Vista if the OS is Windows 7.
Define two additional features (window7 config and win vista config) have the components target the same file and install the feature conditionally based on OS.
Which is the best approach to take. Any tips, tricks and sample wix to get this going?