問題描述:
當使用pip安裝Pillow python3包時提示the headers or library files could not be found for zlib,原因是環境變量設置里找不到zip headers library files相關文件,所以編譯失敗導致的。
解決方法:
將對應的zip庫文件路徑設置到環境變量即可。
編輯.zshrc或者.bashrc將下面環境變量添加即可
export CPATH=`xcrun --show-sdk-path`/usr/include