shithub: freetype+ttf2subf

Download patch

ref: 8d3a401fa808a8c70bd6a9ce17d5a840fb0ae2db
parent: 3de5b07cc3e205a4928f82d8be5b8fda91e01c1e
author: David Turner <[email protected]>
date: Tue Mar 20 06:14:24 EST 2001

* builds/*/*-def.mk: changed the objects directory from "obj" to "objs"

	* include/freetype/config/ftheader.h: removed obsolete macros like
	FT_SOURCE_FILE, etc.. and added cache-specific macro definitions that
	were previously defined in <freetype/ftcache.h>. Added comments to be
	included in a new API Reference section.

	* src/*/*: removed the use of FT_SOURCE_FILE, etc.. now, each component
	needs to added its own directory to the include path at compile time.
	Modified all "rules.mk" and "descrip.mms" accordingly..

git/fs: mount .git/fs: mount/attach disallowed
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,17 @@
+2001-03-20  David Turner    <[email protected]>
+
+	* builds/*/*-def.mk: changed the objects directory from "obj" to "objs"
+
+	* include/freetype/config/ftheader.h: removed obsolete macros like
+	FT_SOURCE_FILE, etc.. and added cache-specific macro definitions that
+	were previously defined in <freetype/ftcache.h>. Added comments to be
+	included in a new API Reference section.
+
+	* src/*/*: removed the use of FT_SOURCE_FILE, etc.. now, each component
+	needs to added its own directory to the include path at compile time.
+	Modified all "rules.mk" and "descrip.mms" accordingly..
+
+
 2001-03-20  Werner Lemberg  <[email protected]>
 
 	* builds/unix/configure.in: Add $ft_version.
@@ -69,8 +83,8 @@
 	* include/freetype/internal/psaux.h:  Changed the lenIV member of
 	the T1_Decoder_ struct to be an FT_Int instead of an FT_UInt.
 
-        * src/psaux/t1decode.c (T1_Decoder_Parse_Charstrings):  Adjust
-        for lenIV seed bytes at the start of a decrypted subroutine.
+	* src/psaux/t1decode.c (T1_Decoder_Parse_Charstrings):  Adjust
+	for lenIV seed bytes at the start of a decrypted subroutine.
 
 	* src/cid/cidload.c (cid_read_subrs): Decrypt subroutines only
 	if lenIV >= 0.
--- a/builds/ansi/ansi-def.mk
+++ b/builds/ansi/ansi-def.mk
@@ -34,7 +34,7 @@
 #   make -f $TOP/Makefile
 #
 ifndef OBJ_DIR
-  OBJ_DIR := $(TOP)$(SEP)obj
+  OBJ_DIR := $(TOP)$(SEP)objs
 endif
 
 
--- a/builds/cygwin/cygwin-def.in
+++ b/builds/cygwin/cygwin-def.in
@@ -66,7 +66,7 @@
 #   make -f $TOP/Makefile
 #
 ifndef OBJ_DIR
-  OBJ_DIR := $(shell cd $(TOP)/obj; pwd)
+  OBJ_DIR := $(shell cd $(TOP)/objs; pwd)
 endif
 
 
--- a/builds/cygwin/cygwinddef.mk
+++ b/builds/cygwin/cygwinddef.mk
@@ -33,7 +33,7 @@
 # The directory where all object files are placed.
 #
 ifndef OBJ_DIR
-  OBJ_DIR := $(shell cd $(TOP)/obj; pwd)
+  OBJ_DIR := $(shell cd $(TOP)/objs; pwd)
 endif
 
 
--- a/builds/dos/dos-def.mk
+++ b/builds/dos/dos-def.mk
@@ -34,7 +34,7 @@
 #   make -f %TOP%/Makefile
 #
 ifndef OBJ_DIR
-  OBJ_DIR := $(TOP)$(SEP)obj
+  OBJ_DIR := $(TOP)$(SEP)objs
 endif
 
 
--- a/builds/freetype.mk
+++ b/builds/freetype.mk
@@ -130,7 +130,7 @@
 #                 in the `freetype/builds/<system>' directory, as these
 #                 files will override the default sources.
 #
-INCLUDES := $(BUILD) $(TOP)$(SEP)include $(SRC)
+INCLUDES := $(BUILD) $(TOP)$(SEP)include
 
 INCLUDE_FLAGS = $(INCLUDES:%=$I%)
 
--- a/builds/os2/os2-def.mk
+++ b/builds/os2/os2-def.mk
@@ -34,7 +34,7 @@
 #   make -f %TOP%/Makefile
 #
 ifndef OBJ_DIR
-  OBJ_DIR := $(TOP)$(SEP)obj
+  OBJ_DIR := $(TOP)$(SEP)objs
 endif
 
 
--- a/builds/unix/ft2unix.h
+++ b/builds/unix/ft2unix.h
@@ -34,7 +34,7 @@
 #define FT2_CONFIG_FILE( x )    <freetype2/freetype/config/ ## x ## >
 #define FT2_INTERNAL_FILE( x )  <freetype2/freetype/internal/ ## x ## >
 
-#include FT2_CONFIG_FILE( ft2build.h )
+#include FT2_CONFIG_FILE( ftheader.h )
 
 #endif /* __FT2_BUILD_UNIX_H__ */
 
--- a/builds/unix/unix-def.in
+++ b/builds/unix/unix-def.in
@@ -66,7 +66,7 @@
 #   make -f $TOP/Makefile
 #
 ifndef OBJ_DIR
-  OBJ_DIR := $(shell cd $(TOP)/obj; pwd)
+  OBJ_DIR := $(shell cd $(TOP)/objs; pwd)
 endif
 
 
--- a/builds/unix/unixddef.mk
+++ b/builds/unix/unixddef.mk
@@ -33,7 +33,7 @@
 # The directory where all object files are placed.
 #
 ifndef OBJ_DIR
-  OBJ_DIR := $(shell cd $(TOP)/obj; pwd)
+  OBJ_DIR := $(shell cd $(TOP)/objs; pwd)
 endif
 
 
--- a/builds/win32/detect.mk
+++ b/builds/win32/detect.mk
@@ -86,6 +86,14 @@
     .PHONY: visualc
   endif
 
+  ifneq ($(findstring intelc,$(MAKECMDGOALS)),)     # Intel C/C++
+    CONFIG_FILE := w32-intl.mk
+    SEP         := $(BACKSLASH)
+    CC          := cl
+    visualc: setup
+    .PHONY: visualc
+  endif
+
   ifneq ($(findstring watcom,$(MAKECMDGOALS)),)      # Watcom C/C++
     CONFIG_FILE := w32-wat.mk
     SEP         := $(BACKSLASH)
--- a/builds/win32/win32-def.mk
+++ b/builds/win32/win32-def.mk
@@ -36,7 +36,7 @@
 #   make -f %TOP%/Makefile
 #
 ifndef OBJ_DIR
-  OBJ_DIR := $(TOP)$(SEP)obj
+  OBJ_DIR := $(TOP)$(SEP)objs
 endif
 
 
--- a/include/freetype/config/ftheader.h
+++ b/include/freetype/config/ftheader.h
@@ -15,137 +15,11 @@
 /*                                                                         */
 /***************************************************************************/
 
+#ifndef __FT_HEADER_H__
+#define __FT_HEADER_H__
 
   /*************************************************************************/
   /*                                                                       */
