download.lst                                          |    4 -
 external/poppler/clang-std-ranges.patch.1             |   49 +++++++++++++++++-
 external/poppler/poppler-config.patch.1               |   14 ++---
 sdext/source/pdfimport/xpdfwrapper/pdfioutdev_gpl.cxx |    9 ++-
 sdext/source/pdfimport/xpdfwrapper/pnghelper.cxx      |   17 ++++--
 5 files changed, 74 insertions(+), 19 deletions(-)

New commits:
commit 0dc3f263ec49763a23037a8c4497f6f18e89c32b
Author:     Xisco Fauli <[email protected]>
AuthorDate: Mon May 5 10:03:10 2025 +0200
Commit:     Stephan Bergmann <[email protected]>
CommitDate: Mon Nov 17 13:50:58 2025 +0100

    poppler: uggrade to 25.05
    
    Downloaded from https://poppler.freedesktop.org/poppler-25.05.0.tar.xz
    
    Change-Id: Icd2b318cc01bedc5baeb4445a463a136ed6d7c48
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/184953
    Tested-by: Jenkins
    Reviewed-by: Xisco Fauli <[email protected]>
    Signed-off-by: Xisco Fauli <[email protected]>
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/186651
    Reviewed-by: Christian Lohmaier <[email protected]>
    (cherry picked from commit 7475b3583a59cf56db74d01adead17fb4b759376)
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/194035
    Reviewed-by: Michael Stahl <[email protected]>
    Tested-by: Jenkins CollaboraOffice <[email protected]>

diff --git a/download.lst b/download.lst
index 6aea981fc431..882e71f8a6d8 100644
--- a/download.lst
+++ b/download.lst
@@ -646,8 +646,8 @@ LIBTIFF_TARBALL := tiff-4.7.1.tar.xz
 # three static lines
 # so that git cherry-pick
 # will not run into conflicts
-POPPLER_SHA256SUM := 
b010c596dce127fba88532fd2f1043e55ea30601767952d0f2c0a80e7dc0da3d
-POPPLER_TARBALL := poppler-25.04.0.tar.xz
+POPPLER_SHA256SUM := 
9b1627c5b76816ac5e4052a03f5b605ba40b45cf06b02cadd0479620b499ab38
+POPPLER_TARBALL := poppler-25.05.0.tar.xz
 POPPLER_DATA_SHA256SUM := 
c835b640a40ce357e1b83666aabd95edffa24ddddd49b8daff63adb851cdab74
 POPPLER_DATA_TARBALL := poppler-data-0.4.12.tar.gz
 # three static lines
diff --git a/external/poppler/poppler-config.patch.1 
b/external/poppler/poppler-config.patch.1
index a12fb0107098..ecb0b6aca839 100644
--- a/external/poppler/poppler-config.patch.1
+++ b/external/poppler/poppler-config.patch.1
@@ -164,7 +164,7 @@ index 0fbd336a..451213f8 100644
 +/* #undef WORDS_BIGENDIAN */
 +
 +/* Define as const if the declaration of iconv() needs const. */
-+#define ICONV_CONST 
++#define ICONV_CONST
 +
 +/* Generate OPI comments in PS output. */
 +#define OPI_SUPPORT 1
@@ -179,7 +179,7 @@ index 0fbd336a..451213f8 100644
 +#define PACKAGE_NAME "poppler"
 +
 +/* Define to the full name and version of this package. */
-+#define PACKAGE_STRING "poppler 25.01.0"
++#define PACKAGE_STRING "poppler 25.05.0"
 +
 +/* Define to the one symbol short name of this package. */
 +#define PACKAGE_TARNAME "poppler"
@@ -188,7 +188,7 @@ index 0fbd336a..451213f8 100644
 +#define PACKAGE_URL ""
 +
 +/* Define to the version of this package. */
-+#define PACKAGE_VERSION "25.01.0"
++#define PACKAGE_VERSION "25.05.0"
 +
 +/* Poppler data dir */
 +#define POPPLER_DATADIR "/usr/local/share/poppler"
