minor cmake doc improvements

This commit is contained in:
Wenzel Jakob 2016-01-20 01:26:44 +01:00
parent b670b77060
commit d4db8bc4bf

View File

@ -29,15 +29,14 @@ and that the pybind11 repository is located in a subdirectory named :file:`pybin
# Try to autodetect Python (can be overridden manually if needed) # Try to autodetect Python (can be overridden manually if needed)
set(Python_ADDITIONAL_VERSIONS 3.4 3.5 3.6 3.7) set(Python_ADDITIONAL_VERSIONS 3.4 3.5 3.6 3.7)
if (NOT ${PYBIND11_PYTHON_VERSION} STREQUAL "") if (NOT ${EXAMPLE_PYTHON_VERSION} STREQUAL "")
find_package(PythonLibs ${PYBIND11_PYTHON_VERSION} EXACT) find_package(PythonLibs ${EXAMPLE_PYTHON_VERSION} EXACT)
if (NOT PythonLibs_FOUND) if (NOT PythonLibs_FOUND)
find_package(PythonLibs ${PYBIND11_PYTHON_VERSION} REQUIRED) find_package(PythonLibs ${EXAMPLE_PYTHON_VERSION} REQUIRED)
endif() endif()
else() else()
find_package(PythonLibs REQUIRED) find_package(PythonLibs REQUIRED)
endif() endif()
find_package(PythonInterp ${PYTHONLIBS_VERSION_STRING} EXACT REQUIRED)
# Uncomment the following line if you will also require a matching Python interpreter # Uncomment the following line if you will also require a matching Python interpreter
# find_package(PythonInterp ${PYTHONLIBS_VERSION_STRING} EXACT REQUIRED) # find_package(PythonInterp ${PYTHONLIBS_VERSION_STRING} EXACT REQUIRED)