caffe icon indicating copy to clipboard operation
caffe copied to clipboard

Could NOT find Boost (missing: system thread filesystem) (found suitable version "1.70.0", minimum required is "1.54")

Open movie3105 opened this issue 6 years ago • 18 comments

CMake Error at C:/Program Files/CMake/share/cmake-3.15/Modules/FindPackageHandleStandardArgs.cmake:137 (message): Could NOT find Boost (missing: system thread filesystem) (found suitable version "1.70.0", minimum required is "1.54") Call Stack (most recent call first): C:/Program Files/CMake/share/cmake-3.15/Modules/FindPackageHandleStandardArgs.cmake:378 (_FPHSA_FAILURE_MESSAGE) C:/Program Files/CMake/share/cmake-3.15/Modules/FindBoost.cmake:2142 (find_package_handle_standard_args) cmake/Dependencies.cmake:8 (find_package) CMakeLists.txt:80 (include)

-- Configuring incomplete, errors occurred! See also "E:/Program/caffe/build/CMakeFiles/CMakeOutput.log". ERROR: Configure failed

can someone tell me how to solve this error ?

movie3105 avatar Jul 18 '19 09:07 movie3105

have you solved it now? I met it too.

firebrain7 avatar Oct 23 '19 14:10 firebrain7

I also have this issue with version 1.71.0.

seanquijote avatar Nov 06 '19 02:11 seanquijote

Same issue here with 1.71.0

josthoma avatar Nov 10 '19 15:11 josthoma

Same issue with 1.71.0 when trying to install lightGBM for GPU:

Found OpenCL: C:/Program Files/NVIDIA GPU Computing Toolkit/CUDA/v10.2/lib/x64/OpenCL.lib (found version "1.2") OpenCL include directory: C:/Program Files/NVIDIA GPU Computing Toolkit/CUDA/v10.2/include CMake Error at C:/Program Files (x86)/CMake/share/cmake-3.16/Modules/FindPackageHandleStandardArgs.cmake:146 (message): Could NOT find Boost (missing: filesystem system) (found suitable version "1.71.0", minimum required is "1.56.0") Call Stack (most recent call first): C:/Program Files (x86)/CMake/share/cmake-3.16/Modules/FindPackageHandleStandardArgs.cmake:393 (_FPHSA_FAILURE_MESSAGE) C:/Program Files (x86)/CMake/share/cmake-3.16/Modules/FindBoost.cmake:2165 (find_package_handle_standard_args) CMakeLists.txt:100 (find_package)

juliuskittler avatar Nov 23 '19 23:11 juliuskittler

This helped: https://stackoverflow.com/questions/57870032/cmake-v3-15-3-cannot-find-boost-v1-71-0

I had to specify my path C:\boost\boost_1_71_0 as boost directory.

juliuskittler avatar Nov 23 '19 23:11 juliuskittler

Where to Specify??

npav5057 avatar Mar 05 '20 17:03 npav5057

Same issue here with 1.72.0

dererror33 avatar Apr 15 '20 15:04 dererror33

I'm having the same issue with 1.72.0, and I tried everything, but it still doesn't work.

zavodnyrichard avatar Apr 25 '20 10:04 zavodnyrichard

I have my Windows to locate the Boost with CMake by adding below in the Windows Environment Variables:

Variable name: Boost_INCLUDE_DIR Variable value: \libs\headers eg. C:\local\boost_1_73_0\libs\headers

Variable name: BOOST_ROOT Variable value: eg. C:\local\boost_1_73_0

Open a new Command prompt and install the lightgbm (gpu mode) again.

cupofjava2 avatar May 03 '20 12:05 cupofjava2

Today I had the same problem and I just added

set(Boost_USE_STATIC_LIBS ON)

to my CMakeLists.txt which solved the issue for me. Perhaps this is necessary to tell CMake since regex is one of the few Boost components which is not header-only. Therefore you need to link against something which is not required in case of header-only libraries.

Also, in my opinion it is bad to specify host dependent paths, like @juliuskittler told in his solution. This blows up manually tackled set up phases.

EDIT: Equivalent to my suggestion is passing an argument like here: https://stackoverflow.com/a/57875055/6346852

Necktschnagge avatar Nov 02 '20 13:11 Necktschnagge

Today Same problem with CMake 3.20 Boost 1.75.0 under windows 10 and got this error:

Selecting Windows SDK version 10.0.19041.0 to target Windows 10.0.19042.
CMake Error at C:/CMake/share/cmake-3.20/Modules/FindPackageHandleStandardArgs.cmake:230 (message):
  Could NOT find Boost (missing: chrono system) (found version "1.75.0")
