0

我在准备使用 cmake 脚本的 firebreath 视觉工作室解决方案时遇到问题。问题似乎出在 findboost.cmake 模块上。这是我得到的错误:

CMake Error at C:/Users/chenning/cmake-2.8.8-win32-x86/share/cmake-2.8/Modules/F
indBoost.cmake:1200 (message):
  Unable to find the requested Boost libraries.

  Boost version: 1.50.0

  Boost include path: c:/boost

  The following Boost libraries could not be found:

          boost_date_time

  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.

我的 boost 根目录应该是 c:\boost。

测试该模块的最基本脚本或命令行(Windows 7)是什么?我需要找出参数的正确值:BOOST_ROOT、BOOST_INCLUDE_DIR 和 BOOST_LIBRARYDIR。

提前谢谢,克里斯蒂安

4

1 回答 1

1

你可以在这里看到一些例子

您也可以使用 boost 调试选项:

set (Boost_DEBUG Yes)

我确定,如果这个版本的 CMake 能够搜索 Boost-1.50,那么你可以使用

    set(Boost_ADDITIONAL_VERSIONS "1.50" "1.50.0")

这可以帮助找到最新版本的 Boost

于 2012-07-28T16:55:48.600 回答