fixed a bug where unsetting the cached python version leads to different numpy/cython/libraries being used

release/4.3a0
Matthew Broadway 2019-02-14 10:55:16 +00:00
parent e9e8ca3990
commit 9c1dfd244f
1 changed files with 2 additions and 0 deletions

View File

@ -7,8 +7,10 @@ unset(PYTHON_INCLUDE_DIR CACHE)
unset(PYTHON_MAJOR_VERSION CACHE)
if(GTSAM_PYTHON_VERSION STREQUAL "Default")
find_package(PythonInterp REQUIRED)
find_package(PythonLibs REQUIRED)
else()
find_package(PythonInterp ${GTSAM_PYTHON_VERSION} EXACT REQUIRED)
find_package(PythonLibs ${GTSAM_PYTHON_VERSION} EXACT REQUIRED)
endif()
find_package(Cython 0.25.2 REQUIRED)