[vtkusers] Link error when building VTK with boost support in Visual Studio 2010

Jeff Baumes jeff.baumes at kitware.com
Mon Dec 13 10:39:47 EST 2010


On Sat, Dec 11, 2010 at 10:52 PM, Hong Yi <hongyi at renci.org> wrote:

> Thanks, Jeff.
>
>
>
> I don’t get this error (i.e., fatal error LNK1104: cannot open file
> 'libboost_serialization-vc100-mt-gd-1_44.lib') any more after I turned off
> Windows 7 Account Access Control and rebuilt everything, so this error was
> caused by windows 7 Account Access Control. However, I got the following 3
> linking errors:
>
>
>
> 8>BoostArrayLogWeighting.obj : error LNK2019: unresolved external symbol
> "__declspec(dllimport) public: static class vtkBoostLogWeighting * __cdecl
> vtkBoostLogWeighting::New(void)" (__imp_?New at vtkBoostLogWeighting
> @@SAPAV1 at XZ) referenced in function "public: static class
> vtkSmartPointer<class vtkBoostLogWeighting> __cdecl vtkSmartPointer<class
> vtkBoostLogWeighting>::New(void)" (?New@
> ?$vtkSmartPointer at VvtkBoostLogWeighting@@@@SA?AV1 at XZ)
>
> 8>BoostArrayRandomSparseArraySource.obj : error LNK2019: unresolved
> external symbol "__declspec(dllimport) public: static class
> vtkBoostRandomSparseArraySource * __cdecl
> vtkBoostRandomSparseArraySource::New(void)"
> (__imp_?New at vtkBoostRandomSparseArraySource@@SAPAV1 at XZ) referenced in
> function "public: static class vtkSmartPointer<class
> vtkBoostRandomSparseArraySource> __cdecl vtkSmartPointer<class
> vtkBoostRandomSparseArraySource>::New(void)" (?New@
> ?$vtkSmartPointer at VvtkBoostRandomSparseArraySource@@@@SA?AV1 at XZ)
>
> 8>BoostArrayRandomSparseArraySource.obj : error LNK2019: unresolved
> external symbol "__declspec(dllimport) public: void __thiscall
> vtkBoostRandomSparseArraySource::SetExtents(class vtkArrayExtents const &)"
> (__imp_?SetExtents at vtkBoostRandomSparseArraySource
> @@QAEXABVvtkArrayExtents@@@Z) referenced in function "int __cdecl
> BoostArrayRandomSparseArraySource(int,char * * const)"
> (?BoostArrayRandomSparseArraySource@@YAHHQAPAD at Z)
>
> 8>C:\Users\hongyi.HONGYI-W510\VTK-CMake\bin\RelWithDebInfo\InfovisBoostArrayCxxTests.exe
> : fatal error LNK1120: 3 unresolved externals
>
>
>
> Any suggestions on what additional libs I should include in the link
> property setup to make above three symbols resolved?
>
>
It would seem that vtkInfovis is not building with vtkBoostLogWeighting
and vtkBoostRandomSparseArraySource, but they should if you have
VTK_USE_N_WAY_ARRAYS and VTK_USE_BOOST on. If either is not on, then the
executable InfovisBoostArrayCxxTests should not be built, so I'm not sure
what the issue is here.

Another not-directly-related question: I have written a simple example using
> VTK and QT and it only works with release configuration with VTK built and
> installed with release configuration also. When I run the example with debug
> configuration, I got an error message “this application has failed to start
> because the application configuration is incorrect. Review the manifest file
> for possible errors.” I am new to VTK and read from the web that VTK should
> be installed with release configuration since the debug configuration does
> not work well, is that a true statement? I am currently using visual studio
> 2010 to build VTK 5.6 version. If I want my VTK+QT example to work with
> debug configuration, is there anything special I should do and be aware of?
> Thanks for any suggestions and guidelines on this.
>

You may want to start a new thread on this topic.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20101213/070ac36d/attachment.htm>


More information about the vtkusers mailing list