"Carl" <an*******@nospam.com> wrote in message
news:OQ**************@TK2MSFTNGP12.phx.gbl...
I have a managed c++ web service that uses ATL.
Everything worked fine with VC 7.0, but when I recompile
with VC 7.1 I get the following link warning:
LINK : warning LNK4243: DLL containing objects compiled with /clr is not
linked with /NOENTRY; image may not run correctly.
Having looked in various files, I'm told to
1) Add the /NOENTRY option,
2) Add __DllMainCRTStartup@ 12 to the Force Symbol Reference
3) Remove nochkclr.obj (which isn't there to remove).
When I do this, ATL CStrings, and some functions don't work.
How do I correct this for a managed web service?
I am not sure if one the various files is the this one:
http://msdn.microsoft.com/library/de...omixedmode.asp
If not, it should explain the procedure for the various cases in some
detail. If I read it correctly, you will have to implement the usual
DllMain() procedure which is called by _DllMainCRTStartup() which, in turn,
is called by the call that _you_ must make to __crt_dll_initialize(). Be
sure that you don't try to use the CRT until it is initialized.
Just by the way, I don't know if my experience is typical, but when I needed
to do this, the debugger refused to examine static variables when stopped in
unmanaged code. It had no problem when stopped in managed code, however.
Regards,
Will