1
votes

I am building a project in Visual Studio 2005 that require some libraries that were built in Visual Studio 2003. I'm getting linker errors like

msvcprt.lib(MSVCP80.dll) : error LNK2005: class std::basic_string[...]already defined in libdiguy.lib(bdiNavMesh.obj)

I believe that my program and the libraries are both compiled dynamically instead of statically. I've also tried changing the /MD and /MDd options because that seemed to be the solution to similar errors. My best guess at the moment is that it needs to link against MSVCP70.dll instead of MSVCP80.dll to resolve these errors. Is there a way I can compile against the older dll to see if that will fix it?

Thank you!

1

1 Answers

0
votes

As far as I know you have two options: either get a VS2005 version of the libraries, or keep using the VS2003 headers and libraries. The first is in my opinion the better option because you will not benefit from fixes MS made in headers and libs. But it may be difficult or even impossible. The latter can be done by changing the VS2005 directories to the corresponding VS2003 ones. I think that you also have to ignore all default libraries and explicitly specify the ones from VS2003.

Hope this helps.

Cheers,

Sebastiaan