Call Stack (most recent call first):
  C:/CMake/share/cmake-3.20/Modules/FindPackageHandleStandardArgs.cmake:594 (_FPHSA_FAILURE_MESSAGE)
  C:/CMake/share/cmake-3.20/Modules/FindBoost.cmake:2344 (find_package_handle_standard_args)
  CMakeLists.txt:88 (FIND_PACKAGE)

Have tried these kind of things but same error. BOOST_DIR Boost_INCLUDE_DIRS - Boost include directories Boost_LIBRARY_DIRS - Link directories for Boost libraries

set(Boost_USE_STATIC_LIBS ON) in CMakeLists.txt

niva-xx-zz avatar Mar 19 '21 19:03 niva-xx-zz

I met the same problem in 1.72.0

JustBeLeo avatar Apr 08 '21 11:04 JustBeLeo

Hi everyone. I ran into this problem. Openning the CMakeCache.txt gave me this line

//The directory containing a CMake configuration file for Boost.
Boost_DIR:PATH=Boost_DIR-NOTFOUND

You guys should check this line. From the line, we can see the Cmake can't fine the cmake configuration of boost, which should be some where called "boost_dir".

I follow this tutorial because I don't have Visual Studio to build the libraries. You can build yourself with gcc https://gist.github.com/sim642/29caef3cc8afaa273ce6 After that, I have a "cmake" folder inside the lib folder after building.

I set the environment variable: BOOST_DIR with value "C:\development\boost\lib\cmake" . Remember "lib" is the folder of built libraries. I hope this helps.

ntd252 avatar May 14 '21 07:05 ntd252

for those who install boost using vcpkg, dont forget to add the toolchain. while the error seems to find the boost, it's file structure is totally different, thus producing confusing results making you think you need to add use_static=on. just add vcpkg.cmake toolchain. add vcpkg to path is not enough.

tothedistance avatar Nov 05 '21 02:11 tothedistance

Hi, I am using macOS 12.3 Even if I set set(Boost_USE_STATIC_LIBS ON) in CMakeLists.txt The errors are still there :

-- The C compiler identification is AppleClang 13.1.6.13160021
-- The CXX compiler identification is AppleClang 13.1.6.13160021
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: /Library/Developer/CommandLineTools/usr/bin/cc - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /Library/Developer/CommandLineTools/usr/bin/c++ - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
CMake Error at /usr/local/lib/cmake/Boost-1.72.0/BoostConfig.cmake:120 (find_package):
  Found package configuration file:

    /usr/local/lib/cmake/boost_filesystem-1.72.0/boost_filesystem-config.cmake

  but it set boost_filesystem_FOUND to FALSE so package "boost_filesystem" is
  considered to be NOT FOUND.  Reason given by package:

  No suitable build variant has been found.

  The following variants have been tried and rejected:

  * libboost_filesystem-clang-darwin100-mt-d-x64-1_72.dylib (clang-darwin100,
  detected clang-darwin131, set Boost_COMPILER to override)

  * libboost_filesystem-clang-darwin100-mt-d-x64-1_72.a (clang-darwin100,
  detected clang-darwin131, set Boost_COMPILER to override)

  * libboost_filesystem-clang-darwin100-mt-s-x64-1_72.a (clang-darwin100,
  detected clang-darwin131, set Boost_COMPILER to override)

  * libboost_filesystem-clang-darwin100-mt-sd-x64-1_72.a (clang-darwin100,
  detected clang-darwin131, set Boost_COMPILER to override)

  * libboost_filesystem-clang-darwin100-mt-x64-1_72.dylib (clang-darwin100,
  detected clang-darwin131, set Boost_COMPILER to override)

  * libboost_filesystem-clang-darwin100-mt-x64-1_72.a (clang-darwin100,
  detected clang-darwin131, set Boost_COMPILER to override)

Call Stack (most recent call first):
  /usr/local/lib/cmake/Boost-1.72.0/BoostConfig.cmake:185 (boost_find_component)
  /usr/local/Cellar/cmake/3.21.4/share/cmake/Modules/FindBoost.cmake:594 (find_package)
  CMakeLists.txt:8 (find_package)

winkee01 avatar Mar 31 '22 03:03 winkee01

您好,邮件已收到,谢谢!

lovie123 avatar Mar 31 '22 03:03 lovie123

and finally, I have to use -DBoost_NO_BOOST_CMAKE=ON

winkee01 avatar Mar 31 '22 03:03 winkee01

这是来自QQ邮箱的假期自动回复邮件。 谢谢,您的邮件已收到,尽快给您回复。

xiaolin1990 avatar Mar 31 '22 03:03 xiaolin1990