Skip to content
Snippets Groups Projects
Commit f36a9891 authored by Guilhem Saurel's avatar Guilhem Saurel
Browse files

modernize if available

parent 17046a1b
No related branches found
No related tags found
No related merge requests found
Pipeline #20366 canceled
......@@ -32,19 +32,7 @@ COMPUTE_PROJECT_ARGS(PROJECT_ARGS LANGUAGES CXX)
PROJECT(${PROJECT_NAME} ${PROJECT_ARGS})
IF(BUILD_PYTHON_INTERFACE)
set(PYTHON_COMPONENTS Interpreter)
if(CMAKE_VERSION VERSION_LESS "3.18")
# Development.Module only require headers, so it's best for our module
# But it's not available before CMake 3.18
set(PYTHON_COMPONENTS ${PYTHON_COMPONENTS} Development)
else()
set(PYTHON_COMPONENTS ${PYTHON_COMPONENTS} Development.Module)
endif()
if(NOT CMAKE_VERSION VERSION_LESS "3.14")
# NumPy provides a standard CMake imported target,
# But it's not available before CMake 3.14
set(PYTHON_COMPONENTS ${PYTHON_COMPONENTS} NumPy)
endif()
set(PYTHON_COMPONENTS Interpreter Development.Module NumPy)
FINDPYTHON()
ADD_PROJECT_DEPENDENCY(pinocchio)
STRING(REGEX REPLACE "-" "_" PY_NAME ${PROJECT_NAME})
......
Subproject commit 7c6837de72c724329c93a1d4f107767240d58727
Subproject commit 9d6ba210c26a330e7bfff9efea9e41c69beb7025
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment