Skip to content

Commit 3d6ca2e

Browse files
committed
[CMake] workaround boost bind warnings
1 parent d46da1d commit 3d6ca2e

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

Diff for: CMakeLists.txt

+6
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,12 @@ IF(BUILD_PYTHON_INTERFACE)
4343
STRING(REGEX REPLACE "-" "_" PY_NAME ${PROJECT_NAME})
4444
ADD_PROJECT_DEPENDENCY(dynamic-graph-python 4.0.0 REQUIRED)
4545
SET(CATKIN_REQUIRED_COMPONENTS ${CATKIN_REQUIRED_COMPONENTS} rospy)
46+
47+
IF(Boost_VERSION GREATER 107299 OR Boost_VERSION_MACRO GREATER 107299)
48+
# Silence a warning about a deprecated use of boost bind by boost >= 1.73
49+
# without dropping support for boost < 1.73
50+
ADD_DEFINITIONS(-DBOOST_BIND_GLOBAL_PLACEHOLDERS)
51+
ENDIF()
4652
ENDIF(BUILD_PYTHON_INTERFACE)
4753

4854
find_package(catkin REQUIRED COMPONENTS ${CATKIN_REQUIRED_COMPONENTS})

0 commit comments

Comments
 (0)