-  /* This file corresponds to the default "ft2build.h" file for            */
-  /* FreeType 2.  It uses the "freetype" include root.                     */
-  /*                                                                       */
-  /* Note that specific platforms might use a different configuration.     */
-  /* For example, on Unix, the "freetype2" include root could be used,     */
-  /* with a specific "ft2build.h" to take care of this.  The latter then   */
-  /* looks like the following:                                             */
-  /*                                                                       */
-  /*     #ifndef __FT2_BUILD_UNIX_H__                                      */
-  /*     #define __FT2_BUILD_UNIX_H__                                      */
-  /*                                                                       */
-  /*     #define FT2_ROOT  freetype2                                       */
-  /*     #include <freetype2/config/ft2build.h>                            */
-  /*                                                                       */
-  /*     #include FT2_CONFIG_FILE( ft2build.h )                            */
-  /*                                                                       */
-  /*     #endif                                                            */
-  /*                                                                       */
-  /* If necessary, the macro FT_SOURCE_FILE() can be redefined also if a   */
-  /* different path separator is needed.                                   */
-  /*                                                                       */
-  /*************************************************************************/
-
-
-#ifndef __FT2_BUILD_H__
-#define __FT2_BUILD_H__
-
-
-  /* this macro is used to enclose its argument in brackets */
-#define FT2_ENCLOSE(x)  <x>
-
-  /* this macro is used to join a path and a file name */
-#define FT2_JOINPATH(d,x)  d/x
-
-  /* this macro is used to format a path in "<d/x>" format easily */
-#define FT2_PUBLIC_PATH(d,x)  FT2_ENCLOSE(d/x)
-
-
-
-  /*************************************************************************/
-  /*                                                                       */
-  /* The macro FT2_ROOT is used to define the root of all public header    */
-  /* files for FreeType 2.  By default, it is set to "freetype", which     */
-  /* means that all public files should be included with a line like:      */
-  /*                                                                       */
-  /*   #include <freetype/...>                                             */
-  /*                                                                       */
-  /* Redefine it to something different if necessary, depending where the  */
-  /* library is installed on the particular system.                        */
-  /*                                                                       */
-#ifndef FT2_ROOT
-#define FT2_ROOT  freetype
-#endif
-
-
-  /*************************************************************************/
-  /*                                                                       */
-  /* The macro FT2_CONFIG_ROOT is used to define the root of all           */
-  /* configuration header files for FreeType 2.  By default, it is set to  */
-  /* "freetype/config", which means that all config files should be        */
-  /* include with a line like:                                             */
-  /*                                                                       */
-  /*   #include <freetype/config/...>                                      */
-  /*                                                                       */
-  /* Redefine it to something different, depending where the library is    */
-  /* installed on the particular system.                                   */
-  /*                                                                       */
-#ifndef FT2_CONFIG_ROOT
-#define FT2_CONFIG_ROOT    FT2_JOINPATH(FT2_ROOT,config)
-#endif
-
-
-#define FT2_INTERNAL_ROOT  FT2_JOINPATH(FT2_ROOT,internal)
-
-  /*************************************************************************/
-  /*                                                                       */
-  /* The macro FT2_PUBLIC_FILE is used to include a FreeType 2 public file.*/
-  /* Its parameter is the file pathname, relative to the public root of a  */
-  /* given header file.                                                    */
-  /*                                                                       */
-#define FT2_PUBLIC_FILE( x )  FT2_PUBLIC_PATH(FT2_ROOT,x)
-
-
-  /*************************************************************************/
-  /*                                                                       */
-  /* The macro FT2_CONFIG_FILE is used to include a FreeType 2 config file.*/
-  /* Its parameter is the file pathname, relative to the configuration     */
-  /* root directory of a given header file.                                */
-  /*                                                                       */
-#define FT2_CONFIG_FILE( x )  FT2_PUBLIC_PATH(FT2_CONFIG_ROOT,x)
-
-
-  /*************************************************************************/
-  /*                                                                       */
-  /* The macro FT2_INTERNAL_FILE is used to include a FreeType 2 internal  */
-  /* file.  Its parameter is the file pathname, relative to the            */
-  /* configuration root directory of a given header file.                  */
-  /*                                                                       */
-#define FT2_INTERNAL_FILE( x )  FT2_ENCLOSE(FT2_ROOT/internal/x)
-
-
-  /*************************************************************************/
-  /*                                                                       */
-  /* The macro FT_SOURCE_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.                                                  */
-  /*                                                                       */
-#ifndef FT_SOURCE_FILE
-
-#ifdef FT_FLAT_COMPILATION
-#define FT_SOURCE_FILE( d, x )  #x
-#else
-#define FT_SOURCE_FILE( d, x )  FT2_PUBLIC_PATH(d,x)
-#endif
-
-#endif /* !FT_SOURCE_FILE */
-
-
-  /*************************************************************************/
-  /*                                                                       */
   /* <Macro>                                                               */
   /*    FT_BEGIN_HEADER                                                    */
   /*                                                                       */
@@ -431,10 +305,39 @@
  *    a macro used in #include statements to name the file containing
  *    the API of the optional FreeType 2 cache sub-system.
  */
-#define FT_CACHE_H             <freetype/ftcache.h>
+#define FT_CACHE_H                 <freetype/ftcache.h>
 
 /*************************************************************************
  *
+ * @macro: FT_CACHE_IMAGE_H
+ *
+ * @description:
+ *    a macro used in #include statements to name the file containing
+ *    the "glyph image" API of the FreeType 2 cache sub-system
+ *
+ *    it is used to define a cache for @FT_Glyph elements. You can also
+ *    see the API defined in @FT_CACHE_SMALL_BITMAPS_H if you only need
+ *    to store small glyph bitmaps, as it will use less memory
+ */
+#define FT_CACHE_IMAGE_H           <freetype/cache/ftcimage.h>
+
+/*************************************************************************
+ *
+ * @macro: FT_CACHE_SMALL_BITMAPS_H
+ *
+ * @description:
+ *    a macro used in #include statements to name the file containing
+ *    the "small bitmaps" API of the FreeType 2 cache sub-system
+ *
+ *    it is used to define a cache for small glyph bitmaps in a relatively
+ *    memory-efficient way. You can also use the API defined in
+ *    @FT_CACHE_IMAGE_H if you want to cache arbitrary glyph images, including
+ *    scalable outlines.
+ */
+#define FT_CACHE_SMALL_BITMAPS_H   <freetype/cache/ftcsbits.h>
+
+/*************************************************************************
+ *
  * @macro: FT_MAC_H
  *
  * @description:
@@ -466,15 +369,20 @@
  *    the optional FreeType 2 API used to access embedded "name" strings
  *    in SFNT-based font formats (i.e. TrueType and OpenType)
  */
-#define FT_NAMES_H             <freetype/ftnames.h>
+#define FT_NAMES_H              <freetype/ftnames.h>
 
  /* */
  
-#define FT_SYNTHESIS_H         <freetype/ftsynth.h>
+#define FT_SYNTHESIS_H             <freetype/ftsynth.h>
 
+#define FT_CACHE_MANAGER_H         <freetype/cache/ftcmanag.h>
 
+#define FT_CACHE_INTERNAL_LRU_H    <freetype/cache/ftlru.h>
+#define FT_CACHE_INTERNAL_GLYPH_H  <freetype/cache/ftcglyph.h>
+#define FT_CACHE_INTERNAL_CHUNK_H  <freetype/cache/ftcchunk.h>
+
   /* now include internal headers definitions from <freetype/internal/...> */
-#define  FT_INTERNAL_INTERNAL_H   <freetype/internal/internal.h>
+#define  FT_INTERNAL_INTERNAL_H    <freetype/internal/internal.h>
 #include FT_INTERNAL_INTERNAL_H
 
 
--- a/include/freetype/config/ftoption.h
+++ b/include/freetype/config/ftoption.h
@@ -311,7 +311,7 @@
   /* By undefining this, you will only compile the code necessary to load  */
   /* TrueType glyphs without hinting.                                      */
   /*                                                                       */
-#define TT_CONFIG_OPTION_BYTECODE_INTERPRETER
+#undef  TT_CONFIG_OPTION_BYTECODE_INTERPRETER
 
 
   /*************************************************************************/
--- a/include/freetype/freetype.h
+++ b/include/freetype/freetype.h
@@ -2339,10 +2339,6 @@
   /* <Return>                                                              */
   /*    The result of `(a + 0x8000) & -0x10000'.                           */
   /*                                                                       */
-  /* <Note>                                                                */
-  /*    This function assumes that the target platform supports 32-bit     */
-  /*    signed integers.                                                   */
-  /*                                                                       */
   FT_EXPORT( FT_Fixed )  FT_RoundFix( FT_Fixed  a );
 
 
@@ -2361,10 +2357,6 @@
   /* <Return>                                                              */
   /*    The result of `(a + 0x10000 - 1) & -0x10000'.                      */
   /*                                                                       */
-  /* <Note>                                                                */
-  /*    This function assumes that the target platform supports 32-bit     */
-  /*    signed integers.                                                   */
-  /*                                                                       */
   FT_EXPORT( FT_Fixed )  FT_CeilFix( FT_Fixed  a );
 
 
@@ -2382,10 +2374,6 @@
   /*                                                                       */
   /* <Return>                                                              */
   /*    The result of `a & -0x10000'.                                      */
-  /*                                                                       */
-  /* <Note>                                                                */
-  /*    This function assumes that the target platform supports 32-bit     */
-  /*    signed integers.                                                   */
   /*                                                                       */
   FT_EXPORT( FT_Fixed )  FT_FloorFix( FT_Fixed  a );
 
--- a/include/freetype/ftcache.h
+++ b/include/freetype/ftcache.h
@@ -42,15 +42,6 @@
 FT_BEGIN_HEADER
 
 
-#define FT_CACHE_MANAGER_H         FT2_PUBLIC_FILE(cache/ftcmanag.h)
-#define FT_CACHE_IMAGE_H           FT2_PUBLIC_FILE(cache/ftcimage.h)
-#define FT_CACHE_SMALL_BITMAPS_H   FT2_PUBLIC_FILE(cache/ftcsbits.h)
-
-#define FT_CACHE_INTERNAL_LRU_H    FT2_PUBLIC_FILE(cache/ftlru.h)
-#define FT_CACHE_INTERNAL_GLYPH_H  FT2_PUBLIC_FILE(cache/ftcglyph.h)
-#define FT_CACHE_INTERNAL_CHUNK_H  FT2_PUBLIC_FILE(cache/ftcchunk.h)
-
-
   /*************************************************************************/
   /*                                                                       */
   /* <Section>                                                             */
