diff --git a/ChangeLog b/ChangeLog index 0bcc636db..2e55776af 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,16 @@ +2009-12-31 Lars Abrahamsson + + Make compilation with FT_CONFIG_OPTION_PIC work again. + + * src/base/ftglyph.c (FT_Glyph_To_Bitmap) [FT_CONFIG_OPTION_PIC]: + Declare `library' for FT_BITMAP_GLYPH_CLASS_GET. + + * src/base/ftinit.c (ft_destroy_default_module_classes, + ft_create_default_module_classes): Use proper casts (needed for C++ + compilation). + + * src/sfnt/ttcmap.c (tt_cmap13_class_rec): Use FT_DEFINE_TT_CMAP. + 2009-12-22 Marc Kleine-Budde Make freetype-config aware of $SYSROOT. diff --git a/src/base/ftglyph.c b/src/base/ftglyph.c index ef61d45df..3505d6dde 100644 --- a/src/base/ftglyph.c +++ b/src/base/ftglyph.c @@ -372,7 +372,7 @@ if ( slot->format == FT_GLYPH_FORMAT_BITMAP ) clazz = FT_BITMAP_GLYPH_CLASS_GET; - /* it it is an outline too */ + /* if it is an outline */ else if ( slot->format == FT_GLYPH_FORMAT_OUTLINE ) clazz = FT_OUTLINE_GLYPH_CLASS_GET; @@ -515,6 +515,10 @@ const FT_Glyph_Class* clazz; +#ifdef FT_CONFIG_OPTION_PIC + FT_Library library = FT_GLYPH( glyph )->library; +#endif + /* check argument */ if ( !the_glyph ) diff --git a/src/base/ftinit.c b/src/base/ftinit.c index ef1350386..f94f25a83 100644 --- a/src/base/ftinit.c +++ b/src/base/ftinit.c @@ -115,7 +115,7 @@ FT_Module_Class** classes; FT_Memory memory; FT_UInt i; - BasePIC* pic_container = library->pic_container.base; + BasePIC* pic_container = (BasePIC*)library->pic_container.base; if ( !pic_container->default_module_classes ) return; @@ -145,7 +145,7 @@ FT_Module_Class** classes; FT_Module_Class* clazz; FT_UInt i; - BasePIC* pic_container = library->pic_container.base; + BasePIC* pic_container = (BasePIC*)library->pic_container.base; memory = library->memory; pic_container->default_module_classes = 0; diff --git a/src/sfnt/ttcmap.c b/src/sfnt/ttcmap.c index 26ea83c16..b283f6d16 100644 --- a/src/sfnt/ttcmap.c +++ b/src/sfnt/ttcmap.c @@ -2574,10 +2574,7 @@ } - FT_CALLBACK_TABLE_DEF - const TT_CMap_ClassRec tt_cmap13_class_rec = - { - { + FT_DEFINE_TT_CMAP(tt_cmap13_class_rec, sizeof ( TT_CMap13Rec ), (FT_CMap_InitFunc) tt_cmap13_init, @@ -2586,11 +2583,11 @@ (FT_CMap_CharNextFunc) tt_cmap13_char_next, NULL, NULL, NULL, NULL, NULL - }, + , 13, (TT_CMap_ValidateFunc) tt_cmap13_validate, (TT_CMap_Info_GetFunc) tt_cmap13_get_info - }; + ) #endif /* TT_CONFIG_CMAP_FORMAT_13 */