[vtkusers] vtkMFC as .dll vs static library
Michael Jackson
mike.jackson at bluequartz.net
Thu Feb 5 11:49:32 EST 2009
I have gotten that error before when I was trying to link libraries
that were not the same from a "Threading" perspective, ie, one library
was linked as a single threaded library to the single threaded c/c++
runtime while the another library was linked to a MultiThreaded c/c++
runtime.
You must ensure _every_ library that you use are all built the
_exact_ same way with respect to the following:
MultiThreaded/Single Threaded
C/C++ Static/Dynamic Link
Check your settings carefully. That one is tough to track down
sometimes.
I think VS2003.Net was single threaded by default where VS2008 may be
multi-threaded by default.
HTH
_________________________________________________________
Mike Jackson mike.jackson at bluequartz.net
BlueQuartz Software www.bluequartz.net
Principal Software Engineer Dayton, Ohio
On Feb 5, 2009, at 11:42 AM, Alon Mozes wrote:
> It suggests setting /nodefaultlib - which I've tried - but that
> results in other linker errors saying it can't find the most basic
> functions. I'm guessing I can't just sweepingly use the /
> nodefaultlib switch. Does anyone know which .libs I have to ignore
> to get vtkMFC to work as a static library in my project? Has anyone
> used vtkMFC as a static library?
More information about the vtkusers
mailing list