[vtkusers] missing vtk library for vtk5 compilation

Fcs ftpronk at engits.com
Mon Nov 5 06:05:24 EST 2018


Hello Idayat,

By looking at your CMakeErrorLog, your build is trying to find files like
pthread.h and unistd.h, which are header files belonging to of the POSIX
(thread) API. As you are building under Windows with Visual Studio, these
files don't exist, and you need to link to the Win32 API, and not the POSIX
API.  This means something is wrong with your build.

Did you use the correct generator with CMake? I personally haven't built
vtk5 under windows, but I expect their CMake setup to correctly deal with
the POSIX/Win32 issue.  Have a look here
<https://cmake.org/cmake/help/v3.4/manual/cmake-generators.7.html#visual-studio-generators>  
for more information about CMake generators.

It could also be a bug introduced in the specific commit your are trying to
compile.  Did you try using an earlier release?

Also, keep in mind that Visual Studio 2013 did not exist when vtk 5.10 was
released, and it might simply not be compatible with that compiler.  Would
it be acceptable for your project to use an earlier compiler? If all else
fails, you could try using a toolchain that is guaranteed to be compatible
with vtk 5.

Last but not least, if I remember properly, the earlier versions of vtk 5
where defining macros conflicting with c++11. I don't remember if that was
also the case for the later versions of vtk 5, or if you could disable those
macros in CMake and use their c++11 equivalent, but keep in mind that Visual
Studio 2013 has (some....) c++11 support which might conflict with vtk 5.

Kind regards






--
Sent from: http://vtk.1045678.n5.nabble.com/VTK-Users-f1224199.html


More information about the vtkusers mailing list