Registration of dlls - proposition
Jacek Caban
jack at itma.pwr.wroc.pl
Fri Mar 18 12:42:53 CST 2005
Hi,
Currently functions Dll[Un]RegisterServer in Wine look strange to me.
It's a great code duplication. As we have ATLRegistrar implementation
right now
it can be changed. We can use ATL to register dlls. This way functions
Dll[Un]RegisterServer can be really simple and registry can be described by
elastic and simple rgs scripts. You can see example of rgs script here:
http://cvs.winehq.org/cvsweb/wine/dlls/atl/atl.rgs?rev=1.2&content-type=text/x-cvsweb-markup
and documentation of ATLRegistrar here:
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vcmfc98/html/_atl_using_replaceable_parameters_.28.the_registrar.92.s_preprocessor.29.asp
There are two more aspects of this solution:
- dependence on atl
I don't think it's a true problem as we can create ATLRegistrar by
CoCreateInstance and finally
we depend on atl _only_ while registering, so it's not a great
dependency...
- header file
We would need to make atliface.idl accessible for other dlls.
Actually it is a public ATL header file,
so there is nothing wrong in doing this. We could just move it to
include/ (or maybe
include/atl where, in future, more headers of ATL could be placed).
The benefit is: no code duplication, more elastic and clean registration
code. What do you think?
Is it a good idea?
Thanks,
Jacek
More information about the wine-devel
mailing list