[vtk-developers] Python Wrapping Error

Sankhesh Jhaveri sankhesh.jhaveri at kitware.com
Thu Oct 20 11:56:06 EDT 2011


Hello fellow developers,

Recently, I was running into a problem when building VTK with
VTK_WRAP_PYTHON checked.

CMake found the right python headers and library but build failed giving an
error -

[  9%] Building CXX object
Wrapping/Python/CMakeFiles/vtkPythonCore.dir/PyVTKObject.cxx.o
~/Projects/VTK/Source-correct-test-failures/Wrapping/Python/PyVTKObject.cxx:381:23:
error: expected primary-expression before ‘,’ token
~/Projects/VTK/Source-correct-test-failures/Wrapping/Python/PyVTKObject.cxx:381:25:
error: ‘vtk_weakreflist’ was not declared in this scope
~/Projects/VTK/Source-correct-test-failures/Wrapping/Python/PyVTKObject.cxx:381:40:
error: ‘offsetof’ was not declared in this scope
make[2]: ***
[Wrapping/Python/CMakeFiles/vtkPythonCore.dir/PyVTKObject.cxx.o] Error 1
make[1]: *** [Wrapping/Python/CMakeFiles/vtkPythonCore.dir/all] Error 2
make: *** [all] Error 2

I did some digging and found that adding #include <vtksys/cstddef> solved
the problem.

Is that a valid hack or is it something that I am overlooking?

Thanks,
Sankhesh
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/vtk-developers/attachments/20111020/5b7352f5/attachment.html>


More information about the vtk-developers mailing list