[vtk-developers] Do we really need the VTK version of FindPythonLibs.cmake?

Andrew Maclean andrew.amaclean at gmail.com
Thu Mar 19 03:21:19 EDT 2015

Hi David,
   Thanks for getting back so fast ... what time was it where you are? I am
in no hurry, so take your time and have a good look at the code!

All these questions arose because I did a gerrit submission, (now abandoned
because I thought it would be a good idea to wait for GitLab to be up and
running): http://review.source.kitware.com/#/c/19474/
These changes worked but on thinking about it they raised a lot of
questions, hence the email.

I did consider just a change to the VTK version of FindPythonLibs.cmake but
then I found the CMake version worked quite well. The abandoned topic built
Ok on the test machines and Windows.

In response to your points:
2) I agree that the synchronization with CMake should be better!

1) It is strange that there exist FindPythonLibs.cmake and
FindPythonInterp.cmake but I guess it may be historical. A FindPython.cmake
would be more intuitive. You can emulate this by doing a:
find_package(PythonInterp ${VTK_PYTHON_VERSION})
find_package(PythonLibs ${VTK_PYTHON_VERSION})
Which leads to point 3:

3)  I think the problem here is that in the VTK stuff, all the finding of
the Python Libs are done by:
note that Python_ADDITIONAL_VERSIONS is not being used. I think these calls
should be:
find_package(PythonLibs ${VTK_PYTHON_VERSION})
this should fix the issue that python3 libs are being found when python (2)
is needed.

It is interesting that the third party stuff all does this:
Which raises the possibility that the third party lib versions could be
different from the VTK versions!

Anyway I think that if the python stuff can be streamlined an simplified
that will be the best approach. So take your time and have a good look at
the code! I can do a quick fix to FindPythonLibs.cmake but there are deeper
issues here.

I am in no hurry!

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/vtk-developers/attachments/20150319/820f55b9/attachment-0001.html>

More information about the vtk-developers mailing list