--- a/include/freetype/fttypes.h
+++ b/include/freetype/fttypes.h
@@ -55,6 +55,8 @@
   /*    FT_Long                                                            */
   /*    FT_ULong                                                           */
   /*    FT_Bool                                                            */
+  /*    FT_Offset                                                          */
+  /*    FT_PtrDist                                                         */
   /*    FT_Error                                                           */
   /*    FT_Fixed                                                           */
   /*    FT_Pointer                                                         */
@@ -266,6 +268,32 @@
   /*    A simple typedef for a typeless pointer.                           */
   /*                                                                       */
   typedef void*  FT_Pointer;
+
+
+  /*************************************************************************/
+  /*                                                                       */
+  /* <Type>                                                                */
+  /*    FT_Offset                                                          */
+  /*                                                                       */
+  /* <Description>                                                         */
+  /*    This is equivalent to the ANSI C "size_t" type, i.e. it's the      */
+  /*    largest _unsigned_ integer type used to express a file size or     */
+  /*    position, or a memory block size.                                  */
+  /*                                                                       */
+  typedef size_t  FT_Offset;
+
+
+  /*************************************************************************/
+  /*                                                                       */
+  /* <Type>                                                                */
+  /*    FT_PtrDist                                                         */
+  /*                                                                       */
+  /* <Description>                                                         */
+  /*    This is equivalent to the ANSI C "ptrdiff_t" type, i.e. the        */
+  /*    largest _signed_ integer type used to express the distance         */
+  /*    between two pointers.                                              */
+  /*                                                                       */
+  typedef size_t  FT_PtrDist;
 
 
   /*************************************************************************/
--- a/src/autohint/ahangles.c
+++ b/src/autohint/ahangles.c
@@ -21,7 +21,7 @@
 
 
 #include <ft2build.h>
-#include FT_SOURCE_FILE(autohint,ahangles.h)
+#include "ahangles.h"
 
 
   /* the following table has been automatically generated with */
--- a/src/autohint/ahangles.h
+++ b/src/autohint/ahangles.h
@@ -26,7 +26,7 @@
 
 #include <ft2build.h>
 #include FT_INTERNAL_OBJECTS_H
-#include FT_SOURCE_FILE(autohint,ahtypes.h)
+#include "ahtypes.h"
 
 
 FT_BEGIN_HEADER
--- a/src/autohint/ahglobal.c
+++ b/src/autohint/ahglobal.c
@@ -20,8 +20,8 @@
 
 
 #include <ft2build.h>
-#include FT_SOURCE_FILE(autohint,ahglobal.h)
-#include FT_SOURCE_FILE(autohint,ahglyph.h)
+#include "ahglobal.h"
+#include "ahglyph.h"
 
 
 #define MAX_TEST_CHARACTERS  12
--- a/src/autohint/ahglobal.h
+++ b/src/autohint/ahglobal.h
@@ -25,7 +25,7 @@
 
 
 #include <ft2build.h>
-#include FT_SOURCE_FILE(autohint,ahtypes.h)
+#include "ahtypes.h"
 #include FT_INTERNAL_OBJECTS_H
 
 
--- a/src/autohint/ahglyph.c
+++ b/src/autohint/ahglyph.c
@@ -21,9 +21,9 @@
 
 
 #include <ft2build.h>
-#include FT_SOURCE_FILE(autohint,ahglyph.h)
-#include FT_SOURCE_FILE(autohint,ahangles.h)
-#include FT_SOURCE_FILE(autohint,ahglobal.h)
+#include "ahglyph.h"
+#include "ahangles.h"
+#include "ahglobal.h"
 
 #include <stdio.h>
 
--- a/src/autohint/ahglyph.h
+++ b/src/autohint/ahglyph.h
@@ -25,7 +25,7 @@
 
 
 #include <ft2build.h>
-#include FT_SOURCE_FILE(autohint,ahtypes.h)
+#include "ahtypes.h"
 
 
 FT_BEGIN_HEADER
--- a/src/autohint/ahhint.c
+++ b/src/autohint/ahhint.c
@@ -20,9 +20,9 @@
 
 
 #include <ft2build.h>
-#include FT_SOURCE_FILE(autohint,ahhint.h)
-#include FT_SOURCE_FILE(autohint,ahglyph.h)
-#include FT_SOURCE_FILE(autohint,ahangles.h)
+#include "ahhint.h"
+#include "ahglyph.h"
+#include "ahangles.h"
 #include FT_OUTLINE_H
 
 
--- a/src/autohint/ahhint.h
+++ b/src/autohint/ahhint.h
@@ -24,7 +24,7 @@
 
 
 #include <ft2build.h>
-#include FT_SOURCE_FILE(autohint,ahglobal.h)
+#include "ahglobal.h"
 
 
 FT_BEGIN_HEADER
--- a/src/autohint/ahmodule.c
+++ b/src/autohint/ahmodule.c
@@ -21,7 +21,7 @@
 
 #include <ft2build.h>
 #include FT_MODULE_H
-#include FT_SOURCE_FILE(autohint,ahhint.h)
+#include "ahhint.h"
 
 
   typedef struct  FT_AutoHinterRec_
--- a/src/autohint/ahoptim.c
+++ b/src/autohint/ahoptim.c
@@ -33,7 +33,7 @@
 
 #include <ft2build.h>
 #include FT_INTERNAL_OBJECTS_H        /* for ALLOC_ARRAY() and FREE() */
-#include FT_SOURCE_FILE(autohint,ahoptim.h)
+#include "ahoptim.h"
 
 
   /* define this macro to use brute force optimisation -- this is slow,  */
--- a/src/autohint/ahoptim.h
+++ b/src/autohint/ahoptim.h
@@ -24,7 +24,7 @@
 
 
 #include <ft2build.h>
-#include FT_SOURCE_FILE(autohint,ahtypes.h)
+#include "ahtypes.h"
 
 
 FT_BEGIN_HEADER
--- a/src/autohint/ahtypes.h
+++ b/src/autohint/ahtypes.h
@@ -26,7 +26,7 @@
 
 #include <ft2build.h>
 #include FT_INTERNAL_OBJECTS_H
-#include FT_SOURCE_FILE(autohint,ahloader.h)
+#include "ahloader.h"
 
 
 #define xxAH_DEBUG
--- a/src/autohint/autohint.c
+++ b/src/autohint/autohint.c
@@ -22,11 +22,11 @@
 #define FT_MAKE_OPTION_SINGLE_OBJECT
 
 #include <ft2build.h>
-#include FT_SOURCE_FILE(autohint,ahangles.c)
-#include FT_SOURCE_FILE(autohint,ahglyph.c)
-#include FT_SOURCE_FILE(autohint,ahglobal.c)
-#include FT_SOURCE_FILE(autohint,ahhint.c)
-#include FT_SOURCE_FILE(autohint,ahmodule.c)
+#include "ahangles.c"
+#include "ahglyph.c"
+#include "ahglobal.c"
+#include "ahhint.c"
+#include "ahmodule.c"
 
 
 /* END */
--- a/src/autohint/descrip.mms
+++ b/src/autohint/descrip.mms
@@ -15,7 +15,7 @@
 # Note that this license is compatible with the FreeType license.
 
 
-CFLAGS=$(COMP_FLAGS)$(DEBUG)/incl=[--.include]
+CFLAGS=$(COMP_FLAGS)$(DEBUG)/incl=([--.include],[--.src.autohint])
 
 OBJS=autohint.obj
 
--- a/src/autohint/rules.mk
+++ b/src/autohint/rules.mk
@@ -24,7 +24,7 @@
 
 # compilation flags for the driver
 #
-AUTO_COMPILE := $(FT_COMPILE)
+AUTO_COMPILE := $(FT_COMPILE) $I$(AUTO_DIR)
 
 
 # AUTO driver sources (i.e., C files)
--- a/src/base/descrip.mms
+++ b/src/base/descrip.mms
@@ -13,7 +13,7 @@
 # fully.
 
 
-CFLAGS=$(COMP_FLAGS)$(DEBUG)/include=([--.builds.vms],[--.include])
+CFLAGS=$(COMP_FLAGS)$(DEBUG)/include=([--.builds.vms],[--.include],[--.src.base])
 
 OBJS=ftbase.obj,ftinit.obj,ftglyph.obj
 
--- a/src/base/ftbase.c
+++ b/src/base/ftbase.c
@@ -17,13 +17,18 @@
 
 
 #include <ft2build.h>
-#include FT_SOURCE_FILE(base,ftcalc.c)
-#include FT_SOURCE_FILE(base,ftobjs.c)
-#include FT_SOURCE_FILE(base,ftstream.c)
-#include FT_SOURCE_FILE(base,ftlist.c)
-#include FT_SOURCE_FILE(base,ftoutln.c)
-#include FT_SOURCE_FILE(base,ftextend.c)
-#include FT_SOURCE_FILE(base,ftnames.c)
 
+#define  FT_MAKE_OPTION_SINGLE_OBJECT
+
+#include "ftcalc.c"
+#include "ftobjs.c"
+#include "ftstream.c"
+#include "ftlist.c"
+#include "ftoutln.c"
+#include "ftnames.c"
+
+#if 0
+#include "ftextend.c"
+#endif
 
 /* END */
