Macos Install Pycairo

Macos Install Pycairo

When I try to install pycairo on my mac (10.14.2 Beta), I get the following error.

Can someone help troubleshoot?

I ran pip3 install pycairo, but I got an error when setup.py was run for pycairo.

I have cairo installed, but when I run cairo in the terminal, it tells me that the command isn't found.

3

1 Answer

From your screenshots it seems that you haven't installed cairo before, which it seems to be needed to run pycairo.

Please try brew install cairo and then try to run pip install pycairo.

If you run into the same problem that I did, and still find errors in installing pycairo due to a missing libffi packaged, I found that following the solutions here solved my issue. Briefly, I reinstalled libffi, added the path to libffi.pc to PATH, and then tried reinstalling pycairo in a new terminal session.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Sophia Al-Mansoor
Author

Sophia Al-Mansoor

Sophia analyzes international trade, startup ecosystems, retail transformation, and supply chain logistics for modern digital publications.