CMakeLists.txt 2.03 KB
Newer Older
Thomas Moulard's avatar
Thomas Moulard committed
1
# Copyright 2010, 2011, Florent Lamiraux, Thomas Moulard, JRL, CNRS/AIST
florent's avatar
florent committed
2
#
Thomas Moulard's avatar
Thomas Moulard committed
3
4
5
6
7
# This file is part of dynamic-graph-python.
# dynamic-graph-python is free software: you can redistribute it and/or
# modify it under the terms of the GNU Lesser General Public License
# as published by the Free Software Foundation, either version 3 of
# the License, or (at your option) any later version.
florent's avatar
florent committed
8
#
Thomas Moulard's avatar
Thomas Moulard committed
9
10
11
12
13
14
# dynamic-graph-python is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
# General Lesser Public License for more details.  You should have
# received a copy of the GNU Lesser General Public License along with
# dynamic-graph-python. If not, see <http://www.gnu.org/licenses/>.
florent's avatar
florent committed
15
16
17

CMAKE_MINIMUM_REQUIRED(VERSION 2.6)

18
INCLUDE(cmake/base.cmake)
Thomas Moulard's avatar
Thomas Moulard committed
19
INCLUDE(cmake/boost.cmake)
20
INCLUDE(cmake/eigen.cmake)
Thomas Moulard's avatar
Thomas Moulard committed
21
22
INCLUDE(cmake/pthread.cmake)
INCLUDE(cmake/cpack.cmake)
23
include(cmake/header.cmake)
Guilhem Saurel's avatar
Guilhem Saurel committed
24
include(cmake/python.cmake)
florent's avatar
florent committed
25

Thomas Moulard's avatar
Thomas Moulard committed
26
27
SET(PROJECT_NAME dynamic-graph-python)
SET(PROJECT_DESCRIPTION "Dynamic graph library Python bindings")
Guilhem Saurel's avatar
Guilhem Saurel committed
28
SET(PROJECT_URL "http://github.com/stack-of-tasks/dynamic-graph-python")
florent's avatar
florent committed
29

Guilhem Saurel's avatar
Guilhem Saurel committed
30
31
SET(DOXYGEN_USE_MATHJAX YES)

32
SET(CUSTOM_HEADER_DIR "dynamic-graph/python")
33
34
35
# Headers list.
SET(${PROJECT_NAME}_HEADERS
  include/dynamic-graph/python/interpreter.hh
36
  include/dynamic-graph/python/api.hh
37
38
  include/dynamic-graph/python/exception-python.hh

39
)
florent's avatar
florent committed
40

41
42
SET(PKG_CONFIG_ADDITIONAL_VARIABLES plugindir ${PKG_CONFIG_ADDITIONAL_VARIABLES})

Thomas Moulard's avatar
Thomas Moulard committed
43
SETUP_PROJECT()
florent's avatar
florent committed
44

45
FINDPYTHON(2.7 EXACT REQUIRED)
Guilhem Saurel's avatar
Guilhem Saurel committed
46

Thomas Moulard's avatar
Thomas Moulard committed
47
# Trigger dependency to dynamic-graph.
48
ADD_REQUIRED_DEPENDENCY("dynamic-graph >= 3.0.0")
florent's avatar
florent committed
49

50
51
52
# Add dependency toward dynamic graph library in pkg-config file.
PKG_CONFIG_APPEND_LIBS("dynamic-graph-python")

53
# Search for Boost.
54
SET(BOOST_COMPONENTS python filesystem system thread program_options unit_test_framework)
55
SEARCH_FOR_BOOST()
56
SEARCH_FOR_EIGEN()
57

florent's avatar
florent committed
58
ADD_SUBDIRECTORY(src)
59
ADD_SUBDIRECTORY(include)
Thomas Moulard's avatar
Thomas Moulard committed
60
ADD_SUBDIRECTORY(doc)
61
ADD_SUBDIRECTORY(unitTesting)
62

Thomas Moulard's avatar
Thomas Moulard committed
63
SETUP_PROJECT_FINALIZE()
64