mirror of
https://github.com/zeek/zeek.git
synced 2025-10-02 14:48:21 +00:00
Update CMake logic to enforce Python >= 3.5
This commit is contained in:
parent
33a55a04c3
commit
eeec219a66
1 changed files with 8 additions and 1 deletions
|
@ -236,6 +236,7 @@ if (NOT SED_EXE)
|
||||||
endif ()
|
endif ()
|
||||||
endif ()
|
endif ()
|
||||||
|
|
||||||
|
list(APPEND Python_ADDITIONAL_VERSIONS 3)
|
||||||
FindRequiredPackage(PythonInterp)
|
FindRequiredPackage(PythonInterp)
|
||||||
FindRequiredPackage(FLEX)
|
FindRequiredPackage(FLEX)
|
||||||
FindRequiredPackage(BISON)
|
FindRequiredPackage(BISON)
|
||||||
|
@ -282,6 +283,12 @@ if (MISSING_PREREQS)
|
||||||
message(FATAL_ERROR "Configuration aborted due to missing prerequisites")
|
message(FATAL_ERROR "Configuration aborted due to missing prerequisites")
|
||||||
endif ()
|
endif ()
|
||||||
|
|
||||||
|
set(ZEEK_PYTHON_MIN 3.5.0)
|
||||||
|
|
||||||
|
if ( PYTHON_VERSION_STRING VERSION_LESS ${ZEEK_PYTHON_MIN} )
|
||||||
|
message(FATAL_ERROR "Python ${ZEEK_PYTHON_MIN} or greater is required.")
|
||||||
|
endif ()
|
||||||
|
|
||||||
if ( CAF_ROOT_DIR )
|
if ( CAF_ROOT_DIR )
|
||||||
find_package(CAF COMPONENTS core io openssl REQUIRED)
|
find_package(CAF COMPONENTS core io openssl REQUIRED)
|
||||||
endif ()
|
endif ()
|
||||||
|
@ -530,7 +537,7 @@ endif ()
|
||||||
|
|
||||||
if (INSTALL_ZEEKCTL)
|
if (INSTALL_ZEEKCTL)
|
||||||
# CPack RPM Generator may not automatically detect this
|
# CPack RPM Generator may not automatically detect this
|
||||||
set(CPACK_RPM_PACKAGE_REQUIRES "python >= 2.6.0")
|
set(CPACK_RPM_PACKAGE_REQUIRES "python >= ${ZEEK_PYTHON_MIN}")
|
||||||
endif ()
|
endif ()
|
||||||
|
|
||||||
# If this CMake project is a sub-project of another, we will not
|
# If this CMake project is a sub-project of another, we will not
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue