[HarfBuzz] harfbuzz documentation

Werner LEMBERG wl at gnu.org
Thu Jun 21 13:01:20 PDT 2012


Behdad,


given that there is zero documentation in harfbuzz, and your
whitepaper

  http://lists.freedesktop.org/archives/harfbuzz/2009-August/000359.html

is three years old while harfbuzz has evolved a lot meanwhile, I
wonder where I should start.  (BTW, you should temporarily add the
above e-mail to the git archive.)

Is there something *much* simpler than the programs in the `util'
directory which holds some nifty C++ code which is not easy to
comprehend?  I want to start using it for my ttfautohint program, but
I neither have an idea how cairo works nor how glib is structured...
In case these are prerequisites, it should be mentioned somewhere.

BTW, it seems to me that harfbuzz is plain C disguised as C++, right?

Below is a patch for current git so that autogen.sh works with
automake 1.12.1.  I also suggest to add a README.git file which lists
the various dependencies for bootstrapping, for example, pkg-config or
gobject-introspection (this is new).

Compiling with introspection set to true currently fails:

  GISCAN hb-1.0.gir
    /usr/local/include/freetype2/freetype/config/ftconfig.h:354:
      syntax error, unexpected '{', expecting ',' or ';' in '  {' at '{'
    /usr/local/include/freetype2/freetype/config/ftconfig.h:358:
      syntax error, unexpected identifier in
                    '    __asm__ __volatile__ (' at '__asm__'
    g-ir-scanner: hb: warning:
      112 warnings suppressed (use --warn-all to see them)
  GICOMP hb-1.0.gir
    error parsing file hb-1.0.gir: Line 20, character 32:
    The attribute 'name' on the element 'type' must be specified

What the heck are those GISCAN and GICOMP errors?

Compiling with introspection set to false fails too:

  make[2]: Entering directory `/home/wl/git/harfbuzz.compiled/src'
  /usr/share/gobject-introspection-1.0/Makefile.introspection:150:
    *** Need to define hb_1_0_gir_FILES.  Stop.

So I'm stuck...


    Werner


======================================================================


diff --git a/configure.ac b/configure.ac
index fc930e9..9da7f58 100644
--- a/configure.ac
+++ b/configure.ac
@@ -11,6 +11,10 @@ AC_CONFIG_HEADERS([config.h])
 AM_INIT_AUTOMAKE([1.11.1 gnu dist-bzip2 no-dist-gzip -Wall no-define])
 AM_SILENT_RULES([yes])
 
+# AM_PROG_AR is new in automake 1.11.2;
+# however, MinGW doesn't have it yet (June 2012)
+m4_ifdef([AM_PROG_AR], [AM_PROG_AR])
+
 # Initialize libtool
 LT_PREREQ([2.2])
 LT_INIT([disable-static])
@@ -195,6 +199,10 @@ fi
 
 dnl ===========================================================================
 
+AM_CONDITIONAL([HAVE_INTROSPECTION], [true])
+
+dnl ===========================================================================
+
 AC_CONFIG_FILES([
 Makefile
 harfbuzz.pc



More information about the HarfBuzz mailing list