外部環境:ubuntu16.04, 64bits, 全局環境python2.7html
在虛擬環境(python3.5)中執行 pip install wordcloud 時安裝失敗,報錯:python
error: command 'x86_64-linux-gnu-gcc' failed with exit status 1 ---------------------------------------- Failed building wheel for wordcloud Running setup.py clean for wordcloud Failed to build wordcloud
解決方案:在外部環境執行 sudo apt-get install python3-dev ,再在虛擬環境中從新 pip install wordcloud 便可。linux
參考:ubuntu
http://www.cnblogs.com/canitang/p/7994184.htmlpython2.7