small CMake tweaks from progguide branch

This commit is contained in:
Axel Kohlmeyer 2020-06-13 12:03:50 -04:00
parent daae6ea97f
commit 9b0213f1ab
No known key found for this signature in database
GPG Key ID: D9B44E93BF0C375A
1 changed files with 5 additions and 0 deletions

View File

@ -625,6 +625,8 @@ install(
###############################################################################
if(BUILD_SHARED_LIBS)
if(CMAKE_VERSION VERSION_LESS 3.12)
# adjust so we find Python 3 versions before Python 2 on old systems with old CMake
set(Python_ADDITIONAL_VERSIONS 3.8 3.7 3.6 3.5)
find_package(PythonInterp) # Deprecated since version 3.12
if(PYTHONINTERP_FOUND)
set(Python_EXECUTABLE ${PYTHON_EXECUTABLE})
@ -780,3 +782,6 @@ if(PKG_KSPACE)
endif()
endif()
endif()
if(BUILD_DOC)
message(STATUS "<<< Building HTML Manual >>>")
endif()