1
votes

i'm trying to utilize PIL to open a jpeg image and assign it to a Tkinter's label. However whenever i try to open the image i get the same problem as this guy I tried all the suggestions he got and also the ones i found here but it doesn't seem to fix, by installing PIL or Pillow(i tried that too) during the setup i get :

*** TKINTER support not available
*** JPEG support not available

And whenever i run my code i get an IOError: decoder jpeg not available I'm using python 2.7. Can someone provide a good method to make PIL or Pillow work with jpeg support? I've been googling extensively for two days, but all the possible fixes that i found don't seem to work for me

1
What is the result of the shell command find /usr/lib -name libjpeg.so on your Raspberry Pi?halex
@halex i get: /user/lib/libjpeg.so /user/lib/arm-linux-gnueabihf/libjpeg.so /user/lib/jvm/jdk-8-oracle-arm-vfp-hflt/jre/lib/arm/libjpeg.soMarco Bellan

1 Answers

0
votes

Installing libjpeg-dev should do the trick, as proposed by the link you provided. But if it doesn't help (I ran into that as well) you can consider upgrading to Pillow 3, it looks like you are running Pillow 2. This also helped me getting rid of the errors, don't know why exactly..