[vtkusers] How to specify the path to VTK in CMake?

Michael Xanadu xanadu.michael at googlemail.com
Wed Jul 21 10:25:28 EDT 2010


Hi Dave,

thank you for your help. I did what you told me without success.
I replaced

   FIND_PACKAGE(VTK)

with

   FIND_PACKAGE(VTK REQUIRED)

No success. Then I replaced the whole code block. No success. Then I used a
codeblock found in the internet:

   FIND_PACKAGE(VTK REQUIRED)
   INCLUDE(${VTK_USE_FILE})

Always the same story. I can't set the path to VTK bin in CMake GUI & CMake
always links the (wrong) 32lib.
There are VTKConfig.cmake + useVTK.cmake in the build directory
"c:\work\libs\vtk_bin_5.6.0_x64" but not in the build directory of my own
apllication. Do you have any further suggestions for me?

With best regards,
Michael



2010/7/21 Dave Partyka <dave.partyka at kitware.com>

> You shouldn't need to set a VTK_DIR environment variable. Also you can
> simplify your logic slightly by using FIND_PACKAGE(VTK REQUIRED) instead.
>
>  That said, the only thing you should have to do is set VTK_DIR in the
> cmake gui to C:\WORK\LIBS\VTK_BIN_5.6.0_x64 and that should be it. Are
> there definately VTKConfig.cmake and UseVTK.cmake files in the root of your
> build directory?
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20100721/0b4d8ee1/attachment.htm>


More information about the vtkusers mailing list