[arch-commits] Commit in kitinerary/trunk (PKGBUILD poppler-21.8.0.patch)

Evangelos Foutras foutrelis at gemini.archlinux.org
Sun Aug 1 19:48:08 UTC 2021


    Date: Sunday, August 1, 2021 @ 19:48:07
  Author: foutrelis
Revision: 421002

Add untested patch for poppler 21.8.0

Added:
  kitinerary/trunk/poppler-21.8.0.patch
Modified:
  kitinerary/trunk/PKGBUILD

----------------------+
 PKGBUILD             |   10 ++++++++--
 poppler-21.8.0.patch |   41 +++++++++++++++++++++++++++++++++++++++++
 2 files changed, 49 insertions(+), 2 deletions(-)

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2021-08-01 18:48:49 UTC (rev 421001)
+++ PKGBUILD	2021-08-01 19:48:07 UTC (rev 421002)
@@ -9,13 +9,19 @@
 license=(LGPL)
 depends=(kmime kpkpass kcalendarcore kcontacts poppler libphonenumber zxing-cpp)
 makedepends=(extra-cmake-modules)
-source=(https://download.kde.org/stable/release-service/$pkgver/src/$pkgname-$pkgver.tar.xz{,.sig})
+source=(https://download.kde.org/stable/release-service/$pkgver/src/$pkgname-$pkgver.tar.xz{,.sig}
+        poppler-21.8.0.patch)
 sha256sums=('5cee2f06b446997e0414e131618149f124c437aa50b6808494f4902f3178fc61'
-            'SKIP')
+            'SKIP'
+            'ac4cae76f3d4392c4dc3c41f0a0ee26d79c9937f4451736f64cd114bdaa94d28')
 validpgpkeys=(CA262C6C83DE4D2FB28A332A3A6A4DB839EAA6D7  # Albert Astals Cid <aacid at kde.org>
               F23275E4BF10AFC1DF6914A6DBD2CE893E2D1C87  # Christoph Feck <cfeck at kde.org>
               D81C0CB38EB725EF6691C385BB463350D6EF31EF) # Heiko Becker <heiko.becker at kde.org>
 
+prepare() {
+  patch -Np1 -d $pkgname-$pkgver <poppler-21.8.0.patch
+}
+
 build() {
   cmake -B build -S $pkgname-$pkgver \
     -DCMAKE_INSTALL_LIBEXECDIR=lib \

Added: poppler-21.8.0.patch
===================================================================
--- poppler-21.8.0.patch	                        (rev 0)
+++ poppler-21.8.0.patch	2021-08-01 19:48:07 UTC (rev 421002)
@@ -0,0 +1,41 @@
+diff -upr kitinerary-21.04.3.orig/src/lib/pdf/pdfdocument.cpp kitinerary-21.04.3/src/lib/pdf/pdfdocument.cpp
+--- kitinerary-21.04.3.orig/src/lib/pdf/pdfdocument.cpp	2021-07-05 22:24:08.000000000 +0300
++++ kitinerary-21.04.3/src/lib/pdf/pdfdocument.cpp	2021-08-01 22:44:05.114172443 +0300
+@@ -201,7 +201,14 @@ int PdfDocument::fileSize() const
+ }
+ 
+ #ifdef HAVE_POPPLER
+-static QDateTime parsePdfDateTime(const char *str)
++
++#if KPOPPLER_VERSION >= QT_VERSION_CHECK(21, 8, 0)
++#define KPOPPLER_DATE_STRING_TYPE GooString
++#else
++#define KPOPPLER_DATE_STRING_TYPE char
++#endif
++
++static QDateTime parsePdfDateTime(const KPOPPLER_DATE_STRING_TYPE *str)
+ {
+     int year, month, day, hour, min, sec, tzHours, tzMins;
+     char tz;
+@@ -233,7 +240,9 @@ QDateTime PdfDocument::creationTime() co
+     if (!dt) {
+         return {};
+     }
+-#if KPOPPLER_VERSION >= QT_VERSION_CHECK(0, 72, 0)
++#if KPOPPLER_VERSION >= QT_VERSION_CHECK(21, 8, 0)
++    return parsePdfDateTime(dt.get());
++#elif KPOPPLER_VERSION >= QT_VERSION_CHECK(0, 72, 0)
+     return parsePdfDateTime(dt->c_str());
+ #else
+     return parsePdfDateTime(dt->getCString());
+@@ -250,7 +259,9 @@ QDateTime PdfDocument::modificationTime(
+     if (!dt) {
+         return {};
+     }
+-#if KPOPPLER_VERSION >= QT_VERSION_CHECK(0, 72, 0)
++#if KPOPPLER_VERSION >= QT_VERSION_CHECK(21, 8, 0)
++    return parsePdfDateTime(dt.get());
++#elif KPOPPLER_VERSION >= QT_VERSION_CHECK(0, 72, 0)
+     return parsePdfDateTime(dt->c_str());
+ #else
+     return parsePdfDateTime(dt->getCString());



More information about the arch-commits mailing list