@@ -206,7 +206,7 @@ index 0fbd336a..451213f8 100644
 +/* #undef USE_FLOAT */
 +
 +/* Version number of package */
-+#define VERSION "25.01.0"
++#define VERSION "25.05.0"
 +
 +#if defined(__APPLE__)
 +#elif defined (_WIN32)
@@ -290,7 +290,7 @@ index 0fbd336a..451213f8 100644
 +
 +/* Defines the poppler version. */
 +#ifndef POPPLER_VERSION
-+#define POPPLER_VERSION "25.01.0"
++#define POPPLER_VERSION "25.05.0"
 +#endif
 +
 +/* Use single precision arithmetic in the Splash backend */
@@ -437,9 +437,9 @@ index 0fbd336a..451213f8 100644
 +
 +#include "poppler-global.h"
 +
-+#define POPPLER_VERSION "25.01.0"
++#define POPPLER_VERSION "25.05.0"
 +#define POPPLER_VERSION_MAJOR 25
-+#define POPPLER_VERSION_MINOR 1
++#define POPPLER_VERSION_MINOR 5
 +#define POPPLER_VERSION_MICRO 0
 +
 +namespace poppler
commit eda9c82c5656b41894e0a1dc09f79aef07795b24
Author:     Christian Lohmaier <[email protected]>
AuthorDate: Tue Apr 22 15:59:23 2025 +0200
Commit:     Stephan Bergmann <[email protected]>
CommitDate: Mon Nov 17 13:50:50 2025 +0100

    poppler: avoid more std::ranges afer update to 25.04.0
    
    Not supported by macOS 12.7 / XCode 14.2
    
    Change-Id: I114190ddc9e36c2660c78a4ea2eb1e7797dadf13
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/184444
    Tested-by: Jenkins
    Reviewed-by: Christian Lohmaier <[email protected]>
    Reviewed-by: Xisco Fauli <[email protected]>
    (cherry picked from commit 8cdbe3666440f81aa71539e8d38d5a93eec17b26)
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/184643
    (cherry picked from commit 195114ab640267d4051967c17c61df24fa8614b7)
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/194034
    Tested-by: Jenkins CollaboraOffice <[email protected]>
    Reviewed-by: Michael Stahl <[email protected]>

diff --git a/external/poppler/clang-std-ranges.patch.1 
b/external/poppler/clang-std-ranges.patch.1
index c1484d9ab81b..28841ed6a005 100644
--- a/external/poppler/clang-std-ranges.patch.1
+++ b/external/poppler/clang-std-ranges.patch.1
@@ -415,3 +415,48 @@ In file included from 
/opt/rh/gcc-toolset-12/root/usr/lib/gcc/x86_64-redhat-linu
      }
  }
  
