mirror of
https://github.com/gnss-sdr/gnss-sdr
synced 2025-05-22 01:04:09 +00:00
Find Python 3 with CMake < 3.12
This commit is contained in:
parent
4d1759bf9a
commit
b552616b99
@ -72,7 +72,8 @@ if(CMAKE_VERSION VERSION_LESS 3.12)
|
|||||||
gnsssdr_python_check_module("six - python 2 and 3 compatibility library" six "True" SIX_FOUND)
|
gnsssdr_python_check_module("six - python 2 and 3 compatibility library" six "True" SIX_FOUND)
|
||||||
else()
|
else()
|
||||||
message(STATUS "PYTHON_EXECUTABLE not set - trying by default python3")
|
message(STATUS "PYTHON_EXECUTABLE not set - trying by default python3")
|
||||||
message(STATUS "Use -DPYTHON_EXECUTABLE=/path/to/python2.7 to build for python 2.7")
|
message(STATUS "Use -DPYTHON_EXECUTABLE=/path/to/python to build for python 2.7")
|
||||||
|
set(Python_ADDITIONAL_VERSIONS 3.4 3.5 3.6 3.7 3.8 3.9)
|
||||||
find_package(PythonInterp ${GNSSSDR_PYTHON_MIN3_VERSION})
|
find_package(PythonInterp ${GNSSSDR_PYTHON_MIN3_VERSION})
|
||||||
if(NOT PYTHONINTERP_FOUND)
|
if(NOT PYTHONINTERP_FOUND)
|
||||||
message(STATUS "python3 not found - trying with python2.7")
|
message(STATUS "python3 not found - trying with python2.7")
|
||||||
|
@ -71,6 +71,7 @@ if(CMAKE_VERSION VERSION_LESS 3.12)
|
|||||||
else()
|
else()
|
||||||
message(STATUS "PYTHON_EXECUTABLE not set - trying by default python3")
|
message(STATUS "PYTHON_EXECUTABLE not set - trying by default python3")
|
||||||
message(STATUS "Use -DPYTHON_EXECUTABLE=/path/to/python to build for python 2.7")
|
message(STATUS "Use -DPYTHON_EXECUTABLE=/path/to/python to build for python 2.7")
|
||||||
|
set(Python_ADDITIONAL_VERSIONS 3.4 3.5 3.6 3.7 3.8 3.9)
|
||||||
find_package(PythonInterp ${VOLK_PYTHON_MIN3_VERSION})
|
find_package(PythonInterp ${VOLK_PYTHON_MIN3_VERSION})
|
||||||
if(NOT PYTHONINTERP_FOUND)
|
if(NOT PYTHONINTERP_FOUND)
|
||||||
message(STATUS "python3 not found - trying with python2.7")
|
message(STATUS "python3 not found - trying with python2.7")
|
||||||
|
Loading…
x
Reference in New Issue
Block a user