问题
I am trying to install Cairo for Python 2.7 in windows. I have installed igraph. There are binaries for this system on Christoph's site. I have downloaded the appropriate binary. How do I use pip to install the Cairo binary.
回答1:
I worked on it and figured it out. Here are detailed instructions. They will work (with appropriate modifications for any binary Python package:
Installing Cairo in Python for Windows.
- Go to site http://www.lfd.uci.edu, Chrisoph Gohlke’s site
- Download the appropriate version of Cairo to your Download folder
- Move the downloaded file from the Download folder to c:\Pythonxx\Scripts (xx is the version of Python)
- Open a command window. Not the Python command window.
- Enter cd c:\Pythonxx\Scripts. The system will give you a command line in that directory
- Enter: pip install downloaded-file-name, for example pycairo-1.10.0-cp27-none-win32.whl
来源:https://stackoverflow.com/questions/28269230/how-do-i-install-cairo-binaries-for-python