+diff -ur poppler.org/poppler/TextOutputDev.cc poppler/poppler/TextOutputDev.cc
+--- poppler.org/poppler/TextOutputDev.cc       2025-04-22 15:42:57.000000000 
+0200
++++ poppler/poppler/TextOutputDev.cc   2025-04-22 15:49:06.000000000 +0200
+@@ -2419,7 +2419,11 @@
+                 }
+             }
+         }
++#ifndef __clang__
+         std::ranges::sort(words, &TextWord::cmpYX);
++#else
++        std::sort(words.begin(), words.end(), &TextWord::cmpYX);
++#endif
+ 
+     } else {
+         for (flow = text->flows; flow; flow = flow->next) {
+@@ -4402,9 +4406,17 @@
+         // if all lines in the region have the same rotation, use it;
+         // otherwise, use the page's primary rotation
+         if (oneRot) {
++#ifndef __clang__
+             std::ranges::sort(frags, &TextLineFrag::cmpYXLineRot);
++#else
++            std::sort(frags.begin(), frags.end(), 
&TextLineFrag::cmpYXLineRot);
++#endif
+         } else {
++#ifndef __clang__
+             std::ranges::sort(frags, &TextLineFrag::cmpYXPrimaryRot);
++#else
++            std::sort(frags.begin(), frags.end(), 
&TextLineFrag::cmpYXPrimaryRot);
++#endif
+         }
+         for (auto it = frags.begin(); it != frags.end();) {
+             double delta = maxIntraLineDelta * it->line->words->fontSize;
+@@ -5416,7 +5428,11 @@
+                 frags.back().computeCoords(true);
+             }
+         }
++#ifndef __clang__
+         std::ranges::sort(frags, &TextLineFrag::cmpYXPrimaryRot);
++#else
++        std::sort(frags.begin(), frags.end(), &TextLineFrag::cmpYXPrimaryRot);
++#endif
+         for (auto it = frags.begin(); it != frags.end();) {
+             double delta = maxIntraLineDelta * it->line->words->fontSize;
+             double base = it->base;
commit 7cdbfaf1b6c37ee4e1be9412bc9761482c4cdc90
Author:     Xisco Fauli <[email protected]>
AuthorDate: Wed Apr 2 16:27:00 2025 +0200
Commit:     Stephan Bergmann <[email protected]>
CommitDate: Mon Nov 17 13:50:43 2025 +0100

    poppler: upgrade to 25.04.0
    
    After 032d035220702523cf10d924fd436c9e6c83d24c
    "Enforce error checking on stream::reset" the return from reset
    has to be checked, otherwise it fails with
    error: ignoring return value of ‘bool ImageStream::reset()’, declared with 
attribute ‘nodiscard’ [-Werror=unused-result]
    
    Downloaded from https://poppler.freedesktop.org/poppler-25.04.0.tar.xz
    
    Change-Id: I5c6022b11c307f4293e4b2ea566e811053e3ab6f
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/183632
    Tested-by: Jenkins
    Reviewed-by: Xisco Fauli <[email protected]>
    (cherry picked from commit 4f13305178c1bf88dffceb42ec15d0944b808a5c)
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/184641
    Reviewed-by: Christian Lohmaier <[email protected]>
    (cherry picked from commit bea78814b532d1509950897d32f8c04cba306f0b)
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/194033
    Tested-by: Jenkins CollaboraOffice <[email protected]>
    Reviewed-by: Michael Stahl <[email protected]>

diff --git a/download.lst b/download.lst
index ea237ed73b6c..6aea981fc431 100644
--- a/download.lst
+++ b/download.lst
@@ -646,8 +646,8 @@ LIBTIFF_TARBALL := tiff-4.7.1.tar.xz
 # three static lines
 # so that git cherry-pick
 # will not run into conflicts
-POPPLER_SHA256SUM := 
21234cb2a9647d73c752ce4031e65a79d11a511a835f2798284c2497b8701dee
-POPPLER_TARBALL := poppler-25.02.0.tar.xz
+POPPLER_SHA256SUM := 
b010c596dce127fba88532fd2f1043e55ea30601767952d0f2c0a80e7dc0da3d
+POPPLER_TARBALL := poppler-25.04.0.tar.xz
 POPPLER_DATA_SHA256SUM := 
c835b640a40ce357e1b83666aabd95edffa24ddddd49b8daff63adb851cdab74
 POPPLER_DATA_TARBALL := poppler-data-0.4.12.tar.gz
 # three static lines
diff --git a/external/poppler/clang-std-ranges.patch.1 
b/external/poppler/clang-std-ranges.patch.1
index 0ba895cf1024..c1484d9ab81b 100644
--- a/external/poppler/clang-std-ranges.patch.1
+++ b/external/poppler/clang-std-ranges.patch.1
@@ -311,8 +311,8 @@ In file included from 
/opt/rh/gcc-toolset-12/root/usr/lib/gcc/x86_64-redhat-linu
          }
  
          lines.push_back(std::move(words));
-@@ -5456,7 +5460,11 @@
-         for (word = rawWords; word; word = word->next) {
+@@ -5385,7 +5385,11 @@
+         for (TextWord *word = rawWords; word; word = word->next) {
              s.clear();
              uText.resize(word->len());
 +#ifndef __clang__
diff --git a/sdext/source/pdfimport/xpdfwrapper/pdfioutdev_gpl.cxx 
b/sdext/source/pdfimport/xpdfwrapper/pdfioutdev_gpl.cxx
index a46932944ede..3ad86bf085c2 100644
--- a/sdext/source/pdfimport/xpdfwrapper/pdfioutdev_gpl.cxx
+++ b/sdext/source/pdfimport/xpdfwrapper/pdfioutdev_gpl.cxx
@@ -212,7 +212,8 @@ static void writeJpeg_( OutputBuffer& o_rOutputBuf, Stream* 
str )
 #else
     str = ((DCTStream *)str)->getRawStream();
 #endif
-    str->reset();
+    if (!str->reset())
+        return;
 
     o_rOutputBuf.clear();
     ExtractJpegData(str, o_rOutputBuf);
@@ -248,7 +249,8 @@ static void writePbm_(OutputBuffer& o_rOutputBuf, Stream* 
str, int width, int he
     o_rOutputBuf.resize(header_size);
 
     // initialize stream
-    str->reset();
+    if (!str->reset())
+        return;
 
     // copy the raw stream
     if( bInvert )
@@ -305,7 +307,8 @@ static void writePpm_( OutputBuffer&     o_rOutputBuf,
                         width,
                         colorMap->getNumPixelComps(),
                         colorMap->getBits()));
-    imgStr->reset();
+    if (!imgStr->reset())
+        return;
 
     for( int y=0; y<height; ++y)
     {
diff --git a/sdext/source/pdfimport/xpdfwrapper/pnghelper.cxx 
b/sdext/source/pdfimport/xpdfwrapper/pnghelper.cxx
index 798555fe2f54..c0547e761e59 100644
--- a/sdext/source/pdfimport/xpdfwrapper/pnghelper.cxx
+++ b/sdext/source/pdfimport/xpdfwrapper/pnghelper.cxx
@@ -214,7 +214,8 @@ void PngHelper::createPng( OutputBuffer&     o_rOutputBuf,
     int nLineSize = (width + 7)/8;
     aScanlines.reserve( nLineSize * height + height );
 
-    str->reset();
+    if (!str->reset())
+        return;
     for( int y = 0; y < height; y++ )
     {
         // determine filter type (none) for this scanline
@@ -252,7 +253,8 @@ void PngHelper::createPng( OutputBuffer& o_rOutputBuf,
                         width,
                         colorMap->getNumPixelComps(),
                         colorMap->getBits()));
-    imgStr->reset();
+    if (!imgStr->reset())
+        return;
 
     // create scan line data buffer
     OutputBuffer aScanlines;
@@ -289,7 +291,9 @@ void PngHelper::createPng( OutputBuffer& o_rOutputBuf,
                         maskColorMap->getNumPixelComps(),
                         maskColorMap->getBits()));
 
-    imgStrMask->reset();
+    if (!imgStrMask->reset())
+        return;
+
     for( int y = 0; y < maskHeight; ++y )
     {
         pm = imgStrMask->getLine();
@@ -337,7 +341,8 @@ void PngHelper::createPng( OutputBuffer& o_rOutputBuf,
                         width,
                         colorMap->getNumPixelComps(),
                         colorMap->getBits()));
-    imgStr->reset();
+    if (!imgStr->reset())
+        return;
 
     // create scan line data buffer
     OutputBuffer aScanlines;
@@ -371,7 +376,9 @@ void PngHelper::createPng( OutputBuffer& o_rOutputBuf,
     std::unique_ptr<ImageStream> imgStrMask(
         new ImageStream(maskStr, maskWidth, 1, 1));
 
-    imgStrMask->reset();
+    if (!imgStrMask->reset())
+        return;
+
     for( int y = 0; y < maskHeight; ++y )
     {
         for( int x = 0; x < maskWidth; ++x )

Reply via email to