error: Unable to find vcvarsall.bat
依照
https://github.com/robotframework/SSHLibrary
1. 先安装 pip
c:\Python27\Scripts>pip install robotframework-sshlibrary
error: Unable to find vcvarsall.bat
----------------------------------------
Command "C:\Python27\python.exe -c "import setuptools, tokenize;__file__='c
:\\users\\clchen\\appdata\\local\\temp\\pip-build-vc3qmm\\pycrypto\\setup.py';ex
ec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'
), __file__, 'exec'))" install --record c:\users\clchen\appdata\local\temp\pip-p
rkrxq-record\install-record.txt --single-version-externally-managed --compile" f
ailed with error code 1 in c:\users\clchen\appdata\local\temp\pip-build-vc3qmm\p
ycrypto
3. 认真看下,Notice that on Windows you should still install PyCrypto manually first. on
https://github.com/robotframework/SSHLibrary
于是到https://github.com/robotframework/SSHLibrary/blob/master/INSTALL.rst里面,找到了
PyCrypto安装包的下载地址:
http://www.voidspace.org.uk/python/modules.shtml#pycrypto
The PyCrypto 2.6 files are all bdist_wininst created with MS Visual Studio 2008 and 2010 (for 3.3). The binaries don't include MPIR / GMP _fastmath.
- PyCrypto 2.6 for Python 2.6 32bit
- PyCrypto 2.6 for Python 2.6 32bit (asc signature)
- PyCrypto 2.6 for Python 2.6 64bit
- PyCrypto 2.6 for Python 2.6 64bit (asc signature)
- PyCrypto 2.6 for Python 2.7 32bit
- PyCrypto 2.6 for Python 2.7 32bit (asc signature)
- PyCrypto 2.6 for Python 2.7 64bit
- PyCrypto 2.6 for Python 2.7 64bit (asc signature)
- PyCrypto 2.6 for Python 3.2 32bit
- PyCrypto 2.6 for Python 3.2 32bit (asc signature)
- PyCrypto 2.6 for Python 3.2 64bit
- PyCrypto 2.6 for Python 3.2 64bit (asc signature)
- PyCrypto 2.6 for Python 3.3 32bit
- PyCrypto 2.6 for Python 3.3 32bit (asc signature)
- PyCrypto 2.6 for Python 3.3 64bit
- PyCrypto 2.6 for Python 3.3 64bit (asc signature)
下载下来,先安装这个exe
然后:重新执行
cd c:\Python27\Scripts (python本机的安装路径c:\Python27)
c:\Python27\Scripts>pip install robotframework-sshlibrary
sshlibrary 安装成功了
c:\Python27\Scripts>pip install robotframework-sshlibrary
Collecting robotframework-sshlibrary
Using cached robotframework-sshlibrary-2.1.1.tar.gz
Requirement already satisfied (use --upgrade to upgrade): robotframework in d:\python278\lib\site-pa
ckages (from robotframework-sshlibrary)
Collecting paramiko>=1.8.0 (from robotframework-sshlibrary)
Using cached paramiko-1.15.2-py2.py3-none-any.whl
Collecting ecdsa>=0.11 (from paramiko>=1.8.0->robotframework-sshlibrary)
Using cached ecdsa-0.13-py2.py3-none-any.whl
Requirement already satisfied (use --upgrade to upgrade): pycrypto!=2.4,>=2.1 in d:\python278\lib\si
te-packages (from paramiko>=1.8.0->robotframework-sshlibrary)
Installing collected packages: ecdsa, paramiko, robotframework-sshlibrary
Running setup.py install for robotframework-sshlibrary
Successfully installed ecdsa-0.13 paramiko-1.15.2 robotframework-sshlibrary-2.1.1