--- configure.orig	2021-08-06 10:56:54 UTC
+++ configure
@@ -8359,8 +8359,8 @@ done
 	else
 		ac_save_CFLAGS="$CFLAGS"
 		ac_save_LIBS="$LIBS"
-		FREETYPECFLAGS=`$ac_lib_freetype_config $ac_lib_freetype_args --cflags`
-		FREETYPELIBS=`$ac_lib_freetype_config $ac_lib_freetype_args --libs`
+		FREETYPECFLAGS=`pkg-config freetype2 --cflags`
+		FREETYPELIBS=`pkg-config freetype2 --libs`
 		CFLAGS="$FREETYPECFLAGS $CFLAGS"
 		LIBS="$FREETYPELIBS $LIBS"
 		{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for FreeType2" >&5
