Skip to content

Instantly share code, notes, and snippets.

@jegger
Created July 8, 2019 06:34
Show Gist options
  • Save jegger/34d6a68b88f633d3437984a8a7e12dca to your computer and use it in GitHub Desktop.
Save jegger/34d6a68b88f633d3437984a8a7e12dca to your computer and use it in GitHub Desktop.
pygraphviz installation into virtualenv mac
# If you run into the the following error while installing pygraphviz into a virtualenv
# (on macOs, python3)
#
# pygraphviz/graphviz_wrap.c:2987:10: fatal error: 'graphviz/cgraph.h' file not found
# #include "graphviz/cgraph.h"
# ^~~~~~~~~~~~~~~~~~~
# 1 error generated.
# error: command 'clang' failed with exit status 1
# - Install graphviz via brew
# - Download the pygraphviz source code
# - Compile the package without virtualenv: python3 setup.py build
# - Now do venv/bin/python setup.py install (with your virtualenv python)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment