File tree Expand file tree Collapse file tree 2 files changed +8
-6
lines changed Expand file tree Collapse file tree 2 files changed +8
-6
lines changed Original file line number Diff line number Diff line change @@ -7,7 +7,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
77## [ Unreleased]
88
99### Added
10- * Allow use of installed cereal and jrl-cmakemodules via cmake
10+ * Allow use of installed pybind11, cereal and jrl-cmakemodules via cmake
1111* Add compatibility with jrl-cmakemodules workspace ([ #339 ] ( https://github.com/Simple-Robotics/proxsuite/pull/339 ) )
1212* Specifically mention that timings are in microseconds ([ #340 ] ( https://github.com/Simple-Robotics/proxsuite/pull/340 ) )
1313* Fix cereal include directory in cmake ([ #340 ] ( https://github.com/Simple-Robotics/proxsuite/pull/340 ) )
Original file line number Diff line number Diff line change @@ -14,9 +14,12 @@ else()
1414 ${CMAKE_INSTALL_PREFIX} /${PYTHON_SITELIB} /${PROJECT_NAME} )
1515endif ()
1616
17- file (MAKE_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} /external/pybind11)
18- add_subdirectory (external/pybind11
19- ${CMAKE_CURRENT_BINARY_DIR} /external/pybind11)
17+ find_package (pybind11 CONFIG)
18+ if (NOT pybind11_FOUND)
19+ file (MAKE_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} /external/pybind11)
20+ add_subdirectory (external/pybind11
21+ ${CMAKE_CURRENT_BINARY_DIR} /external/pybind11)
22+ endif ()
2023
2124add_custom_target (${PROJECT_NAME} _python)
2225
@@ -92,8 +95,7 @@ function(CREATE_PYTHON_TARGET target_name COMPILE_OPTIONS dependencies)
9295 endif (BUILD_WITH_OPENMP_SUPPORT)
9396
9497 if (cereal_FOUND)
95- target_include_directories (${target_name} SYSTEM
96- PRIVATE ${CEREAL_INCLUDE_DIRS} )
98+ target_link_libraries (${target_name} PRIVATE cereal::cereal)
9799 else ()
98100 target_include_directories (
99101 ${target_name} SYSTEM
You can’t perform that action at this time.
0 commit comments