CMakeLists.txt 1.42 KB
Newer Older
Guilhem Saurel's avatar
Guilhem Saurel committed
1
# Copyright 2010-2020, Florent Lamiraux, Thomas Moulard, Olivier Stasse, Guilhem Saurel, JRL, CNRS/AIST, LAAS-CNRS
florent's avatar
florent committed
2

Guilhem Saurel's avatar
Guilhem Saurel committed
3 4 5 6 7 8
CMAKE_MINIMUM_REQUIRED(VERSION 2.8)

SET(PROJECT_NAMESPACE stack-of-tasks)
SET(PROJECT_NAME dynamic-graph-python)
SET(PROJECT_DESCRIPTION "Dynamic graph library Python bindings")
SET(PROJECT_URL "http://github.com/${PROJECT_NAMESPACE}/${PROJECT_NAME}")
florent's avatar
florent committed
9

10
SET(PROJECT_USE_CMAKE_EXPORT TRUE)
11 12
SET(CUSTOM_HEADER_DIR "dynamic-graph/python")
SET(CXX_DISABLE_WERROR TRUE)
Guilhem Saurel's avatar
Guilhem Saurel committed
13
SET(DOXYGEN_USE_MATHJAX YES)
14

15
INCLUDE(cmake/base.cmake)
Thomas Moulard's avatar
Thomas Moulard committed
16
INCLUDE(cmake/boost.cmake)
17
INCLUDE(cmake/eigen.cmake)
18 19
INCLUDE(cmake/python.cmake)
INCLUDE(cmake/test.cmake)
Guilhem Saurel's avatar
Guilhem Saurel committed
20
INCLUDE(cmake/sphinx.cmake)
florent's avatar
florent committed
21

22 23
SET(PKG_CONFIG_ADDITIONAL_VARIABLES plugindir ${PKG_CONFIG_ADDITIONAL_VARIABLES})

24 25
COMPUTE_PROJECT_ARGS(PROJECT_ARGS LANGUAGES CXX)
PROJECT(${PROJECT_NAME} ${PROJECT_ARGS})
florent's avatar
florent committed
26

Guilhem Saurel's avatar
Guilhem Saurel committed
27
FINDPYTHON()
Guilhem Saurel's avatar
Guilhem Saurel committed
28
INCLUDE_DIRECTORIES(SYSTEM ${PYTHON_INCLUDE_DIRS})
Guilhem Saurel's avatar
Guilhem Saurel committed
29

30
ADD_REQUIRED_DEPENDENCY(eigen3)
31
ADD_PROJECT_DEPENDENCY(dynamic-graph 3.8.1 REQUIRED)
florent's avatar
florent committed
32

33 34 35 36
# manually append to the .pc dependencies for now
# ref https://github.com/jrl-umi3218/jrl-cmakemodules/issues/320
_ADD_TO_LIST(_PKG_CONFIG_REQUIRES "dynamic-graph >= 3.8.1" ",")

37 38
PKG_CONFIG_APPEND_LIBS("dynamic-graph-python")

39
SET(BOOST_COMPONENTS filesystem system thread program_options unit_test_framework python)
40 41
SEARCH_FOR_BOOST()

florent's avatar
florent committed
42
ADD_SUBDIRECTORY(src)
43
ADD_SUBDIRECTORY(include/${CUSTOM_HEADER_DIR})
Thomas Moulard's avatar
Thomas Moulard committed
44
ADD_SUBDIRECTORY(doc)
45
ADD_SUBDIRECTORY(unitTesting)