Seems that pycairo was branched to py2cairo for 2.x versions back in May. There are no pip or easy_install installation options for py2cairo. I've grabbed the latest py2cairo tar, as well as the cairo 1.8.10 package which is registered as a dependency. When I try to configure cairo first, it errors out at the end that it needs pkg-config. However, I also can't find a pkg-config install option in pip or easy_install. I'm at a complete loss as to how to get py2cairo installed. I'm doing this on Mac Snow Leopard.
You can try the Unofficial Windows Binaries for Python Extension Packages web site. You can find the last version of pycairo (1.15. 4) for Python 3.6. It is distributed as a wheel package so you should install it with no pain.
Installing Pycairo requires pkg-config and cairo including its headers. Here are some examples on how to install those for some platforms: Ubuntu/Debian: sudo apt install libcairo2-dev pkg-config python3-dev. macOS/Homebrew: brew install cairo pkg-config.
cairocffi is a CFFI-based drop-in replacement for Pycairo, a set of Python bindings and object-oriented API for cairo. Cairo is a 2D vector graphics library with support for multiple backends including image buffers, PNG, PostScript, PDF, and SVG file output.
pkg-config is a helper tool used when compiling applications and libraries.
If you are using macports then the package name is pkgconfig.
port install pkgconfig
See the portfile at : http://trac.macports.org/browser/trunk/dports/devel/pkgconfig/Portfile
The details are at : http://pkg-config.freedesktop.org/wiki/FrontPage
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With