diff --git a/include/freetype/config/ft2build.h b/include/freetype/config/ft2build.h index 629c3992a..9e8446199 100644 --- a/include/freetype/config/ft2build.h +++ b/include/freetype/config/ft2build.h @@ -26,8 +26,8 @@ /* #ifndef __FT_BUILD_UNIX_H__ */ /* #define __FT_BUILD_UNIX_H__ */ /* */ -/* #define FT_ROOT freetype2 */ -/* #include */ +/* #define FT2_ROOT freetype2 */ +/* #include */ /* */ /* #endif // __FT_BUILD_UNIX_H__ */ /* */ @@ -99,23 +99,6 @@ #define FT2_INTERNAL_FILE( x ) - /*************************************************************************/ - /* */ - /* The macro FT2_COMPONENT_FILE is used to include a given FreeType 2 */ - /* component source file (be it a header, a C source file, or an */ - /* included file). */ - /* */ - /* Its first argument is the component/module's directory according to */ - /* the normal FreeType 2 source directory hierarchy, and the second one */ - /* the file name. */ - /* */ - /* Note that you can also put all library source files in a single */ - /* directory and compile them normally by defining the macro */ - /* FT_FLAT_COMPILATION. */ - /* */ -#define FT2_COMPONENT_FILE( d, x ) - - /*************************************************************************/ /* */ /* The macro FT2_SOURCE_FILE is used to include a given FreeType 2 */ @@ -130,10 +113,10 @@ /* directory and compile them normally by defining the macro */ /* FT_FLAT_COMPILATION. */ /* */ -#ifdef FT2_FLAT_COMPILATION -#define FT2_SOURCE_FILE( d, x ) +#ifdef FT_FLAT_COMPILATION +#define FT_SOURCE_FILE( d, x ) #else -#define FT2_SOURCE_FILE( d, x ) "x" +#define FT_SOURCE_FILE( d, x ) #x #endif diff --git a/src/autohint/ahangles.c b/src/autohint/ahangles.c index caf834814..ff70f4310 100644 --- a/src/autohint/ahangles.c +++ b/src/autohint/ahangles.c @@ -19,16 +19,8 @@ /* */ /***************************************************************************/ - -#ifdef FT_FLAT_COMPILE - -#include "ahangles.h" - -#else - -#include - -#endif +#include +#include FT_SOURCE_FILE(autohint,ahangles.h) /* the following table has been automatically generated with */ diff --git a/src/autohint/ahangles.h b/src/autohint/ahangles.h index cf5abea45..40126140b 100644 --- a/src/autohint/ahangles.h +++ b/src/autohint/ahangles.h @@ -20,28 +20,14 @@ /***************************************************************************/ -#ifndef AHANGLES_H -#define AHANGLES_H +#ifndef __AHANGLES_H__ +#define __AHANGLES_H__ +#include +#include FT_INTERNAL_OBJECTS_H +#include FT_SOURCE_FILE(autohint,ahtypes.h) -#ifdef FT_FLAT_COMPILE - -#include "ahtypes.h" - -#else - -#include - -#endif - - -#include - - -#ifdef __cplusplus - extern "C" { -#endif - +FT_BEGIN_HEADER /* PI expressed in ah_angles -- we don't really need an important */ /* precision, so 256 should be enough */ @@ -62,12 +48,9 @@ AH_Angle ah_angle( FT_Vector* v ); -#ifdef __cplusplus - } -#endif +FT_END_HEADER - -#endif /* AHANGLES_H */ +#endif /* __AHANGLES_H__ */ /* END */ diff --git a/src/cache/ftcmanag.c b/src/cache/ftcmanag.c index 363b214d2..9b83c7176 100644 --- a/src/cache/ftcmanag.c +++ b/src/cache/ftcmanag.c @@ -265,8 +265,8 @@ Exit: if ( error && manager ) { - FT_Lru_Done( manager->sizes_lru ); FT_Lru_Done( manager->faces_lru ); + FT_Lru_Done( manager->sizes_lru ); FREE( manager ); } @@ -304,7 +304,7 @@ manager->faces_lru = 0; FT_Lru_Done( manager->sizes_lru ); - manager->sizes_lru; + manager->sizes_lru = 0; FREE( manager ); }