In my .wxs file for components, there are only components with single file, and this is the case for generatable GUIDs. But it seems to me that for .msm (merge module), component's GUID should be explicitly specified. Or I'm free to use Guid="*" and that would be OK?
I tried this:<Component Guid="*">
<File Id="$(var.Logger.TargetFileName)" Source="$(var.Logger.TargetPath)" KeyPath="yes" />
</Component>
And got an error from light, that
path for key file of the component is not rooted in one of the standard directories (like ProgramFilesFolder)
...
I'm confused, because this path is rooted in ProgramFiles:<Directory Id="TARGETDIR" Name="SourceDir">
<Directory Id="$(var.PlatformProgramFilesFolder)">
<Directory Id="ProductVendor" Name="$(var.BaseProductVendorDirectory)">
<Directory Id="BaseProductDirectory" Name="$(var.BaseProductName)">
<Directory Id="ConfiguratorDir" Name="Configurator" />
</Directory>
</Directory>
</Directory>
</Directory>
You should be able to use automatically generated GUIDs in merge modules with rooted directories. But changes introduced in WIX 3.6 probably makes this impossible until bug http://wixtoolset.org/issues/3810/ is fixed.
See also http://wixtoolset.org/issues/2353/.
And also http://sourceforge.net/p/wix/mailman/message/29956690/ (click the View entire thread link to see the full discussion).