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

[CMake] fix build with python

parent d304407c
No related branches found
Tags v2.7.0
No related merge requests found
Pipeline #1261 passed
......@@ -47,6 +47,17 @@ ADD_REQUIRED_DEPENDENCY("dynamic-graph >= 3.0.0")
ADD_REQUIRED_DEPENDENCY("sot-core >= 3.0.0")
ADD_REQUIRED_DEPENDENCY("sot-tools >= 2.0.0")
SET(BOOST_COMPONENTS filesystem system unit_test_framework)
OPTION (BUILD_PYTHON_INTERFACE "Build the python binding" ON)
IF(BUILD_PYTHON_INTERFACE)
FINDPYTHON()
ADD_REQUIRED_DEPENDENCY("dynamic-graph-python >= 3.0.0")
SET(BOOST_COMPONENTS ${BOOST_COMPONENTS} python)
INCLUDE_DIRECTORIES(${PYTHON_INCLUDE_PATH})
ENDIF(BUILD_PYTHON_INTERFACE)
# List plug-ins that will be compiled.
SET(plugins
zmpreffromcom
......@@ -66,18 +77,6 @@ LIST(APPEND plugins dynamic)
# Add dependency toward sot-dynamic-pinocchio library in pkg-config file.
PKG_CONFIG_APPEND_LIBS(${LIBRARY_NAME})
# Search for dependencies.
# Boost
SET(BOOST_COMPONENTS filesystem system unit_test_framework)
OPTION (BUILD_PYTHON_INTERFACE "Build the python binding" ON)
IF(BUILD_PYTHON_INTERFACE)
FINDPYTHON()
ADD_REQUIRED_DEPENDENCY("dynamic-graph-python >= 3.0.0")
SET(BOOST_COMPONENTS ${BOOST_COMPONENTS} python)
INCLUDE_DIRECTORIES(${PYTHON_INCLUDE_PATH})
ENDIF(BUILD_PYTHON_INTERFACE)
SEARCH_FOR_BOOST()
SEARCH_FOR_EIGEN()
......
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