我正在尝试在我的计算机(OS X 10.10)上编译 dlib,但遇到了一个错误,我不知道如何修复。当我运行 CMake 时,我得到了这个输出
Configuring cmake ...
-- The C compiler identification is AppleClang 7.0.0.7000176
-- The CXX compiler identification is AppleClang 7.0.0.7000176
-- Check for working C compiler: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/cc
-- Check for working C compiler: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/cc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Check for working CXX compiler: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/c++
-- Check for working CXX compiler: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Could NOT find Boost
-- Boost version: 1.59.0
-- Found the following Boost libraries:
-- python
CMake Error at /usr/local/Cellar/cmake/3.3.2/share/cmake/Modules/FindPackageHandleStandardArgs.cmake:148 (message):
Could NOT find PythonLibs: Found unsuitable version "2.7.10", but required
is at least "3.4" (found PYTHON_LIBRARY-NOTFOUND)
Call Stack (most recent call first):
/usr/local/Cellar/cmake/3.3.2/share/cmake/Modules/FindPackageHandleStandardArgs.cmake:386 (_FPHSA_FAILURE_MESSAGE)
/usr/local/Cellar/cmake/3.3.2/share/cmake/Modules/FindPythonLibs.cmake:205 (FIND_PACKAGE_HANDLE_STANDARD_ARGS)
/Users/gabriel/Devspace/dlib/dlib/add_python_module:64 (FIND_PACKAGE)
CMakeLists.txt:6 (include)
-- Configuring incomplete, errors occurred!
See also "/Users/gabriel/Devspace/dlib/tools/python/build/CMakeFiles/CMakeOutput.log".
error: cmake configuration failed!
首先,我想知道 CMake 是如何找不到 Boost 的,但在下一行中给出了我目前在我的计算机上安装的 boost 版本?其次,我想知道如何修复 pythonlibs 错误?我试过谷歌搜索,但主要是发现其他人有类似的错误,但不知道这意味着什么或如何解决它。任何帮助将不胜感激。谢谢