public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
From: "Andreas Sturmlechner" <asturm@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: app-office/scribus/files/, app-office/scribus/
Date: Mon,  4 Mar 2024 22:18:37 +0000 (UTC)	[thread overview]
Message-ID: <1709590691.5f19629e0a9fc0e2ae03382664e72eea71526311.asturm@gentoo> (raw)

commit:     5f19629e0a9fc0e2ae03382664e72eea71526311
Author:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
AuthorDate: Mon Mar  4 22:15:58 2024 +0000
Commit:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
CommitDate: Mon Mar  4 22:18:11 2024 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=5f19629e

app-office/scribus: Fix build with >=app-text/poppler-24.03

Fix is pending upstream:
https://github.com/scribusproject/scribus/pull/177

Signed-off-by: Andreas Sturmlechner <asturm <AT> gentoo.org>

 .../files/scribus-1.6.1-poppler-24.03.patch        | 70 ++++++++++++++++++++++
 app-office/scribus/scribus-1.6.1-r1.ebuild         |  1 +
 2 files changed, 71 insertions(+)

diff --git a/app-office/scribus/files/scribus-1.6.1-poppler-24.03.patch b/app-office/scribus/files/scribus-1.6.1-poppler-24.03.patch
new file mode 100644
index 000000000000..076e48e14fd9
--- /dev/null
+++ b/app-office/scribus/files/scribus-1.6.1-poppler-24.03.patch
@@ -0,0 +1,70 @@
+From dc2470990ab73c87fdd60068c99518ced01a3edd Mon Sep 17 00:00:00 2001
+From: Andreas Sturmlechner <asturm@gentoo.org>
+Date: Mon, 4 Mar 2024 17:35:11 +0100
+Subject: [PATCH] Fix build with >=poppler-24.03.0
+
+Fixes build errors caused by:
+
+"Use an enum for Function getType"
+Upstream commit 6e3824d45d42cb806a28a2df84e4ab6bb3587083
+
+Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>
+---
+ scribus/plugins/import/pdf/slaoutput.cpp | 16 ++++++++++++++++
+ 1 file changed, 16 insertions(+)
+
+diff --git a/scribus/plugins/import/pdf/slaoutput.cpp b/scribus/plugins/import/pdf/slaoutput.cpp
+index 4e31e4b6c..3e4a768ec 100644
+--- a/scribus/plugins/import/pdf/slaoutput.cpp
++++ b/scribus/plugins/import/pdf/slaoutput.cpp
+@@ -1731,7 +1731,11 @@ bool SlaOutputDev::axialShadedFill(GfxState *state, GfxAxialShading *shading, do
+ 	VGradient FillGradient = VGradient(VGradient::linear);
+ 	FillGradient.clearStops();
+ 	GfxColorSpace *color_space = shading->getColorSpace();
++#if POPPLER_ENCODED_VERSION >= POPPLER_VERSION_ENCODE(24, 3, 0)
++	if (func->getType() == Function::Type::Stitching)
++#else
+ 	if (func->getType() == 3)
++#endif
+ 	{
+ 		StitchingFunction *stitchingFunc = (StitchingFunction*)func;
+ 		const double *bounds = stitchingFunc->getBounds();
+@@ -1753,7 +1757,11 @@ bool SlaOutputDev::axialShadedFill(GfxState *state, GfxAxialShading *shading, do
+ 			FillGradient.addStop( ScColorEngine::getShadeColor(m_doc->PageColors[stopColor], m_doc, shade), stopPoint, 0.5, 1.0, stopColor, shade );
+ 		}
+ 	}
++#if POPPLER_ENCODED_VERSION >= POPPLER_VERSION_ENCODE(24, 3, 0)
++	else if ((func->getType() == Function::Type::Exponential) || (func->getType() == Function::Type::Sampled))
++#else
+ 	else if ((func->getType() == 2) || (func->getType() == 0))
++#endif
+ 	{
+ 		GfxColor stop1;
+ 		shading->getColor(0.0, &stop1);
+@@ -1865,7 +1873,11 @@ bool SlaOutputDev::radialShadedFill(GfxState *state, GfxRadialShading *shading,
+ 	VGradient FillGradient = VGradient(VGradient::linear);
+ 	FillGradient.clearStops();
+ 	GfxColorSpace *color_space = shading->getColorSpace();
++#if POPPLER_ENCODED_VERSION >= POPPLER_VERSION_ENCODE(24, 3, 0)
++	if (func->getType() == Function::Type::Stitching)
++#else
+ 	if (func->getType() == 3)
++#endif
+ 	{
+ 		StitchingFunction *stitchingFunc = (StitchingFunction*)func;
+ 		const double *bounds = stitchingFunc->getBounds();
+@@ -1887,7 +1899,11 @@ bool SlaOutputDev::radialShadedFill(GfxState *state, GfxRadialShading *shading,
+ 			FillGradient.addStop( ScColorEngine::getShadeColor(m_doc->PageColors[stopColor], m_doc, shade), stopPoint, 0.5, 1.0, stopColor, shade );
+ 		}
+ 	}
++#if POPPLER_ENCODED_VERSION >= POPPLER_VERSION_ENCODE(24, 3, 0)
++	else if ((func->getType() == Function::Type::Exponential) || (func->getType() == Function::Type::Sampled))
++#else
+ 	else if ((func->getType() == 2) || (func->getType() == 0))
++#endif
+ 	{
+ 		GfxColor stop1;
+ 		shading->getColor(0.0, &stop1);
+-- 
+2.44.0
+

diff --git a/app-office/scribus/scribus-1.6.1-r1.ebuild b/app-office/scribus/scribus-1.6.1-r1.ebuild
index 3b9230eb12a6..21e17e6ae260 100644
--- a/app-office/scribus/scribus-1.6.1-r1.ebuild
+++ b/app-office/scribus/scribus-1.6.1-r1.ebuild
@@ -77,6 +77,7 @@ PATCHES=(
 	"${FILESDIR}"/${PN}-1.6.1-findhyphen.patch
 	"${FILESDIR}"/${PN}-1.7.0-remove-hello-world-test.patch
 	"${FILESDIR}"/${PN}-1.7.0-fix-icon-version.patch
+	"${FILESDIR}"/${PN}-1.6.1-poppler-24.03.patch
 )
 
 src_prepare() {


             reply	other threads:[~2024-03-04 22:18 UTC|newest]

Thread overview: 34+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-03-04 22:18 Andreas Sturmlechner [this message]
  -- strict thread matches above, loose matches on Subject: below --
2025-03-07 13:16 [gentoo-commits] repo/gentoo:master commit in: app-office/scribus/files/, app-office/scribus/ Andreas Sturmlechner
2024-11-03 20:36 Andreas Sturmlechner
2024-06-03 17:36 Miroslav Šulc
2024-05-22  7:39 Miroslav Šulc
2024-05-14 17:25 Andreas Sturmlechner
2024-01-14 10:24 Miroslav Šulc
2024-01-14  9:38 Miroslav Šulc
2024-01-01  9:30 Miroslav Šulc
2023-03-17  6:52 Miroslav Šulc
2023-02-06 10:36 Andreas Sturmlechner
2022-03-27  6:05 Miroslav Šulc
2022-02-10 19:38 Miroslav Šulc
2021-10-09 19:38 Sam James
2021-05-30 10:45 Miroslav Šulc
2021-03-07  1:30 Andreas Sturmlechner
2020-07-18  8:41 Andreas Sturmlechner
2020-05-30  9:31 Andreas Sturmlechner
2020-04-07  7:49 Andreas Sturmlechner
2019-12-29 11:54 Andreas Sturmlechner
2019-11-08 20:13 Andreas Sturmlechner
2019-10-01 23:43 Andreas Sturmlechner
2019-08-16  8:52 Miroslav Šulc
2019-06-23 16:44 Miroslav Šulc
2018-06-20 16:31 Andreas Sturmlechner
2018-05-10 15:55 Andreas Sturmlechner
2018-03-13 22:50 Andreas Sturmlechner
2018-01-09 13:46 Andreas Sturmlechner
2017-12-20 21:34 Justin Lecher
2016-11-06  8:25 Justin Lecher
2016-10-23 20:25 Justin Lecher
2016-09-27 18:50 Michael Weber
2015-10-19 12:06 Justin Lecher
2015-10-16 13:04 Justin Lecher

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1709590691.5f19629e0a9fc0e2ae03382664e72eea71526311.asturm@gentoo \
    --to=asturm@gentoo.org \
    --cc=gentoo-commits@lists.gentoo.org \
    --cc=gentoo-dev@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox