MikeA
July 12th, 1999, 10:55 AM
I have a Windows non-gui mfc program I need to port to Unix. I want to maintain a common source. I can't use MainWin or similar tools. I'm starting by changing the mfc containers to new classes that have different names, and implementing them using stl. I'll handle the other mfc classes later. I'm building now on NT, and will switch to Unix later. When I link I get:
nafxcwd.lib(afxmem.obj) : error LNK2005: "void __cdecl operator delete(void *)" (??3@YAXPAX@Z) already defined in libcpmtd.lib(delop.obj)
Debug/xxx.exe : fatal error LNK1169: one or more multiply defined symbols found
Now, libcpmtd.lib is multi-threaded, debug, static link version of the Standard C++ library, and nafxcwd.lib is the ANSI debug version of the mfc library. I need BOTH of these. So, is the problem that I just can't use stl and mfc together? I haven't seen any statements to that effect. Or am I doing something wrong?
Any thoughts would be appreciated.
nafxcwd.lib(afxmem.obj) : error LNK2005: "void __cdecl operator delete(void *)" (??3@YAXPAX@Z) already defined in libcpmtd.lib(delop.obj)
Debug/xxx.exe : fatal error LNK1169: one or more multiply defined symbols found
Now, libcpmtd.lib is multi-threaded, debug, static link version of the Standard C++ library, and nafxcwd.lib is the ANSI debug version of the mfc library. I need BOTH of these. So, is the problem that I just can't use stl and mfc together? I haven't seen any statements to that effect. Or am I doing something wrong?
Any thoughts would be appreciated.