Skip to content
Snippets Groups Projects
Commit f2f2ac3e authored by Robert K's avatar Robert K
Browse files

[bugfix][FindPythonLibs] Python libs and interpreter should be of the same

versions, otherwise linking errors will occur.
parent cc52d788
Branches
Tags
1 merge request!792Python libs and interpreter version.
Pipeline #26293 passed
......@@ -77,6 +77,11 @@ set(Python_ADDITIONAL_VERSIONS 3.8 3.7 3.6 3.5 3.4)
# Find the Python Interpreter
find_package(PythonInterp 3)
# interpreter was found set available version of library to that version
if(PYTHONINTERP_FOUND)
set(Python_ADDITIONAL_VERSIONS ${PYTHON_VERSION_MAJOR}.${PYTHON_VERSION_MINOR})
endif()
# Find the Python libraries
find_package(PythonLibs)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment