Search code examples
windows-installermerge-module

Updating prerequisites from MSI


I'm having an MSI installing MS VC runtime using merge modules. Microsoft has published an update for the MS VC runtime and also for the merge modules.

Just replacing the new MSMs in the MSI doesn't seem to update the runtime on the client system.

Does the MSI have to be a minor or even major update? Or is there something different to tweak to enforce installing the new VC runtime on the client system?


Solution

  • Apparently, MSMs don't have a version themselves, although the components contained in them do.

    The consequence is, that for an MSI, packaged as a minor upgrade, Windows Installer will only check whether the prerequisite is installed. It won't update it.

    If, however, the MSI is packaged as a major upgrade, Windows Installer will deinstall the MSI contents (decrementing the refCount of the MSM's components and remove them if needed), and on installing it will attempt to install the MSM, thereby installing the MSM's components, or incrementing their refCount.

    The result is that old versions of the MSM's components may still be there (if also used by other applications), and the new versions will be there as well.