[pango/harfbuzz-ng-external] Use external harfbuzz shared library from harfbuzz-ng
- From: Behdad Esfahbod <behdad src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [pango/harfbuzz-ng-external] Use external harfbuzz shared library from harfbuzz-ng
- Date: Wed, 4 Nov 2009 01:36:25 +0000 (UTC)
commit 1a9072ec14c2d57a53c90746e182884453e08957
Author: Behdad Esfahbod <behdad behdad org>
Date: Tue Nov 3 15:12:25 2009 -0500
Use external harfbuzz shared library from harfbuzz-ng
configure.in | 8 +-
pango/Makefile.am | 14 +-
pango/opentype/COPYING | 17 -
pango/opentype/Makefile.am | 58 -
pango/opentype/README | 9 -
pango/opentype/TODO | 6 -
pango/opentype/hb-blob.c | 376 ------
pango/opentype/hb-blob.h | 87 --
pango/opentype/hb-buffer-private.h | 135 --
pango/opentype/hb-buffer.c | 516 --------
pango/opentype/hb-buffer.h | 152 ---
pango/opentype/hb-common.h | 57 -
pango/opentype/hb-font-private.h | 96 --
pango/opentype/hb-font.cc | 323 -----
pango/opentype/hb-font.h | 186 ---
pango/opentype/hb-glib.c | 56 -
pango/opentype/hb-glib.h | 41 -
pango/opentype/hb-object-private.h | 105 --
pango/opentype/hb-open-file-private.hh | 220 ----
pango/opentype/hb-open-type-private.hh | 636 ----------
pango/opentype/hb-ot-layout-common-private.hh | 603 ---------
pango/opentype/hb-ot-layout-gdef-private.hh | 375 ------
pango/opentype/hb-ot-layout-gpos-private.hh | 1538 -----------------------
pango/opentype/hb-ot-layout-gsub-private.hh | 923 --------------
pango/opentype/hb-ot-layout-gsubgpos-private.hh | 958 --------------
pango/opentype/hb-ot-layout-private.h | 121 --
pango/opentype/hb-ot-layout.cc | 558 --------
pango/opentype/hb-ot-layout.h | 202 ---
pango/opentype/hb-ot.h | 34 -
pango/opentype/hb-private.h | 209 ---
pango/opentype/hb-shape.c | 40 -
pango/opentype/hb-shape.h | 53 -
pango/opentype/hb-unicode-private.h | 57 -
pango/opentype/hb-unicode.c | 161 ---
pango/opentype/hb-unicode.h | 219 ----
pango/opentype/hb.h | 35 -
pango/opentype/main.cc | 170 ---
pango/pango-ot-buffer.c | 15 +-
pango/pango-ot-info.c | 3 -
pango/pango-ot-private.h | 4 +-
40 files changed, 24 insertions(+), 9352 deletions(-)
---
diff --git a/configure.in b/configure.in
index ba17346..b3fb74b 100644
--- a/configure.in
+++ b/configure.in
@@ -366,7 +366,7 @@ have_cairo_atsui=false
cairo_required=1.7.6
PKG_CHECK_MODULES(CAIRO, cairo >= $cairo_required, have_cairo=true, AC_MSG_RESULT([no]))
-
+
if $have_cairo ; then
pango_save_libs=$LIBS
LIBS="$LIBS $CAIRO_LIBS"
@@ -448,6 +448,11 @@ AM_CONDITIONAL(HAVE_CAIRO_WIN32, $have_cairo_win32)
AM_CONDITIONAL(HAVE_CAIRO_FREETYPE, $have_cairo_freetype)
AM_CONDITIONAL(HAVE_CAIRO_ATSUI, $have_cairo_atsui)
+
+harfbuzz_required=0.1
+PKG_CHECK_MODULES(HARFBUZZ, harfbuzz >= $harfbuzz_required, have_harfbuzz=true, have_harfbuzz=false)
+AM_CONDITIONAL(HAVE_HARFBUZZ, $have_harfbuzz)
+
#
# We must have some backend defined, in order for the pango-querymodules
# rule in pango/Makefile.am to work correctly. If you are up to writing
@@ -994,7 +999,6 @@ AC_CONFIG_FILES([
Makefile
pango/Makefile
pango/mini-fribidi/Makefile
-pango/opentype/Makefile
pango/pango.rc
pango/pangoft2.rc
pango/pangowin32.rc
diff --git a/pango/Makefile.am b/pango/Makefile.am
index ef0245c..e1285b5 100644
--- a/pango/Makefile.am
+++ b/pango/Makefile.am
@@ -4,18 +4,10 @@
# which are more like other make's VPATH.
GPATH = $(srcdir)
-if HAVE_FREETYPE
-OPENTYPE_SUBDIR=opentype
-endif
-
EXTRA_DIST =
BUILT_GIRSOURCES =
-FRIBIDI_SUBDIR=mini-fribidi
-
-SUBDIRS = $(OPENTYPE_SUBDIR) $(FRIBIDI_SUBDIR)
-
-DIST_SUBDIRS = mini-fribidi opentype
+SUBDIRS = mini-fribidi
INCLUDES = \
-DG_LOG_DOMAIN=\"Pango\" \
@@ -28,6 +20,7 @@ INCLUDES = \
$(GLIB_CFLAGS) \
$(XFT_CFLAGS) \
$(CAIRO_CFLAGS) \
+ $(HARFBUZZ_CFLAGS) \
$(FREETYPE_CFLAGS) \
$(X_CFLAGS)
@@ -242,14 +235,13 @@ pangoft2_public_sources = \
libpangoft2_1_0_la_LDFLAGS = $(LIBRARY_LIBTOOL_OPTIONS)
libpangoft2_1_0_la_LIBADD = \
- opentype/libharfbuzz.la \
libpango-$(PANGO_API_VERSION).la \
$(INCLUDED_FC_MODULES) \
$(GLIB_LIBS) \
+ $(HARFBUZZ_LIBS) \
$(FREETYPE_LIBS) \
$(libm)
libpangoft2_1_0_la_DEPENDENCIES = \
- opentype/libharfbuzz.la \
libpango-$(PANGO_API_VERSION).la \
$(INCLUDED_FC_MODULES)
libpangoft2_1_0_la_SOURCES = \
diff --git a/pango/pango-ot-buffer.c b/pango/pango-ot-buffer.c
index a4aacc3..8965360 100644
--- a/pango/pango-ot-buffer.c
+++ b/pango/pango-ot-buffer.c
@@ -29,6 +29,17 @@ static hb_buffer_t *cached_buffer = NULL;
G_LOCK_DEFINE_STATIC (cached_buffer);
static hb_buffer_t *
+create_buffer (void)
+{
+ hb_buffer_t *buffer;
+
+ buffer = hb_buffer_create (32);
+ hb_buffer_set_unicode_funcs (buffer, hb_glib_get_unicode_funcs ());
+
+ return buffer;
+}
+
+static hb_buffer_t *
acquire_buffer (gboolean *free_buffer)
{
hb_buffer_t *buffer;
@@ -36,14 +47,14 @@ acquire_buffer (gboolean *free_buffer)
if (G_LIKELY (G_TRYLOCK (cached_buffer)))
{
if (G_UNLIKELY (!cached_buffer))
- cached_buffer = hb_buffer_create (64);
+ cached_buffer = create_buffer ();
buffer = cached_buffer;
*free_buffer = FALSE;
}
else
{
- buffer = hb_buffer_create (32);
+ buffer = create_buffer ();
*free_buffer = TRUE;
}
diff --git a/pango/pango-ot-info.c b/pango/pango-ot-info.c
index d6fa0da..c06065d 100644
--- a/pango/pango-ot-info.c
+++ b/pango/pango-ot-info.c
@@ -157,9 +157,6 @@ pango_ot_info_get (FT_Face face)
info->hb_face = hb_face_create_for_tables (_get_table, NULL, info);
}
-
- hb_face_set_unicode_funcs (info->hb_face, hb_glib_get_unicode_funcs ());
-
/* XXX this is such a waste if not SFNT */
if (!hb_ot_layout_has_font_glyph_classes (info->hb_face))
synthesize_class_def (info);
diff --git a/pango/pango-ot-private.h b/pango/pango-ot-private.h
index a011b74..9bd178f 100644
--- a/pango/pango-ot-private.h
+++ b/pango/pango-ot-private.h
@@ -25,8 +25,8 @@
#include <glib-object.h>
#include <pango/pango-ot.h>
-#include "opentype/hb-ot.h"
-#include "opentype/hb-glib.h"
+#include <hb-ot.h>
+#include <hb-glib.h>
G_BEGIN_DECLS
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]