【发布时间】:2017-03-23 15:31:49
【问题描述】:
我正在使用 CMake。我想将 Python3 库链接到我的项目。我用 homebrew 安装了 Python3,这样写CMakeLists.txt:
find_package(PythonLibs 3.6 REQUIRED)
然后它给了我一个错误:
Could NOT find PythonLibs: Found unsuitable version "2.7.10", but required
is at least "3.6" (found /usr/lib/libpython2.7.dylib)
此错误发生在 Mac OS X 上。谁能告诉我如何解决它?谢谢。
【问题讨论】:
-
你读过this answer吗?看起来很相似。
标签: python macos python-3.x cmake