繁体   English   中英

Cmake找不到Boost文件夹

[英]Cmake can't find Boost Folder

我正在使用Windows 7 - 64位,我正在尝试构建一个项目。 当我使用cmake时,我得到了错误

CMake Error at C:/Program Files (x86)/CMake 2.8/share/cmake-2.8/Modules/FindBoos
t.cmake:1191 (message):
  Unable to find the requested Boost libraries.

  Unable to find the Boost header files.  Please set BOOST_ROOT to the root
  directory containing Boost or BOOST_INCLUDEDIR to the directory containing
  Boost's headers.
Call Stack (most recent call first):
  src/CMakeLists.txt:310 (find_package)


CMake Error at src/CMakeLists.txt:312 (message):
  Boost C++ libraries not found.  Please install or try setting BOOST_ROOT

我已将变量设置为BOOST_ROOT到D:\\ MyProject \\ boost_1_43_0 \\ boost \\但我仍然得到这个。 我该如何解决这个问题。

将boost添加到项目的子文件夹中并不是定位增强的标准CMake实践。 我已经在程序文件中安装了x64 - MSVC 2010,CMake会自动找到它。

Boost_DIR : C:/Program Files/Boost/share/cmake/boost
Boost_INCLUDE_DIR : C:/Program Files/Boost/include

您也可以尝试在系统环境变量级别设置Boost_DIR。

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM