ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question

Boost python not found when building cv_bridge under OSX

asked 2014-05-16 23:47:09 -0600

madmax gravatar image

I am having the problem that cv_bridge can't find my boost libraries although it must have found them for the packages before when installing hydro on OSX.
When I look into /usr/local/include I can see all the boost files and folders, also python.

What's the problem here?

When I print the output of my boost libraries it says none. CMAkeLists.txt:

cmake_minimum_required(VERSION 2.8)

find_package(catkin REQUIRED COMPONENTS rosconsole sensor_msgs)

find_package(Boost REQUIRED python)
find_package(OpenCV REQUIRED)
message("Include dirs of boost: " ${Boost_INCLUDE_DIRS} )
message("Libs of boost: " ${Boost_LIBRARIES} )


CMake Error at /usr/local/Cellar/cmake/ (message):
  Unable to find the requested Boost libraries.

  Boost version: 1.55.0

  Boost include path: /usr/local/include

  Could not find the following Boost libraries:


  No Boost libraries were found.  You may need to set BOOST_LIBRARYDIR to the
  directory containing Boost libraries or BOOST_ROOT to the location of
Call Stack (most recent call first):
  CMakeLists.txt:6 (find_package)

Include dirs of boost: /usr/local/include
Libs of boost:
edit retag flag offensive close merge delete



That cmakelists.txt works as expected over here. What version of OS X are you on? Also, I would start by `brew update`, `brew remove boost cmake`, `brew install boost cmake` to make sure nothing funky is going on with your installs.

demmeln gravatar image demmeln  ( 2014-05-18 04:12:20 -0600 )edit

Did you manage to solve this? I currently have the same problem. Thanks

CodePorter gravatar image CodePorter  ( 2014-06-12 14:51:17 -0600 )edit

1 Answer

Sort by ยป oldest newest most voted

answered 2014-06-13 04:31:42 -0600

demmeln gravatar image

Recent changes with the homebrew boost formula removed python from being built by default. You will have to manually brew install boost --with-python or brew reinstall boost --with-python . See

edit flag offensive delete link more


for now it is brew install boost-python

J.M.T. gravatar image J.M.T.  ( 2014-10-07 08:49:47 -0600 )edit

I just updated the rosdep rule for boost to include boost-python.

William gravatar image William  ( 2014-10-07 12:52:03 -0600 )edit

Question Tools

1 follower


Asked: 2014-05-16 23:47:09 -0600

Seen: 5,659 times

Last updated: Jun 13 '14