summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndreas K. Hüttel <dilfridge@gentoo.org>2019-11-16 14:25:31 +0100
committerAndreas K. Hüttel <dilfridge@gentoo.org>2019-11-16 14:25:43 +0100
commit3e20f1daf5328ec3f6e512e927c892c247394020 (patch)
tree84c8112bd2c5d08dd3d93cfcd1f52337394fee04 /media-gfx/inkscape
parentdev-python/apipkg: Fix remaining MissingTestRestrict (diff)
downloadgentoo-3e20f1daf5328ec3f6e512e927c892c247394020.tar.gz
gentoo-3e20f1daf5328ec3f6e512e927c892c247394020.tar.bz2
gentoo-3e20f1daf5328ec3f6e512e927c892c247394020.zip
media-gfx/inkscape: Fix build with poppler-0.82
Closes: https://bugs.gentoo.org/677058 Package-Manager: Portage-2.3.79, Repoman-2.3.18 Signed-off-by: Andreas K. Hüttel <dilfridge@gentoo.org>
Diffstat (limited to 'media-gfx/inkscape')
-rw-r--r--media-gfx/inkscape/files/inkscape-0.92.4-poppler-0.82.0.patch76
-rw-r--r--media-gfx/inkscape/inkscape-0.92.4.ebuild1
2 files changed, 77 insertions, 0 deletions
diff --git a/media-gfx/inkscape/files/inkscape-0.92.4-poppler-0.82.0.patch b/media-gfx/inkscape/files/inkscape-0.92.4-poppler-0.82.0.patch
new file mode 100644
index 000000000000..73cc4f97c37b
--- /dev/null
+++ b/media-gfx/inkscape/files/inkscape-0.92.4-poppler-0.82.0.patch
@@ -0,0 +1,76 @@
+From 9b2f1a99bd8a411926925ac0c91f50289c7db8ee Mon Sep 17 00:00:00 2001
+From: Thomas Holder <thomas@thomas-holder.de>
+Date: Sat, 16 Nov 2019 14:12:24 +0100
+Subject: [PATCH] fix poppler 0.82.0 build
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+Backport of 324c7903d9fd62e74c042c31477299be3b980fd2 from master by
+Andreas K. Hüttel <dilfridge@gentoo.org>
+---
+ src/extension/internal/pdfinput/pdf-parser.cpp | 2 +-
+ src/extension/internal/pdfinput/poppler-transition-api.h | 6 ++++++
+ src/extension/internal/pdfinput/svg-builder.cpp | 2 +-
+ src/extension/internal/pdfinput/svg-builder.h | 2 +-
+ 4 files changed, 9 insertions(+), 3 deletions(-)
+
+diff --git a/src/extension/internal/pdfinput/pdf-parser.cpp b/src/extension/internal/pdfinput/pdf-parser.cpp
+index ddbff7671f..e71bb79381 100644
+--- a/src/extension/internal/pdfinput/pdf-parser.cpp
++++ b/src/extension/internal/pdfinput/pdf-parser.cpp
+@@ -2414,7 +2414,7 @@ void PdfParser::doShowText(GooString *s) {
+ int wMode;
+ double riseX, riseY;
+ CharCode code;
+- Unicode *u = NULL;
++ Unicode _POPPLER_CONST_82 *u = NULL;
+ double x, y, dx, dy, tdx, tdy;
+ double originX, originY, tOriginX, tOriginY;
+ double oldCTM[6], newCTM[6];
+diff --git a/src/extension/internal/pdfinput/poppler-transition-api.h b/src/extension/internal/pdfinput/poppler-transition-api.h
+index 21a60702fa..93c0f99ba1 100644
+--- a/src/extension/internal/pdfinput/poppler-transition-api.h
++++ b/src/extension/internal/pdfinput/poppler-transition-api.h
+@@ -3,6 +3,12 @@
+
+ #include <glib/poppler-features.h>
+
++#if POPPLER_CHECK_VERSION(0, 82, 0)
++#define _POPPLER_CONST_82 const
++#else
++#define _POPPLER_CONST_82
++#endif
++
+ #if POPPLER_CHECK_VERSION(0, 76, 0)
+ #define _POPPLER_NEW_PARSER(xref, obj) Parser(xref, obj, gFalse)
+ #else
+diff --git a/src/extension/internal/pdfinput/svg-builder.cpp b/src/extension/internal/pdfinput/svg-builder.cpp
+index 1cefb92abd..ea2940ffe1 100644
+--- a/src/extension/internal/pdfinput/svg-builder.cpp
++++ b/src/extension/internal/pdfinput/svg-builder.cpp
+@@ -1379,7 +1379,7 @@ void SvgBuilder::beginString(GfxState *state) {
+ void SvgBuilder::addChar(GfxState *state, double x, double y,
+ double dx, double dy,
+ double originX, double originY,
+- CharCode /*code*/, int /*nBytes*/, Unicode *u, int uLen) {
++ CharCode /*code*/, int /*nBytes*/, Unicode const *u, int uLen) {
+
+
+ bool is_space = ( uLen == 1 && u[0] == 32 );
+diff --git a/src/extension/internal/pdfinput/svg-builder.h b/src/extension/internal/pdfinput/svg-builder.h
+index 34b42e17b8..78e302081f 100644
+--- a/src/extension/internal/pdfinput/svg-builder.h
++++ b/src/extension/internal/pdfinput/svg-builder.h
+@@ -141,7 +141,7 @@ public:
+ void addChar(GfxState *state, double x, double y,
+ double dx, double dy,
+ double originX, double originY,
+- CharCode code, int nBytes, Unicode *u, int uLen);
++ CharCode code, int nBytes, Unicode const *u, int uLen);
+ void beginTextObject(GfxState *state);
+ void endTextObject(GfxState *state);
+
+--
+2.24.0
+
diff --git a/media-gfx/inkscape/inkscape-0.92.4.ebuild b/media-gfx/inkscape/inkscape-0.92.4.ebuild
index c38fe42d1a66..87203911632c 100644
--- a/media-gfx/inkscape/inkscape-0.92.4.ebuild
+++ b/media-gfx/inkscape/inkscape-0.92.4.ebuild
@@ -98,6 +98,7 @@ PATCHES=(
"${FILESDIR}/${PN}-0.91_pre3-sk-man.patch"
"${FILESDIR}/${PN}-0.48.4-epython.patch"
"${FILESDIR}/${PN}-0.92.4-poppler-0.76.0.patch" #684246
+ "${FILESDIR}/${PN}-0.92.4-poppler-0.82.0.patch"
)
S="${WORKDIR}/${MY_P}"