--- a/src/base/ftmac.c
+++ b/src/base/ftmac.c
@@ -60,8 +60,8 @@
 #include <ft2build.h>
 #include FT_FREETYPE_H
 #include FT_INTERNAL_STREAM_H
-#include FT_SOURCE_FILE( truetype, ttobjs.h )
-#include FT_SOURCE_FILE( type1, t1objs.h )
+#include "truetype/ttobjs.h"
+#include "type1/t1objs.h"
 
 #include <Resources.h>
 #include <Fonts.h>
--- a/src/base/ftobjs.c
+++ b/src/base/ftobjs.c
@@ -2079,10 +2079,10 @@
   }
 
 
-  FT_LOCAL_DEF
-  FT_Error  FT_Render_Glyph_Internal( FT_Library    library,
-                                      FT_GlyphSlot  slot,
-                                      FT_UInt       render_mode )
+  FT_EXPORT_DEF(FT_Error)
+  FT_Render_Glyph_Internal( FT_Library    library,
+                            FT_GlyphSlot  slot,
+                            FT_UInt       render_mode )
   {
     FT_Error     error = FT_Err_Ok;
     FT_Renderer  renderer;
--- a/src/cache/descrip.mms
+++ b/src/cache/descrip.mms
@@ -13,7 +13,7 @@
 # fully.
 
 
-CFLAGS=$(COMP_FLAGS)$(DEBUG)/include=[--.include]
+CFLAGS=$(COMP_FLAGS)$(DEBUG)/include=([--.include],[--.src.cache])
 
 OBJS=ftcache.obj
 
--- a/src/cache/ftcache.c
+++ b/src/cache/ftcache.c
@@ -19,12 +19,12 @@
 #define FT_MAKE_OPTION_SINGLE_OBJECT
 
 #include <ft2build.h>
-#include FT_SOURCE_FILE(cache,ftlru.c)
-#include FT_SOURCE_FILE(cache,ftcmanag.c)
-#include FT_SOURCE_FILE(cache,ftcglyph.c)
-#include FT_SOURCE_FILE(cache,ftcchunk.c)
-#include FT_SOURCE_FILE(cache,ftcimage.c)
-#include FT_SOURCE_FILE(cache,ftcsbits.c)
+#include "ftlru.c"
+#include "ftcmanag.c"
+#include "ftcglyph.c"
+#include "ftcchunk.c"
+#include "ftcimage.c"
+#include "ftcsbits.c"
 
 
 /* END */
--- a/src/cache/rules.mk
+++ b/src/cache/rules.mk
@@ -23,7 +23,7 @@
 
 # compilation flags for the driver
 #
-Cache_COMPILE := $(FT_COMPILE)
+Cache_COMPILE := $(FT_COMPILE) $I$(CACHE_DIR)
 
 
 # Cache driver sources (i.e., C files)
--- a/src/cff/cff.c
+++ b/src/cff/cff.c
@@ -19,11 +19,11 @@
 #define FT_MAKE_OPTION_SINGLE_OBJECT
 
 #include <ft2build.h>
-#include FT_SOURCE_FILE(cff,cffdrivr.c)
-#include FT_SOURCE_FILE(cff,cffparse.c)
-#include FT_SOURCE_FILE(cff,cffload.c)
-#include FT_SOURCE_FILE(cff,cffobjs.c)
-#include FT_SOURCE_FILE(cff,cffgload.c)
+#include "cffdrivr.c"
+#include "cffparse.c"
+#include "cffload.c"
+#include "cffobjs.c"
+#include "cffgload.c"
 
 
 /* END */
--- a/src/cff/cffdrivr.c
+++ b/src/cff/cffdrivr.c
@@ -24,9 +24,9 @@
 #include FT_TRUETYPE_NAMES_H
 #include FT_INTERNAL_CFF_ERRORS_H
 
-#include FT_SOURCE_FILE(cff,cffdrivr.h)
-#include FT_SOURCE_FILE(cff,cffgload.h)
-#include FT_SOURCE_FILE(cff,cffload.h)
+#include "cffdrivr.h"
+#include "cffgload.h"
+#include "cffload.h"
 
   /*************************************************************************/
   /*                                                                       */
--- a/src/cff/cffgload.c
+++ b/src/cff/cffgload.c
@@ -24,8 +24,8 @@
 #include FT_OUTLINE_H
 #include FT_TRUETYPE_TAGS_H
 
-#include FT_SOURCE_FILE(cff,cffload.h)
-#include FT_SOURCE_FILE(cff,cffgload.h)
+#include "cffload.h"
+#include "cffgload.h"
 
 #include FT_INTERNAL_CFF_ERRORS_H
 
@@ -74,7 +74,7 @@
 
     cff_op_hintmask,
     cff_op_cntrmask,
-    cff_op_dotsection,
+    cff_op_dotsection,  /* deprecated, acts as no-op */
 
     cff_op_abs,
     cff_op_add,
@@ -1092,11 +1092,6 @@
           args = stack;
           break;
 
-        case cff_op_dotsection:
-
-          FT_TRACE4(( " dotsection" ));
-          break;
-
         case cff_op_rmoveto:
           FT_TRACE4(( " rmoveto" ));
 
@@ -1842,6 +1837,13 @@
           FT_TRACE4(( " load" ));
 
           goto Unimplemented;
+
+        case cff_op_dotsection:
+          {
+            /* this operator is deprecated and ignored by the parser */
+            FT_TRACE4(( " dotsection" ));
+          }
+          break;
 
         case cff_op_and:
           {
--- a/src/cff/cffgload.h
+++ b/src/cff/cffgload.h
@@ -22,7 +22,7 @@
 
 #include <ft2build.h>
 #include FT_FREETYPE_H
-#include FT_SOURCE_FILE(cff,cffobjs.h)
+#include "cffobjs.h"
 
 
 FT_BEGIN_HEADER
--- a/src/cff/cffload.c
+++ b/src/cff/cffload.c
@@ -8,7 +8,7 @@
 /*  David Turner, Robert Wilhelm, and Werner Lemberg.                      */
 /*                                                                         */
 /*  This file is part of the FreeType project, and may only be used,       */
-/*  modified, and distributed under the terms of the FreeType project      */
+/*  modified, and xdistributed under the terms of the FreeType project      */
 /*  license, LICENSE.TXT.  By continuing to use, modify, or distribute     */
 /*  this file you indicate that you have read the license and              */
 /*  understand and accept it fully.                                        */
@@ -24,8 +24,8 @@
 #include FT_INTERNAL_CFF_ERRORS_H
 #include FT_TRUETYPE_TAGS_H
 
-#include FT_SOURCE_FILE(cff,cffload.h)
-#include FT_SOURCE_FILE(cff,cffparse.h)
+#include "cffload.h"
+#include "cffparse.h"
 
 
   /*************************************************************************/
@@ -1790,7 +1790,7 @@
             for ( k = i; k < nleft + i; k++, glyph_code++ )
             {
               /* Make sure k is not too big. */
-              if ( k > num_glyphs )
+              if ( (FT_UInt)k > num_glyphs )
                 goto Exit;
 
               /* Assign code to GID mapping. */
--- a/src/cff/cffobjs.c
+++ b/src/cff/cffobjs.c
@@ -25,8 +25,8 @@
 #include FT_TRUETYPE_TAGS_H
 #include FT_INTERNAL_SFNT_H
 #include FT_INTERNAL_POSTSCRIPT_NAMES_H
-#include FT_SOURCE_FILE(cff,cffobjs.h)
-#include FT_SOURCE_FILE(cff,cffload.h)
+#include "cffobjs.h"
+#include "cffload.h"
 #include FT_INTERNAL_CFF_ERRORS_H
 
 #include <string.h>         /* for strlen() */
@@ -388,8 +388,8 @@
 
         /* set global bbox, as well as EM size */
         root->bbox         = dict->font_bbox;
-        root->ascender     = root->bbox.yMax >> 16;
-        root->descender    = root->bbox.yMin >> 16;
+        root->ascender     = (FT_Short)(root->bbox.yMax >> 16);
+        root->descender    = (FT_Short)(root->bbox.yMin >> 16);
         root->height       = ( ( root->ascender - root->descender ) * 12 ) / 10;
 
         if ( dict->units_per_em )
--- a/src/cff/cffparse.c
+++ b/src/cff/cffparse.c
@@ -17,7 +17,7 @@
 
 
 #include <ft2build.h>
-#include FT_SOURCE_FILE(cff,cffparse.h)
+#include "cffparse.h"
 #include FT_INTERNAL_CFF_ERRORS_H
 #include FT_INTERNAL_STREAM_H
 
@@ -477,7 +477,7 @@
   static const CFF_Field_Handler  cff_field_handlers[] =
   {
 
-#include FT_SOURCE_FILE(cff,cfftoken.h)
+#include "cfftoken.h"
 
     { 0, 0, 0, 0, 0, 0, 0 }
   };
--- a/src/cff/descrip.mms
+++ b/src/cff/descrip.mms
@@ -13,7 +13,7 @@
 # fully.
 
 
-CFLAGS=$(COMP_FLAGS)$(DEBUG)/include=[--.include]
+CFLAGS=$(COMP_FLAGS)$(DEBUG)/include=([--.include],[--.src.cff])
 
 OBJS=cff.obj
 
--- a/src/cff/rules.mk
+++ b/src/cff/rules.mk
@@ -19,7 +19,7 @@
 CFF_DIR_ := $(CFF_DIR)$(SEP)
 
 
-CFF_COMPILE := $(FT_COMPILE)
+CFF_COMPILE := $(FT_COMPILE) $I$(CFF_DIR)
 
 
 # CFF driver sources (i.e., C files)
--- a/src/cid/cidgload.c
+++ b/src/cid/cidgload.c
@@ -17,8 +17,8 @@
 
 
 #include <ft2build.h>
-#include FT_SOURCE_FILE(cid,cidload.h)
-#include FT_SOURCE_FILE(cid,cidgload.h)
+#include "cidload.h"
+#include "cidgload.h"
 #include FT_INTERNAL_DEBUG_H
 #include FT_INTERNAL_STREAM_H
 #include FT_OUTLINE_H
--- a/src/cid/cidgload.h
+++ b/src/cid/cidgload.h
@@ -21,7 +21,7 @@
 
 
 #include <ft2build.h>
-#include FT_SOURCE_FILE(cid,cidobjs.h)
+#include "cidobjs.h"
 
 
 FT_BEGIN_HEADER
--- a/src/cid/cidload.c
+++ b/src/cid/cidload.c
@@ -22,7 +22,7 @@
 #include FT_MULTIPLE_MASTERS_H
 #include FT_INTERNAL_TYPE1_TYPES_H
 #include FT_INTERNAL_TYPE1_ERRORS_H
-#include FT_SOURCE_FILE(cid,cidload.h)
+#include "cidload.h"
 
 #include <stdio.h>
 #include <ctype.h>  /* for isspace(), isalnum() */
@@ -271,15 +271,7 @@
   const T1_Field  cid_field_records[] =
   {
 
-#ifdef FT_FLAT_COMPILE
-
 #include "cidtokens.h"
-
-#else
-
-#include <cid/cidtokens.h>
-
-#endif
 
     T1_FIELD_CALLBACK( "FontBBox", parse_font_bbox )
     T1_FIELD_CALLBACK( "FDArray", parse_fd_array )
--- a/src/cid/cidload.h
+++ b/src/cid/cidload.h
@@ -22,7 +22,7 @@
 
 #include <ft2build.h>
 #include FT_INTERNAL_STREAM_H
-#include FT_SOURCE_FILE(cid,cidparse.h)
+#include "cidparse.h"
 
 
 FT_BEGIN_HEADER
--- a/src/cid/cidobjs.c
+++ b/src/cid/cidobjs.c
@@ -19,8 +19,8 @@
 #include <ft2build.h>
 #include FT_INTERNAL_DEBUG_H
 #include FT_INTERNAL_STREAM_H
-#include FT_SOURCE_FILE(cid,cidgload.h)
-#include FT_SOURCE_FILE(cid,cidload.h)
+#include "cidgload.h"
+#include "cidload.h"
 #include FT_INTERNAL_POSTSCRIPT_NAMES_H
 #include FT_INTERNAL_POSTSCRIPT_AUX_H
 
--- a/src/cid/cidparse.c
+++ b/src/cid/cidparse.c
@@ -22,7 +22,7 @@
 #include FT_INTERNAL_OBJECTS_H
 #include FT_INTERNAL_STREAM_H
 #include FT_INTERNAL_TYPE1_ERRORS_H
-#include FT_SOURCE_FILE(cid,cidparse.h)
+#include "cidparse.h"
 
 #include <string.h>     /* for strncmp() */
 
--- a/src/cid/cidriver.c
+++ b/src/cid/cidriver.c
@@ -17,8 +17,8 @@
 
 
 #include <ft2build.h>
-#include FT_SOURCE_FILE(cid,cidriver.h)
-#include FT_SOURCE_FILE(cid,cidgload.h)
+#include "cidriver.h"
+#include "cidgload.h"
 #include FT_INTERNAL_DEBUG_H
 #include FT_INTERNAL_STREAM_H
 #include FT_INTERNAL_POSTSCRIPT_NAMES_H
--- a/src/cid/descrip.mms
+++ b/src/cid/descrip.mms
@@ -13,7 +13,7 @@
 # fully.
 
 
-CFLAGS=$(COMP_FLAGS)$(DEBUG)/include=[--.include]
+CFLAGS=$(COMP_FLAGS)$(DEBUG)/include=([--.include],[--.src.cid])
 
 OBJS=type1cid.obj
 
--- a/src/cid/rules.mk
+++ b/src/cid/rules.mk
@@ -19,7 +19,7 @@
 CID_DIR_ := $(CID_DIR)$(SEP)
 
 
-CID_COMPILE := $(FT_COMPILE)
+CID_COMPILE := $(FT_COMPILE) $I$(CID_DIR)
 
 
 # CID driver sources (i.e., C files)
--- a/src/cid/type1cid.c
+++ b/src/cid/type1cid.c
@@ -19,11 +19,11 @@
 #define FT_MAKE_OPTION_SINGLE_OBJECT
 
 #include <ft2build.h>
-#include FT_SOURCE_FILE(cid,cidparse.c)
-#include FT_SOURCE_FILE(cid,cidload.c)
-#include FT_SOURCE_FILE(cid,cidobjs.c)
-#include FT_SOURCE_FILE(cid,cidriver.c)
-#include FT_SOURCE_FILE(cid,cidgload.c)
+#include "cidparse.c"
+#include "cidload.c"
+#include "cidobjs.c"
+#include "cidriver.c"
+#include "cidgload.c"
 
 
 /* END */
--- a/src/pcf/descrip.mms
+++ b/src/pcf/descrip.mms
@@ -25,7 +25,7 @@
 # THE SOFTWARE.
 
 
-CFLAGS=$(COMP_FLAGS)$(DEBUG)/include=[--.include]
+CFLAGS=$(COMP_FLAGS)$(DEBUG)/include=([--.include],[--.src.pcf])
 
 OBJS=pcf.obj
 
--- a/src/pcf/pcf.c
+++ b/src/pcf/pcf.c
@@ -29,8 +29,8 @@
 
 
 #include <ft2build.h>
-#include FT_SOURCE_FILE(pcf,pcfutil.c)
-#include FT_SOURCE_FILE(pcf,pcfread.c)
-#include FT_SOURCE_FILE(pcf,pcfdriver.c)
+#include "pcfutil.c"
+#include "pcfread.c"
+#include "pcfdriver.c"
 
 /* END */
--- a/src/pcf/pcf.h
+++ b/src/pcf/pcf.h
@@ -226,7 +226,7 @@
 
 #define GLYPHPADOPTIONS  4 /* I'm not sure about this */
 
-  static 
+  FT_LOCAL
   FT_Error  pcf_load_font( FT_Stream,
                            PCF_Face );
     
--- a/src/pcf/pcfdriver.c
+++ b/src/pcf/pcfdriver.c
@@ -32,9 +32,9 @@
 #include FT_INTERNAL_STREAM_H
 #include FT_INTERNAL_OBJECTS_H
 
-#include FT_SOURCE_FILE(pcf,pcf.h)
-#include FT_SOURCE_FILE(pcf,pcfdriver.h)
-#include FT_SOURCE_FILE(pcf,pcfutil.h)
+#include "pcf.h"
+#include "pcfdriver.h"
+#include "pcfutil.h"
 
 
   /*************************************************************************/
--- a/src/pcf/pcfread.c
+++ b/src/pcf/pcfread.c
@@ -32,8 +32,8 @@
 #include FT_INTERNAL_STREAM_H
 #include FT_INTERNAL_OBJECTS_H
 
-#include FT_SOURCE_FILE(pcf,pcf.h)
-#include FT_SOURCE_FILE(pcf,pcfdriver.h)
+#include "pcf.h"
+#include "pcfdriver.h"
 
 #include <string.h>     /* strlen(), strcpy() */
 
@@ -856,6 +856,7 @@
   }
 
 
+  FT_LOCAL_DEF
   FT_Error  pcf_load_font( FT_Stream  stream,
                            PCF_Face   face )
   {
--- a/src/pcf/pcfutil.c
+++ b/src/pcf/pcfutil.c
@@ -27,7 +27,7 @@
 
 
 #include <ft2build.h>
-#include FT_SOURCE_FILE(pcf,pcfutil.h)
+#include "pcfutil.h"
 
 
   /* Utility functions for reformatting font bitmaps */
--- a/src/pcf/rules.mk
+++ b/src/pcf/rules.mk
@@ -31,7 +31,7 @@
 PCF_DIR_ := $(PCF_DIR)$(SEP)
 
 
-PCF_COMPILE := $(FT_COMPILE)
+PCF_COMPILE := $(FT_COMPILE) $I$(PCF_DIR)
 
 
 # pcf driver sources (i.e., C files)
--- a/src/psaux/descrip.mms
+++ b/src/psaux/descrip.mms
@@ -13,7 +13,7 @@
 # fully.
 
 
-CFLAGS=$(COMP_FLAGS)$(DEBUG)/include=[--.include]
+CFLAGS=$(COMP_FLAGS)$(DEBUG)/include=([--.include],[--.src.psaux])
 
 OBJS=psaux.obj
 
--- a/src/psaux/psaux.c
+++ b/src/psaux/psaux.c
@@ -19,9 +19,9 @@
 #define FT_MAKE_OPTION_SINGLE_OBJECT
 
 #include <ft2build.h>
-#include FT_SOURCE_FILE(psaux,psobjs.c)
-#include FT_SOURCE_FILE(psaux,psauxmod.c)
-#include FT_SOURCE_FILE(psaux,t1decode.c)
+#include "psobjs.c"
+#include "psauxmod.c"
+#include "t1decode.c"
 
 
 /* END */
--- a/src/psaux/psauxmod.c
+++ b/src/psaux/psauxmod.c
@@ -17,9 +17,9 @@
 
 
 #include <ft2build.h>
-#include FT_SOURCE_FILE(psaux,psauxmod.h)
-#include FT_SOURCE_FILE(psaux,psobjs.h)
-#include FT_SOURCE_FILE(psaux,t1decode.h)
+#include "psauxmod.h"
+#include "psobjs.h"
+#include "t1decode.h"
 
 
   FT_CALLBACK_TABLE_DEF
--- a/src/psaux/psobjs.c
+++ b/src/psaux/psobjs.c
@@ -20,7 +20,7 @@
 #include FT_INTERNAL_POSTSCRIPT_AUX_H
 #include FT_INTERNAL_DEBUG_H
 #include FT_ERRORS_H
-#include FT_SOURCE_FILE(psaux,psobjs.h)
+#include "psobjs.h"
 
 
   /*************************************************************************/
--- a/src/psaux/rules.mk
+++ b/src/psaux/rules.mk
@@ -21,7 +21,7 @@
 
 # compilation flags for the driver
 #
-PSAUX_COMPILE := $(FT_COMPILE)
+PSAUX_COMPILE := $(FT_COMPILE) $I$(PSAUX_DIR)
 
 
 # PSAUX driver sources (i.e., C files)
--- a/src/psaux/t1decode.c
+++ b/src/psaux/t1decode.c
@@ -20,8 +20,8 @@
 #include FT_INTERNAL_DEBUG_H
 #include FT_INTERNAL_TYPE1_ERRORS_H
 #include FT_OUTLINE_H
-#include FT_SOURCE_FILE(psaux,t1decode.h)
-#include FT_SOURCE_FILE(psaux,psobjs.h)
+#include "t1decode.h"
+#include "psobjs.h"
 
 
   /*************************************************************************/
--- a/src/psnames/descrip.mms
+++ b/src/psnames/descrip.mms
@@ -13,7 +13,7 @@
 # fully.
 
 
-CFLAGS=$(COMP_FLAGS)$(DEBUG)/include=[--.include]
+CFLAGS=$(COMP_FLAGS)$(DEBUG)/include=([--.include],[--.src.psnames])
 
 OBJS=psnames.obj
 
--- a/src/psnames/psmodule.c
+++ b/src/psnames/psmodule.c
@@ -19,8 +19,8 @@
 #include <ft2build.h>
 #include FT_INTERNAL_POSTSCRIPT_NAMES_H
 #include FT_INTERNAL_OBJECTS_H
-#include FT_SOURCE_FILE(psnames,psmodule.h)
-#include FT_SOURCE_FILE(psnames,pstables.h)
+#include "psmodule.h"
+#include "pstables.h"
 
 #include <stdlib.h>     /* for qsort()             */
 #include <string.h>     /* for strcmp(), strncpy() */
--- a/src/psnames/psnames.c
+++ b/src/psnames/psnames.c
@@ -19,7 +19,7 @@
 #define FT_MAKE_OPTION_SINGLE_OBJECT
 
 #include <ft2build.h>
-#include FT_SOURCE_FILE(psnames,psmodule.c)
+#include "psmodule.c"
 
 
 /* END */
--- a/src/psnames/rules.mk
+++ b/src/psnames/rules.mk
@@ -21,7 +21,7 @@
 
 # compilation flags for the driver
 #
-PSNAMES_COMPILE := $(FT_COMPILE)
+PSNAMES_COMPILE := $(FT_COMPILE) $I$(PSNAMES_DIR)
 
 
 # PSNames driver sources (i.e., C files)
--- a/src/raster/descrip.mms
+++ b/src/raster/descrip.mms
@@ -13,7 +13,7 @@
 # fully.
 
 
-CFLAGS=$(COMP_FLAGS)$(DEBUG)/include=[--.include]
+CFLAGS=$(COMP_FLAGS)$(DEBUG)/include=([--.include],[--.src.raster])
 
 OBJS=raster.obj
 
--- a/src/raster/ftraster.c
+++ b/src/raster/ftraster.c
@@ -23,7 +23,7 @@
 
 
 #include <ft2build.h>
-#include FT_SOURCE_FILE(raster,ftraster.h)
+#include "ftraster.h"
 #include FT_INTERNAL_CALC_H   /* for FT_MulDiv only */
 
 
--- a/src/raster/ftrend1.c
+++ b/src/raster/ftrend1.c
@@ -19,8 +19,8 @@
 #include <ft2build.h>
 #include FT_INTERNAL_OBJECTS_H
 #include FT_OUTLINE_H
-#include FT_SOURCE_FILE(raster,ftrend1.h)
-#include FT_SOURCE_FILE(raster,ftraster.h)
+#include "ftrend1.h"
+#include "ftraster.h"
 
 
   /* initialize renderer -- init its raster */
--- a/src/raster/raster.c
+++ b/src/raster/raster.c
@@ -19,8 +19,8 @@
 #define FT_MAKE_OPTION_SINGLE_OBJECT
 
 #include <ft2build.h>
-#include FT_SOURCE_FILE(raster,ftraster.c)
-#include FT_SOURCE_FILE(raster,ftrend1.c)
+#include "ftraster.c"
+#include "ftrend1.c"
 
 
 /* END */
--- a/src/raster/rules.mk
+++ b/src/raster/rules.mk
@@ -20,7 +20,7 @@
 
 # compilation flags for the driver
 #
-RAS1_COMPILE := $(FT_COMPILE)
+RAS1_COMPILE := $(FT_COMPILE) $I$(RAS1_DIR)
 
 
 # raster1 driver sources (i.e., C files)
--- a/src/sfnt/descrip.mms
+++ b/src/sfnt/descrip.mms
@@ -13,7 +13,7 @@
 # fully.
 
 
-CFLAGS=$(COMP_FLAGS)$(DEBUG)/include=[--.include]
+CFLAGS=$(COMP_FLAGS)$(DEBUG)/include=([--.include],[--.src.sfnt])
 
 OBJS=sfnt.obj
 
--- a/src/sfnt/rules.mk
+++ b/src/sfnt/rules.mk
@@ -21,7 +21,7 @@
 
 # compilation flags for the driver
 #
-SFNT_COMPILE := $(FT_COMPILE)
+SFNT_COMPILE := $(FT_COMPILE) $I$(SFNT_DIR)
 
 
 # SFNT driver sources (i.e., C files)
--- a/src/sfnt/sfdriver.c
+++ b/src/sfnt/sfdriver.c
@@ -20,17 +20,17 @@
 #include FT_INTERNAL_SFNT_H
 #include FT_INTERNAL_OBJECTS_H
 
-#include FT_SOURCE_FILE(sfnt,sfdriver.h)
-#include FT_SOURCE_FILE(sfnt,ttload.h)
-#include FT_SOURCE_FILE(sfnt,ttcmap.h)
-#include FT_SOURCE_FILE(sfnt,sfobjs.h)
+#include "sfdriver.h"
+#include "ttload.h"
+#include "ttcmap.h"
+#include "sfobjs.h"
 
 #ifdef TT_CONFIG_OPTION_EMBEDDED_BITMAPS
-#include FT_SOURCE_FILE(sfnt,ttsbit.h)
+#include "ttsbit.h"
 #endif
 
 #ifdef TT_CONFIG_OPTION_POSTSCRIPT_NAMES
-#include FT_SOURCE_FILE(sfnt,ttpost.h)
+#include "ttpost.h"
 #endif
 
 #include <string.h>     /* for strcmp() */
--- a/src/sfnt/sfnt.c
+++ b/src/sfnt/sfnt.c
@@ -19,17 +19,17 @@
 #define FT_MAKE_OPTION_SINGLE_OBJECT
 
 #include <ft2build.h>
-#include FT_SOURCE_FILE(sfnt,ttload.c)
-#include FT_SOURCE_FILE(sfnt,ttcmap.c)
-#include FT_SOURCE_FILE(sfnt,sfobjs.c)
-#include FT_SOURCE_FILE(sfnt,sfdriver.c)
+#include "ttload.c"
+#include "ttcmap.c"
+#include "sfobjs.c"
+#include "sfdriver.c"
 
 #ifdef TT_CONFIG_OPTION_EMBEDDED_BITMAPS
-#include FT_SOURCE_FILE(sfnt,ttsbit.c)
+#include "ttsbit.c"
 #endif
 
 #ifdef TT_CONFIG_OPTION_POSTSCRIPT_NAMES
-#include FT_SOURCE_FILE(sfnt,ttpost.c)
+#include "ttpost.c"
 #endif
 
 
--- a/src/sfnt/sfobjs.c
+++ b/src/sfnt/sfobjs.c
@@ -17,8 +17,8 @@
 
 
 #include <ft2build.h>
-#include FT_SOURCE_FILE(sfnt,sfobjs.h)
-#include FT_SOURCE_FILE(sfnt,ttload.h)
+#include "sfobjs.h"
+#include "ttload.h"
 #include FT_INTERNAL_SFNT_H
 #include FT_INTERNAL_POSTSCRIPT_NAMES_H
 #include FT_TRUETYPE_NAMES_H
--- a/src/sfnt/ttcmap.c
+++ b/src/sfnt/ttcmap.c
@@ -19,8 +19,8 @@
 #include <ft2build.h>
 #include FT_INTERNAL_DEBUG_H
 #include FT_INTERNAL_TRUETYPE_ERRORS_H
-#include FT_SOURCE_FILE(sfnt,ttload.h)
-#include FT_SOURCE_FILE(sfnt,ttcmap.h)
+#include "ttload.h"
+#include "ttcmap.h"
 
 
   /*************************************************************************/
--- a/src/sfnt/ttload.c
+++ b/src/sfnt/ttload.c
@@ -22,8 +22,8 @@
 #include FT_INTERNAL_TRUETYPE_ERRORS_H
 #include FT_INTERNAL_STREAM_H
 #include FT_TRUETYPE_TAGS_H
-#include FT_SOURCE_FILE(sfnt,ttload.h)
-#include FT_SOURCE_FILE(sfnt,ttcmap.h)
+#include "ttload.h"
+#include "ttcmap.h"
 
 
   /*************************************************************************/
--- a/src/sfnt/ttpost.c
+++ b/src/sfnt/ttpost.c
@@ -29,8 +29,8 @@
 #include FT_INTERNAL_STREAM_H
 #include FT_INTERNAL_TRUETYPE_ERRORS_H
 #include FT_TRUETYPE_TAGS_H
-#include FT_SOURCE_FILE(sfnt,ttpost.h)
-#include FT_SOURCE_FILE(sfnt,ttload.h)
+#include "ttpost.h"
+#include "ttload.h"
 
 
   /*************************************************************************/
--- a/src/sfnt/ttsbit.c
+++ b/src/sfnt/ttsbit.c
@@ -21,7 +21,7 @@
 #include FT_INTERNAL_TRUETYPE_ERRORS_H
 #include FT_INTERNAL_STREAM_H
 #include FT_TRUETYPE_TAGS_H
-#include FT_SOURCE_FILE(sfnt,ttsbit.h)
+#include "ttsbit.h"
 
 
   /*************************************************************************/
--- a/src/sfnt/ttsbit.h
+++ b/src/sfnt/ttsbit.h
@@ -21,7 +21,7 @@
 
 
 #include <ft2build.h>
-#include FT_SOURCE_FILE(sfnt,ttload.h)
+#include "ttload.h"
 
 
 FT_BEGIN_HEADER
--- a/src/smooth/descrip.mms
+++ b/src/smooth/descrip.mms
@@ -13,7 +13,7 @@
 # fully.
 
 
-CFLAGS=$(COMP_FLAGS)$(DEBUG)/include=[--.include]
+CFLAGS=$(COMP_FLAGS)$(DEBUG)/include=([--.include],[--.src.smooth])
 
 OBJS=smooth.obj
 
--- a/src/smooth/ftgrays.c
+++ b/src/smooth/ftgrays.c
@@ -123,7 +123,7 @@
 #else /* _STANDALONE_ */
 
 #include <ft2build.h>
-#include FT_SOURCE_FILE(smooth,ftgrays.h)
+#include "ftgrays.h"
 #include FT_INTERNAL_OBJECTS_H
 #include FT_INTERNAL_DEBUG_H
 #include FT_OUTLINE_H
--- a/src/smooth/ftsmooth.c
+++ b/src/smooth/ftsmooth.c
@@ -19,8 +19,8 @@
 #include <ft2build.h>
 #include FT_INTERNAL_OBJECTS_H
 #include FT_OUTLINE_H
-#include FT_SOURCE_FILE(smooth,ftsmooth.h)
-#include FT_SOURCE_FILE(smooth,ftgrays.h)
+#include "ftsmooth.h"
+#include "ftgrays.h"
 
 
   /* initialize renderer -- init its raster */
--- a/src/smooth/rules.mk
+++ b/src/smooth/rules.mk
@@ -20,7 +20,7 @@
 
 # compilation flags for the driver
 #
-SMOOTH_COMPILE := $(FT_COMPILE)
+SMOOTH_COMPILE := $(FT_COMPILE) $I$(SMOOTH_DIR)
 
 
 # smooth driver sources (i.e., C files)
--- a/src/smooth/smooth.c
+++ b/src/smooth/smooth.c
@@ -19,8 +19,8 @@
 #define FT_MAKE_OPTION_SINGLE_OBJECT
 
 #include <ft2build.h>
-#include FT_SOURCE_FILE(smooth,ftgrays.c)
-#include FT_SOURCE_FILE(smooth,ftsmooth.c)
+#include "ftgrays.c"
+#include "ftsmooth.c"
 
 
 /* END */
--- a/src/truetype/descrip.mms
+++ b/src/truetype/descrip.mms
@@ -13,7 +13,7 @@
 # fully.
 
 
-CFLAGS=$(COMP_FLAGS)$(DEBUG)/include=[--.include]
+CFLAGS=$(COMP_FLAGS)$(DEBUG)/include=([--.include],[--.src.truetype])
 
 OBJS=truetype.obj
 
--- a/src/truetype/rules.mk
+++ b/src/truetype/rules.mk
@@ -21,7 +21,7 @@
 
 # compilation flags for the driver
 #
-TT_COMPILE := $(FT_COMPILE)
+TT_COMPILE := $(FT_COMPILE) $I$(TT_DIR)
 
 
 # TrueType driver sources (i.e., C files)
--- a/src/truetype/truetype.c
+++ b/src/truetype/truetype.c
@@ -19,13 +19,13 @@
 #define FT_MAKE_OPTION_SINGLE_OBJECT
 
 #include <ft2build.h>
-#include FT_SOURCE_FILE(truetype,ttdriver.c)   /* driver interface */
-#include FT_SOURCE_FILE(truetype,ttpload.c)    /* tables loader    */
-#include FT_SOURCE_FILE(truetype,ttgload.c)    /* glyph loader     */
-#include FT_SOURCE_FILE(truetype,ttobjs.c)     /* object manager   */
+#include "ttdriver.c"   /* driver interface */
+#include "ttpload.c"    /* tables loader    */
+#include "ttgload.c"    /* glyph loader     */
+#include "ttobjs.c"     /* object manager   */
 
 #ifdef TT_CONFIG_OPTION_BYTECODE_INTERPRETER
-#include FT_SOURCE_FILE(truetype,ttinterp.c)
+#include "ttinterp.c"
 #endif
 
 
--- a/src/truetype/ttdriver.c
+++ b/src/truetype/ttdriver.c
@@ -21,8 +21,8 @@
 #include FT_INTERNAL_STREAM_H
 #include FT_INTERNAL_SFNT_H
 #include FT_TRUETYPE_NAMES_H
-#include FT_SOURCE_FILE(truetype,ttdriver.h)
-#include FT_SOURCE_FILE(truetype,ttgload.h)
+#include "ttdriver.h"
+#include "ttgload.h"
 
 
   /*************************************************************************/
--- a/src/truetype/ttgload.c
+++ b/src/truetype/ttgload.c
@@ -24,7 +24,7 @@
 #include FT_TRUETYPE_TAGS_H
 #include FT_OUTLINE_H
 
-#include FT_SOURCE_FILE(truetype,ttgload.h)
+#include "ttgload.h"
 
 
   /*************************************************************************/
--- a/src/truetype/ttgload.h
+++ b/src/truetype/ttgload.h
@@ -21,10 +21,10 @@
 
 
 #include <ft2build.h>
-#include FT_SOURCE_FILE(truetype,ttobjs.h)
+#include "ttobjs.h"
 
 #ifdef TT_CONFIG_OPTION_BYTECODE_INTERPRETER
-#include FT_SOURCE_FILE(truetype,ttinterp.h)
+#include "ttinterp.h"
 #endif
 
 
--- a/src/truetype/ttinterp.c
+++ b/src/truetype/ttinterp.c
@@ -20,7 +20,7 @@
 #include FT_INTERNAL_DEBUG_H
 #include FT_INTERNAL_CALC_H
 #include FT_SYSTEM_H
-#include FT_SOURCE_FILE(truetype,ttinterp.h)
+#include "ttinterp.h"
 #include FT_INTERNAL_TRUETYPE_ERRORS_H
 
 
--- a/src/truetype/ttinterp.h
+++ b/src/truetype/ttinterp.h
@@ -21,7 +21,7 @@
 
 
 #include <ft2build.h>
-#include FT_SOURCE_FILE(truetype,ttobjs.h)
+#include "ttobjs.h"
 
 
 FT_BEGIN_HEADER
--- a/src/truetype/ttobjs.c
+++ b/src/truetype/ttobjs.c
@@ -26,11 +26,11 @@
 #include FT_INTERNAL_POSTSCRIPT_NAMES_H
 #include FT_INTERNAL_TRUETYPE_ERRORS_H
 
-#include FT_SOURCE_FILE(truetype,ttgload.h)
-#include FT_SOURCE_FILE(truetype,ttpload.h)
+#include "ttgload.h"
+#include "ttpload.h"
 
 #ifdef TT_CONFIG_OPTION_BYTECODE_INTERPRETER
-#include FT_SOURCE_FILE(truetype,ttinterp.h)
+#include "ttinterp.h"
 #endif
 
 
--- a/src/truetype/ttpload.c
+++ b/src/truetype/ttpload.c
@@ -21,7 +21,7 @@
 #include FT_INTERNAL_OBJECTS_H
 #include FT_INTERNAL_STREAM_H
 #include FT_TRUETYPE_TAGS_H
-#include FT_SOURCE_FILE(truetype,ttpload.h)
+#include "ttpload.h"
 #include FT_INTERNAL_TRUETYPE_ERRORS_H
 
 
--- a/src/type1/descrip.mms
+++ b/src/type1/descrip.mms
@@ -13,7 +13,7 @@
 # fully.
 
 
-CFLAGS=$(COMP_FLAGS)$(DEBUG)/include=[--.include]
+CFLAGS=$(COMP_FLAGS)$(DEBUG)/include=([--.include],[--.src.type1])
 
 OBJS=type1.obj
 
--- a/src/type1/rules.mk
+++ b/src/type1/rules.mk
@@ -21,7 +21,7 @@
 
 # compilation flags for the driver
 #
-T1_COMPILE := $(FT_COMPILE)
+T1_COMPILE := $(FT_COMPILE) $I$(T1_DIR)
 
 
 # Type1 driver sources (i.e., C files)
--- a/src/type1/t1afm.c
+++ b/src/type1/t1afm.c
@@ -17,7 +17,7 @@
 
 
 #include <ft2build.h>
-#include FT_SOURCE_FILE(type1,t1afm.h)
+#include "t1afm.h"
 #include FT_INTERNAL_STREAM_H
 #include FT_INTERNAL_TYPE1_TYPES_H
 #include <stdlib.h>  /* for qsort()   */
--- a/src/type1/t1afm.h
+++ b/src/type1/t1afm.h
@@ -20,7 +20,7 @@
 #define __T1AFM_H__
 
 #include <ft2build.h>
-#include FT_SOURCE_FILE(type1,t1objs.h)
+#include "t1objs.h"
 
 
 FT_BEGIN_HEADER
--- a/src/type1/t1driver.c
+++ b/src/type1/t1driver.c
@@ -17,12 +17,12 @@
 
 
 #include <ft2build.h>
-#include FT_SOURCE_FILE(type1,t1driver.h)
-#include FT_SOURCE_FILE(type1,t1gload.h)
-#include FT_SOURCE_FILE(type1,t1load.h)
+#include "t1driver.h"
+#include "t1gload.h"
+#include "t1load.h"
 
 #ifndef T1_CONFIG_OPTION_NO_AFM
-#include FT_SOURCE_FILE(type1,t1afm.h)
+#include "t1afm.h"
 #endif
 
 #include FT_INTERNAL_DEBUG_H
--- a/src/type1/t1gload.c
+++ b/src/type1/t1gload.c
@@ -17,7 +17,7 @@
 
 
 #include <ft2build.h>
-#include FT_SOURCE_FILE(type1,t1gload.h)
+#include "t1gload.h"
 #include FT_INTERNAL_DEBUG_H
 #include FT_INTERNAL_STREAM_H
 #include FT_OUTLINE_H
--- a/src/type1/t1gload.h
+++ b/src/type1/t1gload.h
@@ -21,7 +21,7 @@
 
 
 #include <ft2build.h>
-#include FT_SOURCE_FILE(type1,t1objs.h)
+#include "t1objs.h"
 
 
 FT_BEGIN_HEADER
--- a/src/type1/t1load.c
+++ b/src/type1/t1load.c
@@ -68,7 +68,7 @@
 #include FT_INTERNAL_TYPE1_TYPES_H
 #include FT_INTERNAL_TYPE1_ERRORS_H
 
-#include FT_SOURCE_FILE(type1,t1load.h)
+#include "t1load.h"
 
 #include <string.h>     /* for strncmp(), strcmp() */
 #include <ctype.h>      /* for isalnum()           */
@@ -1383,7 +1383,7 @@
   const T1_Field  t1_keywords[] =
   {
 
-#include FT_SOURCE_FILE(type1,t1tokens.h)
+#include "t1tokens.h"
 
     /* now add the special functions... */
     T1_FIELD_CALLBACK( "FontName", parse_font_name )
--- a/src/type1/t1load.h
+++ b/src/type1/t1load.h
@@ -25,7 +25,7 @@
 #include FT_INTERNAL_POSTSCRIPT_AUX_H
 #include FT_MULTIPLE_MASTERS_H
 
-#include FT_SOURCE_FILE(type1,t1parse.h)
+#include "t1parse.h"
 
 
 FT_BEGIN_HEADER
--- a/src/type1/t1objs.c
+++ b/src/type1/t1objs.c
@@ -22,11 +22,11 @@
 
 #include <string.h>         /* strcmp() */
 
-#include FT_SOURCE_FILE(type1,t1gload.h)
-#include FT_SOURCE_FILE(type1,t1load.h)
+#include "t1gload.h"
+#include "t1load.h"
 
 #ifndef T1_CONFIG_OPTION_NO_AFM
-#include FT_SOURCE_FILE(type1,t1afm.h)
+#include "t1afm.h"
 #endif
 
 #include FT_INTERNAL_POSTSCRIPT_NAMES_H
--- a/src/type1/t1parse.c
+++ b/src/type1/t1parse.c
@@ -39,7 +39,7 @@
 #include FT_INTERNAL_STREAM_H
 #include FT_INTERNAL_TYPE1_ERRORS_H
 #include FT_INTERNAL_POSTSCRIPT_AUX_H
-#include FT_SOURCE_FILE(type1,t1parse.h)
+#include "t1parse.h"
 
 #include <string.h>     /* for strncmp() */
 
--- a/src/type1/type1.c
+++ b/src/type1/type1.c
@@ -19,14 +19,14 @@
 #define FT_MAKE_OPTION_SINGLE_OBJECT
 
 #include <ft2build.h>
-#include FT_SOURCE_FILE(type1,t1parse.c)
-#include FT_SOURCE_FILE(type1,t1load.c)
-#include FT_SOURCE_FILE(type1,t1objs.c)
-#include FT_SOURCE_FILE(type1,t1driver.c)
-#include FT_SOURCE_FILE(type1,t1gload.c)
+#include "t1parse.c"
+#include "t1load.c"
+#include "t1objs.c"
+#include "t1driver.c"
+#include "t1gload.c"
 
 #ifndef T1_CONFIG_OPTION_NO_AFM
-#include FT_SOURCE_FILE(type1,t1afm.c)
+#include "t1afm.c"
 #endif
 
 
--- a/src/winfonts/descrip.mms
+++ b/src/winfonts/descrip.mms
@@ -13,7 +13,7 @@
 # fully.
 
 
-CFLAGS=$(COMP_FLAGS)$(DEBUG)/include=[--.include]
+CFLAGS=$(COMP_FLAGS)$(DEBUG)/include=([--.include],[--.src.winfonts])
 
 OBJS=winfnt.obj
 
--- a/src/winfonts/rules.mk
+++ b/src/winfonts/rules.mk
@@ -19,7 +19,7 @@
 FNT_DIR_ := $(FNT_DIR)$(SEP)
 
 
-FNT_COMPILE := $(FT_COMPILE)
+FNT_COMPILE := $(FT_COMPILE) $I$(FNT_DIR)
 
 
 # Windows driver sources (i.e., C files)
--- a/src/winfonts/winfnt.c
+++ b/src/winfonts/winfnt.c
@@ -22,7 +22,7 @@
 #include FT_INTERNAL_STREAM_H
 #include FT_INTERNAL_OBJECTS_H
 #include FT_INTERNAL_FNT_TYPES_H
-#include FT_SOURCE_FILE(winfonts,winfnt.h)
+#include "winfnt.h"
 
 
   /*************************************************************************/