ros-perception / vision_opencv

Apache License 2.0
543 stars 599 forks source link

Unable to find the requested Boost libraries : boost_python37 #341

Open Joechencc opened 4 years ago

Joechencc commented 4 years ago

I have error when boot python library. When do I fix this bug? I have python3 installed

Python 3.6.9 (default, Apr 18 2020, 01:56:04) [GCC 8.4.0] on linux Type "help", "copyright", "credits" or "license" for more information.

ERROR MESSAGE:

CMake Error at /usr/share/cmake-3.10/Modules/FindBoost.cmake:1947 (message): Unable to find the requested Boost libraries.

Boost version: 1.65.1

Boost include path: /usr/include

Could not find the following Boost libraries:

      boost_python37

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 Boost. Call Stack (most recent call first): vision_opencv/cv_bridge/CMakeLists.txt:11 (find_package)

jacksonhshields commented 4 years ago

I had the same problem. What ROS version are you using? The default branch is set to noetic, if you are using melodic, try checking out the melodic branch

Joechencc commented 4 years ago

It is melodic. However the core is ARM64

chinedu0507 commented 4 years ago

I had the same issue (with noetic), I fixed it by commenting out lines 11 and 12 in the CMakeLists.txt file in the /home/pc_name/catkin_ws/src/vision_opencv/cv_bridge directory. I am running Pop OS 20.04 (based on Ubuntu 20.04 (Focal Fossa)).

I was able to successfully compile the package after that. I hope this helps.

doubleZ0108 commented 3 years ago

@chinedu0507 he said just right, you can comment out find_package(Boost REQUIRED python37) and use find_package(Boost REQUIRED python) below instead. Then in my case I fix my error. Hope this state why and help.

TheMaakarov commented 3 years ago

I had the same issue (with noetic), I fixed it by commenting out lines 11 and 12 in the CMakeLists.txt file in the /home/pc_name/catkin_ws/src/vision_opencv/cv_bridge directory. I am running Pop OS 20.04 (based on Ubuntu 20.04 (Focal Fossa)).

I was able to successfully compile the package after that. I hope this helps.

As an alternative, this worked for me in Ubuntu 18.04 (Melodic): https://answers.ros.org/question/344951/could-not-find-the-following-boost-libraries-boost_python3/

xela1601 commented 2 years ago

@chinedu0507 he said just right, you can comment out find_package(Boost REQUIRED python37) and use find_package(Boost REQUIRED python) below instead. Then in my case I fix my error. Hope this state why and help.

this helped me resolving this, thank you. Also you can use

sed -i '11,12 s/^/#/' cv_bridge/CMakeLists.txt

to comment out these lines through sed. Very handy if you use Docker e.g.