Having problems with installing manimlib by 3blue1brown. Pycairo runs into a problem

Viewed 798

I'm attempting to install the manimlib package by 3blue1brown for math animations, all goes well until the installation of pycairo

I have followed the instructions from https://github.com/3b1b/manim, downloading and installing all of the system requirements "ffmpeg, sox, latex and cairo"

I have also followed instructions to install the Microsoft Visual C++ Build Tools however the same error occurs.

I attempted to pip install manimlib and it displayed the errors below Many other tutorials for installing manimlib all gave me the same error.

Building wheels for collected packages: pycairo
Building wheel for pycairo (setup.py) ... error
ERROR: Complete output from command 'c:\users\jmcaw\appdata\local\programs\python\python37-32\python.exe' -u -c 'import setuptools, tokenize;__file__='"'"'C:\\Users\\jmcaw\\AppData\\Local\\Temp\\pip-install-nh2i0b16\\pycairo\\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\jmcaw\AppData\Local\Temp\pip-wheel-mzptag15' --python-tag cp37:
    ERROR: running bdist_wheel
    running build
    running build_py
    creating build
    creating build\lib.win32-3.7
    creating build\lib.win32-3.7\cairo
    copying cairo\__init__.py -> build\lib.win32-3.7\cairo
    copying cairo\__init__.pyi -> build\lib.win32-3.7\cairo
    copying cairo\py.typed -> build\lib.win32-3.7\cairo
    running build_ext
    building 'cairo._cairo' extension
    error: Microsoft Visual C++ 14.0 is required. Get it with "Microsoft Visual C++ Build Tools": https://visualstudio.microsoft.com/downloads/


  ----------------------------------------
ERROR: Failed building wheel for pycairo
Running setup.py clean for pycairo
Failed to build pycairo
Installing collected packages: pycairo, manimlib
    Found existing installation: pycairo 1.18.1
    Uninstalling pycairo-1.18.1:
    Successfully uninstalled pycairo-1.18.1
    Running setup.py install for pycairo ... error
    ERROR: Complete output from command
'c:\users\jmcaw\appdata\local\programs\python\python37-32\python.exe' -u -c 'import setuptools, tokenize;__file__='"'"'C:\\Users\\jmcaw\\AppData\\Local\\Temp\\pip-install-nh2i0b16\\pycairo\\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\jmcaw\AppData\Local\Temp\pip-record-bsapizpe\install-record.txt' --single-version-externally-managed --compile:
     ERROR: running install
     running build
     running build_py
     creating build
     creating build\lib.win32-3.7
     creating build\lib.win32-3.7\cairo
     copying cairo\__init__.py -> build\lib.win32-3.7\cairo
     copying cairo\__init__.pyi -> build\lib.win32-3.7\cairo
     copying cairo\py.typed -> build\lib.win32-3.7\cairo
     running build_ext
     building 'cairo._cairo' extension
     error: Microsoft Visual C++ 14.0 is required. Get it with "Microsoft Visual C++ Build Tools": https://visualstudio.microsoft.com/downloads/


----------------------------------------
Rolling back uninstall of pycairo
Moving to c:\users\jmcaw\appdata\local\programs\python\python37-32\lib\site-packages\cairo\
from c:\users\jmcaw\appdata\local\programs\python\python37-32\lib\site-packages\~airo
Moving to c:\users\jmcaw\appdata\local\programs\python\python37-32\lib\site-packages\pycairo-1.18.1.dist-info\
from c:\users\jmcaw\appdata\local\programs\python\python37-32\lib\site-packages\~ycairo-1.18.1.dist-info
ERROR: Command "'c:\users\jmcaw\appdata\local\programs\python\python37-32\python.exe' -u -c 'import setuptools, tokenize;__file__='"'"'C:\\Users\\jmcaw\\AppData\\Local\\Temp\\pip-install-nh2i0b16\\pycairo\\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\jmcaw\AppData\Local\Temp\pip-record-bsapizpe\install-record.txt' --single-version-externally-managed --compile" failed with error code 1 in C:\Users\jmcaw\AppData\Local\Temp\pip-install-nh2i0b16\pycairo\

The installation on pycairo on its own works when using the file pycairo‑1.18.1‑cp37‑cp37m‑win32.whl from https://www.lfd.uci.edu/~gohlke/pythonlibs/#pycairo, however it appears to try and uninstall this and install the version 1.18.0 instead of the latest 1.18.1.

0 Answers
Related