I'm currently migrating a DLL which compiles and links fine on Visual Studio .NET 2003 over to Visual Studio 2005. Its using a couple of custom libraries provided by a thrid party (but source included).
I've recompiled the external libraries without a problem, and the linker can find them fine. I have to specifically tell the linker to ignore libcmt.lib and libcpmt.lib, as for some reason it tries to link them in (I'm compiling as a multi-threaded DLL), but that's not a big issue. The problem is that when it links, it gets a linker error LNK2019 for each of the external libraries I'm using. The error messages are as follows:
error LNK2019: unresolved external symbol "private: static int std::locale::id::_Id_cnt" ( _Id_cnt@id@locale@std@@0HA) referenced in function "public: __thiscall std::locale::id::operator unsigned int(void)" ( Bid@locale@std@@QAEIXZ)
error LNK2001: unresolved external symbol "private: static int std::locale::id::_Id_cnt" ( _Id_cnt@id@locale@std@@0HA)
I've traced down the objects in question, and have determined that the problem appears to stem from the use of ostream, especially where formatting is used (setfill, setw, dec, hex, etc). Furthermore, I get linker errors when I try to use anything that takes advantage of ostream in the dll, as it claims that all the ostream functions are already declared in one of the libraries (the one that generated LNK2019).
Ideas Please let me know if I need to provide any further information.

LNK2019 problems
yy608
Battle,
This is the behavior you see when libraries are compiled under a different configuration than each other or the application they are being linked with.
Specifically, the libraries can either be single threaded, or multi-threaded, and either static, or dynamic (DLL). These settings determine which c-runtime library to link with your final executable. If the libraries don’t agree with each other or with the main project, then you've got a problem of it needing multiple c-runtime libraries. This often causes conflicts of "multiply defined types." But if you specifically tell the linker NOT to include some of the libraries then the components which are set to use a c-runtime of a different configuration will complain about missing symbols.
The solution is to go back and re-compile/link all of your libraries and executables and make certain that they all share the same configuration (ie single/multi, static/dll).
Cheers!
Rodrigo Harambure