summaryrefslogtreecommitdiff
path: root/extra/freetype2
diff options
context:
space:
mode:
authorParabola <dev@list.parabolagnulinux.org>2011-04-05 14:26:38 +0000
committerParabola <dev@list.parabolagnulinux.org>2011-04-05 14:26:38 +0000
commit415856bdd4f48ab4f2732996f0bae58595092bbe (patch)
treeede2018b591f6dfb477fe9341ba17b9bc000fab9 /extra/freetype2
Tue Apr 5 14:26:38 UTC 2011
Diffstat (limited to 'extra/freetype2')
-rw-r--r--extra/freetype2/PKGBUILD34
-rw-r--r--extra/freetype2/allow-hlineto-vlineto-without-arguments.patch57
-rw-r--r--extra/freetype2/freetype-2.2.1-enable-valid.patch20
-rw-r--r--extra/freetype2/freetype-2.3.0-enable-spr.patch11
4 files changed, 122 insertions, 0 deletions
diff --git a/extra/freetype2/PKGBUILD b/extra/freetype2/PKGBUILD
new file mode 100644
index 000000000..cfaffb725
--- /dev/null
+++ b/extra/freetype2/PKGBUILD
@@ -0,0 +1,34 @@
+# $Id: PKGBUILD 105523 2011-01-10 10:25:14Z jgc $
+# Maintainer: Jan de Groot <jgc@archlinux.org>
+
+pkgname=freetype2
+pkgver=2.4.4
+pkgrel=2
+pkgdesc="TrueType font rendering library"
+arch=(i686 x86_64)
+license=('GPL')
+url="http://freetype.sourceforge.net"
+depends=('zlib')
+options=('!libtool')
+source=(http://downloads.sourceforge.net/sourceforge/freetype/freetype-${pkgver}.tar.bz2
+ freetype-2.3.0-enable-spr.patch
+ freetype-2.2.1-enable-valid.patch
+ allow-hlineto-vlineto-without-arguments.patch)
+md5sums=('b3e2b6e2f1c3e0dffa1fd2a0f848b671'
+ '816dc8619a6904a7385769433c0a8653'
+ '214119610444c9b02766ccee5e220680')
+
+build() {
+ cd "${srcdir}/freetype-${pkgver}"
+ patch -Np1 -i "${srcdir}/freetype-2.3.0-enable-spr.patch"
+ patch -Np1 -i "${srcdir}/freetype-2.2.1-enable-valid.patch"
+ patch -Np1 -i "${srcdir}/allow-hlineto-vlineto-without-arguments.patch"
+
+ ./configure --prefix=/usr
+ make
+ make DESTDIR="${pkgdir}" install
+}
+md5sums=('b3e2b6e2f1c3e0dffa1fd2a0f848b671'
+ '816dc8619a6904a7385769433c0a8653'
+ '214119610444c9b02766ccee5e220680'
+ 'bb094e147b25892f1d04cfb5ff877bce')
diff --git a/extra/freetype2/allow-hlineto-vlineto-without-arguments.patch b/extra/freetype2/allow-hlineto-vlineto-without-arguments.patch
new file mode 100644
index 000000000..5990041aa
--- /dev/null
+++ b/extra/freetype2/allow-hlineto-vlineto-without-arguments.patch
@@ -0,0 +1,57 @@
+From 396b11b840f84e8bff62f3c361d0b592e77ee703 Mon Sep 17 00:00:00 2001
+From: Werner Lemberg <wl@gnu.org>
+Date: Thu, 09 Dec 2010 22:16:18 +0000
+Subject: [cff] Allow `hlineto' and `vlineto' without arguments.
+
+We simply ignore such instructions. This is invalid, but it doesn't
+harm; and indeed, there exist such subsetted fonts in PDFs.
+
+Reported by Albert Astals Cid <aacid@kde.org>.
+
+* src/cff/cffgload.c (cff_decoder_parse_charstrings)
+[cff_op_hlineto]: Ignore instruction if there aren't any arguments
+on the stack.
+---
+diff --git a/ChangeLog b/ChangeLog
+index b7aea52..579ae62 100644
+--- a/ChangeLog
++++ b/ChangeLog
+@@ -1,3 +1,16 @@
++2010-12-09 Werner Lemberg <wl@gnu.org>
++
++ [cff] Allow `hlineto' and `vlineto' without arguments.
++
++ We simply ignore such instructions. This is invalid, but it doesn't
++ harm; and indeed, there exist such subsetted fonts in PDFs.
++
++ Reported by Albert Astals Cid <aacid@kde.org>.
++
++ * src/cff/cffgload.c (cff_decoder_parse_charstrings)
++ [cff_op_hlineto]: Ignore instruction if there aren't any arguments
++ on the stack.
++
+ 2010-11-28 Werner Lemberg <wl@gnu.org>
+
+ * Version 2.4.4 released.
+diff --git a/src/cff/cffgload.c b/src/cff/cffgload.c
+index e99ee70..99c5b0c 100644
+--- a/src/cff/cffgload.c
++++ b/src/cff/cffgload.c
+@@ -1438,9 +1438,14 @@
+ FT_TRACE4(( op == cff_op_hlineto ? " hlineto\n"
+ : " vlineto\n" ));
+
+- if ( num_args < 1 )
++ if ( num_args < 0 )
+ goto Stack_Underflow;
+
++ /* there exist subsetted fonts (found in PDFs) */
++ /* which call `hlineto' without arguments */
++ if ( num_args == 0 )
++ break;
++
+ if ( cff_builder_start_point ( builder, x, y ) ||
+ check_points( builder, num_args ) )
+ goto Fail;
+--
+cgit v0.8.3.2
diff --git a/extra/freetype2/freetype-2.2.1-enable-valid.patch b/extra/freetype2/freetype-2.2.1-enable-valid.patch
new file mode 100644
index 000000000..c78b6b70f
--- /dev/null
+++ b/extra/freetype2/freetype-2.2.1-enable-valid.patch
@@ -0,0 +1,20 @@
+--- freetype-2.2.1/modules.cfg.orig 2006-07-07 21:01:09.000000000 -0400
++++ freetype-2.2.1/modules.cfg 2006-07-07 21:01:54.000000000 -0400
+@@ -110,7 +110,7 @@
+ AUX_MODULES += cache
+
+ # TrueType GX/AAT table validation. Needs ftgxval.c below.
+-# AUX_MODULES += gxvalid
++AUX_MODULES += gxvalid
+
+ # Support for streams compressed with gzip (files with suffix .gz).
+ #
+@@ -124,7 +124,7 @@
+
+ # OpenType table validation. Needs ftotval.c below.
+ #
+-# AUX_MODULES += otvalid
++AUX_MODULES += otvalid
+
+ # Auxiliary PostScript driver component to share common code.
+ #
diff --git a/extra/freetype2/freetype-2.3.0-enable-spr.patch b/extra/freetype2/freetype-2.3.0-enable-spr.patch
new file mode 100644
index 000000000..8432e28a4
--- /dev/null
+++ b/extra/freetype2/freetype-2.3.0-enable-spr.patch
@@ -0,0 +1,11 @@
+--- freetype-2.3.0/include/freetype/config/ftoption.h.spf 2007-01-18 14:27:34.000000000 -0500
++++ freetype-2.3.0/include/freetype/config/ftoption.h 2007-01-18 14:27:48.000000000 -0500
+@@ -92,7 +92,7 @@
+ /* This is done to allow FreeType clients to run unmodified, forcing */
+ /* them to display normal gray-level anti-aliased glyphs. */
+ /* */
+-/* #define FT_CONFIG_OPTION_SUBPIXEL_RENDERING */
++#define FT_CONFIG_OPTION_SUBPIXEL_RENDERING
+
+
+ /*************************************************************************/