Pillow: libopenjp2.so.7: cannot open shared object file: No such file or directory

半城伤御伤魂 提交于 2019-12-06 03:02:21

问题


I have a fresh, minimal Raspbian Stretch install. I have installed the PIXEL-dekstop by running sudo apt-get install --no-install-recommends xserver-xorg and am now trying to use Pillow in Python. Pillow was installed by running sudo apt-get install pip3 and then sudo pip3 install Pillow. Whenever I try from PIL import Image I get the error ImportError: libopenjp2.so.7: cannot open shared object file: No such file or directory.

I have attempted to reinstall Pillow under different versions but it does not help. I have also enabled apt-get sources in /etc/apt/sources.txt and ran sudo apt-get build-dep python-imaging, which also did not help. Any help is appreciated.

Python version: 3.5.3, current Pillow version: 4.3.0


回答1:


What worked for me was running :

sudo apt-get install libopenjp2-7

Good Luck!



来源:https://stackoverflow.com/questions/48012582/pillow-libopenjp2-so-7-cannot-open-shared-object-file-no-such-file-or-directo

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!