Skip to content

Fix find python for cmake <3.12 and >= 3.12

Bas van der Tol requested to merge fix-cmake-find-python into master

CMakeLists.txt used the variables ${PYTHON_VERSION_MAJOR} and ${PYTHON_VERSION_MINOR} to set the ${PYTHON_INSTALL_PATH} The correct names of the intended variables are ${Python3_VERSION_MAJOR} and ${Python3_VERSION_MINOR}. These are set by cmake system module FindPython3.cmake. This module is only available from cmake 3.12 onwards. For versions <3.12 we emulate the FindPython3.cmake behaviour.

Merge request reports

Loading