Sync FindPythonLibs with CMake
VTK's FindPythonLibs
is setting PYTHON_*_VERSION
variables which are not provided by the CMake module. These variables are not provided by CMake's FindPythonLibs
(it offers PYTHONLIBS_VERSION_STRING
), but are required in vtkPythonWrapping
. This fails when a project does find_package(PythonLibs)
on its own and then later includes VTK (because it is optional) and those variables are not set because CMake's find module was used rather than VTK's.
The proper solution is to sync with CMake and not use the VTK-specific variables.