CMakeLists.txt 1.44 KB
Newer Older
Guilhem Saurel's avatar
Guilhem Saurel committed
1
2
CMAKE_MINIMUM_REQUIRED(VERSION 2.6)

3
INCLUDE(cmake/base.cmake)
Guilhem Saurel's avatar
Guilhem Saurel committed
4
INCLUDE(cmake/boost.cmake)
5
INCLUDE(cmake/test.cmake)
6
INCLUDE(cmake/python.cmake)
7
INCLUDE(cmake/hpp.cmake)
8

9
SET(PROJECT_ORG loco-3d)
10
SET(PROJECT_NAME curves)
11
SET(PROJECT_DESCRIPTION
12
13
  "template based classes for creating and manipulating spline and bezier curves. Comes with extra options specific to end-effector trajectories in robotics."
  )
14

15
16
# Disable -Werror on Unix for now.
SET(CXX_DISABLE_WERROR True)
17

18
SETUP_HPP_PROJECT()
19

Guilhem Saurel's avatar
Guilhem Saurel committed
20
ADD_REQUIRED_DEPENDENCY(eigen3)
21
22
23
24
25
OPTION(CURVES_WITH_PINOCCHIO_SUPPORT "Build with pinocchio support" OFF)
IF(CURVES_WITH_PINOCCHIO_SUPPORT)
  ADD_REQUIRED_DEPENDENCY(pinocchio)
ENDIF(CURVES_WITH_PINOCCHIO_SUPPORT)

Guilhem Saurel's avatar
Guilhem Saurel committed
26

Guilhem Saurel's avatar
Guilhem Saurel committed
27
SET(BOOST_COMPONENTS unit_test_framework serialization)
Guilhem Saurel's avatar
Guilhem Saurel committed
28

Guilhem Saurel's avatar
Guilhem Saurel committed
29
OPTION (BUILD_PYTHON_INTERFACE "Build the python binding" ON)
30
IF(BUILD_PYTHON_INTERFACE)
Guilhem Saurel's avatar
Guilhem Saurel committed
31
32
33
34
  FINDPYTHON()
  INCLUDE_DIRECTORIES(SYSTEM ${PYTHON_INCLUDE_DIRS})

  STRING(REGEX REPLACE "-" "_" PY_NAME ${PROJECT_NAME})
35

Guilhem Saurel's avatar
Guilhem Saurel committed
36
37
  ADD_REQUIRED_DEPENDENCY("eigenpy")
  SET(BOOST_COMPONENTS ${BOOST_COMPONENTS} python)
38
39
ENDIF(BUILD_PYTHON_INTERFACE)

40
41
42
#find_package(Boost 1.58 REQUIRED unit_test_framework system serialization)
#SET(BOOST_COMPONENTS unit_test_framework serialization)

Guilhem Saurel's avatar
Guilhem Saurel committed
43
44
SEARCH_FOR_BOOST()
INCLUDE_DIRECTORIES(SYSTEM ${Boost_INCLUDE_DIRS})
45

46
47
48
49
IF(BUILD_PYTHON_INTERFACE)
  ADD_SUBDIRECTORY(python)
ENDIF(BUILD_PYTHON_INTERFACE)

50
ADD_SUBDIRECTORY(include/curves)
51
ADD_SUBDIRECTORY(tests)
52

53
SETUP_HPP_PROJECT_FINALIZE()