简体   繁体   中英

Python 3 windows 10 pip install error

Hi i did a clean install of anconda 3 on windows 10.. but when i run from shell some install command by pip like "pip install pysam" i got that error message:

building 'pysam.libchtslib' extension
error: Unable to find vcvarsall.bat

    ----------------------------------------
Command "C:\Users\rando\Anaconda3\python.exe -u -c "import setuptools, tokenize;__file__='C:\\Users\\rando\\AppData\\Local\\Temp\\pip-build-dqrfhm5k\\pysam\\setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record C:\Users\rando\AppData\Local\Temp\pip-b5ng0_7u-record\install-record.txt --single-version-externally-managed --compile" failed with error code 1 in C:\Users\rando\AppData\Local\Temp\pip-build-dqrfhm5k\pysam\

I saw many posts about that and i understood that's could be a visual c++ problem.. i reinstalled it and also i installed Microsoft Visual C++ Compiler for Python but the situation isn't changed.. What can I do? Thanks for your help!

Look at Anaconda Faq . The topic How is CPython compiled? tells you which version of VC++ you need. So install the Visual Studio version for your python version.

Then you have to find Visual Studio Command Prompt in the startmenu (make sure you use the 64 bit version). From there you should be able to run vcvarsall.bat and then finally to install the package.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM