public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
From: Marek Kasik <mkasik@redhat.com>
To: git-commits@fedoraproject.org
Subject: [rpms/scribus] epel9: Rebuild for poppler 24.08.0
Date: Wed, 04 Nov 2026 21:42:48 GMT	[thread overview]
Message-ID: <179382856824.1.9973624366460925676.rpms-scribus-1f13657293ac@fedoraproject.org> (raw)

            A new commit has been pushed.

            Repo   : rpms/scribus
            Branch : epel9
            Commit : 1f13657293ac505c7b0166177d8e04f95a6b4b7a
            Author : Marek Kasik <mkasik@redhat.com>
            Date   : 2024-08-22T16:13:43+02:00
            Stats  : +196/-0 in 6 file(s)
            URL    : https://src.fedoraproject.org/rpms/scribus/c/1f13657293ac505c7b0166177d8e04f95a6b4b7a?branch=epel9

            Log:
            Rebuild for poppler 24.08.0

Backport of changes necessary to do the rebuild.

---
diff --git a/scribus-1.6.1-c++20-warnings.patch b/scribus-1.6.1-c++20-warnings.patch
new file mode 100644
index 0000000..944055a
--- /dev/null
+++ b/scribus-1.6.1-c++20-warnings.patch
@@ -0,0 +1,30 @@
+From 3116328e804c7366ec64c4224cbf20b0f14e52c8 Mon Sep 17 00:00:00 2001
+From: Jean Ghali <jghali@libertysurf.fr>
+Date: Sun, 31 Mar 2024 21:40:42 +0000
+Subject: Fix C++20 related warning "template-id is not allowed for constructor
+ in C++20"
+
+git-svn-id: svn://scribus.net/trunk/Scribus@26079 11d20701-8431-0410-a711-e3c959e3b870
+
+diff --git a/scribus/third_party/lib2geom/rect.h b/scribus/third_party/lib2geom/rect.h
+index c740d847f..ae1934782 100644
+--- a/scribus/third_party/lib2geom/rect.h
++++ b/scribus/third_party/lib2geom/rect.h
+@@ -56,14 +56,14 @@ class D2<Interval> {
+   private:
+     Interval f[2];
+   public:
+-    D2<Interval>() { f[X] = f[Y] = Interval(0, 0); }
++    D2() { f[X] = f[Y] = Interval(0, 0); }
+     
+-    D2<Interval>(Interval const &a, Interval const &b) {
++    D2(Interval const &a, Interval const &b) {
+         f[X] = a;
+         f[Y] = b;
+     }
+ 
+-    D2<Interval>(Point const & a, Point const & b) {
++    D2(Point const & a, Point const & b) {
+         f[X] = Interval(a[X], b[X]);
+         f[Y] = Interval(a[Y], b[Y]);
+     }

diff --git a/scribus-1.6.1-c++20.patch b/scribus-1.6.1-c++20.patch
new file mode 100644
index 0000000..5544598
--- /dev/null
+++ b/scribus-1.6.1-c++20.patch
@@ -0,0 +1,27 @@
+From 985b7944e50b23f4558ba4ca539659f37b4b7ba4 Mon Sep 17 00:00:00 2001
+From: Jean Ghali <jghali@libertysurf.fr>
+Date: Thu, 2 May 2024 22:26:03 +0000
+Subject: Enforce C++20 when building with poppler >= 24.05.0
+
+git-svn-id: svn://scribus.net/trunk/Scribus@26125 11d20701-8431-0410-a711-e3c959e3b870
+
+diff --git a/CMakeLists_Dependencies.cmake b/CMakeLists_Dependencies.cmake
+index a19acfc23..33f827298 100644
+--- a/CMakeLists_Dependencies.cmake
++++ b/CMakeLists_Dependencies.cmake
+@@ -28,7 +28,14 @@ if (poppler_FOUND)
+ 	message(STATUS "Found poppler")
+ 	message(STATUS "Found poppler libs: ${poppler_LIBRARY}")
+ 	message(STATUS "Found poppler includes: ${poppler_INCLUDE_DIR}")
+-	if (poppler_VERSION VERSION_GREATER_EQUAL 22.01.0)
++	if (poppler_VERSION VERSION_GREATER_EQUAL 24.05.0)
++		message(STATUS "Poppler Version:" ${poppler_VERSION})
++		if (CMAKE_CXX_STANDARD LESS 20)
++			message(STATUS "C++20 is the minimum C++ standard since poppler 24.05.0")
++			message(STATUS "Enabling C++20 compiler features")
++			set(CMAKE_CXX_STANDARD 20)
++		endif()
++	elseif (poppler_VERSION VERSION_GREATER_EQUAL 22.01.0)
+ 		message(STATUS "Poppler Version:" ${poppler_VERSION})
+ 		if (CMAKE_CXX_STANDARD LESS 17)
+ 			message(STATUS "C++17 is the minimum C++ standard since poppler 22.01.0")

diff --git a/scribus-1.6.1-point-operator.patch b/scribus-1.6.1-point-operator.patch
new file mode 100644
index 0000000..030fc6d
--- /dev/null
+++ b/scribus-1.6.1-point-operator.patch
@@ -0,0 +1,42 @@
+From 8beacae24242c683d60cd280fec14ba5db6d8090 Mon Sep 17 00:00:00 2001
+From: Jean Ghali <jghali@libertysurf.fr>
+Date: Sat, 1 Jun 2024 22:03:54 +0000
+Subject: #17229: scribus fails to compile with boost 1.85.0
+
+git-svn-id: svn://scribus.net/trunk/Scribus@26169 11d20701-8431-0410-a711-e3c959e3b870
+
+diff --git a/scribus/third_party/lib2geom/point.h b/scribus/third_party/lib2geom/point.h
+index 9aa62461a..4e86740e1 100644
+--- a/scribus/third_party/lib2geom/point.h
++++ b/scribus/third_party/lib2geom/point.h
+@@ -121,10 +121,14 @@ class Point {
+ 
+     Point &operator*=(Matrix const &m);
+ 
+-    inline int operator == (const Point &in_pnt) {
++    inline bool operator==(const Point &in_pnt) const {
+         return ((_pt[X] == in_pnt[X]) && (_pt[Y] == in_pnt[Y]));
+     }
+ 
++    inline bool operator!=(const Point &in_pnt) const {
++        return ((_pt[X] != in_pnt[X]) || (_pt[Y] != in_pnt[Y]));
++    }
++
+     friend inline std::ostream &operator<< (std::ostream &out_file, const Geom::Point &in_pnt);
+ };
+ 
+@@ -144,14 +148,6 @@ inline Point operator^(Point const &a, Point const &b) {
+     return ret;
+ }
+ 
+-//IMPL: boost::EqualityComparableConcept
+-inline bool operator==(Point const &a, Point const &b) {
+-    return (a[X] == b[X]) && (a[Y] == b[Y]);
+-}
+-inline bool operator!=(Point const &a, Point const &b) {
+-    return (a[X] != b[X]) || (a[Y] != b[Y]);
+-}
+-
+ /** This is a lexicographical ordering for points.  It is remarkably useful for sweepline algorithms*/
+ inline bool operator<=(Point const &a, Point const &b) {
+     return ( ( a[Y] < b[Y] ) ||

diff --git a/scribus-1.6.1-poppler-24.03.0-fix.patch b/scribus-1.6.1-poppler-24.03.0-fix.patch
new file mode 100644
index 0000000..7c8968a
--- /dev/null
+++ b/scribus-1.6.1-poppler-24.03.0-fix.patch
@@ -0,0 +1,32 @@
+From 53e715d2f65ffaf6b78833d9dd012a93dbaaca93 Mon Sep 17 00:00:00 2001
+From: Jean Ghali <jghali@libertysurf.fr>
+Date: Tue, 5 Mar 2024 16:42:40 +0000
+Subject: Fix incorrect value used in initial build fix against poppler 24.03.
+ See
+ https://gitlab.freedesktop.org/poppler/poppler/-/commit/6e3824d45d42cb806a28a2df84e4ab6bb3587083
+ for details.
+
+git-svn-id: svn://scribus.net/trunk/Scribus@26047 11d20701-8431-0410-a711-e3c959e3b870
+
+diff --git a/scribus/plugins/import/pdf/slaoutput.cpp b/scribus/plugins/import/pdf/slaoutput.cpp
+index f5297bba7..e69c4177c 100644
+--- a/scribus/plugins/import/pdf/slaoutput.cpp
++++ b/scribus/plugins/import/pdf/slaoutput.cpp
+@@ -1758,7 +1758,7 @@ bool SlaOutputDev::axialShadedFill(GfxState *state, GfxAxialShading *shading, do
+ 		}
+ 	}
+ #if POPPLER_ENCODED_VERSION >= POPPLER_VERSION_ENCODE(24, 3, 0)
+-	else if ((func->getType() == Function::Type::Exponential) || (func->getType() == Function::Type::Identity))
++	else if ((func->getType() == Function::Type::Exponential) || (func->getType() == Function::Type::Sampled))
+ #else
+ 	else if ((func->getType() == 2) || (func->getType() == 0))
+ #endif
+@@ -1900,7 +1900,7 @@ bool SlaOutputDev::radialShadedFill(GfxState *state, GfxRadialShading *shading,
+ 		}
+ 	}
+ #if POPPLER_ENCODED_VERSION >= POPPLER_VERSION_ENCODE(24, 3, 0)
+-	else if ((func->getType() == Function::Type::Exponential) || (func->getType() == Function::Type::Identity))
++	else if ((func->getType() == Function::Type::Exponential) || (func->getType() == Function::Type::Sampled))
+ #else
+ 	else if ((func->getType() == 2) || (func->getType() == 0))
+ #endif

diff --git a/scribus-1.6.1-poppler-24.03.0.patch b/scribus-1.6.1-poppler-24.03.0.patch
new file mode 100644
index 0000000..a188164
--- /dev/null
+++ b/scribus-1.6.1-poppler-24.03.0.patch
@@ -0,0 +1,59 @@
+From c57362c4f7bdef67904bf2f3d8126073792bdcf9 Mon Sep 17 00:00:00 2001
+From: Jean Ghali <jghali@libertysurf.fr>
+Date: Mon, 4 Mar 2024 20:39:54 +0000
+Subject: Fix build failure with poppler 24.03.0
+
+git-svn-id: svn://scribus.net/trunk/Scribus@26042 11d20701-8431-0410-a711-e3c959e3b870
+
+diff --git a/scribus/plugins/import/pdf/slaoutput.cpp b/scribus/plugins/import/pdf/slaoutput.cpp
+index 4e31e4b6c..58f030503 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::Identity))
++#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::Identity))
++#else
+ 	else if ((func->getType() == 2) || (func->getType() == 0))
++#endif
+ 	{
+ 		GfxColor stop1;
+ 		shading->getColor(0.0, &stop1);

diff --git a/scribus.spec b/scribus.spec
index 0824b95..8739f5c 100644
--- a/scribus.spec
+++ b/scribus.spec
@@ -14,6 +14,12 @@ Source0:        %{name}-%{version}-free.tar.xz
 #Source0:        http://downloads.sourceforge.net/%%{name}/%%{name}-%%{version}.tar.xz
 #Source1:        http://downloads.sourceforge.net/%%{name}/%%{name}-%%{version}.tar.xz.asc
 
+# Enforce C++20 due to poppler
+Patch0:         scribus-1.6.1-c++20.patch
+Patch1:         scribus-1.6.1-c++20-warnings.patch
+Patch2:         scribus-1.6.1-point-operator.patch
+Patch3:         scribus-1.6.1-poppler-24.03.0.patch
+Patch4:         scribus-1.6.1-poppler-24.03.0-fix.patch
 
 BuildRequires:  boost-devel
 BuildRequires:  cmake

                 reply	other threads:[~2026-11-04 21:42 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=179382856824.1.9973624366460925676.rpms-scribus-1f13657293ac@fedoraproject.org \
    --to=mkasik@redhat.com \
    --cc=git-commits@fedoraproject.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