Skip to content

Instantly share code, notes, and snippets.

@shingonoide
Created December 29, 2013 16:58
Show Gist options
  • Star 15 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save shingonoide/8172291 to your computer and use it in GitHub Desktop.
Save shingonoide/8172291 to your computer and use it in GitHub Desktop.
Trying to install PIL "pip install PIL" and got this error.
building '_imagingft' extension
gcc -pthread -fno-strict-aliasing -march=x86-64 -mtune=generic -O2 -pipe -fstack-protector --param=ssp-buffer-size=4 -DNDEBUG -march=x86-64 -mtune=generic -O2 -pipe -fstack-protecto
r --param=ssp-buffer-size=4 -fPIC -I/usr/include/freetype2 -IlibImaging -I/home/cafeerp/instances/cafeerp_ocb7/include -I/usr/local/include -I/usr/include -I/usr/include/python2.7 -
c _imagingft.c -o build/temp.linux-x86_64-2.7/_imagingft.o
_imagingft.c:73:31: fatal error: freetype/fterrors.h: No such file or directory
#include <freetype/fterrors.h>
^
compilation terminated.
@ondrejsika
Copy link

Thanks!

@suresudheer
Copy link

it works nicely Thanks bro

@santiagobasulto
Copy link

Worked too! Thanks

@ericek111
Copy link

Worked perfectly, thank you!

@NathanHarrington
Copy link

Symbolic link also fixes the issue on Fedora Core 22.

@jthmiranda
Copy link

Worked on Dockerfile using From ubuntu 14.0.2

@misaelnieto
Copy link

Trick worked on Fedora 22. Thanks.

@mckatzenelson
Copy link

Altering the directory structure in an actively maintained distro to work around a bug in someone's installation script, is not the right way to solve the problem. It would be better to go back to the author of the PIL setup and ask them to fix it.

@ricgu8086
Copy link

The directory structure have changed a bit in Ubuntu 16.04, but this workaround fixed the problem:

ln -s /usr/include/freetype2/freetype /usr/include/freetype

@koalabella
Copy link

@ricgu8086 Thanks! Worked perfectly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment