【发布时间】:2014-08-02 04:30:17
【问题描述】:
收到此错误:
sudo: unable to resolve host coderw@ll
-- Could NOT find PythonLibs (missing: PYTHON_LIBRARIES PYTHON_INCLUDE_DIRS)
CMake Error at /usr/share/cmake-2.8/Modules/FindPackageHandleStandardArgs.cmake:108
(message):
Could NOT find PythonInterp (missing: PYTHON_EXECUTABLE)
Call Stack (most recent call first):
/usr/share/cmake-2.8/Modules/FindPackageHandleStandardArgs.cmake:315
(_FPHSA_FAILURE_MESSAGE)
/usr/share/cmake-2.8/Modules/FindPythonInterp.cmake:139
(FIND_PACKAGE_HANDLE_STANDARD_ARGS)
Code/cmake/Modules/FindNumPy.cmake:10 (find_package)
CMakeLists.txt:114 (find_package)
-- Configuring incomplete, errors occurred!
See also "/home/coderwall/Desktop/rdkit/build/CMakeFiles/CMakeOutput.log".
See also "/home/coderwall/Desktop/rdkit/build/CMakeFiles/CMakeError.log".
我已经安装了:
- sudo apt-get install python-dev
-
环境变量已经设置如下:
PYTHON_INCLUDE_DIRS=/usr/include/python2.7 PYTHON_LIBRARIES=/usr/lib/python2.7/config/libpython2.7.so
python.h 的位置:/usr/lib/include/python2.7/python.h
python 库的位置:/usr/lib/python2.7/
如何解决这个问题?
【问题讨论】:
-
嗯,试试设置
PYTHON_EXECUTABLE=...? -
尝试并识别但仍然:
Could NOT find PythonLibs (missing: PYTHON_LIBRARIES PYTHON_INCLUDE_DIRS) -
能否将 rdkit 根 CMakeLists.txt 文件的代码包含在您的问题中?这可能会有所帮助。
标签: python python-2.7 cmake