summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAvatar Timo Gurr <tgurr@exherbo.org> 2020-10-21 10:16:42 +0200
committerAvatar Timo Gurr <tgurr@exherbo.org> 2020-10-21 08:18:15 +0000
commitc2f24405ab0319063b7c2a19a400213ae8355b0b (patch)
tree1620e11731946a65b5038541089121a7e8907b32
parent3642a923e90b890adae787a4b04c9f37888b32cc (diff)
downloadarbor-c2f24405ab0319063b7c2a19a400213ae8355b0b.tar.gz
arbor-c2f24405ab0319063b7c2a19a400213ae8355b0b.tar.xz
ghostscript: update the freetype patch with the upstream version
-rw-r--r--packages/app-text/ghostscript/files/41ef9a0bc36b9db7115fbe9623f989bfb47bbade.patch53
-rw-r--r--packages/app-text/ghostscript/files/ghostscript-9.53.3-freetype-2.10.patch23
-rw-r--r--packages/app-text/ghostscript/ghostscript-9.53.3.exheres-04
3 files changed, 56 insertions, 24 deletions
diff --git a/packages/app-text/ghostscript/files/41ef9a0bc36b9db7115fbe9623f989bfb47bbade.patch b/packages/app-text/ghostscript/files/41ef9a0bc36b9db7115fbe9623f989bfb47bbade.patch
new file mode 100644
index 000000000..171c6209b
--- /dev/null
+++ b/packages/app-text/ghostscript/files/41ef9a0bc36b9db7115fbe9623f989bfb47bbade.patch
@@ -0,0 +1,53 @@
+Source/Upstream: Yes, fixed in git master
+Reason: Fix build with recent freetype versions
+
+From 41ef9a0bc36b9db7115fbe9623f989bfb47bbade Mon Sep 17 00:00:00 2001
+From: Chris Liddell <chris.liddell@artifex.com>
+Date: Tue, 20 Oct 2020 09:49:45 +0100
+Subject: [PATCH] Bug 702985: drop use of FT_CALLBACK_DEF() def
+
+From 2.10.3, Freetype disappeared the FT_CALLBACK_DEF() macro, which is what
+we used when defining our callbacks from Freetype.
+
+No guidance forthcoming from the Freetype developer who made those changes,
+so change to explicitly declaring the callbacks file static.
+
+Should fix the reported build failures.
+---
+ base/fapi_ft.c | 6 +++---
+ 1 file changed, 3 insertions(+), 3 deletions(-)
+
+diff --git a/base/fapi_ft.c b/base/fapi_ft.c
+index 65fa6dcf4..21aef2f06 100644
+--- a/base/fapi_ft.c
++++ b/base/fapi_ft.c
+@@ -125,7 +125,7 @@ static void
+ delete_inc_int_info(gs_fapi_server * a_server,
+ FT_IncrementalRec * a_inc_int_info);
+
+-FT_CALLBACK_DEF(void *)
++static void *
+ FF_alloc(FT_Memory memory, long size)
+ {
+ gs_memory_t *mem = (gs_memory_t *) memory->user;
+@@ -133,7 +133,7 @@ FF_alloc(FT_Memory memory, long size)
+ return (gs_malloc(mem, size, 1, "FF_alloc"));
+ }
+
+-FT_CALLBACK_DEF(void *)
++static void *
+ FF_realloc(FT_Memory memory, long cur_size, long new_size, void *block)
+ {
+ gs_memory_t *mem = (gs_memory_t *) memory->user;
+@@ -153,7 +153,7 @@ FT_CALLBACK_DEF(void *)
+ return (tmp);
+ }
+
+-FT_CALLBACK_DEF(void)
++static void
+ FF_free(FT_Memory memory, void *block)
+ {
+ gs_memory_t *mem = (gs_memory_t *) memory->user;
+--
+2.17.1
+
diff --git a/packages/app-text/ghostscript/files/ghostscript-9.53.3-freetype-2.10.patch b/packages/app-text/ghostscript/files/ghostscript-9.53.3-freetype-2.10.patch
deleted file mode 100644
index 4c66049e4..000000000
--- a/packages/app-text/ghostscript/files/ghostscript-9.53.3-freetype-2.10.patch
+++ /dev/null
@@ -1,23 +0,0 @@
-# Author: Christopher Alexander Chavez
-# Upstream-status: Reported (https://bugs.ghostscript.com/show_bug.cgi?id=702985)
-# This is a workaround for freetype moving FT_CALLBACK_DEF into a private,
-# non-installed header.
-
-
---- base/fapi_ft.c.orig
-+++ base/fapi_ft.c
-@@ -124,6 +124,14 @@
- static void
- delete_inc_int_info(gs_fapi_server * a_server,
- FT_IncrementalRec * a_inc_int_info);
-+
-+#ifndef FT_CALLBACK_DEF
-+#ifdef __cplusplus
-+#define FT_CALLBACK_DEF( x ) extern "C" x
-+#else
-+#define FT_CALLBACK_DEF( x ) static x
-+#endif
-+#endif
-
- FT_CALLBACK_DEF(void *)
- FF_alloc(FT_Memory memory, long size)
diff --git a/packages/app-text/ghostscript/ghostscript-9.53.3.exheres-0 b/packages/app-text/ghostscript/ghostscript-9.53.3.exheres-0
index 7f05b232e..284100ac2 100644
--- a/packages/app-text/ghostscript/ghostscript-9.53.3.exheres-0
+++ b/packages/app-text/ghostscript/ghostscript-9.53.3.exheres-0
@@ -53,7 +53,9 @@ DEPENDENCIES="
fonts/urw-fonts[>=20170801] [[ note = [ PostScript standard fonts ] ]]
"
-DEFAULT_SRC_PREPARE_PATCHES=( -p0 "${FILES}"/${PNV}-freetype-2.10.patch )
+DEFAULT_SRC_PREPARE_PATCHES=(
+ "${FILES}"/41ef9a0bc36b9db7115fbe9623f989bfb47bbade.patch
+)
src_prepare() {
# keep these around to build the auxiliary tools if we are cross-compiling