From 00c0972acae849ca3b18a7c76894c078185d3be4 Mon Sep 17 00:00:00 2001 From: Behdad Esfahbod Date: Sun, 28 Dec 2008 04:48:54 -0500 Subject: [PATCH] Fix compile with old FreeType that doesn't have FT_Select_Size() (bug #17498) --- configure.in | 10 +--------- src/fcfreetype.c | 2 ++ 2 files changed, 3 insertions(+), 9 deletions(-) diff --git a/configure.in b/configure.in index e9166c7..bd843a2 100644 --- a/configure.in +++ b/configure.in @@ -223,19 +223,11 @@ FREETYPE_LIBS="`$ft_config --libs`" AC_SUBST(FREETYPE_LIBS) AC_SUBST(FREETYPE_CFLAGS) -# -# Check to see whether we have: -# FT_Get_Next_Char -# FT_Get_BDF_Property -# FT_Get_PS_Font_Info -# FT_Has_PS_Glyph_Names -# - fontconfig_save_libs="$LIBS" fontconfig_save_cflags="$CFLAGS" LIBS="$LIBS $FREETYPE_LIBS" CFLAGS="$CFLAGS $FREETYPE_CFLAGS" -AC_CHECK_FUNCS(FT_Get_Next_Char FT_Get_BDF_Property FT_Get_PS_Font_Info FT_Has_PS_Glyph_Names FT_Get_X11_Font_Format) +AC_CHECK_FUNCS(FT_Get_Next_Char FT_Get_BDF_Property FT_Get_PS_Font_Info FT_Has_PS_Glyph_Names FT_Get_X11_Font_Format FT_Select_Size) AC_CHECK_MEMBER(FT_Bitmap_Size.y_ppem, HAVE_FT_BITMAP_SIZE_Y_PPEM=1, HAVE_FT_BITMAP_SIZE_Y_PPEM=0, diff --git a/src/fcfreetype.c b/src/fcfreetype.c index d6197de..104786d 100644 --- a/src/fcfreetype.c +++ b/src/fcfreetype.c @@ -2551,11 +2551,13 @@ FcFreeTypeCharSetAndSpacingForSize (FT_Face face, FcBlanks *blanks, int *spacing if (!fcs) goto bail0; +#if HAVE_FT_SELECT_SIZE if (strike_index >= 0) { if (FT_Select_Size (face, strike_index) != FT_Err_Ok) goto bail1; using_strike = FcTrue; } +#endif #ifdef CHECK printf ("Family %s style %s\n", face->family_name, face->style_name); -- 2.39.5