I have been trying to determine a best case solution for registering a COM server using WiX to create a Windows Installer package and am struggling.
In this post Deployment Engineering Archive: HOWTO: Use Regsvr32.exe with WIX, there is an open request for the ‘Setup police’ to crack down on using regsvr32 through an exe custom action. I know the evils of using regsvr32 as it registers to the system rather than the user, but I also recall that OleSelfRegister can have issues from a microsoft support bulletin (sorry, can’t find the link) – and I believe they recommended using regsvr32.
Any advice?
Read ‘Do not use the SelfReg and TypeLib tables’ at:
https://msdn.microsoft.com/en-us/library/bb204770#no_selfreg
For WiX, take a look at the Component element in the schema reference at:
http://wixtoolset.org/documentation/manual/v3/xsd/wix/component.html
Take notice of certain child elements such as AppId, Class, ProgId, Registry and so on. The proper technique is to use
COM extractionto reflect the registration information and emit it declaratively into your installer so MSI can take care of it for you without going out of process to some code (likeDllRegisterServer()) that could fail and also not provides MSI insight into the footprint of the component from a repair and advertisement perspective.