Could NOT find Boost (missing: python3) (found version "1.76.0") Windows 10

asked 2021-11-09 09:24:56 -0500

lora gravatar image

updated 2021-11-12 10:14:53 -0500

Hi everyone,

I need help solving this cmake boost python3 find problem when trying to compile cv_bridge. The colcon error message:

> colcon build --symlink-install --merge-install
--- stderr: cv_bridge
    CMake Error at C:/Program Files/CMake/share/cmake-3.22/Modules/FindPackageHandleStandardArgs.cmake:230 (message):
      Could NOT find Boost (missing: python3) (found version "1.76.0")
    Call Stack (most recent call first):
      C:/Program Files/CMake/share/cmake-3.22/Modules/FindPackageHandleStandardArgs.cmake:594 (_FPHSA_FAILURE_MESSAGE)
      C:/Program Files/CMake/share/cmake-3.22/Modules/FindBoost.cmake:2360 (find_package_handle_standard_args)
      CMakeLists.txt:32 (find_package)

What I have tried:

  • Installing different versions of boost: 1.58, 1.67, 1.76
  • Adding to Boost_INCLUDE_DIRS the path to the boost libraries in the CMakeLists.txt of cv_bridge:

      list(APPEND Boost_INCLUDE_DIRS "C:/Program Files/boost/boost_1_76_0")
      list(APPEND Boost_INCLUDE_DIRS "C:/Program Files/boost/boost_1_76_0/stage/lib")

  • Renaming the "libboost_python38-vc142-mt-gd-x64-1_76.lib" to "libboost_python38.lib" and "libboost_python3.lib"
  • Compiling Boost from source with bootstrap.bat and b2 or installing with the zip file.
  • Looked for answers here and elsewhere, which led me to try the above points

I have run out of ideas, please any help will be greatly appreciated!

edit retag flag offensive close merge delete


Hi @lora, hope you find an answer soon and tha you for your clear question. Have you checked this thread?

It discusses an issue with configuration vs installation. I know it’s not Windows but the error is very similar so thought it may help.

osilva gravatar image osilva  ( 2021-11-10 20:44:44 -0500 )edit
osilva gravatar image osilva  ( 2021-11-10 20:50:25 -0500 )edit

Hi @osilva, thanks for the links. I came across those as well. I modified FindBoost.cmake to include the set(Boost_NO_BOOST_CMAKE ON) for the version 1.70 and above and the renaming of the files was also inspired by it. Unfortunately the issue remains.

lora gravatar image lora  ( 2021-11-12 10:17:46 -0500 )edit