]> git.wh0rd.org - fontconfig.git/commitdiff
Add autoconf checks for FT_Has_PS_Glyph_Names
authorKeith Packard <keithp@keithp.com>
Thu, 26 Jun 2003 08:19:11 +0000 (08:19 +0000)
committerKeith Packard <keithp@keithp.com>
Thu, 26 Jun 2003 08:19:11 +0000 (08:19 +0000)
configure.in
src/fcfreetype.c

index 20b9dce1bd502eb90e3e433125db3305f2a26507..491cdf148ed8cc2c849e082de63b1c5d34949422 100644 (file)
@@ -117,11 +117,12 @@ AC_SUBST(FREETYPE_CFLAGS)
 #  FT_Get_Next_Char
 #  FT_Get_BDF_Property
 #  FT_Get_PS_Font_Info
+#  FT_Has_PS_Glyph_Names
 #
 
 fontconfig_save_libs=$LIBS
 LIBS="$LIBS $FREETYPE_LIBS"
-AC_CHECK_FUNCS(FT_Get_Next_Char FT_Get_BDF_Property FT_Get_PS_Font_Info)
+AC_CHECK_FUNCS(FT_Get_Next_Char FT_Get_BDF_Property FT_Get_PS_Font_Info FT_Has_PS_Glyph_Names)
 LIBS=$fontconfig_save_libs
 
 #
index 60e067662ba46fe948d519e25e04419d752063c6..c2d00a9bfca415f5a73faea3bcac6ac4c45cd4b8 100644 (file)
@@ -1599,6 +1599,7 @@ FcHashGlyphName (const FcChar8 *name)
     return h;
 }
 
+#if HAVE_FT_HAS_PS_GLYPH_NAMES
 /*
  * Use Type1 glyph names for fonts which have reliable names
  * and which export an Adobe Custom mapping
@@ -1684,6 +1685,7 @@ FcFreeTypeGlyphNameIndex (FT_Face face, FcChar8 *name)
     }
     return 0;
 }
+#endif
 
 /*
  * Map a UCS4 glyph to a glyph index.  Use all available encoding
@@ -1731,6 +1733,7 @@ FcFreeTypeCharIndex (FT_Face face, FcChar32 ucs4)
        if (glyphindex)
            return glyphindex;
     }
+#if HAVE_FT_HAS_PS_GLYPH_NAMES
     /*
      * Check postscript name table if present
      */
@@ -1744,6 +1747,7 @@ FcFreeTypeCharIndex (FT_Face face, FcChar32 ucs4)
                return glyphindex;
        }
     }
+#endif
     return 0;
 }
 
@@ -1933,6 +1937,7 @@ FcFreeTypeCharSetAndSpacing (FT_Face face, FcBlanks *blanks, int *spacing)
 #endif
        }
     }
+#if HAVE_FT_HAS_PS_GLYPH_NAMES
     /*
      * Add mapping from PS glyph names if available
      */
@@ -1967,6 +1972,7 @@ FcFreeTypeCharSetAndSpacing (FT_Face face, FcBlanks *blanks, int *spacing)
            }
        }
     }
+#endif
 #ifdef CHECK
     printf ("%d glyphs %d encoded\n", (int) face->num_glyphs, FcCharSetCount (fcs));
     for (ucs4 = 0; ucs4 <= font_max; ucs4++)