Pip install pygraphviz fails: Failed building wheel for pygraphviz

前端 未结 3 549
悲&欢浪女
悲&欢浪女 2020-12-19 01:57

I have troubles installing pygraphviz on macOS 10.10.5. I have a fully functional installation of Python 2.7.x, and I\'d like to run the test example of queueing-tool, which

相关标签:
3条回答
  • 2020-12-19 02:15

    Basically you need to download graphviz first using brew:

    brew install graphviz
    
    pip install graphviz
    
    pip install pygraphviz 
    

    You can also try using pip3 in place of pip just in case there is Python's version issue. Hope it helps.

    0 讨论(0)
  • 2020-12-19 02:18

    The comment by Andrew brought me on the right path. Thank you for that.

    It turns out that a detailed solution for installing pygraphviz on macOS is already available on stackoverflow, see this solution by teut.

    0 讨论(0)
  • 2020-12-19 02:27

    Try this :

    sudo apt-get install python-dev graphviz libgraphviz-dev pkg-config
    

    or the following might be needed if you're using Python 3:

    sudo apt-get install python3-dev graphviz libgraphviz-dev pkg-config
    

    then

    sudo pip install pygraphviz
    
    0 讨论(0)
提交回复
热议问题