CMake FIND_PACKAGE succeeds but returns wrong path

后端 未结 6 1404
日久生厌
日久生厌 2020-12-14 19:57

I\'m trying to have CMake 2.8.6 link to boost::program_options using the following code in my CMakeLists.txt

FIND_PACKAGE(Boost COMPONENTS program_options RE         


        
6条回答
  •  无人及你
    2020-12-14 20:45

    This problem occurs when using some older versions of boost with cmake-2.8.6-rc2 or later, where the boost package finding code was changed.

    The problem can be worked around by specifying -DBoost_NO_BOOST_CMAKE=ON on the cmake command line.

    The actual commit where this problem is introduced is 7da796d1fdd7cca07df733d010cd343f6f8787a9, and can be viewed here.

提交回复
热议问题