Django OS X Wrong JPEG library version: library is 80, caller expects 62 sorl.thumbnail

前端 未结 4 772
野趣味
野趣味 2021-02-06 17:48

Im using sorl.thumbnail for django locally on my mac and have been having trouble with PIL, but today i finally managed to get it installed - was some trouble with libjpeg.

4条回答
  •  梦如初夏
    2021-02-06 18:28

    I had a slightly different problem than the OP, but I wanted to share my solution here to help someone in the future.

    OS: OSX El Capitan I installed libjpeg-turbo from the precompiled binaries on their website. However, I did not know that I already had a different version of libjpeg installed on my mac. I was building my c file like this gcc myfile.c -o myfile.out -L /opt/libjpeg-turbo/lib -ljpeg. This got the library from the correct location, but the the linker was getting the included header file jpeglib.h from the pre-installed location. I changed my build command to this: gcc myfile.c -o myfile.out -I/opt/libjpeg-turbo/include/ -L /opt/libjpeg-turbo/lib -ljpeg and it worked. No more library is 80, caller expects 62!

提交回复
热议问题