<div dir="ltr">Thanks Cory.<div>Unfortunately, even this solution didn't work.</div><div>Always the same error as the first message.</div><div class="gmail_extra"><br clear="all"><div><div class="gmail_signature"><div dir="ltr">Regards,<div>Paolo Grossi.</div></div></div></div>
<br><div class="gmail_quote">On 17 July 2015 at 13:40, Cory Quammen <span dir="ltr"><<a href="mailto:cory.quammen@kitware.com" target="_blank">cory.quammen@kitware.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Hmm, I would try to remove the line<div><br></div><div><span style="font-size:12.8000001907349px">set(VTK_DIR $HOME/build-VTK)</span><br></div><div><span style="font-size:12.8000001907349px"><br></span></div><div><span style="font-size:12.8000001907349px">and set that manually though ccmake and see if that works.</span></div><span class="HOEnZb"><font color="#888888"><div><span style="font-size:12.8000001907349px"><br></span></div><div><span style="font-size:12.8000001907349px">Cory</span></div></font></span></div><div class="HOEnZb"><div class="h5"><div class="gmail_extra"><br><div class="gmail_quote">On Fri, Jul 17, 2015 at 8:11 AM, Paolo Grossi <span dir="ltr"><<a href="mailto:smoldino@gmail.com" target="_blank">smoldino@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Thanks Cory for your quick answer.<div>I didn't receive an error during the configuration with ccmake.</div><div>I tried to build the example outside the main directory and to correct the CMakeLists.txt, but the result is always the same.</div><div class="gmail_extra"><br clear="all"><div><div><div dir="ltr">Regards,<div>Paolo Grossi.</div></div></div></div><div><div>
<br><div class="gmail_quote">On 17 July 2015 at 13:01, Cory Quammen <span dir="ltr"><<a href="mailto:cory.quammen@kitware.com" target="_blank">cory.quammen@kitware.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div>Paolo,</div><div><br></div>Did you get an error when configuring with ccmake? It looks like the VTK include directories are not being set properly.<div><br></div><div>I would also recommend putting the example code and CMakeLists.txt file in a directory outside your VTK build directory. I'm not sure that this is causing the problem, but it is good practice to build dependent projects outside the VTK build directory.</div><div><br></div><div>Also, in your CMakeLists.txt file, I think you can access your HOME environment variable with</div><div><br></div><div><span style="color:rgb(0,0,0);font-family:sans-serif;font-size:16px;line-height:20.7999992370605px;text-align:justify">$ENV{HOME}</span></div><div><div style="text-align:justify"><font color="#000000" face="sans-serif"><span style="font-size:16px;line-height:20.7999992370605px"><br></span></font></div><div style="text-align:justify"><font color="#000000" face="sans-serif"><span style="font-size:16px;line-height:20.7999992370605px">not</span></font></div><div style="text-align:justify"><font color="#000000" face="sans-serif"><span style="font-size:16px;line-height:20.7999992370605px"><br></span></font></div><div style="text-align:justify"><font color="#000000" face="sans-serif"><span style="font-size:16px;line-height:20.7999992370605px">$HOME</span></font></div><div><br></div><div>Thanks,</div><div>Cory</div></div></div><div class="gmail_extra"><br><div class="gmail_quote"><div><div>On Fri, Jul 17, 2015 at 6:56 AM, Paolo Grossi <span dir="ltr"><<a href="mailto:smoldino@gmail.com" target="_blank">smoldino@gmail.com</a>></span> wrote:<br></div></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div><div dir="ltr"><div>Greetings to the whole community of VTK,</div><div>I'm a newbie user!</div><div><br></div>After the installation of VTK on my PC (Ubuntu 14.04.2), I was trying to run the example linked here:<div><a href="http://www.vtk.org/Wiki/VTK/Examples/Cxx/GeometricObjects/Cone" target="_blank">http://www.vtk.org/Wiki/VTK/Examples/Cxx/GeometricObjects/Cone</a></div><div>During the installation I selected the "BUILD EXAMPLE" option.</div><div>I also unselected the "BUILD SHARED LIBS" option, because I can't proceed with the installation if I had selected it.</div><div><br></div><div>My steps were:</div><div>1) created the file Cone.cxx into the directory "$HOME/build-VTK/Examples/Tutorial/Step1/Cxx/CmakeFiles/Cone.dir" with the text:</div><div><div><br></div><div>#include <vtkConeSource.h></div><div>#include <vtkPolyData.h></div><div>#include <vtkSmartPointer.h></div><div>#include <vtkPolyDataMapper.h></div><div>#include <vtkActor.h></div><div>#include <vtkRenderWindow.h></div><div>#include <vtkRenderer.h></div><div>#include <vtkRenderWindowInteractor.h></div><div> </div><div>int main(int, char *[])</div><div>{</div><div>  //Create a cone</div><div>  vtkSmartPointer<vtkConeSource> coneSource = vtkSmartPointer<vtkConeSource>::New();</div><div>  coneSource->Update();</div><div> </div><div>  //Create a mapper and actor</div><div>  vtkSmartPointer<vtkPolyDataMapper> mapper = vtkSmartPointer<vtkPolyDataMapper>::New();</div><div>  mapper->SetInputConnection(coneSource->GetOutputPort());</div><div> </div><div>  vtkSmartPointer<vtkActor> actor = vtkSmartPointer<vtkActor>::New();</div><div>  actor->SetMapper(mapper);</div><div> </div><div>  //Create a renderer, render window, and interactor</div><div>  vtkSmartPointer<vtkRenderer> renderer = vtkSmartPointer<vtkRenderer>::New();</div><div>  vtkSmartPointer<vtkRenderWindow> renderWindow = vtkSmartPointer<vtkRenderWindow>::New();</div><div>  renderWindow->AddRenderer(renderer);</div><div>  vtkSmartPointer<vtkRenderWindowInteractor> renderWindowInteractor = vtkSmartPointer<vtkRenderWindowInteractor>::New();</div><div>  renderWindowInteractor->SetRenderWindow(renderWindow);</div><div> </div><div>  //Add the actors to the scene</div><div>  renderer->AddActor(actor);</div><div>  renderer->SetBackground(.3, .2, .1); // Background color dark red</div><div> </div><div>  //Render and interact</div><div>  renderWindow->Render();</div><div>  renderWindowInteractor->Start();</div><div> </div><div>  return EXIT_SUCCESS;</div><div>}</div></div><div><br clear="all"><div><div><div>2) created the file CMakeLists.txt into the same directory above with the text:</div><div><div><br></div><div>cmake_minimum_required(VERSION 2.8)</div><div>project(Cone)</div><div><div>set(VTK_DIR $HOME/build-VTK)</div></div><div>find_package(VTK REQUIRED)</div><div>include(${VTK_USE_FILE})</div><div>add_executable(Cone Cone.cxx) </div><div>if(VTK_LIBRARIES)</div><div>  target_link_libraries(Cone ${VTK_LIBRARIES})</div><div>else()</div><div>  target_link_libraries(Cone vtkHybrid vtkWidgets)</div><div>endif()</div></div><div><br></div><div>3) typed the command "ccmake ." into the same directory above, pressed the C button and the G button</div><div><br></div><div>4) typed the command "make" into the same directory above, receiving the error explained below:</div><div><br></div><div><div>$HOME/build-VTK/Examples/Tutorial/Step1/Cxx/CMakeFiles/Cone.dir/Cone.cxx:19:27: error: vtkConeSource.h: No such file or directory</div><div>$HOME/build-VTK/Examples/Tutorial/Step1/Cxx/CMakeFiles/Cone.dir/Cone.cxx:20:31: error: vtkPolyDataMapper.h: No such file or directory</div><div>$HOME/build-VTK/Examples/Tutorial/Step1/Cxx/CMakeFiles/Cone.dir/Cone.cxx:21:29: error: vtkRenderWindow.h: No such file or directory</div><div>$HOME/build-VTK/Examples/Tutorial/Step1/Cxx/CMakeFiles/Cone.dir/Cone.cxx:22:23: error: vtkCamera.h: No such file or directory</div><div>$HOME/build-VTK/Examples/Tutorial/Step1/Cxx/CMakeFiles/Cone.dir/Cone.cxx:23:22: error: vtkActor.h: No such file or directory</div><div>$HOME/build-VTK/Examples/Tutorial/Step1/Cxx/CMakeFiles/Cone.dir/Cone.cxx:24:25: error: vtkRenderer.h: No such file or directory</div><div>$HOME/build-VTK/Examples/Tutorial/Step1/Cxx/CMakeFiles/Cone.dir/Cone.cxx: In function ‘int main()’:</div><div>$HOME/build-VTK/Examples/Tutorial/Step1/Cxx/CMakeFiles/Cone.dir/Cone.cxx:34: error: ‘vtkConeSource’ was not declared in this scope</div><div>$HOME/build-VTK/Examples/Tutorial/Step1/Cxx/CMakeFiles/Cone.dir/Cone.cxx:34: error: ‘cone’ was not declared in this scope</div><div>$HOME/build-VTK/Examples/Tutorial/Step1/Cxx/CMakeFiles/Cone.dir/Cone.cxx:34: error: ‘vtkConeSource’ is not a class or namespace</div><div>$HOME/build-VTK/Examples/Tutorial/Step1/Cxx/CMakeFiles/Cone.dir/Cone.cxx:46: error: ‘vtkPolyDataMapper’ was not declared in this scope</div><div>$HOME/build-VTK/Examples/Tutorial/Step1/Cxx/CMakeFiles/Cone.dir/Cone.cxx:46: error: ‘coneMapper’ was not declared in this scope</div><div>$HOME/build-VTK/Examples/Tutorial/Step1/Cxx/CMakeFiles/Cone.dir/Cone.cxx:46: error: ‘vtkPolyDataMapper’ is not a class or namespace</div><div>$HOME/build-VTK/Examples/Tutorial/Step1/Cxx/CMakeFiles/Cone.dir/Cone.cxx:56: error: ‘vtkActor’ was not declared in this scope</div><div>$HOME/build-VTK/Examples/Tutorial/Step1/Cxx/CMakeFiles/Cone.dir/Cone.cxx:56: error: ‘coneActor’ was not declared in this scope</div><div>$HOME/build-VTK/Examples/Tutorial/Step1/Cxx/CMakeFiles/Cone.dir/Cone.cxx:56: error: ‘vtkActor’ is not a class or namespace</div><div>$HOME/build-VTK/Examples/Tutorial/Step1/Cxx/CMakeFiles/Cone.dir/Cone.cxx:65: error: ‘vtkRenderer’ was not declared in this scope</div><div>$HOME/build-VTK/Examples/Tutorial/Step1/Cxx/CMakeFiles/Cone.dir/Cone.cxx:65: error: ‘ren1’ was not declared in this scope</div><div>$HOME/build-VTK/Examples/Tutorial/Step1/Cxx/CMakeFiles/Cone.dir/Cone.cxx:65: error: ‘vtkRenderer’ is not a class or namespace</div><div>$HOME/build-VTK/Examples/Tutorial/Step1/Cxx/CMakeFiles/Cone.dir/Cone.cxx:74: error: ‘vtkRenderWindow’ was not declared in this scope</div><div>$HOME/build-VTK/Examples/Tutorial/Step1/Cxx/CMakeFiles/Cone.dir/Cone.cxx:74: error: ‘renWin’ was not declared in this scope</div><div>$HOME/build-VTK/Examples/Tutorial/Step1/Cxx/CMakeFiles/Cone.dir/Cone.cxx:74: error: ‘vtkRenderWindow’ is not a class or namespace</div><div>make[2]: *** [CMakeFiles/Cone.dir/Cone.cxx.o] Error 1</div><div>make[1]: *** [CMakeFiles/Cone.dir/all] Error 2</div><div>make: *** [all] Error 2</div></div><div><br></div><div>I have really no idea about the solution of this problem.</div><div>Sorry for my incompetence!</div><div>I'm looking forward to hear you.</div><div dir="ltr"><br></div><div dir="ltr">Thanks,<div>Paolo Grossi.</div></div></div></div>
</div></div>
<br></div></div>_______________________________________________<br>
Powered by <a href="http://www.kitware.com" rel="noreferrer" target="_blank">www.kitware.com</a><br>
<br>
Visit other Kitware open-source projects at <a href="http://www.kitware.com/opensource/opensource.html" rel="noreferrer" 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" rel="noreferrer" target="_blank">http://www.vtk.org/Wiki/VTK_FAQ</a><br>
<br>
Search the list archives at: <a href="http://markmail.org/search/?q=vtkusers" rel="noreferrer" target="_blank">http://markmail.org/search/?q=vtkusers</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="http://public.kitware.com/mailman/listinfo/vtkusers" rel="noreferrer" target="_blank">http://public.kitware.com/mailman/listinfo/vtkusers</a><br>
<br></blockquote></div><span><font color="#888888"><br><br clear="all"><div><br></div>-- <br><div>Cory Quammen<br>R&D Engineer<br>Kitware, Inc.</div>
</font></span></div>
</blockquote></div><br></div></div></div></div>
</blockquote></div><br><br clear="all"><div><br></div>-- <br><div>Cory Quammen<br>R&D Engineer<br>Kitware, Inc.</div>
</div>
</div></div></blockquote></div><br></div></div>