SDL2_ttf : compilation on Mac OS Catalina -- configure fails with libfreetype2

Dear all,

I dunno if this is the appropriate place to report a problem related to the SDL2_ttf. Sorry if it is not.

Here is the issue :

OS : Mac OS X Catalina

Distribution :

Reproducibility : apparently always on Mac OS X Catalina, but I cannot be sure.

Symptoms :

  • the SDL2 is compiled from source and installed in /usr/local

  • Compiling and installing the libfreetype2 sources included in the SDL2_ttf archive runs fine.

  • libfreetype is then installed in /usr/local

  • which freetype-config returns /usr/local/bin/free-type-config : OK

  • freetype-config --prefix returns /usr/local : OK

  • freetype-config --version returns 22.1.16 : OK

  • Then, the configure script of SDL2_ttf fails with :

checking for FreeType – version >= 7.0.1… no
configure: WARNING: The FreeType test program failed to run. If your system uses shared libraries and they are installed outside the normal system library path, make sure the variable LD_LIBRARY_PATH (or whatever is appropriate for your system) is correctly set.

configure: error: *** Unable to find FreeType2 library (

  • Runing the configure script with

…/configure --with-ft-prefix=/usr/local

ends up with the same error

Remarks :

  • As far as my students told me, installing the latest libfreetype ends up with the same error with the configure script

  • As far I know, but I am not sure, this problem occured on all our student’s Mac equiped with Catalina : it was reported by 7 out of our 200 students

  • At least once, the problem occurs when another libfreetype lib was previously installed in a non standard directory ($HOME/anaconda3)

  • I cannot reproduce the issue myself (I am not under Catalina).

  • We did not have the opportunity to test with the night build of TTF so far

I guess there should be a simple workarround, but I can’t figure it out !
Thank you

occurs also on mac os X.14

See bug report :

(currently being documented)

Can be closed here.