首页
学习
活动
专区
圈层
工具
发布
首页
学习
活动
专区
圈层
工具
MCP广场
社区首页 >问答首页 >安装用于python windows的cmake时出错

安装用于python windows的cmake时出错
EN

Stack Overflow用户
提问于 2017-04-17 21:12:07
回答 5查看 17K关注 0票数 0

我有windows10和全新的Python 3.6.1。我尝试使用以下命令安装包Cmake 0.6.0 (另一个包atari-py需要)

代码语言:javascript
运行
复制
pip install cmake

但是我得到了一个错误。

我已经安装了这些包: pip、scikit-build、setuptools、轮子、pybdist。我的帐户名称中确实有一个外来符号(吸取了教训),但它在安装其他软件包时工作得很好。我不是一个熟练的windows管理员。

代码语言:javascript
运行
复制
Collecting cmake
  Using cached cmake-0.6.0.tar.gz
Building wheels for collected packages: cmake
  Running setup.py bdist_wheel for cmake: started
  Running setup.py bdist_wheel for cmake: finished with status 'error'
  Complete output from command C:\Python\Python36-32\python.exe -u -c "import setuptools, tokenize;__file__='C:\\Users\\Čejkis\\AppData\\Local\\Temp\\pycharm-packaging1\\cmake\\setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" bdist_wheel -d C:\Users\EJKIS~1\AppData\Local\Temp\tmp3br7eri7pip-wheel- --python-tag cp36:
  Traceback (most recent call last):
    File "C:\Python\Python36-32\lib\site-packages\skbuild\setuptools_wrap.py", line 405, in setup
      cmkr = cmaker.CMaker()
    File "C:\Python\Python36-32\lib\site-packages\skbuild\cmaker.py", line 67, in __init__
      "Problem with the CMake installation, aborting build.")

  Problem with the CMake installation, aborting build.

  ----------------------------------------
  Running setup.py clean for cmake
Failed to build cmake
Installing collected packages: cmake
  Running setup.py install for cmake: started
    Running setup.py install for cmake: finished with status 'error'
    Complete output from command C:\Python\Python36-32\python.exe -u -c "import setuptools, tokenize;__file__='C:\\Users\\Čejkis\\AppData\\Local\\Temp\\pycharm-packaging1\\cmake\\setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record C:\Users\EJKIS~1\AppData\Local\Temp\pip-5ql_x35g-record\install-record.txt --single-version-externally-managed --compile:
    Traceback (most recent call last):
      File "C:\Python\Python36-32\lib\site-packages\skbuild\setuptools_wrap.py", line 405, in setup
        cmkr = cmaker.CMaker()
      File "C:\Python\Python36-32\lib\site-packages\skbuild\cmaker.py", line 67, in __init__
        "Problem with the CMake installation, aborting build.")

    Problem with the CMake installation, aborting build.

    ----------------------------------------

  Failed building wheel for cmake
Command "C:\Python\Python36-32\python.exe -u -c "import setuptools, tokenize;__file__='C:\\Users\\Čejkis\\AppData\\Local\\Temp\\pycharm-packaging1\\cmake\\setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record C:\Users\EJKIS~1\AppData\Local\Temp\pip-5ql_x35g-record\install-record.txt --single-version-externally-managed --compile" failed with error code 1 in C:\Users\Čejkis\AppData\Local\Temp\pycharm-packaging1\cmake\
EN

回答 5

Stack Overflow用户

发布于 2020-08-13 08:50:29

如果上面关于pip3或pip install cmake的答案不起作用,请尝试

sudo apt-get install cmake

票数 5
EN

Stack Overflow用户

发布于 2020-03-12 17:37:55

python -m pip install --upgrade pip

然后你就可以运行

pip3 install cmake

这对我在Pyhton 3.8上很有效

票数 4
EN

Stack Overflow用户

发布于 2017-11-09 14:07:44

到今天为止,Python3.6的CMake轮子已经可用,pip install cmake有望正常工作。

背景

在你的第一篇文章中,还没有Python3.6的轮子,pip正试图使用源码发行版来构建轮子。

考虑到这一点:

cmake

  • we和
  • 只需将现有的二进制文件重新打包到CMake wheels

中,即可生成windows wheels本身的

  • 项目

..。您得到了一般的错误消息Problem with the CMake installation, aborting build

参考文献:

  • http://cmake-python-distributions.readthedocs.io
  • http://scikit-build.readthedocs.io/

在windows上安装atari-py

查看相应项目的文档和打开拉取请求,它看起来不支持windows。请参阅https://github.com/openai/atari-py

如果你想帮助这个项目并改善他们的windows支持,请让我知道,我可以试着给你一些指导来创建一个拉请求并简化他们的构建系统。

票数 1
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/43452203

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档