I'm developing a .net-Component (.dll) that needs to act as as server for two clients: one of them is c++-native and one is .net.
To get the native-client use the server, the server has a COM-Interface and is registered via regasm
:
[
Guid("B9BE47C8-2838-4449-B2C4-22B07F52EEA6"),
InterfaceType(ComInterfaceType.InterfaceIsDual),
ContractClass(typeof(IComMethodsLicenseServerContracts)),
ComVisible(true)
]
public interface ILicenseServer{...}
The native-client imports it via #import "server.tlb" named_guids
into the client
I thought the .net-client can use the com-interface as well but right know I learnd that tlbim
does not work with .net-dlls so the client has to use it like a regular .net-reference.
On the target machine both Clients can be installed together or seperately. To avoid version-conflicts I need to have the server-component only once at the target machine. I thought I have to let the setup put the server-component somewhere in %program files%\common-files at the target machine and register it but that doesn't seem to work for the .net-client (since it does not use COM so it wont find the server).
Whats the thing to do here? Is it the right solution to but the server (and all it's dependencies) into the GAC of the target machine? If so, how to regasm it as a COM-Component for the native-client? Do I have to know the exact path of the GAC?
Seems like I'm a bit stucked ;-(