Fix build with newer freetype by using the #defines to reach includes.

Also from FreeBSD.
This commit is contained in:
landry 2014-01-10 18:17:06 +00:00
parent e703f7360d
commit 2949b18fa5
4 changed files with 58 additions and 15 deletions

View File

@ -0,0 +1,13 @@
$OpenBSD: patch-lily_freetype-error_cc,v 1.1 2014/01/10 18:17:06 landry Exp $
--- lily/freetype-error.cc.orig Fri Jan 10 18:55:04 2014
+++ lily/freetype-error.cc Fri Jan 10 18:55:25 2014
@@ -31,7 +31,8 @@ const struct Freetype_error_message
const char* err_msg;
} ft_errors[] =
-#include <freetype/fterrors.h>
+#include <ft2build.h>
+#include FT_ERRORS_H
;

View File

@ -1,10 +1,20 @@
$OpenBSD: patch-lily_open-type-font_cc,v 1.1 2011/07/06 14:14:06 kili Exp $
$OpenBSD: patch-lily_open-type-font_cc,v 1.2 2014/01/10 18:17:07 landry Exp $
Make g++-3.3.5 happy.
--- lily/open-type-font.cc.orig Sun Jun 12 16:05:50 2011
+++ lily/open-type-font.cc Sat Jun 25 12:29:24 2011
@@ -220,8 +220,9 @@ Open_type_font::get_indexed_char_dimensions (size_t si
--- lily/open-type-font.cc.orig Tue Jul 26 00:42:15 2011
+++ lily/open-type-font.cc Fri Jan 10 18:54:41 2014
@@ -23,7 +23,8 @@
using namespace std;
-#include <freetype/tttables.h>
+#include <ft2build.h>
+#include FT_TRUETYPE_TABLES_H
#include "dimensions.hh"
#include "international.hh"
@@ -220,8 +221,9 @@ Open_type_font::get_indexed_char_dimensions (size_t si
FT_Glyph_Metrics m = face_->glyph->metrics;
FT_Pos hb = m.horiBearingX;
FT_Pos vb = m.horiBearingY;

View File

@ -1,7 +1,17 @@
$OpenBSD: patch-lily_pango-font_cc,v 1.2 2011/07/06 14:14:06 kili Exp $
--- lily/pango-font.cc.orig Sun Jun 12 16:05:50 2011
+++ lily/pango-font.cc Sun Jun 19 13:45:40 2011
@@ -95,19 +95,21 @@ Pango_font::derived_mark () const
$OpenBSD: patch-lily_pango-font_cc,v 1.3 2014/01/10 18:17:07 landry Exp $
--- lily/pango-font.cc.orig Tue Jul 26 00:42:15 2011
+++ lily/pango-font.cc Fri Jan 10 18:56:00 2014
@@ -22,7 +22,8 @@
#define PANGO_ENABLE_BACKEND
#include <pango/pangoft2.h>
-#include <freetype/ftxf86.h>
+#include <ft2build.h>
+#include FT_XFREE86_H
#include <map>
#include <cstdio>
@@ -95,19 +96,21 @@ Pango_font::derived_mark () const
void
get_glyph_index_name (char *s,
@ -26,7 +36,7 @@ $OpenBSD: patch-lily_pango-font_cc,v 1.2 2011/07/06 14:14:06 kili Exp $
}
Stencil
@@ -195,7 +197,7 @@ Pango_font::pango_item_string_stencil (PangoGlyphItem
@@ -195,7 +198,7 @@ Pango_font::pango_item_string_stencil (PangoGlyphItem
&& cmap->find (pg) != cmap->end ())
{
FT_ULong char_code = cmap->find (pg)->second;
@ -35,7 +45,7 @@ $OpenBSD: patch-lily_pango-font_cc,v 1.2 2011/07/06 14:14:06 kili Exp $
}
if (glyph_name[0] == '\0' && has_glyph_names)
@@ -212,7 +214,7 @@ Pango_font::pango_item_string_stencil (PangoGlyphItem
@@ -212,7 +215,7 @@ Pango_font::pango_item_string_stencil (PangoGlyphItem
if (glyph_name[0] == '\0' && is_ttf)
// Access by glyph index directly.

View File

@ -1,7 +1,17 @@
$OpenBSD: patch-lily_ttf_cc,v 1.4 2011/07/06 14:14:06 kili Exp $
--- lily/ttf.cc.orig Sun Jun 12 16:05:50 2011
+++ lily/ttf.cc Sun Jun 19 13:45:47 2011
@@ -440,7 +440,7 @@ print_trailer (void *out,
$OpenBSD: patch-lily_ttf_cc,v 1.5 2014/01/10 18:17:07 landry Exp $
--- lily/ttf.cc.orig Tue Jul 26 00:42:15 2011
+++ lily/ttf.cc Fri Jan 10 18:56:22 2014
@@ -20,7 +20,8 @@
#include <cstdio>
#include "freetype.hh"
-#include <freetype/tttables.h>
+#include <ft2build.h>
+#include FT_TRUETYPE_TABLES_H
#include "international.hh"
#include "memory-stream.hh"
@@ -440,7 +441,7 @@ print_trailer (void *out,
if (!glyph_name[0] && ic_map.find (i) != ic_map.end ())
{
FT_ULong ucode = ic_map[i];
@ -10,7 +20,7 @@ $OpenBSD: patch-lily_ttf_cc,v 1.4 2011/07/06 14:14:06 kili Exp $
}
if (i == 0)
@@ -449,7 +449,7 @@ print_trailer (void *out,
@@ -449,7 +450,7 @@ print_trailer (void *out,
glyph_name[0] = '\0';
if (!glyph_name[0])