zoukankan      html  css  js  c++  java
  • Win7 x64安装Paramiko

    先说一下我的环境:
    win7 x64 旗舰版、Python3.5.0、pip8.1.0
    pip install paramiko时报错如下:
    大概意思:
    blablabla...
    反正大概意思就是少GMP or MPIR?
    warning: GMP or MPIR library not found; Not building Crypto.PublicKey._fastmath.
    上面的问题貌似是C++版本低导致pycrypto安装不成功?(我也不知道,Google一上午都让我装Visual c++)
    翻了好多Stack Overflow的答案。。。最后找到一个:
    用下面的链接安装解决:(From:=>Github:https://github.com/sfbahr/PyCrypto-Wheels
    pip install --use-wheel --no-index --find-links=https://github.com/sfbahr/PyCrypto-Wheels/raw/master/pycrypto-2.6.1-cp35-none-win_amd64.whl pycrypto
    用上面的方式安装pycrypto之后
    再使用 pip install paramiko
    看到上面的图显示安装成功了。。。
    But...
    import paramiko的时候又报错了。。。(囧。。。我的一上午啊!!!) 
     Google到一个解决方法如下,亲测有效:(From:=>Github:https://github.com/dlitz/pycrypto/pull/46
    打开:%PythonHome%Python35Libsite-packagesCryptoRandomOSRNG t.py 文件
    将28行按下面修改:
    import winrandom ==> from Crypto.Random.OSRNG import winrandom 
    问题最终解决:
     
     
  • 相关阅读:
    多态
    java8的十大新特性
    Floyd最短路径算法
    ES6(六)函数扩展
    ES6(五)数组扩展
    ES6(四)数值扩展
    ES6(一)解构赋值
    store封装
    ipad方案
    pyinstaller编译打包为pyd
  • 原文地址:https://www.cnblogs.com/panfb/p/8411057.html
Copyright © 2011-2022 走看看