<html>
<head>
<style><!--
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
font-size: 12pt;
font-family:Calibri
}
--></style></head>
<body class='hmmessage'><div dir='ltr'>Hi Christopher,<br><br>Yes I have seen and read that page. The problem I am having is not building VTK itself, rather, building my own application which uses VTK. I have cobbled together a CMake file from scouring the VTK documentation / Google. It reads<br><br><blockquote>cmake_minimum_required(VERSION 2.8.7)<br>project(Test)<br>set(VTK_DIR "C:/VTK-6.1.0/install")<br>find_package(VTK 6.1 REQUIRED NO_MODULE)<br>if(VTK_FOUND)<br>    message("found VTK. Version:" ${VTK_VERSION}. VTK_DIR: ${VTK_DIR})<br>endif()<br>include(${VTK_USE_FILE})<br>add_executable(Test test.cpp)<br>target_link_libraries(Test ${VTK_LIBRARIES})<br></blockquote><br>It configures fine and generates a Visual Studio solution I can open, but when I try and build this it throws a linker error saying<br><br><blockquote>"cannot open input file 'vtkalglib.lib'"<br><br></blockquote>Interesting to note is that in my install folder (specified while building VTK) there is a .lib called 'vtkalglib-6.1.lib' but no 'vtkalglib.lib'. Also, even though I specified my VTK_DIR in the CMake it keeps showing the wrong directory in the CMake GUI and even if I change it, it swaps back when I click on configure.<br><br>Regards,<br>Dan<br><br><br><div><hr id="stopSpelling">Date: Tue, 1 Jul 2014 15:43:36 -0400<br>Subject: Re: [vtkusers] CMake/Linking Issues VTK 6.1.0<br>From: christopher.mullins@kitware.com<br>To: dbpvusrlist@hotmail.co.uk<br>CC: vtkusers@vtk.org<br><br><div dir="ltr">Have you checked out the wiki page for configuring and building [1] ?  It was written for VTK 6.1.0.  <div><br></div><div>Could you post which step you're trying to accomplish, and the errors you receive?  I think this will help us diagnose what's happening.<div>
<br></div><div><br></div><div>[1] <a href="http://www.vtk.org/Wiki/VTK/Configure_and_Build" target="_blank">http://www.vtk.org/Wiki/VTK/Configure_and_Build</a></div></div></div><div class="ecxgmail_extra"><br><br><div class="ecxgmail_quote">On Tue, Jul 1, 2014 at 3:33 PM, Dan <span dir="ltr"><<a href="mailto:dbpvusrlist@hotmail.co.uk" target="_blank">dbpvusrlist@hotmail.co.uk</a>></span> wrote:<br>
<blockquote class="ecxgmail_quote" style="border-left:1px #ccc solid;padding-left:1ex;">


<div><div dir="ltr">Hi All,<br><br>I have been using VTK (version 5) for some time. I downloaded and built the source as detailed on the website, and then I was able to link to the libraries and include the header files manually as I usually do for third party libraries. Everything worked fine.<br>
<br>I'm now on a new system so I downloaded, configured and built VTK 6.1.0. It built fine and I installed it to the specified directory. However, I then found it impossible to manually link my VS project to the libraries. To get around this I tried using CMake to generate a Visual Studio project but nothing I try seems to work. A number of permutations each seem to give different errors, either include errors or linking errors. Some won't even configure with CMake!<br>
<br>Could someone please explain, in clear steps how one goes about building and linking to VTK?<br><br>Thanks very much,<br>Dan<br><br>(I'm not a novice but after three days trying to sort this out I'm out of ideas!)<br>
<br>                                        </div></div>
<br>_______________________________________________<br>
Powered by <a href="http://www.kitware.com" target="_blank">www.kitware.com</a><br>
<br>
Visit other Kitware open-source projects at <a href="http://www.kitware.com/opensource/opensource.html" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
<br>
Please keep messages on-topic and check the VTK FAQ at: <a href="http://www.vtk.org/Wiki/VTK_FAQ" target="_blank">http://www.vtk.org/Wiki/VTK_FAQ</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="http://public.kitware.com/mailman/listinfo/vtkusers" target="_blank">http://public.kitware.com/mailman/listinfo/vtkusers</a><br>
<br></blockquote></div><br><br clear="all"><div><br></div>-- <br>Christopher Mullins<div>R&D Engineer</div><div>Kitware Inc.,</div><div>919.869.8871</div>
</div></div>                                          </div></body>
</html>