Github messages for voidlinux
 help / color / mirror / Atom feed
* [PR PATCH] exiv2: update to 0.28.0.
@ 2023-10-23  0:10 mhmdanas
  2023-10-23  0:20 ` [PR PATCH] [Updated] " mhmdanas
                   ` (25 more replies)
  0 siblings, 26 replies; 27+ messages in thread
From: mhmdanas @ 2023-10-23  0:10 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 1751 bytes --]

There is a new pull request by mhmdanas against master on the void-packages repository

https://github.com/mhmdanas/void-packages exiv2-0.28.0
https://github.com/void-linux/void-packages/pull/46838

exiv2: update to 0.28.0.

<!-- Uncomment relevant sections and delete options which are not applicable -->

#### Testing the changes
- I tested the changes in this PR: **briefly**

TODO:
- [ ] Fix `gwenview`'s failed checks

@Johnnynator ufraw has been [unmaintained since December 2016](https://sourceforge.net/p/ufraw/discussion/434060/thread/30b4249b/), and it doesn't build with this PR; here are the options:
- remove the package entirely
- replace it with the newer [nufraw](https://sourceforge.net/projects/nufraw/), which already has [an exiv 0.28.x patch floating around](https://aur.archlinux.org/cgit/aur.git/tree/exiv2-error.patch?h=nufraw)
- patch it to build with this PR

What do you think?

<!--
#### New package
- This new package conforms to the [package requirements](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#package-requirements): **YES**|**NO**
-->

<!-- Note: If the build is likely to take more than 2 hours, please add ci skip tag as described in
https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration
and test at least one native build and, if supported, at least one cross build.
Ignore this section if this PR is not skipping CI.
-->
<!--
#### Local build testing
- I built this PR locally for my native architecture, (ARCH-LIBC)
- I built this PR locally for these architectures (if supported. mark crossbuilds):
  - aarch64-musl
  - armv7l
  - armv6l-musl
-->


A patch file from https://github.com/void-linux/void-packages/pull/46838.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-exiv2-0.28.0-46838.patch --]
[-- Type: text/x-diff, Size: 46629 bytes --]

From 39d73cdb4a59c4fc38da541948a9344b0e942d37 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:12 +0100
Subject: [PATCH 01/21] exiv2: update to 0.28.0.

---
 common/shlibs                        |  2 +-
 srcpkgs/exiv2/patches/fix-tests.diff | 31 ++++++++++++++++++++++++++++
 srcpkgs/exiv2/template               | 14 ++++++++-----
 3 files changed, 41 insertions(+), 6 deletions(-)
 create mode 100644 srcpkgs/exiv2/patches/fix-tests.diff

diff --git a/common/shlibs b/common/shlibs
index 185ba856d7e6c..954b17fa3de29 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -555,7 +555,7 @@ libgimpcolor-2.0.so.0 libgimp-2.10.0_1
 libgimpmodule-2.0.so.0 libgimp-2.10.0_1
 libgmic.so.3 gmic-3.1.6_1
 libcgmic.so.3 gmic-3.1.6_1
-libexiv2.so.27 exiv2-0.27_1
+libexiv2.so.28 exiv2-0.28.0_1
 libKF5Holidays.so.5 kholidays-5.47.0_1
 libPhabricatorHelpers.so.5 purpose-5.48.0_1
 libKF5PurposeWidgets.so.5 purpose-5.48.0_1
diff --git a/srcpkgs/exiv2/patches/fix-tests.diff b/srcpkgs/exiv2/patches/fix-tests.diff
new file mode 100644
index 0000000000000..3eb7adc1635f3
--- /dev/null
+++ b/srcpkgs/exiv2/patches/fix-tests.diff
@@ -0,0 +1,31 @@
+diff --git a/tests/tiff_test/test_tag_compare.py b/tests/tiff_test/test_tag_compare.py
+index a8538bd2..974d1a9a 100644
+--- a/tests/tiff_test/test_tag_compare.py
++++ b/tests/tiff_test/test_tag_compare.py
+@@ -28,8 +28,8 @@ class OutputTagExtract(metaclass=system_tests.CaseMeta):
+             tmp = line.split()
+ 
+             exif, image, tag = tmp[0].split('.')
+-            self.assertEquals(exif, "Exif")
+-            self.assertEquals(image, "Image")
++            self.assertEqual(exif, "Exif")
++            self.assertEqual(image, "Image")
+ 
+             data.append({
+                 "tag": tag,
+@@ -87,13 +87,13 @@ class OutputTagExtract(metaclass=system_tests.CaseMeta):
+         """
+         for pa_elem, pS_elem in zip(self.pa_data, self.pS_data):
+             for key in ["tag", "type", "len"]:
+-                self.assertEquals(pa_elem[key], pS_elem[key])
++                self.assertEqual(pa_elem[key], pS_elem[key])
+ 
+             if pa_elem["tag"] in [
+                     "ImageWidth", "ImageLength", "BitsPerSample",
+                     "DocumentName", "ImageDescription", "StripOffsets",
+                     "SamplesPerPixel", "StripByteCounts"]:
+-                self.assertEquals(pa_elem["val"], pS_elem["val"])
++                self.assertEqual(pa_elem["val"], pS_elem["val"])
+ 
+     def compare_stdout(self, i, command, got_stdout, expected_stdout):
+         super().compare_stdout(i, command, got_stdout, expected_stdout)
diff --git a/srcpkgs/exiv2/template b/srcpkgs/exiv2/template
index 49985fe82cc14..876b253541d00 100644
--- a/srcpkgs/exiv2/template
+++ b/srcpkgs/exiv2/template
@@ -1,17 +1,17 @@
 # Template file for 'exiv2'
 pkgname=exiv2
-version=0.27.6
+version=0.28.0
 revision=1
 build_style=cmake
 configure_args="-DEXIV2_BUILD_SAMPLES=OFF -DEXIV2_ENABLE_BMFF=ON"
-makedepends="zlib-devel expat-devel"
-checkdepends="gtest-devel"
+makedepends="zlib-devel brotli-devel expat-devel inih-devel"
+checkdepends="gtest-devel python3"
 short_desc="Image metadata manipulation"
 maintainer="Enno Boland <gottox@voidlinux.org>"
 license="GPL-2.0-or-later"
 homepage="https://www.exiv2.org"
 distfiles="https://github.com/Exiv2/exiv2/releases/download/v${version}/exiv2-${version}-Source.tar.gz"
-checksum=4c192483a1125dc59a3d70b30d30d32edace9e14adf52802d2f853abf72db8a6
+checksum=89af3b5ef7277753ef7a7b5374ae017c6b9e304db3b688f1948e73e103491f3d
 
 if [ -n "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DEXIV2_BUILD_UNIT_TESTS=ON"
@@ -21,6 +21,11 @@ if [ -n "$XBPS_CCACHE" ]; then
 	configure_args+=" -DBUILD_WITH_CCACHE=ON"
 fi
 
+pre_check() {
+	# https://github.com/Exiv2/exiv2/issues/2762
+	rm -f tests/bugfixes/github/test_issue_2427.py
+}
+
 exiv2-devel_package() {
 	depends="${makedepends} ${sourcepkg}-${version}_${revision}"
 	short_desc+=" - development files"
@@ -28,7 +33,6 @@ exiv2-devel_package() {
 		vmove usr/include
 		vmove usr/lib/cmake
 		vmove usr/lib/pkgconfig
-		vmove "usr/lib/*.a"
 		vmove "usr/lib/*.so"
 	}
 }

From 8197096551e8c86b98e457740f057388e67ae19f Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:37 +0100
Subject: [PATCH 02/21] ART: revbump for exiv2-0.28.0.

---
 srcpkgs/ART/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/ART/template b/srcpkgs/ART/template
index b6c47fc6c4cdf..94c7aa0378061 100644
--- a/srcpkgs/ART/template
+++ b/srcpkgs/ART/template
@@ -1,7 +1,7 @@
 # Template file for 'ART'
 pkgname=ART
 version=1.20.2
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="pkg-config"
 makedepends="fftw-devel gtkmm-devel lensfun-devel

From e5b02103eb9186eacd659585a0ffa904f8ca78a4 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 03/21] darktable: revbump for exiv2-0.28.0.

---
 srcpkgs/darktable/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/darktable/template b/srcpkgs/darktable/template
index 60415a34dc018..3d35571239a93 100644
--- a/srcpkgs/darktable/template
+++ b/srcpkgs/darktable/template
@@ -1,7 +1,7 @@
 # Template file for 'darktable'
 pkgname=darktable
 version=4.4.2
-revision=2
+revision=3
 # upstream only supports these archs:
 archs="x86_64* aarch64* ppc64le*"
 build_style=cmake

From 6d1f82e3f0ecf8b1d60c151c08ce3d277a9d7d0b Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 04/21] digikam: revbump for exiv2-0.28.0.

---
 srcpkgs/digikam/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/digikam/template b/srcpkgs/digikam/template
index 206185f565488..4784bf7d62a8e 100644
--- a/srcpkgs/digikam/template
+++ b/srcpkgs/digikam/template
@@ -1,7 +1,7 @@
 # Template file for 'digikam'
 pkgname=digikam
 version=8.1.0
-revision=1
+revision=2
 build_style=cmake
 configure_args="-DBUILD_TESTING=OFF"
 hostmakedepends="extra-cmake-modules gettext pkg-config bison flex qt5-qmake

From 41c4687e8b6ba51f09fd63338b6ed1beff29673b Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 05/21] geeqie: revbump for exiv2-0.28.0.

---
 srcpkgs/geeqie/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/geeqie/template b/srcpkgs/geeqie/template
index b5f958f854c1b..b494bc149e957 100644
--- a/srcpkgs/geeqie/template
+++ b/srcpkgs/geeqie/template
@@ -1,7 +1,7 @@
 # Template file for 'geeqie'
 pkgname=geeqie
 version=2.1
-revision=1
+revision=2
 build_style=meson
 hostmakedepends="pkg-config gettext xxd gdk-pixbuf-devel glib-devel"
 makedepends="gtk+3-devel glib-devel lcms2-devel exiv2-devel libheif-devel

From 56382905eda6110416b83feb5e3a93ed41b9e5e0 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 06/21] gthumb: revbump for exiv2-0.28.0.

---
 srcpkgs/gthumb/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/gthumb/template b/srcpkgs/gthumb/template
index c8e19f0dedb61..732d5e1c6089f 100644
--- a/srcpkgs/gthumb/template
+++ b/srcpkgs/gthumb/template
@@ -1,7 +1,7 @@
 # Template file for 'gthumb'
 pkgname=gthumb
 version=3.12.3
-revision=1
+revision=2
 build_style=meson
 hostmakedepends="gettext pkg-config itstool glib-devel"
 makedepends="webkit2gtk-devel json-glib-devel libsecret-devel librsvg-devel

From b25f2c6c4155783817e003a9d35e231692a8fe26 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 07/21] gwenview: revbump for exiv2-0.28.0.

---
 srcpkgs/gwenview/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/gwenview/template b/srcpkgs/gwenview/template
index 73d450a458c4d..eb876cfadcfe8 100644
--- a/srcpkgs/gwenview/template
+++ b/srcpkgs/gwenview/template
@@ -1,7 +1,7 @@
 # Template file for 'gwenview'
 pkgname=gwenview
 version=23.08.2
-revision=1
+revision=2
 build_style=cmake
 build_helper=qemu
 hostmakedepends="extra-cmake-modules pkg-config qt5-qmake qt5-host-tools

From 5f07ef1e4297eb0bcc67668bb30fc80509ee4831 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 08/21] hugin: revbump for exiv2-0.28.0.

---
 srcpkgs/hugin/patches/exiv2-0.28.patch | 77 ++++++++++++++++++++++++++
 srcpkgs/hugin/template                 |  2 +-
 2 files changed, 78 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/hugin/patches/exiv2-0.28.patch

diff --git a/srcpkgs/hugin/patches/exiv2-0.28.patch b/srcpkgs/hugin/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..49f0518117020
--- /dev/null
+++ b/srcpkgs/hugin/patches/exiv2-0.28.patch
@@ -0,0 +1,77 @@
+Patch-Source: https://gitlab.archlinux.org/archlinux/packaging/packages/hugin/-/blob/main/exiv2-0.28.patch
+diff -r 79cd11a7a66f src/hugin_base/panodata/Exiv2Helper.cpp
+--- a/src/hugin_base/panodata/Exiv2Helper.cpp	Wed May 24 19:13:20 2023 +0200
++++ b/src/hugin_base/panodata/Exiv2Helper.cpp	Mon Jun 05 00:31:19 2023 +0200
+@@ -40,7 +40,7 @@
+             Exiv2::ExifData::iterator itr = exifData.findKey(Exiv2::ExifKey(keyName));
+             if (itr != exifData.end() && itr->count())
+             {
+-                value = itr->toLong();
++                value = itr->toUint32();
+                 return true;
+             }
+             else
+@@ -165,7 +165,7 @@
+         {
+             if(it!=exifData.end() && it->count())
+             {
+-                return it->toLong();
++                return it->toUint32();
+             }
+             return 0;
+         };
+@@ -600,4 +600,4 @@
+         };
+ 
+     }; //namespace Exiv2Helper
+-}; //namespace HuginBase
+\ No newline at end of file
++}; //namespace HuginBase
+diff -r 79cd11a7a66f src/hugin_base/panodata/SrcPanoImage.cpp
+--- a/src/hugin_base/panodata/SrcPanoImage.cpp	Wed May 24 19:13:20 2023 +0200
++++ b/src/hugin_base/panodata/SrcPanoImage.cpp	Mon Jun 05 00:31:19 2023 +0200
+@@ -384,7 +384,7 @@
+                     pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaImageWidthPixels"));
+                     if (pos != xmpData.end())
+                     {
+-                        croppedWidth = pos->toLong();
++                        croppedWidth = pos->toUint32();
+                     }
+                     else
+                     {
+@@ -394,7 +394,7 @@
+                     pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaImageHeightPixels"));
+                     if (pos != xmpData.end())
+                     {
+-                        croppedHeight = pos->toLong();
++                        croppedHeight = pos->toUint32();
+                     }
+                     else
+                     {
+@@ -408,7 +408,7 @@
+                         double hfov = 0;
+                         if (pos != xmpData.end())
+                         {
+-                            hfov = 360 * croppedWidth / (double)pos->toLong();
++                            hfov = 360 * croppedWidth / (double)pos->toUint32();
+                         }
+                         else
+                         {
+@@ -419,7 +419,7 @@
+                         pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.FullPanoHeightPixels"));
+                         if (pos != xmpData.end())
+                         {
+-                            fullHeight = pos->toLong();
++                            fullHeight = pos->toUint32();
+                         }
+                         else
+                         {
+@@ -430,7 +430,7 @@
+                         pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaTopPixels"));
+                         if (pos != xmpData.end())
+                         {
+-                            cropTop = pos->toLong();
++                            cropTop = pos->toUint32();
+                         }
+                         else
+                         {
diff --git a/srcpkgs/hugin/template b/srcpkgs/hugin/template
index f96d2f6e27d42..ce71f6e4cbb2d 100644
--- a/srcpkgs/hugin/template
+++ b/srcpkgs/hugin/template
@@ -1,7 +1,7 @@
 # Template file for 'hugin'
 pkgname=hugin
 version=2022.0.0
-revision=10
+revision=11
 build_style=cmake
 build_helper=cmake-wxWidgets-gtk3
 pycompile_dirs="usr/share/hugin/data/plugins usr/share/hugin/data/plugins-templates"

From 96078c9785a8111b50bbd77497e69686aa4c314c Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 09/21] kfilemetadata5: revbump for exiv2-0.28.0.

---
 srcpkgs/kfilemetadata5/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/kfilemetadata5/template b/srcpkgs/kfilemetadata5/template
index c034d62deec8f..e6e9fe11aa55d 100644
--- a/srcpkgs/kfilemetadata5/template
+++ b/srcpkgs/kfilemetadata5/template
@@ -1,7 +1,7 @@
 # Template file for 'kfilemetadata5'
 pkgname=kfilemetadata5
 version=5.110.0
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="kcoreaddons extra-cmake-modules pkg-config qt5-host-tools qt5-qmake
  gettext kcoreaddons python3"

From c8cde47177bfb89ad1590ad5690670780cf53e4b Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 10/21] krename: revbump for exiv2-0.28.0.

---
 srcpkgs/krename/patches/e7dd767a.patch | 90 ++++++++++++++++++++++++++
 srcpkgs/krename/template               |  2 +-
 2 files changed, 91 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/krename/patches/e7dd767a.patch

diff --git a/srcpkgs/krename/patches/e7dd767a.patch b/srcpkgs/krename/patches/e7dd767a.patch
new file mode 100644
index 0000000000000..a0ef428ce46b1
--- /dev/null
+++ b/srcpkgs/krename/patches/e7dd767a.patch
@@ -0,0 +1,90 @@
+Patch-Source: https://invent.kde.org/utilities/krename/-/commit/e7dd767a
+From e7dd767a9a1068ee1fe1502c4d619b57d3b12add Mon Sep 17 00:00:00 2001
+From: Andreas Sturmlechner <asturm@gentoo.org>
+Date: Fri, 26 May 2023 23:23:10 +0200
+Subject: [PATCH] Fix build with >=exiv2-0.28, raise minimum to 0.27
+
+- enables use of EXIV2_TEST_VERSION macro
+- exiv2 headers cleanup
+
+Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>
+---
+ CMakeLists.txt         |  6 +-----
+ config-krename.h.cmake |  3 ---
+ src/exiv2plugin.cpp    | 17 +++++------------
+ 3 files changed, 6 insertions(+), 20 deletions(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 0bda8ac..72e7297 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -56,13 +56,9 @@ set_package_properties(Taglib PROPERTIES
+     TYPE OPTIONAL)
+ 
+ # Find exiv2
+-find_package(LibExiv2 0.13) # AccessMode was added in 0.13
++find_package(LibExiv2 0.27) # EXIV2_TEST_VERSION was added in 0.27
+ set_package_properties(LibExiv2 PROPERTIES TYPE OPTIONAL)
+ 
+-if (LibExiv2_VERSION VERSION_GREATER_EQUAL "0.27")
+-    set(HAVE_LIBEXIV2_0_27 TRUE)
+-endif()
+-
+ # Find podofo
+ find_package(PoDoFo)
+ set_package_properties(PoDoFo PROPERTIES
+diff --git a/config-krename.h.cmake b/config-krename.h.cmake
+index 76c3d30..862e40b 100644
+--- a/config-krename.h.cmake
++++ b/config-krename.h.cmake
+@@ -6,9 +6,6 @@
+ /* have Exiv2 */
+ #cmakedefine01 HAVE_EXIV2
+ 
+-/* Defined if we have libexiv2 >= 0.27 */
+-#cmakedefine HAVE_LIBEXIV2_0_27
+-
+ /* have PoDoFo */
+ #cmakedefine01 HAVE_PODOFO
+ 
+diff --git a/src/exiv2plugin.cpp b/src/exiv2plugin.cpp
+index 5694d8c..25e8869 100644
+--- a/src/exiv2plugin.cpp
++++ b/src/exiv2plugin.cpp
+@@ -3,20 +3,9 @@
+ 
+ #include "exiv2plugin.h"
+ 
+-#include "../config-krename.h"
+-
+ #include <KLocalizedString>
+ 
+-#include <exiv2/error.hpp>
+-#include <exiv2/exif.hpp>
+-#include <exiv2/image.hpp>
+-#include <exiv2/iptc.hpp>
+-#ifdef HAVE_LIBEXIV2_0_27
+-    #include <exiv2/xmp_exiv2.hpp>
+-#else
+-    #include <exiv2/xmp.hpp>
+-#endif
+-#include <exiv2/tags.hpp>
++#include <exiv2/exiv2.hpp>
+ 
+ #include "batchrenamer.h"
+ #include "tokenhelpdialog.h"
+@@ -381,7 +370,11 @@ QString Exiv2Plugin::processFile(BatchRenamer *b, int index, const QString &file
+     std::string strFilename(asc.constData(), asc.length());
+ 
+     try {
++#if EXIV2_TEST_VERSION(0,28,0)
++        Image::UniquePtr image = Exiv2::ImageFactory::open(strFilename);
++#else
+         Image::AutoPtr image = Exiv2::ImageFactory::open(strFilename);
++#endif
+         if (image.get() != nullptr && image->good()) {
+             image->readMetadata();
+ 
+-- 
+GitLab
+
diff --git a/srcpkgs/krename/template b/srcpkgs/krename/template
index 66023163e3293..df5535007714a 100644
--- a/srcpkgs/krename/template
+++ b/srcpkgs/krename/template
@@ -1,7 +1,7 @@
 # Template file for 'krename'
 pkgname=krename
 version=5.0.2
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="extra-cmake-modules gettext kcoreaddons pkg-config qt5-host-tools qt5-qmake"
 makedepends="exiv2-devel freetype-devel kjs-devel kparts-devel libpodofo-devel

From 68e0297df1ba2f7b44e7af7ff4c5efa98d432c65 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 11/21] krita: revbump for exiv2-0.28.0.

---
 srcpkgs/krita/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/krita/template b/srcpkgs/krita/template
index a4d3de04b049f..b479e0db798ee 100644
--- a/srcpkgs/krita/template
+++ b/srcpkgs/krita/template
@@ -1,7 +1,7 @@
 # Template file for 'krita'
 pkgname=krita
 version=5.2.0
-revision=1
+revision=2
 build_style=cmake
 configure_args="-Wno-dev -DBUILD_TESTING=OFF"
 hostmakedepends="extra-cmake-modules gettext pkg-config python3

From cf3694a3a38d368ee1414ef13be2142571c664a7 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 12/21] libextractor: revbump for exiv2-0.28.0.

---
 srcpkgs/libextractor/patches/exiv2-0.28.patch | 286 ++++++++++++++++++
 srcpkgs/libextractor/template                 |   2 +-
 2 files changed, 287 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/libextractor/patches/exiv2-0.28.patch

diff --git a/srcpkgs/libextractor/patches/exiv2-0.28.patch b/srcpkgs/libextractor/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..270a626d8ab06
--- /dev/null
+++ b/srcpkgs/libextractor/patches/exiv2-0.28.patch
@@ -0,0 +1,286 @@
+Patch-Source: https://gitlab.archlinux.org/archlinux/packaging/packages/libextractor/-/blob/main/exiv2-0.28.patch
+diff --git a/src/plugins/exiv2_extractor.cc b/src/plugins/exiv2_extractor.cc
+index 78f9bda..d32ed6a 100644
+--- a/src/plugins/exiv2_extractor.cc
++++ b/src/plugins/exiv2_extractor.cc
+@@ -90,7 +90,11 @@ virtual int close ();
+  * @param rcount number of bytes to read
+  * @return buffer with data read, empty buffer (!) on failure (!)
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++virtual Exiv2::DataBuf read (size_t rcount);
++#else
+ virtual Exiv2::DataBuf read (long rcount);
++#endif
+ 
+ /**
+  * Read up to 'rcount' bytes into 'buf'.
+@@ -99,8 +103,17 @@ virtual Exiv2::DataBuf read (long rcount);
+  * @param rcount size of 'buf'
+  * @return number of bytes read successfully, 0 on failure (!)
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++virtual size_t read (Exiv2::byte *buf,
++                   size_t rcount);
++#else
+ virtual long read (Exiv2::byte *buf,
+                    long rcount);
++#endif
++
++#if EXIV2_TEST_VERSION (0,28,0)
++virtual void populateFakeData();
++#endif
+ 
+ /**
+  * Read a single character.
+@@ -117,8 +130,13 @@ virtual int getb ();
+  * @param wcount how many bytes to write
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual size_t write (const Exiv2::byte *data,
++                    size_t wcount);
++#else
+ virtual long write (const Exiv2::byte *data,
+                     long wcount);
++#endif
+ 
+ /**
+  * Write to stream.
+@@ -126,7 +144,11 @@ virtual long write (const Exiv2::byte *data,
+  * @param src stream to copy
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual size_t write (Exiv2::BasicIo &src);
++#else
+ virtual long write (Exiv2::BasicIo &src);
++#endif
+ 
+ /**
+  * Write a single byte.
+@@ -172,7 +194,11 @@ virtual int munmap ();
+  *
+  * @return -1 on error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual size_t tell (void) const;
++#else
+ virtual long int tell (void) const;
++#endif
+ 
+ /**
+  * Return overall size of the file.
+@@ -213,7 +239,11 @@ virtual bool eof () const;
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual const std::string& path () const noexcept;
++#else
+ virtual std::string path () const;
++#endif
+ 
+ #ifdef EXV_UNICODE_PATH
+ /**
+@@ -230,7 +260,11 @@ virtual std::wstring wpath () const;
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual Exiv2::BasicIo::UniquePtr temporary () const;
++#else
+ virtual Exiv2::BasicIo::AutoPtr temporary () const;
++#endif
+ 
+ };
+ 
+@@ -266,7 +300,11 @@ ExtractorIO::close ()
+  * @return buffer with data read, empty buffer (!) on failure (!)
+  */
+ Exiv2::DataBuf
++#if EXIV2_TEST_VERSION (0,28,0)
++ExtractorIO::read (size_t rcount)
++#else
+ ExtractorIO::read (long rcount)
++#endif
+ {
+   void *data;
+   ssize_t ret;
+@@ -284,9 +322,15 @@ ExtractorIO::read (long rcount)
+  * @param rcount size of 'buf'
+  * @return number of bytes read successfully, 0 on failure (!)
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++size_t
++ExtractorIO::read (Exiv2::byte *buf,
++                   size_t rcount)
++#else
+ long
+ ExtractorIO::read (Exiv2::byte *buf,
+                    long rcount)
++#endif
+ {
+   void *data;
+   ssize_t ret;
+@@ -305,6 +349,12 @@ ExtractorIO::read (Exiv2::byte *buf,
+   return got;
+ }
+ 
++#if EXIV2_TEST_VERSION (0,28,0)
++void ExtractorIO::populateFakeData()
++{
++  return;
++}
++#endif
+ 
+ /**
+  * Read a single character.
+@@ -319,7 +369,9 @@ ExtractorIO::getb ()
+   const unsigned char *r;
+ 
+   if (1 != ec->read (ec->cls, &data, 1))
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION(0,28,0)
++    throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+     throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+     throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -336,9 +388,15 @@ ExtractorIO::getb ()
+  * @param wcount how many bytes to write
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++size_t
++ExtractorIO::write (const Exiv2::byte *data,
++                    size_t wcount)
++#else
+ long
+ ExtractorIO::write (const Exiv2::byte *data,
+                     long wcount)
++#endif
+ {
+   return -1;
+ }
+@@ -350,7 +408,11 @@ ExtractorIO::write (const Exiv2::byte *data,
+  * @param src stream to copy
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++size_t
++#else
+ long
++#endif
+ ExtractorIO::write (Exiv2::BasicIo &src)
+ {
+   return -1;
+@@ -378,7 +440,9 @@ ExtractorIO::putb (Exiv2::byte data)
+ void
+ ExtractorIO::transfer (Exiv2::BasicIo& src)
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION(0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -427,7 +491,9 @@ ExtractorIO::seek (long offset,
+ Exiv2::byte *
+ ExtractorIO::mmap (bool isWritable)
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION (0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -452,7 +518,11 @@ ExtractorIO::munmap ()
+  *
+  * @return -1 on error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++size_t
++#else
+ long int
++#endif
+ ExtractorIO::tell (void) const
+ {
+   return (long) ec->seek (ec->cls, 0, SEEK_CUR);
+@@ -516,10 +586,17 @@ ExtractorIO::eof () const
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++const std::string&
++ExtractorIO::path () const noexcept
++#else
+ std::string
+ ExtractorIO::path () const
++#endif
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION (0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -536,7 +613,9 @@ ExtractorIO::path () const
+ std::wstring
+ ExtractorIO::wpath () const
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION (0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -552,11 +631,17 @@ ExtractorIO::wpath () const
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++Exiv2::BasicIo::UniquePtr
++#else
+ Exiv2::BasicIo::AutoPtr
++#endif
+ ExtractorIO::temporary () const
+ {
+   fprintf (stderr, "throwing temporary error\n");
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION(0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -737,8 +822,13 @@ EXTRACTOR_exiv2_extract_method (struct EXTRACTOR_ExtractContext *ec)
+ #if ! EXIV2_TEST_VERSION (0,24,0)
+     Exiv2::LogMsg::setLevel (Exiv2::LogMsg::mute);
+ #endif
++#if EXIV2_TEST_VERSION(0,28,0)
++    std::unique_ptr<Exiv2::BasicIo> eio (new ExtractorIO (ec));
++    Exiv2::Image::UniquePtr image = Exiv2::ImageFactory::open (std::move(eio));
++#else
+     std::auto_ptr<Exiv2::BasicIo> eio (new ExtractorIO (ec));
+     Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open (eio);
++#endif
+     if (0 == image.get ())
+       return;
+     image->readMetadata ();
+@@ -822,7 +912,11 @@ EXTRACTOR_exiv2_extract_method (struct EXTRACTOR_ExtractContext *ec)
+       ADDXMP ("Xmp.lr.hierarchicalSubject", EXTRACTOR_METATYPE_SUBJECT);
+     }
+   }
++#if EXIV2_TEST_VERSION (0,28,0)
++  catch (const Exiv2::Error& e)
++#else
+   catch (const Exiv2::AnyError& e)
++#endif
+   {
+ #if DEBUG
+     std::cerr << "Caught Exiv2 exception '" << e << "'\n";
diff --git a/srcpkgs/libextractor/template b/srcpkgs/libextractor/template
index ddd4790f93e88..bfcea979a308c 100644
--- a/srcpkgs/libextractor/template
+++ b/srcpkgs/libextractor/template
@@ -1,7 +1,7 @@
 # Template file for 'libextractor'
 pkgname=libextractor
 version=1.11
-revision=2
+revision=3
 build_style=gnu-configure
 configure_args="--disable-static"
 hostmakedepends="pkg-config"

From 008a42e66b90895e6f66ef8febb57301b907e5a9 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 13/21] libgexiv2: update to 0.14.2.

---
 srcpkgs/libgexiv2/template | 14 +++++++-------
 1 file changed, 7 insertions(+), 7 deletions(-)

diff --git a/srcpkgs/libgexiv2/template b/srcpkgs/libgexiv2/template
index 23780e5397dc4..91dbcaa9aca52 100644
--- a/srcpkgs/libgexiv2/template
+++ b/srcpkgs/libgexiv2/template
@@ -1,19 +1,19 @@
 # Template file for 'libgexiv2'
 pkgname=libgexiv2
-version=0.14.0
-revision=3
+version=0.14.2
+revision=1
 build_style=meson
 build_helper="gir"
-configure_args="-Dintrospection=$(vopt_if gir true false)
- -Dvapi=$(vopt_if vala true false)"
+configure_args="$(vopt_bool gir introspection) $(vopt_bool vala vapi)"
 hostmakedepends="pkg-config glib-devel $(vopt_if vala 'vala') python3-gobject"
 makedepends="libglib-devel exiv2-devel"
 short_desc="GObject-based wrapper around the Exiv2 library"
 maintainer="Enno Boland <gottox@voidlinux.org>"
 license="GPL-2.0-or-later"
 homepage="https://wiki.gnome.org/Projects/gexiv2"
-distfiles="${GNOME_SITE}/gexiv2/${version%.*}/${pkgname/lib/}-${version}.tar.xz"
-checksum=e58279a6ff20b6f64fa499615da5e9b57cf65ba7850b72fafdf17221a9d6d69e
+changelog="https://gitlab.gnome.org/GNOME/gexiv2/-/raw/master/NEWS"
+distfiles="${GNOME_SITE}/gexiv2/${version%.*}/gexiv2-${version}.tar.xz"
+checksum=2a0c9cf48fbe8b3435008866ffd40b8eddb0667d2212b42396fdf688e93ce0be
 
 build_options="gir vala"
 build_options_default="gir vala"
@@ -23,7 +23,7 @@ libgexiv2-devel_package() {
 	short_desc+=" - development files"
 	pkg_install() {
 		vmove usr/include
-		vmove usr/lib/*.so
+		vmove "usr/lib/*.so"
 		vmove usr/lib/pkgconfig
 		if [ "$build_option_vala" ]; then
 			vmove usr/share/vala

From 360f0a136d3458f1d2f2a1799f885ad153a4be8d Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 14/21] libkexiv25: update to 23.08.2.

---
 srcpkgs/libkexiv25/template | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/srcpkgs/libkexiv25/template b/srcpkgs/libkexiv25/template
index 05c3deb508195..5700eb6e6e026 100644
--- a/srcpkgs/libkexiv25/template
+++ b/srcpkgs/libkexiv25/template
@@ -1,6 +1,6 @@
 # Template file for 'libkexiv25'
 pkgname=libkexiv25
-version=23.04.0
+version=23.08.2
 revision=1
 build_style=cmake
 configure_args="-DBUILD_TESTING=OFF"
@@ -11,7 +11,7 @@ maintainer="Denis Revin <denis.revin@gmail.com>"
 license="GPL-2.0-or-later"
 homepage="https://invent.kde.org/graphics/libkexiv2"
 distfiles="${KDE_SITE}/release-service/${version}/src/libkexiv2-${version}.tar.xz"
-checksum=18d3eed06df9d1e31d8434ed9887e305aba176d0856e19a8cd3bdb555b80d391
+checksum=d06e36a408bf2e846a18056a1f15e61d981fa2a1fceb81f7c15136604319d033
 
 libkexiv25-devel_package() {
 	short_desc+=" - development files"

From a8ac133334ebeedca5b68fe37167cba1dbc647b3 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 15/21] nomacs: update to 3.17.2287.

---
 srcpkgs/nomacs/template | 17 +++++++++++++----
 1 file changed, 13 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/nomacs/template b/srcpkgs/nomacs/template
index 57d3a1e98e846..4f4d9a851d7ac 100644
--- a/srcpkgs/nomacs/template
+++ b/srcpkgs/nomacs/template
@@ -1,7 +1,8 @@
 # Template file for 'nomacs'
 pkgname=nomacs
-version=3.16.224
-revision=5
+version=3.17.2287
+revision=1
+_plugins_ver=3.17.2285
 build_wrksrc=ImageLounge
 build_style=cmake
 configure_args="-DCMAKE_BUILD_TYPE=None -DENABLE_TRANSLATIONS=1
@@ -13,5 +14,13 @@ short_desc="Simple yet powerful Qt imageviewer"
 maintainer="Kharlamov Alexey <der@2-47.ru>"
 license="GPL-3.0-or-later"
 homepage="https://github.com/nomacs/nomacs"
-distfiles="https://github.com/nomacs/nomacs/archive/${version}.tar.gz"
-checksum=bbc7e9048026ef9e0d2b64902c88050f17a679ef3d3c009de2c3b7de5d1d217c
+distfiles="https://github.com/nomacs/nomacs/archive/${version}.tar.gz
+ https://github.com/novomesk/nomacs-plugins/archive/refs/tags/${_plugins_ver}.tar.gz>plugins.tar.gz"
+checksum="6905ea615358f84a0c83d5b1b7077871dea0526ec667500a1951448cb845a92c
+ 946b2d754be9ecca5cb155f7ecc5dcafb164f6c3dcc7bf5c3c0610d3b47774aa"
+skip_extraction="plugins.tar.gz"
+
+post_extract() {
+ cd ${build_wrksrc}
+ vsrcextract -C plugins "plugins.tar.gz"
+}

From ac386a603e92a798b9ba0a3a1f43cc3a9bf01f59 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 16/21] pdf2djvu: revbump for exiv2-0.28.0.

---
 srcpkgs/pdf2djvu/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/pdf2djvu/template b/srcpkgs/pdf2djvu/template
index ef7433c0c98ae..5a6f3ddf4ed35 100644
--- a/srcpkgs/pdf2djvu/template
+++ b/srcpkgs/pdf2djvu/template
@@ -1,7 +1,7 @@
 # Template file for 'pdf2djvu'
 pkgname=pdf2djvu
 version=0.9.19
-revision=4
+revision=5
 build_style=gnu-configure
 hostmakedepends="pkg-config djvulibre gettext"
 makedepends="djvulibre-devel poppler-devel libgraphicsmagick-devel exiv2-devel libuuid-devel"

From cb2f2a670bdd90090dd5311b29fd17d3528d6baf Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 17/21] phototonic: revbump for exiv2-0.28.0.

---
 srcpkgs/phototonic/patches/exiv2-0.28.patch | 135 ++++++++++++++++++++
 srcpkgs/phototonic/template                 |   2 +-
 2 files changed, 136 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/phototonic/patches/exiv2-0.28.patch

diff --git a/srcpkgs/phototonic/patches/exiv2-0.28.patch b/srcpkgs/phototonic/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..1c75b628dab33
--- /dev/null
+++ b/srcpkgs/phototonic/patches/exiv2-0.28.patch
@@ -0,0 +1,135 @@
+From 923a3fc14de0b779a45696c5f0aef34c74d84f13 Mon Sep 17 00:00:00 2001
+From: Andreas Sturmlechner <asturm@gentoo.org>
+Date: Sun, 28 May 2023 18:54:10 +0200
+Subject: [PATCH] Fix build with exiv2-0.28
+
+Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>
+---
+ ImageViewer.cpp   | 9 +++++++++
+ MetadataCache.cpp | 8 ++++++++
+ Phototonic.cpp    | 4 ++++
+ Tags.cpp          | 8 ++++++++
+ ThumbsViewer.cpp  | 4 ++++
+ 5 files changed, 33 insertions(+)
+
+diff --git a/ImageViewer.cpp b/ImageViewer.cpp
+index 357d223..df3ac43 100644
+--- a/ImageViewer.cpp
++++ b/ImageViewer.cpp
+@@ -945,7 +945,11 @@ void ImageViewer::keyMoveEvent(int direction) {
+ }
+ 
+ void ImageViewer::saveImage() {
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr image;
++#else
+     Exiv2::Image::AutoPtr image;
++#endif
+     bool exifError = false;
+ 
+     if (newImage) {
+@@ -985,8 +989,13 @@ void ImageViewer::saveImage() {
+ }
+ 
+ void ImageViewer::saveImageAs() {
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++    Exiv2::Image::UniquePtr newExifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
+     Exiv2::Image::AutoPtr newExifImage;
++#endif
+     bool exifError = false;
+ 
+     setCursorHiding(false);
+diff --git a/MetadataCache.cpp b/MetadataCache.cpp
+index 524ae74..5ddd4c8 100644
+--- a/MetadataCache.cpp
++++ b/MetadataCache.cpp
+@@ -64,7 +64,11 @@ void MetadataCache::clear() {
+ }
+ 
+ bool MetadataCache::loadImageMetadata(const QString &imageFullPath) {
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
++#endif
+     QSet<QString> tags;
+     long orientation = 0;
+ 
+@@ -78,7 +82,11 @@ bool MetadataCache::loadImageMetadata(const QString &imageFullPath) {
+     try {
+         Exiv2::ExifData &exifData = exifImage->exifData();
+         if (!exifData.empty()) {
++#if EXIV2_TEST_VERSION(0,28,0)
++            orientation = exifData["Exif.Image.Orientation"].value().toUint32();
++#else
+             orientation = exifData["Exif.Image.Orientation"].value().toLong();
++#endif
+         }
+     } catch (Exiv2::Error &error) {
+         qWarning() << "Failed to read Exif metadata";
+diff --git a/Phototonic.cpp b/Phototonic.cpp
+index 6cc95b3..bd5497d 100644
+--- a/Phototonic.cpp
++++ b/Phototonic.cpp
+@@ -3151,7 +3151,11 @@ void Phototonic::removeMetadata() {
+ 
+     if (ret == MessageBox::Yes) {
+         for (int file = 0; file < fileList.size(); ++file) {
++#if EXIV2_TEST_VERSION(0,28,0)
++            Exiv2::Image::UniquePtr image;
++#else
+             Exiv2::Image::AutoPtr image;
++#endif
+             try {
+                 image = Exiv2::ImageFactory::open(fileList[file].toStdString());
+                 image->clearMetadata();
+diff --git a/Tags.cpp b/Tags.cpp
+index 84eea16..a62da9d 100644
+--- a/Tags.cpp
++++ b/Tags.cpp
+@@ -136,7 +136,11 @@ void ImageTags::addTag(QString tagName, bool tagChecked) {
+ 
+ bool ImageTags::writeTagsToImage(QString &imageFileName, QSet<QString> &newTags) {
+     QSet<QString> imageTags;
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
++#endif
+ 
+     try {
+         exifImage = Exiv2::ImageFactory::open(imageFileName.toStdString());
+@@ -160,7 +164,11 @@ bool ImageTags::writeTagsToImage(QString &imageFileName, QSet<QString> &newTags)
+         QSetIterator<QString> newTagsIt(newTags);
+         while (newTagsIt.hasNext()) {
+             QString tag = newTagsIt.next();
++#if EXIV2_TEST_VERSION(0,28,0)
++            Exiv2::Value::UniquePtr value = Exiv2::Value::create(Exiv2::string);
++#else
+             Exiv2::Value::AutoPtr value = Exiv2::Value::create(Exiv2::string);
++#endif
+             value->read(tag.toStdString());
+             Exiv2::IptcKey key("Iptc.Application2.Keywords");
+             newIptcData.add(key, value.get());
+diff --git a/ThumbsViewer.cpp b/ThumbsViewer.cpp
+index 77a6189..4a11475 100644
+--- a/ThumbsViewer.cpp
++++ b/ThumbsViewer.cpp
+@@ -210,7 +210,11 @@ void ThumbsViewer::updateImageInfoViewer(QString imageFullPath) {
+         infoView->addEntry(key, val);
+     }
+ 
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
++#endif
+     try {
+         exifImage = Exiv2::ImageFactory::open(imageFullPath.toStdString());
+         exifImage->readMetadata();
+-- 
+2.40.1
+
diff --git a/srcpkgs/phototonic/template b/srcpkgs/phototonic/template
index 77ae8bf6a4406..4af006cb7da41 100644
--- a/srcpkgs/phototonic/template
+++ b/srcpkgs/phototonic/template
@@ -1,7 +1,7 @@
 # Template file for 'phototonic'
 pkgname=phototonic
 version=2.1
-revision=3
+revision=4
 build_style=qmake
 hostmakedepends="pkg-config qt5-qmake qt5-host-tools"
 makedepends="qt5-svg-devel exiv2-devel"

From dccca95373313915fbf68379fb8e31031f289921 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 18/21] qimgv: revbump for exiv2-0.28.0.

---
 srcpkgs/qimgv/patches/exiv2-0.28.patch | 16 ++++++++++++++++
 srcpkgs/qimgv/template                 |  2 +-
 2 files changed, 17 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/qimgv/patches/exiv2-0.28.patch

diff --git a/srcpkgs/qimgv/patches/exiv2-0.28.patch b/srcpkgs/qimgv/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..11f37b5ae2be3
--- /dev/null
+++ b/srcpkgs/qimgv/patches/exiv2-0.28.patch
@@ -0,0 +1,16 @@
+Patch-Source: https://git.alpinelinux.org/aports/tree/community/qimgv/exiv2-0.28.patch
+diff --git a/qimgv/sourcecontainers/documentinfo.cpp b/qimgv/sourcecontainers/documentinfo.cpp
+index 98a68f7..c062474 100644
+--- a/qimgv/sourcecontainers/documentinfo.cpp
++++ b/qimgv/sourcecontainers/documentinfo.cpp
+@@ -271,10 +271,6 @@ void DocumentInfo::loadExifTags() {
+         //std::cout << "Caught Exiv2 exception '" << e.what() << "'\n";
+         return;
+     }
+-    catch (Exiv2::BasicError<CharType> e) {
+-        //std::cout << "Caught BasicError Exiv2 exception '" << e.what() << "'\n";
+-        return;
+-    }
+ #endif
+ }
+ 
diff --git a/srcpkgs/qimgv/template b/srcpkgs/qimgv/template
index 7eb30db33992c..dd341dfe1bfce 100644
--- a/srcpkgs/qimgv/template
+++ b/srcpkgs/qimgv/template
@@ -1,7 +1,7 @@
 # Template file for 'qimgv'
 pkgname=qimgv
 version=1.0.2
-revision=2
+revision=3
 build_style=cmake
 configure_args="$(vopt_if video -DVIDEO_SUPPORT=ON -DVIDEO_SUPPORT=OFF)
  $(vopt_if scale -DOPENCV_SUPPORT=ON -DOPENCV_SUPPORT=OFF)

From d37d6da4b5ef9d983ed48e06fa50c70be7b6eb31 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 19/21] SIR: revbump for exiv2-0.28.0.

---
 srcpkgs/SIR/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/SIR/template b/srcpkgs/SIR/template
index 113077acad354..c6da4c26b6c71 100644
--- a/srcpkgs/SIR/template
+++ b/srcpkgs/SIR/template
@@ -1,7 +1,7 @@
 # Template file for 'SIR'
 pkgname=SIR
 version=3.2.2
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="pkg-config"
 makedepends="exiv2-devel qt5-svg-devel qt5-tools-devel"

From b8e12b2d85bb31569346598a6ce9eb252ec17c87 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 20/21] ufraw: revbump for exiv2-0.28.0.

---
 srcpkgs/ufraw/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/ufraw/template b/srcpkgs/ufraw/template
index ceddcacacefb2..15de1e78293f7 100644
--- a/srcpkgs/ufraw/template
+++ b/srcpkgs/ufraw/template
@@ -1,7 +1,7 @@
 # Template file for 'ufraw'
 pkgname=ufraw
 version=0.22
-revision=5
+revision=6
 build_style=gnu-configure
 configure_args="--enable-contrast --enable-mime --enable-openmp --with-gimp
  $(vopt_enable extras)"

From 0db320ce3c54b4a07a5b6ffbbc18eb2aa010f78f Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 21/21] viewnior: revbump for exiv2-0.28.0.

---
 srcpkgs/viewnior/patches/exiv2-0.28.patch | 147 ++++++++++++++++++++++
 srcpkgs/viewnior/template                 |   2 +-
 2 files changed, 148 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/viewnior/patches/exiv2-0.28.patch

diff --git a/srcpkgs/viewnior/patches/exiv2-0.28.patch b/srcpkgs/viewnior/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..71459dee15768
--- /dev/null
+++ b/srcpkgs/viewnior/patches/exiv2-0.28.patch
@@ -0,0 +1,147 @@
+Patch-Source: https://gitlab.archlinux.org/archlinux/packaging/packages/viewnior/-/blob/f206ce6c22a3ec5f1f9ea1bde4077584f80458dd/exiv2-0.28.patch
+--
+From b6bb81a1b46e911d15bbf9a730972523de177705 Mon Sep 17 00:00:00 2001
+From: tastytea <tastytea@tastytea.de>
+Date: Tue, 16 May 2023 10:54:40 +0200
+Subject: [PATCH 1/2] change exiv2 AutoPtr to unique_ptr
+
+exiv2-0.28.0 removed Exiv2::Image::AutoPtr and added
+Exiv2::Image::UniquePtr instead. since it's a typedef for
+std::unique_ptr<Image>, i'm using that directly instead of adding a
+condition on the exiv2 version.
+---
+ src/uni-exiv2.cpp | 21 +++++++++++----------
+ 1 file changed, 11 insertions(+), 10 deletions(-)
+
+diff --git a/src/uni-exiv2.cpp b/src/uni-exiv2.cpp
+index 0d14b9f..77064c2 100644
+--- a/src/uni-exiv2.cpp
++++ b/src/uni-exiv2.cpp
+@@ -22,12 +22,13 @@
+ 
+ #include <exiv2/exiv2.hpp>
+ #include <iostream>
++#include <memory>
+ 
+ #include "uni-exiv2.hpp"
+ 
+ #define ARRAY_SIZE(array) (sizeof array/sizeof(array[0]))
+ 
+-static Exiv2::Image::AutoPtr cached_image;
++static std::unique_ptr<Exiv2::Image> cached_image;
+ 
+ extern "C"
+ void
+@@ -35,8 +36,8 @@ uni_read_exiv2_map(const char *uri, void (*callback)(const char*, const char*, v
+ {
+     Exiv2::LogMsg::setLevel(Exiv2::LogMsg::mute);
+     try {
+-        Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open(uri);
+-        if ( image.get() == 0 ) {
++        std::unique_ptr<Exiv2::Image> image = Exiv2::ImageFactory::open(uri);
++        if (image == nullptr) {
+             return;
+         }
+ 
+@@ -91,14 +92,14 @@ uni_read_exiv2_to_cache(const char *uri)
+ {
+     Exiv2::LogMsg::setLevel(Exiv2::LogMsg::mute);
+ 
+-    if ( cached_image.get() != NULL ) {
++    if (cached_image != nullptr) {
+         cached_image->clearMetadata();
+-        cached_image.reset(NULL);
++        cached_image.reset(nullptr);
+     }
+ 
+     try {
+         cached_image = Exiv2::ImageFactory::open(uri);
+-        if ( cached_image.get() == 0 ) {
++        if (cached_image == nullptr) {
+             return 1;
+         }
+ 
+@@ -116,13 +117,13 @@ uni_write_exiv2_from_cache(const char *uri)
+ {
+     Exiv2::LogMsg::setLevel(Exiv2::LogMsg::mute);
+ 
+-    if ( cached_image.get() == NULL ) {
++    if (cached_image == nullptr) {
+         return 1;
+     }
+ 
+     try {
+-        Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open(uri);
+-        if ( image.get() == 0 ) {
++        std::unique_ptr<Exiv2::Image> image = Exiv2::ImageFactory::open(uri);
++        if (image == nullptr) {
+             return 2;
+         }
+ 
+@@ -130,7 +131,7 @@ uni_write_exiv2_from_cache(const char *uri)
+         image->writeMetadata();
+ 
+         cached_image->clearMetadata();
+-        cached_image.reset(NULL);
++        cached_image.reset(nullptr);
+ 
+         return 0;
+     } catch (Exiv2::AnyError& e) {
+
+From 47d0b98cb46526aa8aa035bebcabc14a11fa57ee Mon Sep 17 00:00:00 2001
+From: tastytea <tastytea@tastytea.de>
+Date: Tue, 16 May 2023 11:17:00 +0200
+Subject: [PATCH 2/2] add support for exiv-0.28.0 errors
+
+exiv2-0.28.0 changed Exiv2::AnyError to Exiv2::Error.
+---
+ src/uni-exiv2.cpp | 15 ++++++++++++---
+ 1 file changed, 12 insertions(+), 3 deletions(-)
+
+diff --git a/src/uni-exiv2.cpp b/src/uni-exiv2.cpp
+index 77064c2..567a50f 100644
+--- a/src/uni-exiv2.cpp
++++ b/src/uni-exiv2.cpp
+@@ -28,6 +28,15 @@
+ 
+ #define ARRAY_SIZE(array) (sizeof array/sizeof(array[0]))
+ 
++#define EXIV_ERROR Exiv2::AnyError
++#ifdef EXIV2_VERSION
++    #ifdef EXIV2_TEST_VERSION
++        #if EXIV2_TEST_VERSION(0,28,0)
++            #define EXIV_ERROR Exiv2::Error
++        #endif
++    #endif
++#endif
++
+ static std::unique_ptr<Exiv2::Image> cached_image;
+ 
+ extern "C"
+@@ -81,7 +90,7 @@ uni_read_exiv2_map(const char *uri, void (*callback)(const char*, const char*, v
+                 }
+             }
+         }
+-    } catch (Exiv2::AnyError& e) {
++    } catch (EXIV_ERROR& e) {
+         std::cerr << "Exiv2: '" << e << "'\n";
+     }
+ }
+@@ -104,7 +113,7 @@ uni_read_exiv2_to_cache(const char *uri)
+         }
+ 
+         cached_image->readMetadata();
+-    } catch (Exiv2::AnyError& e) {
++    } catch (EXIV_ERROR& e) {
+         std::cerr << "Exiv2: '" << e << "'\n";
+     }
+ 
+@@ -134,7 +143,7 @@ uni_write_exiv2_from_cache(const char *uri)
+         cached_image.reset(nullptr);
+ 
+         return 0;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (EXIV_ERROR& e) {
+         std::cerr << "Exiv2: '" << e << "'\n";
+     }
+ 
diff --git a/srcpkgs/viewnior/template b/srcpkgs/viewnior/template
index ea1e528a8651f..4c73226662ca0 100644
--- a/srcpkgs/viewnior/template
+++ b/srcpkgs/viewnior/template
@@ -1,7 +1,7 @@
 # Template file for 'viewnior'
 pkgname=viewnior
 version=1.8
-revision=1
+revision=2
 build_style=meson
 hostmakedepends="pkg-config intltool glib-devel gettext-devel"
 makedepends="gtk+-devel exiv2-devel"

^ permalink raw reply	[flat|nested] 27+ messages in thread

* Re: [PR PATCH] [Updated] exiv2: update to 0.28.0.
  2023-10-23  0:10 [PR PATCH] exiv2: update to 0.28.0 mhmdanas
@ 2023-10-23  0:20 ` mhmdanas
  2023-11-01 17:23 ` mhmdanas
                   ` (24 subsequent siblings)
  25 siblings, 0 replies; 27+ messages in thread
From: mhmdanas @ 2023-10-23  0:20 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 1756 bytes --]

There is an updated pull request by mhmdanas against master on the void-packages repository

https://github.com/mhmdanas/void-packages exiv2-0.28.0
https://github.com/void-linux/void-packages/pull/46838

exiv2: update to 0.28.0.

<!-- Uncomment relevant sections and delete options which are not applicable -->

#### Testing the changes
- I tested the changes in this PR: **briefly**

TODO:
- [ ] Fix `gwenview`'s failed checks

@Johnnynator ufraw has been [unmaintained since December 2016](https://sourceforge.net/p/ufraw/discussion/434060/thread/30b4249b/), and it doesn't build with this PR; here are the options:
- remove the package entirely
- replace it with the newer [nufraw](https://sourceforge.net/projects/nufraw/), which already has [an exiv 0.28.x patch floating around](https://aur.archlinux.org/cgit/aur.git/tree/exiv2-error.patch?h=nufraw)
- patch it to build with this PR

What do you think?

<!--
#### New package
- This new package conforms to the [package requirements](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#package-requirements): **YES**|**NO**
-->

<!-- Note: If the build is likely to take more than 2 hours, please add ci skip tag as described in
https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration
and test at least one native build and, if supported, at least one cross build.
Ignore this section if this PR is not skipping CI.
-->
<!--
#### Local build testing
- I built this PR locally for my native architecture, (ARCH-LIBC)
- I built this PR locally for these architectures (if supported. mark crossbuilds):
  - aarch64-musl
  - armv7l
  - armv6l-musl
-->


A patch file from https://github.com/void-linux/void-packages/pull/46838.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-exiv2-0.28.0-46838.patch --]
[-- Type: text/x-diff, Size: 47337 bytes --]

From d1c27ceff22c1e85e2f0f15af32c1af86ab52041 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Mon, 23 Oct 2023 01:20:09 +0100
Subject: [PATCH 01/22] inih: add `libINIReader.so.0` common/shlibs entry.

---
 common/shlibs | 1 +
 1 file changed, 1 insertion(+)

diff --git a/common/shlibs b/common/shlibs
index 185ba856d7e6c..d8c41afe078af 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -3903,6 +3903,7 @@ libnotcurses++.so.3 notcurses-3.0.5_1
 libnotcurses-ffi.so.3 notcurses-3.0.5_1
 libevemu.so.3 evemu-2.7.0_1
 libinih.so.0 inih-52_1
+libINIReader.so.0 inih-57_1
 libpcaudio.so.0 pcaudiolib-1.1_1
 libdcerpc-samr.so.0 samba-4.13.2_1
 libdcerpc-server-core.so.0 samba-4.13.2_1

From 3833f25ee5f47ae4e52057681b97bb24d968723a Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:12 +0100
Subject: [PATCH 02/22] exiv2: update to 0.28.0.

---
 common/shlibs                        |  2 +-
 srcpkgs/exiv2/patches/fix-tests.diff | 31 ++++++++++++++++++++++++++++
 srcpkgs/exiv2/template               | 14 ++++++++-----
 3 files changed, 41 insertions(+), 6 deletions(-)
 create mode 100644 srcpkgs/exiv2/patches/fix-tests.diff

diff --git a/common/shlibs b/common/shlibs
index d8c41afe078af..b3fee66f7e206 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -555,7 +555,7 @@ libgimpcolor-2.0.so.0 libgimp-2.10.0_1
 libgimpmodule-2.0.so.0 libgimp-2.10.0_1
 libgmic.so.3 gmic-3.1.6_1
 libcgmic.so.3 gmic-3.1.6_1
-libexiv2.so.27 exiv2-0.27_1
+libexiv2.so.28 exiv2-0.28.0_1
 libKF5Holidays.so.5 kholidays-5.47.0_1
 libPhabricatorHelpers.so.5 purpose-5.48.0_1
 libKF5PurposeWidgets.so.5 purpose-5.48.0_1
diff --git a/srcpkgs/exiv2/patches/fix-tests.diff b/srcpkgs/exiv2/patches/fix-tests.diff
new file mode 100644
index 0000000000000..3eb7adc1635f3
--- /dev/null
+++ b/srcpkgs/exiv2/patches/fix-tests.diff
@@ -0,0 +1,31 @@
+diff --git a/tests/tiff_test/test_tag_compare.py b/tests/tiff_test/test_tag_compare.py
+index a8538bd2..974d1a9a 100644
+--- a/tests/tiff_test/test_tag_compare.py
++++ b/tests/tiff_test/test_tag_compare.py
+@@ -28,8 +28,8 @@ class OutputTagExtract(metaclass=system_tests.CaseMeta):
+             tmp = line.split()
+ 
+             exif, image, tag = tmp[0].split('.')
+-            self.assertEquals(exif, "Exif")
+-            self.assertEquals(image, "Image")
++            self.assertEqual(exif, "Exif")
++            self.assertEqual(image, "Image")
+ 
+             data.append({
+                 "tag": tag,
+@@ -87,13 +87,13 @@ class OutputTagExtract(metaclass=system_tests.CaseMeta):
+         """
+         for pa_elem, pS_elem in zip(self.pa_data, self.pS_data):
+             for key in ["tag", "type", "len"]:
+-                self.assertEquals(pa_elem[key], pS_elem[key])
++                self.assertEqual(pa_elem[key], pS_elem[key])
+ 
+             if pa_elem["tag"] in [
+                     "ImageWidth", "ImageLength", "BitsPerSample",
+                     "DocumentName", "ImageDescription", "StripOffsets",
+                     "SamplesPerPixel", "StripByteCounts"]:
+-                self.assertEquals(pa_elem["val"], pS_elem["val"])
++                self.assertEqual(pa_elem["val"], pS_elem["val"])
+ 
+     def compare_stdout(self, i, command, got_stdout, expected_stdout):
+         super().compare_stdout(i, command, got_stdout, expected_stdout)
diff --git a/srcpkgs/exiv2/template b/srcpkgs/exiv2/template
index 49985fe82cc14..876b253541d00 100644
--- a/srcpkgs/exiv2/template
+++ b/srcpkgs/exiv2/template
@@ -1,17 +1,17 @@
 # Template file for 'exiv2'
 pkgname=exiv2
-version=0.27.6
+version=0.28.0
 revision=1
 build_style=cmake
 configure_args="-DEXIV2_BUILD_SAMPLES=OFF -DEXIV2_ENABLE_BMFF=ON"
-makedepends="zlib-devel expat-devel"
-checkdepends="gtest-devel"
+makedepends="zlib-devel brotli-devel expat-devel inih-devel"
+checkdepends="gtest-devel python3"
 short_desc="Image metadata manipulation"
 maintainer="Enno Boland <gottox@voidlinux.org>"
 license="GPL-2.0-or-later"
 homepage="https://www.exiv2.org"
 distfiles="https://github.com/Exiv2/exiv2/releases/download/v${version}/exiv2-${version}-Source.tar.gz"
-checksum=4c192483a1125dc59a3d70b30d30d32edace9e14adf52802d2f853abf72db8a6
+checksum=89af3b5ef7277753ef7a7b5374ae017c6b9e304db3b688f1948e73e103491f3d
 
 if [ -n "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DEXIV2_BUILD_UNIT_TESTS=ON"
@@ -21,6 +21,11 @@ if [ -n "$XBPS_CCACHE" ]; then
 	configure_args+=" -DBUILD_WITH_CCACHE=ON"
 fi
 
+pre_check() {
+	# https://github.com/Exiv2/exiv2/issues/2762
+	rm -f tests/bugfixes/github/test_issue_2427.py
+}
+
 exiv2-devel_package() {
 	depends="${makedepends} ${sourcepkg}-${version}_${revision}"
 	short_desc+=" - development files"
@@ -28,7 +33,6 @@ exiv2-devel_package() {
 		vmove usr/include
 		vmove usr/lib/cmake
 		vmove usr/lib/pkgconfig
-		vmove "usr/lib/*.a"
 		vmove "usr/lib/*.so"
 	}
 }

From 6083c58617db7d2d932acb65b2c332f6361d1279 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:37 +0100
Subject: [PATCH 03/22] ART: revbump for exiv2-0.28.0.

---
 srcpkgs/ART/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/ART/template b/srcpkgs/ART/template
index b6c47fc6c4cdf..94c7aa0378061 100644
--- a/srcpkgs/ART/template
+++ b/srcpkgs/ART/template
@@ -1,7 +1,7 @@
 # Template file for 'ART'
 pkgname=ART
 version=1.20.2
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="pkg-config"
 makedepends="fftw-devel gtkmm-devel lensfun-devel

From acd859e69cad533b7acdd9b8872d85b3f391efe3 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 04/22] darktable: revbump for exiv2-0.28.0.

---
 srcpkgs/darktable/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/darktable/template b/srcpkgs/darktable/template
index 60415a34dc018..3d35571239a93 100644
--- a/srcpkgs/darktable/template
+++ b/srcpkgs/darktable/template
@@ -1,7 +1,7 @@
 # Template file for 'darktable'
 pkgname=darktable
 version=4.4.2
-revision=2
+revision=3
 # upstream only supports these archs:
 archs="x86_64* aarch64* ppc64le*"
 build_style=cmake

From 7651d5cd2f34199021c36a9e545c6953f52a67db Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 05/22] digikam: revbump for exiv2-0.28.0.

---
 srcpkgs/digikam/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/digikam/template b/srcpkgs/digikam/template
index 206185f565488..4784bf7d62a8e 100644
--- a/srcpkgs/digikam/template
+++ b/srcpkgs/digikam/template
@@ -1,7 +1,7 @@
 # Template file for 'digikam'
 pkgname=digikam
 version=8.1.0
-revision=1
+revision=2
 build_style=cmake
 configure_args="-DBUILD_TESTING=OFF"
 hostmakedepends="extra-cmake-modules gettext pkg-config bison flex qt5-qmake

From 9a863545a61ccc6e2d5ac942db8e3cd34e9ce358 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 06/22] geeqie: revbump for exiv2-0.28.0.

---
 srcpkgs/geeqie/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/geeqie/template b/srcpkgs/geeqie/template
index b5f958f854c1b..b494bc149e957 100644
--- a/srcpkgs/geeqie/template
+++ b/srcpkgs/geeqie/template
@@ -1,7 +1,7 @@
 # Template file for 'geeqie'
 pkgname=geeqie
 version=2.1
-revision=1
+revision=2
 build_style=meson
 hostmakedepends="pkg-config gettext xxd gdk-pixbuf-devel glib-devel"
 makedepends="gtk+3-devel glib-devel lcms2-devel exiv2-devel libheif-devel

From 3f341ca73959f4657b9979c5ee0074037225c036 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 07/22] gthumb: revbump for exiv2-0.28.0.

---
 srcpkgs/gthumb/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/gthumb/template b/srcpkgs/gthumb/template
index c8e19f0dedb61..732d5e1c6089f 100644
--- a/srcpkgs/gthumb/template
+++ b/srcpkgs/gthumb/template
@@ -1,7 +1,7 @@
 # Template file for 'gthumb'
 pkgname=gthumb
 version=3.12.3
-revision=1
+revision=2
 build_style=meson
 hostmakedepends="gettext pkg-config itstool glib-devel"
 makedepends="webkit2gtk-devel json-glib-devel libsecret-devel librsvg-devel

From 5c0742953c5df36f41f0417d69363578f0f11f3a Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 08/22] gwenview: revbump for exiv2-0.28.0.

---
 srcpkgs/gwenview/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/gwenview/template b/srcpkgs/gwenview/template
index 73d450a458c4d..eb876cfadcfe8 100644
--- a/srcpkgs/gwenview/template
+++ b/srcpkgs/gwenview/template
@@ -1,7 +1,7 @@
 # Template file for 'gwenview'
 pkgname=gwenview
 version=23.08.2
-revision=1
+revision=2
 build_style=cmake
 build_helper=qemu
 hostmakedepends="extra-cmake-modules pkg-config qt5-qmake qt5-host-tools

From ee96979d666324d52f4e28f53b5b144b3dfb027c Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 09/22] hugin: revbump for exiv2-0.28.0.

---
 srcpkgs/hugin/patches/exiv2-0.28.patch | 77 ++++++++++++++++++++++++++
 srcpkgs/hugin/template                 |  2 +-
 2 files changed, 78 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/hugin/patches/exiv2-0.28.patch

diff --git a/srcpkgs/hugin/patches/exiv2-0.28.patch b/srcpkgs/hugin/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..49f0518117020
--- /dev/null
+++ b/srcpkgs/hugin/patches/exiv2-0.28.patch
@@ -0,0 +1,77 @@
+Patch-Source: https://gitlab.archlinux.org/archlinux/packaging/packages/hugin/-/blob/main/exiv2-0.28.patch
+diff -r 79cd11a7a66f src/hugin_base/panodata/Exiv2Helper.cpp
+--- a/src/hugin_base/panodata/Exiv2Helper.cpp	Wed May 24 19:13:20 2023 +0200
++++ b/src/hugin_base/panodata/Exiv2Helper.cpp	Mon Jun 05 00:31:19 2023 +0200
+@@ -40,7 +40,7 @@
+             Exiv2::ExifData::iterator itr = exifData.findKey(Exiv2::ExifKey(keyName));
+             if (itr != exifData.end() && itr->count())
+             {
+-                value = itr->toLong();
++                value = itr->toUint32();
+                 return true;
+             }
+             else
+@@ -165,7 +165,7 @@
+         {
+             if(it!=exifData.end() && it->count())
+             {
+-                return it->toLong();
++                return it->toUint32();
+             }
+             return 0;
+         };
+@@ -600,4 +600,4 @@
+         };
+ 
+     }; //namespace Exiv2Helper
+-}; //namespace HuginBase
+\ No newline at end of file
++}; //namespace HuginBase
+diff -r 79cd11a7a66f src/hugin_base/panodata/SrcPanoImage.cpp
+--- a/src/hugin_base/panodata/SrcPanoImage.cpp	Wed May 24 19:13:20 2023 +0200
++++ b/src/hugin_base/panodata/SrcPanoImage.cpp	Mon Jun 05 00:31:19 2023 +0200
+@@ -384,7 +384,7 @@
+                     pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaImageWidthPixels"));
+                     if (pos != xmpData.end())
+                     {
+-                        croppedWidth = pos->toLong();
++                        croppedWidth = pos->toUint32();
+                     }
+                     else
+                     {
+@@ -394,7 +394,7 @@
+                     pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaImageHeightPixels"));
+                     if (pos != xmpData.end())
+                     {
+-                        croppedHeight = pos->toLong();
++                        croppedHeight = pos->toUint32();
+                     }
+                     else
+                     {
+@@ -408,7 +408,7 @@
+                         double hfov = 0;
+                         if (pos != xmpData.end())
+                         {
+-                            hfov = 360 * croppedWidth / (double)pos->toLong();
++                            hfov = 360 * croppedWidth / (double)pos->toUint32();
+                         }
+                         else
+                         {
+@@ -419,7 +419,7 @@
+                         pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.FullPanoHeightPixels"));
+                         if (pos != xmpData.end())
+                         {
+-                            fullHeight = pos->toLong();
++                            fullHeight = pos->toUint32();
+                         }
+                         else
+                         {
+@@ -430,7 +430,7 @@
+                         pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaTopPixels"));
+                         if (pos != xmpData.end())
+                         {
+-                            cropTop = pos->toLong();
++                            cropTop = pos->toUint32();
+                         }
+                         else
+                         {
diff --git a/srcpkgs/hugin/template b/srcpkgs/hugin/template
index f96d2f6e27d42..ce71f6e4cbb2d 100644
--- a/srcpkgs/hugin/template
+++ b/srcpkgs/hugin/template
@@ -1,7 +1,7 @@
 # Template file for 'hugin'
 pkgname=hugin
 version=2022.0.0
-revision=10
+revision=11
 build_style=cmake
 build_helper=cmake-wxWidgets-gtk3
 pycompile_dirs="usr/share/hugin/data/plugins usr/share/hugin/data/plugins-templates"

From 333968ba69e827e78acd5bf1e10e2f4b5047c24e Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 10/22] kfilemetadata5: revbump for exiv2-0.28.0.

---
 srcpkgs/kfilemetadata5/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/kfilemetadata5/template b/srcpkgs/kfilemetadata5/template
index c034d62deec8f..e6e9fe11aa55d 100644
--- a/srcpkgs/kfilemetadata5/template
+++ b/srcpkgs/kfilemetadata5/template
@@ -1,7 +1,7 @@
 # Template file for 'kfilemetadata5'
 pkgname=kfilemetadata5
 version=5.110.0
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="kcoreaddons extra-cmake-modules pkg-config qt5-host-tools qt5-qmake
  gettext kcoreaddons python3"

From 43dbf5319b04f35588652fe00bdce3eb27772eab Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 11/22] krename: revbump for exiv2-0.28.0.

---
 srcpkgs/krename/patches/e7dd767a.patch | 90 ++++++++++++++++++++++++++
 srcpkgs/krename/template               |  2 +-
 2 files changed, 91 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/krename/patches/e7dd767a.patch

diff --git a/srcpkgs/krename/patches/e7dd767a.patch b/srcpkgs/krename/patches/e7dd767a.patch
new file mode 100644
index 0000000000000..a0ef428ce46b1
--- /dev/null
+++ b/srcpkgs/krename/patches/e7dd767a.patch
@@ -0,0 +1,90 @@
+Patch-Source: https://invent.kde.org/utilities/krename/-/commit/e7dd767a
+From e7dd767a9a1068ee1fe1502c4d619b57d3b12add Mon Sep 17 00:00:00 2001
+From: Andreas Sturmlechner <asturm@gentoo.org>
+Date: Fri, 26 May 2023 23:23:10 +0200
+Subject: [PATCH] Fix build with >=exiv2-0.28, raise minimum to 0.27
+
+- enables use of EXIV2_TEST_VERSION macro
+- exiv2 headers cleanup
+
+Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>
+---
+ CMakeLists.txt         |  6 +-----
+ config-krename.h.cmake |  3 ---
+ src/exiv2plugin.cpp    | 17 +++++------------
+ 3 files changed, 6 insertions(+), 20 deletions(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 0bda8ac..72e7297 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -56,13 +56,9 @@ set_package_properties(Taglib PROPERTIES
+     TYPE OPTIONAL)
+ 
+ # Find exiv2
+-find_package(LibExiv2 0.13) # AccessMode was added in 0.13
++find_package(LibExiv2 0.27) # EXIV2_TEST_VERSION was added in 0.27
+ set_package_properties(LibExiv2 PROPERTIES TYPE OPTIONAL)
+ 
+-if (LibExiv2_VERSION VERSION_GREATER_EQUAL "0.27")
+-    set(HAVE_LIBEXIV2_0_27 TRUE)
+-endif()
+-
+ # Find podofo
+ find_package(PoDoFo)
+ set_package_properties(PoDoFo PROPERTIES
+diff --git a/config-krename.h.cmake b/config-krename.h.cmake
+index 76c3d30..862e40b 100644
+--- a/config-krename.h.cmake
++++ b/config-krename.h.cmake
+@@ -6,9 +6,6 @@
+ /* have Exiv2 */
+ #cmakedefine01 HAVE_EXIV2
+ 
+-/* Defined if we have libexiv2 >= 0.27 */
+-#cmakedefine HAVE_LIBEXIV2_0_27
+-
+ /* have PoDoFo */
+ #cmakedefine01 HAVE_PODOFO
+ 
+diff --git a/src/exiv2plugin.cpp b/src/exiv2plugin.cpp
+index 5694d8c..25e8869 100644
+--- a/src/exiv2plugin.cpp
++++ b/src/exiv2plugin.cpp
+@@ -3,20 +3,9 @@
+ 
+ #include "exiv2plugin.h"
+ 
+-#include "../config-krename.h"
+-
+ #include <KLocalizedString>
+ 
+-#include <exiv2/error.hpp>
+-#include <exiv2/exif.hpp>
+-#include <exiv2/image.hpp>
+-#include <exiv2/iptc.hpp>
+-#ifdef HAVE_LIBEXIV2_0_27
+-    #include <exiv2/xmp_exiv2.hpp>
+-#else
+-    #include <exiv2/xmp.hpp>
+-#endif
+-#include <exiv2/tags.hpp>
++#include <exiv2/exiv2.hpp>
+ 
+ #include "batchrenamer.h"
+ #include "tokenhelpdialog.h"
+@@ -381,7 +370,11 @@ QString Exiv2Plugin::processFile(BatchRenamer *b, int index, const QString &file
+     std::string strFilename(asc.constData(), asc.length());
+ 
+     try {
++#if EXIV2_TEST_VERSION(0,28,0)
++        Image::UniquePtr image = Exiv2::ImageFactory::open(strFilename);
++#else
+         Image::AutoPtr image = Exiv2::ImageFactory::open(strFilename);
++#endif
+         if (image.get() != nullptr && image->good()) {
+             image->readMetadata();
+ 
+-- 
+GitLab
+
diff --git a/srcpkgs/krename/template b/srcpkgs/krename/template
index 66023163e3293..df5535007714a 100644
--- a/srcpkgs/krename/template
+++ b/srcpkgs/krename/template
@@ -1,7 +1,7 @@
 # Template file for 'krename'
 pkgname=krename
 version=5.0.2
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="extra-cmake-modules gettext kcoreaddons pkg-config qt5-host-tools qt5-qmake"
 makedepends="exiv2-devel freetype-devel kjs-devel kparts-devel libpodofo-devel

From f5a4ae6bd23368b29b3d4344a41ba5fce3966f7a Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 12/22] krita: revbump for exiv2-0.28.0.

---
 srcpkgs/krita/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/krita/template b/srcpkgs/krita/template
index a4d3de04b049f..b479e0db798ee 100644
--- a/srcpkgs/krita/template
+++ b/srcpkgs/krita/template
@@ -1,7 +1,7 @@
 # Template file for 'krita'
 pkgname=krita
 version=5.2.0
-revision=1
+revision=2
 build_style=cmake
 configure_args="-Wno-dev -DBUILD_TESTING=OFF"
 hostmakedepends="extra-cmake-modules gettext pkg-config python3

From a24a79c92117d854c718c876dac103bd2876f89a Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 13/22] libextractor: revbump for exiv2-0.28.0.

---
 srcpkgs/libextractor/patches/exiv2-0.28.patch | 286 ++++++++++++++++++
 srcpkgs/libextractor/template                 |   2 +-
 2 files changed, 287 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/libextractor/patches/exiv2-0.28.patch

diff --git a/srcpkgs/libextractor/patches/exiv2-0.28.patch b/srcpkgs/libextractor/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..270a626d8ab06
--- /dev/null
+++ b/srcpkgs/libextractor/patches/exiv2-0.28.patch
@@ -0,0 +1,286 @@
+Patch-Source: https://gitlab.archlinux.org/archlinux/packaging/packages/libextractor/-/blob/main/exiv2-0.28.patch
+diff --git a/src/plugins/exiv2_extractor.cc b/src/plugins/exiv2_extractor.cc
+index 78f9bda..d32ed6a 100644
+--- a/src/plugins/exiv2_extractor.cc
++++ b/src/plugins/exiv2_extractor.cc
+@@ -90,7 +90,11 @@ virtual int close ();
+  * @param rcount number of bytes to read
+  * @return buffer with data read, empty buffer (!) on failure (!)
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++virtual Exiv2::DataBuf read (size_t rcount);
++#else
+ virtual Exiv2::DataBuf read (long rcount);
++#endif
+ 
+ /**
+  * Read up to 'rcount' bytes into 'buf'.
+@@ -99,8 +103,17 @@ virtual Exiv2::DataBuf read (long rcount);
+  * @param rcount size of 'buf'
+  * @return number of bytes read successfully, 0 on failure (!)
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++virtual size_t read (Exiv2::byte *buf,
++                   size_t rcount);
++#else
+ virtual long read (Exiv2::byte *buf,
+                    long rcount);
++#endif
++
++#if EXIV2_TEST_VERSION (0,28,0)
++virtual void populateFakeData();
++#endif
+ 
+ /**
+  * Read a single character.
+@@ -117,8 +130,13 @@ virtual int getb ();
+  * @param wcount how many bytes to write
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual size_t write (const Exiv2::byte *data,
++                    size_t wcount);
++#else
+ virtual long write (const Exiv2::byte *data,
+                     long wcount);
++#endif
+ 
+ /**
+  * Write to stream.
+@@ -126,7 +144,11 @@ virtual long write (const Exiv2::byte *data,
+  * @param src stream to copy
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual size_t write (Exiv2::BasicIo &src);
++#else
+ virtual long write (Exiv2::BasicIo &src);
++#endif
+ 
+ /**
+  * Write a single byte.
+@@ -172,7 +194,11 @@ virtual int munmap ();
+  *
+  * @return -1 on error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual size_t tell (void) const;
++#else
+ virtual long int tell (void) const;
++#endif
+ 
+ /**
+  * Return overall size of the file.
+@@ -213,7 +239,11 @@ virtual bool eof () const;
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual const std::string& path () const noexcept;
++#else
+ virtual std::string path () const;
++#endif
+ 
+ #ifdef EXV_UNICODE_PATH
+ /**
+@@ -230,7 +260,11 @@ virtual std::wstring wpath () const;
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual Exiv2::BasicIo::UniquePtr temporary () const;
++#else
+ virtual Exiv2::BasicIo::AutoPtr temporary () const;
++#endif
+ 
+ };
+ 
+@@ -266,7 +300,11 @@ ExtractorIO::close ()
+  * @return buffer with data read, empty buffer (!) on failure (!)
+  */
+ Exiv2::DataBuf
++#if EXIV2_TEST_VERSION (0,28,0)
++ExtractorIO::read (size_t rcount)
++#else
+ ExtractorIO::read (long rcount)
++#endif
+ {
+   void *data;
+   ssize_t ret;
+@@ -284,9 +322,15 @@ ExtractorIO::read (long rcount)
+  * @param rcount size of 'buf'
+  * @return number of bytes read successfully, 0 on failure (!)
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++size_t
++ExtractorIO::read (Exiv2::byte *buf,
++                   size_t rcount)
++#else
+ long
+ ExtractorIO::read (Exiv2::byte *buf,
+                    long rcount)
++#endif
+ {
+   void *data;
+   ssize_t ret;
+@@ -305,6 +349,12 @@ ExtractorIO::read (Exiv2::byte *buf,
+   return got;
+ }
+ 
++#if EXIV2_TEST_VERSION (0,28,0)
++void ExtractorIO::populateFakeData()
++{
++  return;
++}
++#endif
+ 
+ /**
+  * Read a single character.
+@@ -319,7 +369,9 @@ ExtractorIO::getb ()
+   const unsigned char *r;
+ 
+   if (1 != ec->read (ec->cls, &data, 1))
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION(0,28,0)
++    throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+     throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+     throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -336,9 +388,15 @@ ExtractorIO::getb ()
+  * @param wcount how many bytes to write
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++size_t
++ExtractorIO::write (const Exiv2::byte *data,
++                    size_t wcount)
++#else
+ long
+ ExtractorIO::write (const Exiv2::byte *data,
+                     long wcount)
++#endif
+ {
+   return -1;
+ }
+@@ -350,7 +408,11 @@ ExtractorIO::write (const Exiv2::byte *data,
+  * @param src stream to copy
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++size_t
++#else
+ long
++#endif
+ ExtractorIO::write (Exiv2::BasicIo &src)
+ {
+   return -1;
+@@ -378,7 +440,9 @@ ExtractorIO::putb (Exiv2::byte data)
+ void
+ ExtractorIO::transfer (Exiv2::BasicIo& src)
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION(0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -427,7 +491,9 @@ ExtractorIO::seek (long offset,
+ Exiv2::byte *
+ ExtractorIO::mmap (bool isWritable)
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION (0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -452,7 +518,11 @@ ExtractorIO::munmap ()
+  *
+  * @return -1 on error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++size_t
++#else
+ long int
++#endif
+ ExtractorIO::tell (void) const
+ {
+   return (long) ec->seek (ec->cls, 0, SEEK_CUR);
+@@ -516,10 +586,17 @@ ExtractorIO::eof () const
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++const std::string&
++ExtractorIO::path () const noexcept
++#else
+ std::string
+ ExtractorIO::path () const
++#endif
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION (0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -536,7 +613,9 @@ ExtractorIO::path () const
+ std::wstring
+ ExtractorIO::wpath () const
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION (0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -552,11 +631,17 @@ ExtractorIO::wpath () const
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++Exiv2::BasicIo::UniquePtr
++#else
+ Exiv2::BasicIo::AutoPtr
++#endif
+ ExtractorIO::temporary () const
+ {
+   fprintf (stderr, "throwing temporary error\n");
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION(0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -737,8 +822,13 @@ EXTRACTOR_exiv2_extract_method (struct EXTRACTOR_ExtractContext *ec)
+ #if ! EXIV2_TEST_VERSION (0,24,0)
+     Exiv2::LogMsg::setLevel (Exiv2::LogMsg::mute);
+ #endif
++#if EXIV2_TEST_VERSION(0,28,0)
++    std::unique_ptr<Exiv2::BasicIo> eio (new ExtractorIO (ec));
++    Exiv2::Image::UniquePtr image = Exiv2::ImageFactory::open (std::move(eio));
++#else
+     std::auto_ptr<Exiv2::BasicIo> eio (new ExtractorIO (ec));
+     Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open (eio);
++#endif
+     if (0 == image.get ())
+       return;
+     image->readMetadata ();
+@@ -822,7 +912,11 @@ EXTRACTOR_exiv2_extract_method (struct EXTRACTOR_ExtractContext *ec)
+       ADDXMP ("Xmp.lr.hierarchicalSubject", EXTRACTOR_METATYPE_SUBJECT);
+     }
+   }
++#if EXIV2_TEST_VERSION (0,28,0)
++  catch (const Exiv2::Error& e)
++#else
+   catch (const Exiv2::AnyError& e)
++#endif
+   {
+ #if DEBUG
+     std::cerr << "Caught Exiv2 exception '" << e << "'\n";
diff --git a/srcpkgs/libextractor/template b/srcpkgs/libextractor/template
index ddd4790f93e88..bfcea979a308c 100644
--- a/srcpkgs/libextractor/template
+++ b/srcpkgs/libextractor/template
@@ -1,7 +1,7 @@
 # Template file for 'libextractor'
 pkgname=libextractor
 version=1.11
-revision=2
+revision=3
 build_style=gnu-configure
 configure_args="--disable-static"
 hostmakedepends="pkg-config"

From 162e6d403327cfd0bc309c97a6e150d514dc81ee Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 14/22] libgexiv2: update to 0.14.2.

---
 srcpkgs/libgexiv2/template | 14 +++++++-------
 1 file changed, 7 insertions(+), 7 deletions(-)

diff --git a/srcpkgs/libgexiv2/template b/srcpkgs/libgexiv2/template
index 23780e5397dc4..91dbcaa9aca52 100644
--- a/srcpkgs/libgexiv2/template
+++ b/srcpkgs/libgexiv2/template
@@ -1,19 +1,19 @@
 # Template file for 'libgexiv2'
 pkgname=libgexiv2
-version=0.14.0
-revision=3
+version=0.14.2
+revision=1
 build_style=meson
 build_helper="gir"
-configure_args="-Dintrospection=$(vopt_if gir true false)
- -Dvapi=$(vopt_if vala true false)"
+configure_args="$(vopt_bool gir introspection) $(vopt_bool vala vapi)"
 hostmakedepends="pkg-config glib-devel $(vopt_if vala 'vala') python3-gobject"
 makedepends="libglib-devel exiv2-devel"
 short_desc="GObject-based wrapper around the Exiv2 library"
 maintainer="Enno Boland <gottox@voidlinux.org>"
 license="GPL-2.0-or-later"
 homepage="https://wiki.gnome.org/Projects/gexiv2"
-distfiles="${GNOME_SITE}/gexiv2/${version%.*}/${pkgname/lib/}-${version}.tar.xz"
-checksum=e58279a6ff20b6f64fa499615da5e9b57cf65ba7850b72fafdf17221a9d6d69e
+changelog="https://gitlab.gnome.org/GNOME/gexiv2/-/raw/master/NEWS"
+distfiles="${GNOME_SITE}/gexiv2/${version%.*}/gexiv2-${version}.tar.xz"
+checksum=2a0c9cf48fbe8b3435008866ffd40b8eddb0667d2212b42396fdf688e93ce0be
 
 build_options="gir vala"
 build_options_default="gir vala"
@@ -23,7 +23,7 @@ libgexiv2-devel_package() {
 	short_desc+=" - development files"
 	pkg_install() {
 		vmove usr/include
-		vmove usr/lib/*.so
+		vmove "usr/lib/*.so"
 		vmove usr/lib/pkgconfig
 		if [ "$build_option_vala" ]; then
 			vmove usr/share/vala

From cfd1dbe47c17109af780d3ecadec8905c90d5c1a Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 15/22] libkexiv25: update to 23.08.2.

---
 srcpkgs/libkexiv25/template | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/srcpkgs/libkexiv25/template b/srcpkgs/libkexiv25/template
index 05c3deb508195..5700eb6e6e026 100644
--- a/srcpkgs/libkexiv25/template
+++ b/srcpkgs/libkexiv25/template
@@ -1,6 +1,6 @@
 # Template file for 'libkexiv25'
 pkgname=libkexiv25
-version=23.04.0
+version=23.08.2
 revision=1
 build_style=cmake
 configure_args="-DBUILD_TESTING=OFF"
@@ -11,7 +11,7 @@ maintainer="Denis Revin <denis.revin@gmail.com>"
 license="GPL-2.0-or-later"
 homepage="https://invent.kde.org/graphics/libkexiv2"
 distfiles="${KDE_SITE}/release-service/${version}/src/libkexiv2-${version}.tar.xz"
-checksum=18d3eed06df9d1e31d8434ed9887e305aba176d0856e19a8cd3bdb555b80d391
+checksum=d06e36a408bf2e846a18056a1f15e61d981fa2a1fceb81f7c15136604319d033
 
 libkexiv25-devel_package() {
 	short_desc+=" - development files"

From 1ab053430d5be561153e9acda51dfde6ec538891 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 16/22] nomacs: update to 3.17.2287.

---
 srcpkgs/nomacs/template | 17 +++++++++++++----
 1 file changed, 13 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/nomacs/template b/srcpkgs/nomacs/template
index 57d3a1e98e846..4f4d9a851d7ac 100644
--- a/srcpkgs/nomacs/template
+++ b/srcpkgs/nomacs/template
@@ -1,7 +1,8 @@
 # Template file for 'nomacs'
 pkgname=nomacs
-version=3.16.224
-revision=5
+version=3.17.2287
+revision=1
+_plugins_ver=3.17.2285
 build_wrksrc=ImageLounge
 build_style=cmake
 configure_args="-DCMAKE_BUILD_TYPE=None -DENABLE_TRANSLATIONS=1
@@ -13,5 +14,13 @@ short_desc="Simple yet powerful Qt imageviewer"
 maintainer="Kharlamov Alexey <der@2-47.ru>"
 license="GPL-3.0-or-later"
 homepage="https://github.com/nomacs/nomacs"
-distfiles="https://github.com/nomacs/nomacs/archive/${version}.tar.gz"
-checksum=bbc7e9048026ef9e0d2b64902c88050f17a679ef3d3c009de2c3b7de5d1d217c
+distfiles="https://github.com/nomacs/nomacs/archive/${version}.tar.gz
+ https://github.com/novomesk/nomacs-plugins/archive/refs/tags/${_plugins_ver}.tar.gz>plugins.tar.gz"
+checksum="6905ea615358f84a0c83d5b1b7077871dea0526ec667500a1951448cb845a92c
+ 946b2d754be9ecca5cb155f7ecc5dcafb164f6c3dcc7bf5c3c0610d3b47774aa"
+skip_extraction="plugins.tar.gz"
+
+post_extract() {
+ cd ${build_wrksrc}
+ vsrcextract -C plugins "plugins.tar.gz"
+}

From d37c0a07168cf2f656ec1428c2e98ce7026b440f Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 17/22] pdf2djvu: revbump for exiv2-0.28.0.

---
 srcpkgs/pdf2djvu/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/pdf2djvu/template b/srcpkgs/pdf2djvu/template
index ef7433c0c98ae..5a6f3ddf4ed35 100644
--- a/srcpkgs/pdf2djvu/template
+++ b/srcpkgs/pdf2djvu/template
@@ -1,7 +1,7 @@
 # Template file for 'pdf2djvu'
 pkgname=pdf2djvu
 version=0.9.19
-revision=4
+revision=5
 build_style=gnu-configure
 hostmakedepends="pkg-config djvulibre gettext"
 makedepends="djvulibre-devel poppler-devel libgraphicsmagick-devel exiv2-devel libuuid-devel"

From 96dbf4362a30d0b359a2cc551bc4fcffdc713264 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 18/22] phototonic: revbump for exiv2-0.28.0.

---
 srcpkgs/phototonic/patches/exiv2-0.28.patch | 135 ++++++++++++++++++++
 srcpkgs/phototonic/template                 |   2 +-
 2 files changed, 136 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/phototonic/patches/exiv2-0.28.patch

diff --git a/srcpkgs/phototonic/patches/exiv2-0.28.patch b/srcpkgs/phototonic/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..1c75b628dab33
--- /dev/null
+++ b/srcpkgs/phototonic/patches/exiv2-0.28.patch
@@ -0,0 +1,135 @@
+From 923a3fc14de0b779a45696c5f0aef34c74d84f13 Mon Sep 17 00:00:00 2001
+From: Andreas Sturmlechner <asturm@gentoo.org>
+Date: Sun, 28 May 2023 18:54:10 +0200
+Subject: [PATCH] Fix build with exiv2-0.28
+
+Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>
+---
+ ImageViewer.cpp   | 9 +++++++++
+ MetadataCache.cpp | 8 ++++++++
+ Phototonic.cpp    | 4 ++++
+ Tags.cpp          | 8 ++++++++
+ ThumbsViewer.cpp  | 4 ++++
+ 5 files changed, 33 insertions(+)
+
+diff --git a/ImageViewer.cpp b/ImageViewer.cpp
+index 357d223..df3ac43 100644
+--- a/ImageViewer.cpp
++++ b/ImageViewer.cpp
+@@ -945,7 +945,11 @@ void ImageViewer::keyMoveEvent(int direction) {
+ }
+ 
+ void ImageViewer::saveImage() {
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr image;
++#else
+     Exiv2::Image::AutoPtr image;
++#endif
+     bool exifError = false;
+ 
+     if (newImage) {
+@@ -985,8 +989,13 @@ void ImageViewer::saveImage() {
+ }
+ 
+ void ImageViewer::saveImageAs() {
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++    Exiv2::Image::UniquePtr newExifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
+     Exiv2::Image::AutoPtr newExifImage;
++#endif
+     bool exifError = false;
+ 
+     setCursorHiding(false);
+diff --git a/MetadataCache.cpp b/MetadataCache.cpp
+index 524ae74..5ddd4c8 100644
+--- a/MetadataCache.cpp
++++ b/MetadataCache.cpp
+@@ -64,7 +64,11 @@ void MetadataCache::clear() {
+ }
+ 
+ bool MetadataCache::loadImageMetadata(const QString &imageFullPath) {
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
++#endif
+     QSet<QString> tags;
+     long orientation = 0;
+ 
+@@ -78,7 +82,11 @@ bool MetadataCache::loadImageMetadata(const QString &imageFullPath) {
+     try {
+         Exiv2::ExifData &exifData = exifImage->exifData();
+         if (!exifData.empty()) {
++#if EXIV2_TEST_VERSION(0,28,0)
++            orientation = exifData["Exif.Image.Orientation"].value().toUint32();
++#else
+             orientation = exifData["Exif.Image.Orientation"].value().toLong();
++#endif
+         }
+     } catch (Exiv2::Error &error) {
+         qWarning() << "Failed to read Exif metadata";
+diff --git a/Phototonic.cpp b/Phototonic.cpp
+index 6cc95b3..bd5497d 100644
+--- a/Phototonic.cpp
++++ b/Phototonic.cpp
+@@ -3151,7 +3151,11 @@ void Phototonic::removeMetadata() {
+ 
+     if (ret == MessageBox::Yes) {
+         for (int file = 0; file < fileList.size(); ++file) {
++#if EXIV2_TEST_VERSION(0,28,0)
++            Exiv2::Image::UniquePtr image;
++#else
+             Exiv2::Image::AutoPtr image;
++#endif
+             try {
+                 image = Exiv2::ImageFactory::open(fileList[file].toStdString());
+                 image->clearMetadata();
+diff --git a/Tags.cpp b/Tags.cpp
+index 84eea16..a62da9d 100644
+--- a/Tags.cpp
++++ b/Tags.cpp
+@@ -136,7 +136,11 @@ void ImageTags::addTag(QString tagName, bool tagChecked) {
+ 
+ bool ImageTags::writeTagsToImage(QString &imageFileName, QSet<QString> &newTags) {
+     QSet<QString> imageTags;
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
++#endif
+ 
+     try {
+         exifImage = Exiv2::ImageFactory::open(imageFileName.toStdString());
+@@ -160,7 +164,11 @@ bool ImageTags::writeTagsToImage(QString &imageFileName, QSet<QString> &newTags)
+         QSetIterator<QString> newTagsIt(newTags);
+         while (newTagsIt.hasNext()) {
+             QString tag = newTagsIt.next();
++#if EXIV2_TEST_VERSION(0,28,0)
++            Exiv2::Value::UniquePtr value = Exiv2::Value::create(Exiv2::string);
++#else
+             Exiv2::Value::AutoPtr value = Exiv2::Value::create(Exiv2::string);
++#endif
+             value->read(tag.toStdString());
+             Exiv2::IptcKey key("Iptc.Application2.Keywords");
+             newIptcData.add(key, value.get());
+diff --git a/ThumbsViewer.cpp b/ThumbsViewer.cpp
+index 77a6189..4a11475 100644
+--- a/ThumbsViewer.cpp
++++ b/ThumbsViewer.cpp
+@@ -210,7 +210,11 @@ void ThumbsViewer::updateImageInfoViewer(QString imageFullPath) {
+         infoView->addEntry(key, val);
+     }
+ 
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
++#endif
+     try {
+         exifImage = Exiv2::ImageFactory::open(imageFullPath.toStdString());
+         exifImage->readMetadata();
+-- 
+2.40.1
+
diff --git a/srcpkgs/phototonic/template b/srcpkgs/phototonic/template
index 77ae8bf6a4406..4af006cb7da41 100644
--- a/srcpkgs/phototonic/template
+++ b/srcpkgs/phototonic/template
@@ -1,7 +1,7 @@
 # Template file for 'phototonic'
 pkgname=phototonic
 version=2.1
-revision=3
+revision=4
 build_style=qmake
 hostmakedepends="pkg-config qt5-qmake qt5-host-tools"
 makedepends="qt5-svg-devel exiv2-devel"

From efec2988d8dfe985beb897ba352596f2a040a332 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 19/22] qimgv: revbump for exiv2-0.28.0.

---
 srcpkgs/qimgv/patches/exiv2-0.28.patch | 16 ++++++++++++++++
 srcpkgs/qimgv/template                 |  2 +-
 2 files changed, 17 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/qimgv/patches/exiv2-0.28.patch

diff --git a/srcpkgs/qimgv/patches/exiv2-0.28.patch b/srcpkgs/qimgv/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..11f37b5ae2be3
--- /dev/null
+++ b/srcpkgs/qimgv/patches/exiv2-0.28.patch
@@ -0,0 +1,16 @@
+Patch-Source: https://git.alpinelinux.org/aports/tree/community/qimgv/exiv2-0.28.patch
+diff --git a/qimgv/sourcecontainers/documentinfo.cpp b/qimgv/sourcecontainers/documentinfo.cpp
+index 98a68f7..c062474 100644
+--- a/qimgv/sourcecontainers/documentinfo.cpp
++++ b/qimgv/sourcecontainers/documentinfo.cpp
+@@ -271,10 +271,6 @@ void DocumentInfo::loadExifTags() {
+         //std::cout << "Caught Exiv2 exception '" << e.what() << "'\n";
+         return;
+     }
+-    catch (Exiv2::BasicError<CharType> e) {
+-        //std::cout << "Caught BasicError Exiv2 exception '" << e.what() << "'\n";
+-        return;
+-    }
+ #endif
+ }
+ 
diff --git a/srcpkgs/qimgv/template b/srcpkgs/qimgv/template
index 7eb30db33992c..dd341dfe1bfce 100644
--- a/srcpkgs/qimgv/template
+++ b/srcpkgs/qimgv/template
@@ -1,7 +1,7 @@
 # Template file for 'qimgv'
 pkgname=qimgv
 version=1.0.2
-revision=2
+revision=3
 build_style=cmake
 configure_args="$(vopt_if video -DVIDEO_SUPPORT=ON -DVIDEO_SUPPORT=OFF)
  $(vopt_if scale -DOPENCV_SUPPORT=ON -DOPENCV_SUPPORT=OFF)

From 2578f8827a2aec3460b991a771f8b9e6cfeed3e7 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 20/22] SIR: revbump for exiv2-0.28.0.

---
 srcpkgs/SIR/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/SIR/template b/srcpkgs/SIR/template
index 113077acad354..c6da4c26b6c71 100644
--- a/srcpkgs/SIR/template
+++ b/srcpkgs/SIR/template
@@ -1,7 +1,7 @@
 # Template file for 'SIR'
 pkgname=SIR
 version=3.2.2
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="pkg-config"
 makedepends="exiv2-devel qt5-svg-devel qt5-tools-devel"

From c7a1aa459033fd7921feb15bc503bb0fe7cb9c4b Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 21/22] ufraw: revbump for exiv2-0.28.0.

---
 srcpkgs/ufraw/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/ufraw/template b/srcpkgs/ufraw/template
index ceddcacacefb2..15de1e78293f7 100644
--- a/srcpkgs/ufraw/template
+++ b/srcpkgs/ufraw/template
@@ -1,7 +1,7 @@
 # Template file for 'ufraw'
 pkgname=ufraw
 version=0.22
-revision=5
+revision=6
 build_style=gnu-configure
 configure_args="--enable-contrast --enable-mime --enable-openmp --with-gimp
  $(vopt_enable extras)"

From da440b1e24998dbed5ae8164a3ea07fb740b3fcf Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 22/22] viewnior: revbump for exiv2-0.28.0.

---
 srcpkgs/viewnior/patches/exiv2-0.28.patch | 147 ++++++++++++++++++++++
 srcpkgs/viewnior/template                 |   2 +-
 2 files changed, 148 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/viewnior/patches/exiv2-0.28.patch

diff --git a/srcpkgs/viewnior/patches/exiv2-0.28.patch b/srcpkgs/viewnior/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..71459dee15768
--- /dev/null
+++ b/srcpkgs/viewnior/patches/exiv2-0.28.patch
@@ -0,0 +1,147 @@
+Patch-Source: https://gitlab.archlinux.org/archlinux/packaging/packages/viewnior/-/blob/f206ce6c22a3ec5f1f9ea1bde4077584f80458dd/exiv2-0.28.patch
+--
+From b6bb81a1b46e911d15bbf9a730972523de177705 Mon Sep 17 00:00:00 2001
+From: tastytea <tastytea@tastytea.de>
+Date: Tue, 16 May 2023 10:54:40 +0200
+Subject: [PATCH 1/2] change exiv2 AutoPtr to unique_ptr
+
+exiv2-0.28.0 removed Exiv2::Image::AutoPtr and added
+Exiv2::Image::UniquePtr instead. since it's a typedef for
+std::unique_ptr<Image>, i'm using that directly instead of adding a
+condition on the exiv2 version.
+---
+ src/uni-exiv2.cpp | 21 +++++++++++----------
+ 1 file changed, 11 insertions(+), 10 deletions(-)
+
+diff --git a/src/uni-exiv2.cpp b/src/uni-exiv2.cpp
+index 0d14b9f..77064c2 100644
+--- a/src/uni-exiv2.cpp
++++ b/src/uni-exiv2.cpp
+@@ -22,12 +22,13 @@
+ 
+ #include <exiv2/exiv2.hpp>
+ #include <iostream>
++#include <memory>
+ 
+ #include "uni-exiv2.hpp"
+ 
+ #define ARRAY_SIZE(array) (sizeof array/sizeof(array[0]))
+ 
+-static Exiv2::Image::AutoPtr cached_image;
++static std::unique_ptr<Exiv2::Image> cached_image;
+ 
+ extern "C"
+ void
+@@ -35,8 +36,8 @@ uni_read_exiv2_map(const char *uri, void (*callback)(const char*, const char*, v
+ {
+     Exiv2::LogMsg::setLevel(Exiv2::LogMsg::mute);
+     try {
+-        Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open(uri);
+-        if ( image.get() == 0 ) {
++        std::unique_ptr<Exiv2::Image> image = Exiv2::ImageFactory::open(uri);
++        if (image == nullptr) {
+             return;
+         }
+ 
+@@ -91,14 +92,14 @@ uni_read_exiv2_to_cache(const char *uri)
+ {
+     Exiv2::LogMsg::setLevel(Exiv2::LogMsg::mute);
+ 
+-    if ( cached_image.get() != NULL ) {
++    if (cached_image != nullptr) {
+         cached_image->clearMetadata();
+-        cached_image.reset(NULL);
++        cached_image.reset(nullptr);
+     }
+ 
+     try {
+         cached_image = Exiv2::ImageFactory::open(uri);
+-        if ( cached_image.get() == 0 ) {
++        if (cached_image == nullptr) {
+             return 1;
+         }
+ 
+@@ -116,13 +117,13 @@ uni_write_exiv2_from_cache(const char *uri)
+ {
+     Exiv2::LogMsg::setLevel(Exiv2::LogMsg::mute);
+ 
+-    if ( cached_image.get() == NULL ) {
++    if (cached_image == nullptr) {
+         return 1;
+     }
+ 
+     try {
+-        Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open(uri);
+-        if ( image.get() == 0 ) {
++        std::unique_ptr<Exiv2::Image> image = Exiv2::ImageFactory::open(uri);
++        if (image == nullptr) {
+             return 2;
+         }
+ 
+@@ -130,7 +131,7 @@ uni_write_exiv2_from_cache(const char *uri)
+         image->writeMetadata();
+ 
+         cached_image->clearMetadata();
+-        cached_image.reset(NULL);
++        cached_image.reset(nullptr);
+ 
+         return 0;
+     } catch (Exiv2::AnyError& e) {
+
+From 47d0b98cb46526aa8aa035bebcabc14a11fa57ee Mon Sep 17 00:00:00 2001
+From: tastytea <tastytea@tastytea.de>
+Date: Tue, 16 May 2023 11:17:00 +0200
+Subject: [PATCH 2/2] add support for exiv-0.28.0 errors
+
+exiv2-0.28.0 changed Exiv2::AnyError to Exiv2::Error.
+---
+ src/uni-exiv2.cpp | 15 ++++++++++++---
+ 1 file changed, 12 insertions(+), 3 deletions(-)
+
+diff --git a/src/uni-exiv2.cpp b/src/uni-exiv2.cpp
+index 77064c2..567a50f 100644
+--- a/src/uni-exiv2.cpp
++++ b/src/uni-exiv2.cpp
+@@ -28,6 +28,15 @@
+ 
+ #define ARRAY_SIZE(array) (sizeof array/sizeof(array[0]))
+ 
++#define EXIV_ERROR Exiv2::AnyError
++#ifdef EXIV2_VERSION
++    #ifdef EXIV2_TEST_VERSION
++        #if EXIV2_TEST_VERSION(0,28,0)
++            #define EXIV_ERROR Exiv2::Error
++        #endif
++    #endif
++#endif
++
+ static std::unique_ptr<Exiv2::Image> cached_image;
+ 
+ extern "C"
+@@ -81,7 +90,7 @@ uni_read_exiv2_map(const char *uri, void (*callback)(const char*, const char*, v
+                 }
+             }
+         }
+-    } catch (Exiv2::AnyError& e) {
++    } catch (EXIV_ERROR& e) {
+         std::cerr << "Exiv2: '" << e << "'\n";
+     }
+ }
+@@ -104,7 +113,7 @@ uni_read_exiv2_to_cache(const char *uri)
+         }
+ 
+         cached_image->readMetadata();
+-    } catch (Exiv2::AnyError& e) {
++    } catch (EXIV_ERROR& e) {
+         std::cerr << "Exiv2: '" << e << "'\n";
+     }
+ 
+@@ -134,7 +143,7 @@ uni_write_exiv2_from_cache(const char *uri)
+         cached_image.reset(nullptr);
+ 
+         return 0;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (EXIV_ERROR& e) {
+         std::cerr << "Exiv2: '" << e << "'\n";
+     }
+ 
diff --git a/srcpkgs/viewnior/template b/srcpkgs/viewnior/template
index ea1e528a8651f..4c73226662ca0 100644
--- a/srcpkgs/viewnior/template
+++ b/srcpkgs/viewnior/template
@@ -1,7 +1,7 @@
 # Template file for 'viewnior'
 pkgname=viewnior
 version=1.8
-revision=1
+revision=2
 build_style=meson
 hostmakedepends="pkg-config intltool glib-devel gettext-devel"
 makedepends="gtk+-devel exiv2-devel"

^ permalink raw reply	[flat|nested] 27+ messages in thread

* Re: [PR PATCH] [Updated] exiv2: update to 0.28.0.
  2023-10-23  0:10 [PR PATCH] exiv2: update to 0.28.0 mhmdanas
  2023-10-23  0:20 ` [PR PATCH] [Updated] " mhmdanas
@ 2023-11-01 17:23 ` mhmdanas
  2023-11-01 17:26 ` mhmdanas
                   ` (23 subsequent siblings)
  25 siblings, 0 replies; 27+ messages in thread
From: mhmdanas @ 2023-11-01 17:23 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 1855 bytes --]

There is an updated pull request by mhmdanas against master on the void-packages repository

https://github.com/mhmdanas/void-packages exiv2-0.28.0
https://github.com/void-linux/void-packages/pull/46838

exiv2: update to 0.28.0.
<!-- Uncomment relevant sections and delete options which are not applicable -->

#### Testing the changes
- I tested the changes in this PR: **briefly**

TODO:
- [x] Fix `gwenview`'s failed checks (not really fixed but the exact same tests fail on master as well)

@Johnnynator ufraw has been [unmaintained since December 2016](https://sourceforge.net/p/ufraw/discussion/434060/thread/30b4249b/), and it doesn't build with this PR; here are the options:
- remove the package entirely
- replace it with the newer [nufraw](https://sourceforge.net/projects/nufraw/), which already has [an exiv 0.28.x patch floating around](https://aur.archlinux.org/cgit/aur.git/tree/exiv2-error.patch?h=nufraw)
- patch it to build with this PR

What do you think?

<!--
#### New package
- This new package conforms to the [package requirements](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#package-requirements): **YES**|**NO**
-->

<!-- Note: If the build is likely to take more than 2 hours, please add ci skip tag as described in
https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration
and test at least one native build and, if supported, at least one cross build.
Ignore this section if this PR is not skipping CI.
-->
<!--
#### Local build testing
- I built this PR locally for my native architecture, (ARCH-LIBC)
- I built this PR locally for these architectures (if supported. mark crossbuilds):
  - aarch64-musl
  - armv7l
  - armv6l-musl
-->


A patch file from https://github.com/void-linux/void-packages/pull/46838.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-exiv2-0.28.0-46838.patch --]
[-- Type: text/x-diff, Size: 61142 bytes --]

From c24ded872bb81ede65102d92b828d9575252b4f9 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Mon, 23 Oct 2023 01:20:09 +0100
Subject: [PATCH 01/22] inih: add `libINIReader.so.0` common/shlibs entry.

---
 common/shlibs | 1 +
 1 file changed, 1 insertion(+)

diff --git a/common/shlibs b/common/shlibs
index 9036a675c1ae5..8f03a38a16789 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -3905,6 +3905,7 @@ libnotcurses++.so.3 notcurses-3.0.5_1
 libnotcurses-ffi.so.3 notcurses-3.0.5_1
 libevemu.so.3 evemu-2.7.0_1
 libinih.so.0 inih-52_1
+libINIReader.so.0 inih-57_1
 libpcaudio.so.0 pcaudiolib-1.1_1
 libdcerpc-samr.so.0 samba-4.13.2_1
 libdcerpc-server-core.so.0 samba-4.13.2_1

From 3cb90b2a57497f5e65cbfa759bacceee267febf6 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:12 +0100
Subject: [PATCH 02/22] exiv2: update to 0.28.0.

---
 common/shlibs                        |  2 +-
 srcpkgs/exiv2/patches/fix-tests.diff | 31 ++++++++++++++++++++++++++++
 srcpkgs/exiv2/template               | 14 ++++++++-----
 3 files changed, 41 insertions(+), 6 deletions(-)
 create mode 100644 srcpkgs/exiv2/patches/fix-tests.diff

diff --git a/common/shlibs b/common/shlibs
index 8f03a38a16789..0b1d0c89d3e51 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -555,7 +555,7 @@ libgimpcolor-2.0.so.0 libgimp-2.10.0_1
 libgimpmodule-2.0.so.0 libgimp-2.10.0_1
 libgmic.so.3 gmic-3.1.6_1
 libcgmic.so.3 gmic-3.1.6_1
-libexiv2.so.27 exiv2-0.27_1
+libexiv2.so.28 exiv2-0.28.0_1
 libKF5Holidays.so.5 kholidays-5.47.0_1
 libPhabricatorHelpers.so.5 purpose-5.48.0_1
 libKF5PurposeWidgets.so.5 purpose-5.48.0_1
diff --git a/srcpkgs/exiv2/patches/fix-tests.diff b/srcpkgs/exiv2/patches/fix-tests.diff
new file mode 100644
index 0000000000000..3eb7adc1635f3
--- /dev/null
+++ b/srcpkgs/exiv2/patches/fix-tests.diff
@@ -0,0 +1,31 @@
+diff --git a/tests/tiff_test/test_tag_compare.py b/tests/tiff_test/test_tag_compare.py
+index a8538bd2..974d1a9a 100644
+--- a/tests/tiff_test/test_tag_compare.py
++++ b/tests/tiff_test/test_tag_compare.py
+@@ -28,8 +28,8 @@ class OutputTagExtract(metaclass=system_tests.CaseMeta):
+             tmp = line.split()
+ 
+             exif, image, tag = tmp[0].split('.')
+-            self.assertEquals(exif, "Exif")
+-            self.assertEquals(image, "Image")
++            self.assertEqual(exif, "Exif")
++            self.assertEqual(image, "Image")
+ 
+             data.append({
+                 "tag": tag,
+@@ -87,13 +87,13 @@ class OutputTagExtract(metaclass=system_tests.CaseMeta):
+         """
+         for pa_elem, pS_elem in zip(self.pa_data, self.pS_data):
+             for key in ["tag", "type", "len"]:
+-                self.assertEquals(pa_elem[key], pS_elem[key])
++                self.assertEqual(pa_elem[key], pS_elem[key])
+ 
+             if pa_elem["tag"] in [
+                     "ImageWidth", "ImageLength", "BitsPerSample",
+                     "DocumentName", "ImageDescription", "StripOffsets",
+                     "SamplesPerPixel", "StripByteCounts"]:
+-                self.assertEquals(pa_elem["val"], pS_elem["val"])
++                self.assertEqual(pa_elem["val"], pS_elem["val"])
+ 
+     def compare_stdout(self, i, command, got_stdout, expected_stdout):
+         super().compare_stdout(i, command, got_stdout, expected_stdout)
diff --git a/srcpkgs/exiv2/template b/srcpkgs/exiv2/template
index 49985fe82cc14..876b253541d00 100644
--- a/srcpkgs/exiv2/template
+++ b/srcpkgs/exiv2/template
@@ -1,17 +1,17 @@
 # Template file for 'exiv2'
 pkgname=exiv2
-version=0.27.6
+version=0.28.0
 revision=1
 build_style=cmake
 configure_args="-DEXIV2_BUILD_SAMPLES=OFF -DEXIV2_ENABLE_BMFF=ON"
-makedepends="zlib-devel expat-devel"
-checkdepends="gtest-devel"
+makedepends="zlib-devel brotli-devel expat-devel inih-devel"
+checkdepends="gtest-devel python3"
 short_desc="Image metadata manipulation"
 maintainer="Enno Boland <gottox@voidlinux.org>"
 license="GPL-2.0-or-later"
 homepage="https://www.exiv2.org"
 distfiles="https://github.com/Exiv2/exiv2/releases/download/v${version}/exiv2-${version}-Source.tar.gz"
-checksum=4c192483a1125dc59a3d70b30d30d32edace9e14adf52802d2f853abf72db8a6
+checksum=89af3b5ef7277753ef7a7b5374ae017c6b9e304db3b688f1948e73e103491f3d
 
 if [ -n "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DEXIV2_BUILD_UNIT_TESTS=ON"
@@ -21,6 +21,11 @@ if [ -n "$XBPS_CCACHE" ]; then
 	configure_args+=" -DBUILD_WITH_CCACHE=ON"
 fi
 
+pre_check() {
+	# https://github.com/Exiv2/exiv2/issues/2762
+	rm -f tests/bugfixes/github/test_issue_2427.py
+}
+
 exiv2-devel_package() {
 	depends="${makedepends} ${sourcepkg}-${version}_${revision}"
 	short_desc+=" - development files"
@@ -28,7 +33,6 @@ exiv2-devel_package() {
 		vmove usr/include
 		vmove usr/lib/cmake
 		vmove usr/lib/pkgconfig
-		vmove "usr/lib/*.a"
 		vmove "usr/lib/*.so"
 	}
 }

From c770db7b4c73e4a05854124fed22690af0553595 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:37 +0100
Subject: [PATCH 03/22] ART: revbump for exiv2-0.28.0.

---
 srcpkgs/ART/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/ART/template b/srcpkgs/ART/template
index b6c47fc6c4cdf..94c7aa0378061 100644
--- a/srcpkgs/ART/template
+++ b/srcpkgs/ART/template
@@ -1,7 +1,7 @@
 # Template file for 'ART'
 pkgname=ART
 version=1.20.2
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="pkg-config"
 makedepends="fftw-devel gtkmm-devel lensfun-devel

From 0d3804c726646adf7e379cbe692d26d242e6e580 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 04/22] darktable: revbump for exiv2-0.28.0.

---
 srcpkgs/darktable/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/darktable/template b/srcpkgs/darktable/template
index 60415a34dc018..3d35571239a93 100644
--- a/srcpkgs/darktable/template
+++ b/srcpkgs/darktable/template
@@ -1,7 +1,7 @@
 # Template file for 'darktable'
 pkgname=darktable
 version=4.4.2
-revision=2
+revision=3
 # upstream only supports these archs:
 archs="x86_64* aarch64* ppc64le*"
 build_style=cmake

From 7e8d45a2e180cd2036b1c81054e20689d00b5a06 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 05/22] digikam: revbump for exiv2-0.28.0.

---
 srcpkgs/digikam/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/digikam/template b/srcpkgs/digikam/template
index 206185f565488..4784bf7d62a8e 100644
--- a/srcpkgs/digikam/template
+++ b/srcpkgs/digikam/template
@@ -1,7 +1,7 @@
 # Template file for 'digikam'
 pkgname=digikam
 version=8.1.0
-revision=1
+revision=2
 build_style=cmake
 configure_args="-DBUILD_TESTING=OFF"
 hostmakedepends="extra-cmake-modules gettext pkg-config bison flex qt5-qmake

From 27a5d8f2a60ae766ad1be21809edb672abb319b8 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 06/22] geeqie: revbump for exiv2-0.28.0.

---
 srcpkgs/geeqie/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/geeqie/template b/srcpkgs/geeqie/template
index b5f958f854c1b..b494bc149e957 100644
--- a/srcpkgs/geeqie/template
+++ b/srcpkgs/geeqie/template
@@ -1,7 +1,7 @@
 # Template file for 'geeqie'
 pkgname=geeqie
 version=2.1
-revision=1
+revision=2
 build_style=meson
 hostmakedepends="pkg-config gettext xxd gdk-pixbuf-devel glib-devel"
 makedepends="gtk+3-devel glib-devel lcms2-devel exiv2-devel libheif-devel

From 096ef0a8962dcae5f6c4de4d702858a861a50189 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 07/22] gthumb: revbump for exiv2-0.28.0.

---
 srcpkgs/gthumb/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/gthumb/template b/srcpkgs/gthumb/template
index c8e19f0dedb61..732d5e1c6089f 100644
--- a/srcpkgs/gthumb/template
+++ b/srcpkgs/gthumb/template
@@ -1,7 +1,7 @@
 # Template file for 'gthumb'
 pkgname=gthumb
 version=3.12.3
-revision=1
+revision=2
 build_style=meson
 hostmakedepends="gettext pkg-config itstool glib-devel"
 makedepends="webkit2gtk-devel json-glib-devel libsecret-devel librsvg-devel

From fb9c21d01088e0f7aa4ca4fe99fa5497c34f6e45 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 08/22] gwenview: revbump for exiv2-0.28.0.

---
 srcpkgs/gwenview/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/gwenview/template b/srcpkgs/gwenview/template
index 73d450a458c4d..eb876cfadcfe8 100644
--- a/srcpkgs/gwenview/template
+++ b/srcpkgs/gwenview/template
@@ -1,7 +1,7 @@
 # Template file for 'gwenview'
 pkgname=gwenview
 version=23.08.2
-revision=1
+revision=2
 build_style=cmake
 build_helper=qemu
 hostmakedepends="extra-cmake-modules pkg-config qt5-qmake qt5-host-tools

From 803aa9fc8cd0eda481b635a9633ac0ef52368c9d Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 09/22] hugin: revbump for exiv2-0.28.0.

---
 srcpkgs/hugin/patches/exiv2-0.28.patch | 77 ++++++++++++++++++++++++++
 srcpkgs/hugin/template                 |  2 +-
 2 files changed, 78 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/hugin/patches/exiv2-0.28.patch

diff --git a/srcpkgs/hugin/patches/exiv2-0.28.patch b/srcpkgs/hugin/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..49f0518117020
--- /dev/null
+++ b/srcpkgs/hugin/patches/exiv2-0.28.patch
@@ -0,0 +1,77 @@
+Patch-Source: https://gitlab.archlinux.org/archlinux/packaging/packages/hugin/-/blob/main/exiv2-0.28.patch
+diff -r 79cd11a7a66f src/hugin_base/panodata/Exiv2Helper.cpp
+--- a/src/hugin_base/panodata/Exiv2Helper.cpp	Wed May 24 19:13:20 2023 +0200
++++ b/src/hugin_base/panodata/Exiv2Helper.cpp	Mon Jun 05 00:31:19 2023 +0200
+@@ -40,7 +40,7 @@
+             Exiv2::ExifData::iterator itr = exifData.findKey(Exiv2::ExifKey(keyName));
+             if (itr != exifData.end() && itr->count())
+             {
+-                value = itr->toLong();
++                value = itr->toUint32();
+                 return true;
+             }
+             else
+@@ -165,7 +165,7 @@
+         {
+             if(it!=exifData.end() && it->count())
+             {
+-                return it->toLong();
++                return it->toUint32();
+             }
+             return 0;
+         };
+@@ -600,4 +600,4 @@
+         };
+ 
+     }; //namespace Exiv2Helper
+-}; //namespace HuginBase
+\ No newline at end of file
++}; //namespace HuginBase
+diff -r 79cd11a7a66f src/hugin_base/panodata/SrcPanoImage.cpp
+--- a/src/hugin_base/panodata/SrcPanoImage.cpp	Wed May 24 19:13:20 2023 +0200
++++ b/src/hugin_base/panodata/SrcPanoImage.cpp	Mon Jun 05 00:31:19 2023 +0200
+@@ -384,7 +384,7 @@
+                     pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaImageWidthPixels"));
+                     if (pos != xmpData.end())
+                     {
+-                        croppedWidth = pos->toLong();
++                        croppedWidth = pos->toUint32();
+                     }
+                     else
+                     {
+@@ -394,7 +394,7 @@
+                     pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaImageHeightPixels"));
+                     if (pos != xmpData.end())
+                     {
+-                        croppedHeight = pos->toLong();
++                        croppedHeight = pos->toUint32();
+                     }
+                     else
+                     {
+@@ -408,7 +408,7 @@
+                         double hfov = 0;
+                         if (pos != xmpData.end())
+                         {
+-                            hfov = 360 * croppedWidth / (double)pos->toLong();
++                            hfov = 360 * croppedWidth / (double)pos->toUint32();
+                         }
+                         else
+                         {
+@@ -419,7 +419,7 @@
+                         pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.FullPanoHeightPixels"));
+                         if (pos != xmpData.end())
+                         {
+-                            fullHeight = pos->toLong();
++                            fullHeight = pos->toUint32();
+                         }
+                         else
+                         {
+@@ -430,7 +430,7 @@
+                         pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaTopPixels"));
+                         if (pos != xmpData.end())
+                         {
+-                            cropTop = pos->toLong();
++                            cropTop = pos->toUint32();
+                         }
+                         else
+                         {
diff --git a/srcpkgs/hugin/template b/srcpkgs/hugin/template
index f96d2f6e27d42..ce71f6e4cbb2d 100644
--- a/srcpkgs/hugin/template
+++ b/srcpkgs/hugin/template
@@ -1,7 +1,7 @@
 # Template file for 'hugin'
 pkgname=hugin
 version=2022.0.0
-revision=10
+revision=11
 build_style=cmake
 build_helper=cmake-wxWidgets-gtk3
 pycompile_dirs="usr/share/hugin/data/plugins usr/share/hugin/data/plugins-templates"

From ecb668d882d5e51f45a26666473251717ca0b6c3 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 10/22] kfilemetadata5: revbump for exiv2-0.28.0.

---
 srcpkgs/kfilemetadata5/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/kfilemetadata5/template b/srcpkgs/kfilemetadata5/template
index 00f7a98cf6399..e294ae5af947c 100644
--- a/srcpkgs/kfilemetadata5/template
+++ b/srcpkgs/kfilemetadata5/template
@@ -1,7 +1,7 @@
 # Template file for 'kfilemetadata5'
 pkgname=kfilemetadata5
 version=5.111.0
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="kcoreaddons extra-cmake-modules pkg-config qt5-host-tools qt5-qmake
  gettext kcoreaddons python3"

From 710c8361aa0e2e5f40a075533e5c68c726573b7f Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 11/22] krename: revbump for exiv2-0.28.0.

---
 srcpkgs/krename/patches/e7dd767a.patch | 90 ++++++++++++++++++++++++++
 srcpkgs/krename/template               |  2 +-
 2 files changed, 91 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/krename/patches/e7dd767a.patch

diff --git a/srcpkgs/krename/patches/e7dd767a.patch b/srcpkgs/krename/patches/e7dd767a.patch
new file mode 100644
index 0000000000000..a0ef428ce46b1
--- /dev/null
+++ b/srcpkgs/krename/patches/e7dd767a.patch
@@ -0,0 +1,90 @@
+Patch-Source: https://invent.kde.org/utilities/krename/-/commit/e7dd767a
+From e7dd767a9a1068ee1fe1502c4d619b57d3b12add Mon Sep 17 00:00:00 2001
+From: Andreas Sturmlechner <asturm@gentoo.org>
+Date: Fri, 26 May 2023 23:23:10 +0200
+Subject: [PATCH] Fix build with >=exiv2-0.28, raise minimum to 0.27
+
+- enables use of EXIV2_TEST_VERSION macro
+- exiv2 headers cleanup
+
+Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>
+---
+ CMakeLists.txt         |  6 +-----
+ config-krename.h.cmake |  3 ---
+ src/exiv2plugin.cpp    | 17 +++++------------
+ 3 files changed, 6 insertions(+), 20 deletions(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 0bda8ac..72e7297 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -56,13 +56,9 @@ set_package_properties(Taglib PROPERTIES
+     TYPE OPTIONAL)
+ 
+ # Find exiv2
+-find_package(LibExiv2 0.13) # AccessMode was added in 0.13
++find_package(LibExiv2 0.27) # EXIV2_TEST_VERSION was added in 0.27
+ set_package_properties(LibExiv2 PROPERTIES TYPE OPTIONAL)
+ 
+-if (LibExiv2_VERSION VERSION_GREATER_EQUAL "0.27")
+-    set(HAVE_LIBEXIV2_0_27 TRUE)
+-endif()
+-
+ # Find podofo
+ find_package(PoDoFo)
+ set_package_properties(PoDoFo PROPERTIES
+diff --git a/config-krename.h.cmake b/config-krename.h.cmake
+index 76c3d30..862e40b 100644
+--- a/config-krename.h.cmake
++++ b/config-krename.h.cmake
+@@ -6,9 +6,6 @@
+ /* have Exiv2 */
+ #cmakedefine01 HAVE_EXIV2
+ 
+-/* Defined if we have libexiv2 >= 0.27 */
+-#cmakedefine HAVE_LIBEXIV2_0_27
+-
+ /* have PoDoFo */
+ #cmakedefine01 HAVE_PODOFO
+ 
+diff --git a/src/exiv2plugin.cpp b/src/exiv2plugin.cpp
+index 5694d8c..25e8869 100644
+--- a/src/exiv2plugin.cpp
++++ b/src/exiv2plugin.cpp
+@@ -3,20 +3,9 @@
+ 
+ #include "exiv2plugin.h"
+ 
+-#include "../config-krename.h"
+-
+ #include <KLocalizedString>
+ 
+-#include <exiv2/error.hpp>
+-#include <exiv2/exif.hpp>
+-#include <exiv2/image.hpp>
+-#include <exiv2/iptc.hpp>
+-#ifdef HAVE_LIBEXIV2_0_27
+-    #include <exiv2/xmp_exiv2.hpp>
+-#else
+-    #include <exiv2/xmp.hpp>
+-#endif
+-#include <exiv2/tags.hpp>
++#include <exiv2/exiv2.hpp>
+ 
+ #include "batchrenamer.h"
+ #include "tokenhelpdialog.h"
+@@ -381,7 +370,11 @@ QString Exiv2Plugin::processFile(BatchRenamer *b, int index, const QString &file
+     std::string strFilename(asc.constData(), asc.length());
+ 
+     try {
++#if EXIV2_TEST_VERSION(0,28,0)
++        Image::UniquePtr image = Exiv2::ImageFactory::open(strFilename);
++#else
+         Image::AutoPtr image = Exiv2::ImageFactory::open(strFilename);
++#endif
+         if (image.get() != nullptr && image->good()) {
+             image->readMetadata();
+ 
+-- 
+GitLab
+
diff --git a/srcpkgs/krename/template b/srcpkgs/krename/template
index 66023163e3293..df5535007714a 100644
--- a/srcpkgs/krename/template
+++ b/srcpkgs/krename/template
@@ -1,7 +1,7 @@
 # Template file for 'krename'
 pkgname=krename
 version=5.0.2
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="extra-cmake-modules gettext kcoreaddons pkg-config qt5-host-tools qt5-qmake"
 makedepends="exiv2-devel freetype-devel kjs-devel kparts-devel libpodofo-devel

From 86e47a7365d59ef2ae477e4dc591e0a8954786d2 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 12/22] krita: revbump for exiv2-0.28.0.

---
 srcpkgs/krita/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/krita/template b/srcpkgs/krita/template
index a4d3de04b049f..b479e0db798ee 100644
--- a/srcpkgs/krita/template
+++ b/srcpkgs/krita/template
@@ -1,7 +1,7 @@
 # Template file for 'krita'
 pkgname=krita
 version=5.2.0
-revision=1
+revision=2
 build_style=cmake
 configure_args="-Wno-dev -DBUILD_TESTING=OFF"
 hostmakedepends="extra-cmake-modules gettext pkg-config python3

From 19f8c98058c10e2fc1a7a2abaedcf7ae04668c14 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 13/22] libextractor: revbump for exiv2-0.28.0.

---
 srcpkgs/libextractor/patches/exiv2-0.28.patch | 286 ++++++++++++++++++
 srcpkgs/libextractor/template                 |   2 +-
 2 files changed, 287 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/libextractor/patches/exiv2-0.28.patch

diff --git a/srcpkgs/libextractor/patches/exiv2-0.28.patch b/srcpkgs/libextractor/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..270a626d8ab06
--- /dev/null
+++ b/srcpkgs/libextractor/patches/exiv2-0.28.patch
@@ -0,0 +1,286 @@
+Patch-Source: https://gitlab.archlinux.org/archlinux/packaging/packages/libextractor/-/blob/main/exiv2-0.28.patch
+diff --git a/src/plugins/exiv2_extractor.cc b/src/plugins/exiv2_extractor.cc
+index 78f9bda..d32ed6a 100644
+--- a/src/plugins/exiv2_extractor.cc
++++ b/src/plugins/exiv2_extractor.cc
+@@ -90,7 +90,11 @@ virtual int close ();
+  * @param rcount number of bytes to read
+  * @return buffer with data read, empty buffer (!) on failure (!)
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++virtual Exiv2::DataBuf read (size_t rcount);
++#else
+ virtual Exiv2::DataBuf read (long rcount);
++#endif
+ 
+ /**
+  * Read up to 'rcount' bytes into 'buf'.
+@@ -99,8 +103,17 @@ virtual Exiv2::DataBuf read (long rcount);
+  * @param rcount size of 'buf'
+  * @return number of bytes read successfully, 0 on failure (!)
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++virtual size_t read (Exiv2::byte *buf,
++                   size_t rcount);
++#else
+ virtual long read (Exiv2::byte *buf,
+                    long rcount);
++#endif
++
++#if EXIV2_TEST_VERSION (0,28,0)
++virtual void populateFakeData();
++#endif
+ 
+ /**
+  * Read a single character.
+@@ -117,8 +130,13 @@ virtual int getb ();
+  * @param wcount how many bytes to write
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual size_t write (const Exiv2::byte *data,
++                    size_t wcount);
++#else
+ virtual long write (const Exiv2::byte *data,
+                     long wcount);
++#endif
+ 
+ /**
+  * Write to stream.
+@@ -126,7 +144,11 @@ virtual long write (const Exiv2::byte *data,
+  * @param src stream to copy
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual size_t write (Exiv2::BasicIo &src);
++#else
+ virtual long write (Exiv2::BasicIo &src);
++#endif
+ 
+ /**
+  * Write a single byte.
+@@ -172,7 +194,11 @@ virtual int munmap ();
+  *
+  * @return -1 on error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual size_t tell (void) const;
++#else
+ virtual long int tell (void) const;
++#endif
+ 
+ /**
+  * Return overall size of the file.
+@@ -213,7 +239,11 @@ virtual bool eof () const;
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual const std::string& path () const noexcept;
++#else
+ virtual std::string path () const;
++#endif
+ 
+ #ifdef EXV_UNICODE_PATH
+ /**
+@@ -230,7 +260,11 @@ virtual std::wstring wpath () const;
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual Exiv2::BasicIo::UniquePtr temporary () const;
++#else
+ virtual Exiv2::BasicIo::AutoPtr temporary () const;
++#endif
+ 
+ };
+ 
+@@ -266,7 +300,11 @@ ExtractorIO::close ()
+  * @return buffer with data read, empty buffer (!) on failure (!)
+  */
+ Exiv2::DataBuf
++#if EXIV2_TEST_VERSION (0,28,0)
++ExtractorIO::read (size_t rcount)
++#else
+ ExtractorIO::read (long rcount)
++#endif
+ {
+   void *data;
+   ssize_t ret;
+@@ -284,9 +322,15 @@ ExtractorIO::read (long rcount)
+  * @param rcount size of 'buf'
+  * @return number of bytes read successfully, 0 on failure (!)
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++size_t
++ExtractorIO::read (Exiv2::byte *buf,
++                   size_t rcount)
++#else
+ long
+ ExtractorIO::read (Exiv2::byte *buf,
+                    long rcount)
++#endif
+ {
+   void *data;
+   ssize_t ret;
+@@ -305,6 +349,12 @@ ExtractorIO::read (Exiv2::byte *buf,
+   return got;
+ }
+ 
++#if EXIV2_TEST_VERSION (0,28,0)
++void ExtractorIO::populateFakeData()
++{
++  return;
++}
++#endif
+ 
+ /**
+  * Read a single character.
+@@ -319,7 +369,9 @@ ExtractorIO::getb ()
+   const unsigned char *r;
+ 
+   if (1 != ec->read (ec->cls, &data, 1))
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION(0,28,0)
++    throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+     throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+     throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -336,9 +388,15 @@ ExtractorIO::getb ()
+  * @param wcount how many bytes to write
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++size_t
++ExtractorIO::write (const Exiv2::byte *data,
++                    size_t wcount)
++#else
+ long
+ ExtractorIO::write (const Exiv2::byte *data,
+                     long wcount)
++#endif
+ {
+   return -1;
+ }
+@@ -350,7 +408,11 @@ ExtractorIO::write (const Exiv2::byte *data,
+  * @param src stream to copy
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++size_t
++#else
+ long
++#endif
+ ExtractorIO::write (Exiv2::BasicIo &src)
+ {
+   return -1;
+@@ -378,7 +440,9 @@ ExtractorIO::putb (Exiv2::byte data)
+ void
+ ExtractorIO::transfer (Exiv2::BasicIo& src)
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION(0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -427,7 +491,9 @@ ExtractorIO::seek (long offset,
+ Exiv2::byte *
+ ExtractorIO::mmap (bool isWritable)
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION (0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -452,7 +518,11 @@ ExtractorIO::munmap ()
+  *
+  * @return -1 on error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++size_t
++#else
+ long int
++#endif
+ ExtractorIO::tell (void) const
+ {
+   return (long) ec->seek (ec->cls, 0, SEEK_CUR);
+@@ -516,10 +586,17 @@ ExtractorIO::eof () const
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++const std::string&
++ExtractorIO::path () const noexcept
++#else
+ std::string
+ ExtractorIO::path () const
++#endif
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION (0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -536,7 +613,9 @@ ExtractorIO::path () const
+ std::wstring
+ ExtractorIO::wpath () const
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION (0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -552,11 +631,17 @@ ExtractorIO::wpath () const
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++Exiv2::BasicIo::UniquePtr
++#else
+ Exiv2::BasicIo::AutoPtr
++#endif
+ ExtractorIO::temporary () const
+ {
+   fprintf (stderr, "throwing temporary error\n");
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION(0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -737,8 +822,13 @@ EXTRACTOR_exiv2_extract_method (struct EXTRACTOR_ExtractContext *ec)
+ #if ! EXIV2_TEST_VERSION (0,24,0)
+     Exiv2::LogMsg::setLevel (Exiv2::LogMsg::mute);
+ #endif
++#if EXIV2_TEST_VERSION(0,28,0)
++    std::unique_ptr<Exiv2::BasicIo> eio (new ExtractorIO (ec));
++    Exiv2::Image::UniquePtr image = Exiv2::ImageFactory::open (std::move(eio));
++#else
+     std::auto_ptr<Exiv2::BasicIo> eio (new ExtractorIO (ec));
+     Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open (eio);
++#endif
+     if (0 == image.get ())
+       return;
+     image->readMetadata ();
+@@ -822,7 +912,11 @@ EXTRACTOR_exiv2_extract_method (struct EXTRACTOR_ExtractContext *ec)
+       ADDXMP ("Xmp.lr.hierarchicalSubject", EXTRACTOR_METATYPE_SUBJECT);
+     }
+   }
++#if EXIV2_TEST_VERSION (0,28,0)
++  catch (const Exiv2::Error& e)
++#else
+   catch (const Exiv2::AnyError& e)
++#endif
+   {
+ #if DEBUG
+     std::cerr << "Caught Exiv2 exception '" << e << "'\n";
diff --git a/srcpkgs/libextractor/template b/srcpkgs/libextractor/template
index ddd4790f93e88..bfcea979a308c 100644
--- a/srcpkgs/libextractor/template
+++ b/srcpkgs/libextractor/template
@@ -1,7 +1,7 @@
 # Template file for 'libextractor'
 pkgname=libextractor
 version=1.11
-revision=2
+revision=3
 build_style=gnu-configure
 configure_args="--disable-static"
 hostmakedepends="pkg-config"

From ffff9172b168a9a5cbef1b8bbc6619c091ed6c86 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 14/22] libgexiv2: update to 0.14.2.

---
 srcpkgs/libgexiv2/template | 14 +++++++-------
 1 file changed, 7 insertions(+), 7 deletions(-)

diff --git a/srcpkgs/libgexiv2/template b/srcpkgs/libgexiv2/template
index 23780e5397dc4..91dbcaa9aca52 100644
--- a/srcpkgs/libgexiv2/template
+++ b/srcpkgs/libgexiv2/template
@@ -1,19 +1,19 @@
 # Template file for 'libgexiv2'
 pkgname=libgexiv2
-version=0.14.0
-revision=3
+version=0.14.2
+revision=1
 build_style=meson
 build_helper="gir"
-configure_args="-Dintrospection=$(vopt_if gir true false)
- -Dvapi=$(vopt_if vala true false)"
+configure_args="$(vopt_bool gir introspection) $(vopt_bool vala vapi)"
 hostmakedepends="pkg-config glib-devel $(vopt_if vala 'vala') python3-gobject"
 makedepends="libglib-devel exiv2-devel"
 short_desc="GObject-based wrapper around the Exiv2 library"
 maintainer="Enno Boland <gottox@voidlinux.org>"
 license="GPL-2.0-or-later"
 homepage="https://wiki.gnome.org/Projects/gexiv2"
-distfiles="${GNOME_SITE}/gexiv2/${version%.*}/${pkgname/lib/}-${version}.tar.xz"
-checksum=e58279a6ff20b6f64fa499615da5e9b57cf65ba7850b72fafdf17221a9d6d69e
+changelog="https://gitlab.gnome.org/GNOME/gexiv2/-/raw/master/NEWS"
+distfiles="${GNOME_SITE}/gexiv2/${version%.*}/gexiv2-${version}.tar.xz"
+checksum=2a0c9cf48fbe8b3435008866ffd40b8eddb0667d2212b42396fdf688e93ce0be
 
 build_options="gir vala"
 build_options_default="gir vala"
@@ -23,7 +23,7 @@ libgexiv2-devel_package() {
 	short_desc+=" - development files"
 	pkg_install() {
 		vmove usr/include
-		vmove usr/lib/*.so
+		vmove "usr/lib/*.so"
 		vmove usr/lib/pkgconfig
 		if [ "$build_option_vala" ]; then
 			vmove usr/share/vala

From fd0e905656e5bb90b5d58bc4c5180d424b55ee2e Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 15/22] libkexiv25: update to 23.08.2.

---
 srcpkgs/libkexiv25/template | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/srcpkgs/libkexiv25/template b/srcpkgs/libkexiv25/template
index b439a42ef2b97..4d7f9600572ea 100644
--- a/srcpkgs/libkexiv25/template
+++ b/srcpkgs/libkexiv25/template
@@ -1,6 +1,6 @@
 # Template file for 'libkexiv25'
 pkgname=libkexiv25
-version=23.04.0
+version=23.08.2
 revision=1
 build_style=cmake
 configure_args="-DBUILD_TESTING=OFF"
@@ -11,7 +11,7 @@ maintainer="Orphaned <orphan@voidlinux.org>"
 license="GPL-2.0-or-later"
 homepage="https://invent.kde.org/graphics/libkexiv2"
 distfiles="${KDE_SITE}/release-service/${version}/src/libkexiv2-${version}.tar.xz"
-checksum=18d3eed06df9d1e31d8434ed9887e305aba176d0856e19a8cd3bdb555b80d391
+checksum=d06e36a408bf2e846a18056a1f15e61d981fa2a1fceb81f7c15136604319d033
 
 libkexiv25-devel_package() {
 	short_desc+=" - development files"

From 5b521eed1195e26ac1f2825a421c9ed0ac1493b3 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 16/22] nomacs: update to 3.17.2287.

---
 srcpkgs/nomacs/template | 17 +++++++++++++----
 1 file changed, 13 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/nomacs/template b/srcpkgs/nomacs/template
index c52cd54e294db..956bd21ebb129 100644
--- a/srcpkgs/nomacs/template
+++ b/srcpkgs/nomacs/template
@@ -1,7 +1,8 @@
 # Template file for 'nomacs'
 pkgname=nomacs
-version=3.16.224
-revision=5
+version=3.17.2287
+revision=1
+_plugins_ver=3.17.2285
 build_wrksrc=ImageLounge
 build_style=cmake
 configure_args="-DCMAKE_BUILD_TYPE=None -DENABLE_TRANSLATIONS=1
@@ -13,5 +14,13 @@ short_desc="Simple yet powerful Qt imageviewer"
 maintainer="Orphaned <orphan@voidlinux.org>"
 license="GPL-3.0-or-later"
 homepage="https://github.com/nomacs/nomacs"
-distfiles="https://github.com/nomacs/nomacs/archive/${version}.tar.gz"
-checksum=bbc7e9048026ef9e0d2b64902c88050f17a679ef3d3c009de2c3b7de5d1d217c
+distfiles="https://github.com/nomacs/nomacs/archive/${version}.tar.gz
+ https://github.com/novomesk/nomacs-plugins/archive/refs/tags/${_plugins_ver}.tar.gz>plugins.tar.gz"
+checksum="6905ea615358f84a0c83d5b1b7077871dea0526ec667500a1951448cb845a92c
+ 946b2d754be9ecca5cb155f7ecc5dcafb164f6c3dcc7bf5c3c0610d3b47774aa"
+skip_extraction="plugins.tar.gz"
+
+post_extract() {
+ cd ${build_wrksrc}
+ vsrcextract -C plugins "plugins.tar.gz"
+}

From 99075796b9f5817b6fe88fa95de3c6e8b503ae4c Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 17/22] pdf2djvu: revbump for exiv2-0.28.0.

---
 srcpkgs/pdf2djvu/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/pdf2djvu/template b/srcpkgs/pdf2djvu/template
index ef7433c0c98ae..5a6f3ddf4ed35 100644
--- a/srcpkgs/pdf2djvu/template
+++ b/srcpkgs/pdf2djvu/template
@@ -1,7 +1,7 @@
 # Template file for 'pdf2djvu'
 pkgname=pdf2djvu
 version=0.9.19
-revision=4
+revision=5
 build_style=gnu-configure
 hostmakedepends="pkg-config djvulibre gettext"
 makedepends="djvulibre-devel poppler-devel libgraphicsmagick-devel exiv2-devel libuuid-devel"

From 8359c0be8f4dc078f30bbb53c7ae9859f31d60c4 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 18/22] phototonic: revbump for exiv2-0.28.0.

---
 srcpkgs/phototonic/patches/exiv2-0.28.patch | 135 ++++++++++++++++++++
 srcpkgs/phototonic/template                 |   2 +-
 2 files changed, 136 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/phototonic/patches/exiv2-0.28.patch

diff --git a/srcpkgs/phototonic/patches/exiv2-0.28.patch b/srcpkgs/phototonic/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..1c75b628dab33
--- /dev/null
+++ b/srcpkgs/phototonic/patches/exiv2-0.28.patch
@@ -0,0 +1,135 @@
+From 923a3fc14de0b779a45696c5f0aef34c74d84f13 Mon Sep 17 00:00:00 2001
+From: Andreas Sturmlechner <asturm@gentoo.org>
+Date: Sun, 28 May 2023 18:54:10 +0200
+Subject: [PATCH] Fix build with exiv2-0.28
+
+Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>
+---
+ ImageViewer.cpp   | 9 +++++++++
+ MetadataCache.cpp | 8 ++++++++
+ Phototonic.cpp    | 4 ++++
+ Tags.cpp          | 8 ++++++++
+ ThumbsViewer.cpp  | 4 ++++
+ 5 files changed, 33 insertions(+)
+
+diff --git a/ImageViewer.cpp b/ImageViewer.cpp
+index 357d223..df3ac43 100644
+--- a/ImageViewer.cpp
++++ b/ImageViewer.cpp
+@@ -945,7 +945,11 @@ void ImageViewer::keyMoveEvent(int direction) {
+ }
+ 
+ void ImageViewer::saveImage() {
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr image;
++#else
+     Exiv2::Image::AutoPtr image;
++#endif
+     bool exifError = false;
+ 
+     if (newImage) {
+@@ -985,8 +989,13 @@ void ImageViewer::saveImage() {
+ }
+ 
+ void ImageViewer::saveImageAs() {
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++    Exiv2::Image::UniquePtr newExifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
+     Exiv2::Image::AutoPtr newExifImage;
++#endif
+     bool exifError = false;
+ 
+     setCursorHiding(false);
+diff --git a/MetadataCache.cpp b/MetadataCache.cpp
+index 524ae74..5ddd4c8 100644
+--- a/MetadataCache.cpp
++++ b/MetadataCache.cpp
+@@ -64,7 +64,11 @@ void MetadataCache::clear() {
+ }
+ 
+ bool MetadataCache::loadImageMetadata(const QString &imageFullPath) {
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
++#endif
+     QSet<QString> tags;
+     long orientation = 0;
+ 
+@@ -78,7 +82,11 @@ bool MetadataCache::loadImageMetadata(const QString &imageFullPath) {
+     try {
+         Exiv2::ExifData &exifData = exifImage->exifData();
+         if (!exifData.empty()) {
++#if EXIV2_TEST_VERSION(0,28,0)
++            orientation = exifData["Exif.Image.Orientation"].value().toUint32();
++#else
+             orientation = exifData["Exif.Image.Orientation"].value().toLong();
++#endif
+         }
+     } catch (Exiv2::Error &error) {
+         qWarning() << "Failed to read Exif metadata";
+diff --git a/Phototonic.cpp b/Phototonic.cpp
+index 6cc95b3..bd5497d 100644
+--- a/Phototonic.cpp
++++ b/Phototonic.cpp
+@@ -3151,7 +3151,11 @@ void Phototonic::removeMetadata() {
+ 
+     if (ret == MessageBox::Yes) {
+         for (int file = 0; file < fileList.size(); ++file) {
++#if EXIV2_TEST_VERSION(0,28,0)
++            Exiv2::Image::UniquePtr image;
++#else
+             Exiv2::Image::AutoPtr image;
++#endif
+             try {
+                 image = Exiv2::ImageFactory::open(fileList[file].toStdString());
+                 image->clearMetadata();
+diff --git a/Tags.cpp b/Tags.cpp
+index 84eea16..a62da9d 100644
+--- a/Tags.cpp
++++ b/Tags.cpp
+@@ -136,7 +136,11 @@ void ImageTags::addTag(QString tagName, bool tagChecked) {
+ 
+ bool ImageTags::writeTagsToImage(QString &imageFileName, QSet<QString> &newTags) {
+     QSet<QString> imageTags;
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
++#endif
+ 
+     try {
+         exifImage = Exiv2::ImageFactory::open(imageFileName.toStdString());
+@@ -160,7 +164,11 @@ bool ImageTags::writeTagsToImage(QString &imageFileName, QSet<QString> &newTags)
+         QSetIterator<QString> newTagsIt(newTags);
+         while (newTagsIt.hasNext()) {
+             QString tag = newTagsIt.next();
++#if EXIV2_TEST_VERSION(0,28,0)
++            Exiv2::Value::UniquePtr value = Exiv2::Value::create(Exiv2::string);
++#else
+             Exiv2::Value::AutoPtr value = Exiv2::Value::create(Exiv2::string);
++#endif
+             value->read(tag.toStdString());
+             Exiv2::IptcKey key("Iptc.Application2.Keywords");
+             newIptcData.add(key, value.get());
+diff --git a/ThumbsViewer.cpp b/ThumbsViewer.cpp
+index 77a6189..4a11475 100644
+--- a/ThumbsViewer.cpp
++++ b/ThumbsViewer.cpp
+@@ -210,7 +210,11 @@ void ThumbsViewer::updateImageInfoViewer(QString imageFullPath) {
+         infoView->addEntry(key, val);
+     }
+ 
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
++#endif
+     try {
+         exifImage = Exiv2::ImageFactory::open(imageFullPath.toStdString());
+         exifImage->readMetadata();
+-- 
+2.40.1
+
diff --git a/srcpkgs/phototonic/template b/srcpkgs/phototonic/template
index 77ae8bf6a4406..4af006cb7da41 100644
--- a/srcpkgs/phototonic/template
+++ b/srcpkgs/phototonic/template
@@ -1,7 +1,7 @@
 # Template file for 'phototonic'
 pkgname=phototonic
 version=2.1
-revision=3
+revision=4
 build_style=qmake
 hostmakedepends="pkg-config qt5-qmake qt5-host-tools"
 makedepends="qt5-svg-devel exiv2-devel"

From 9677bc84cd49885c0422c230011c5447ccc542ea Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 19/22] qimgv: revbump for exiv2-0.28.0.

---
 srcpkgs/qimgv/patches/exiv2-0.28.patch | 16 ++++++++++++++++
 srcpkgs/qimgv/template                 |  2 +-
 2 files changed, 17 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/qimgv/patches/exiv2-0.28.patch

diff --git a/srcpkgs/qimgv/patches/exiv2-0.28.patch b/srcpkgs/qimgv/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..11f37b5ae2be3
--- /dev/null
+++ b/srcpkgs/qimgv/patches/exiv2-0.28.patch
@@ -0,0 +1,16 @@
+Patch-Source: https://git.alpinelinux.org/aports/tree/community/qimgv/exiv2-0.28.patch
+diff --git a/qimgv/sourcecontainers/documentinfo.cpp b/qimgv/sourcecontainers/documentinfo.cpp
+index 98a68f7..c062474 100644
+--- a/qimgv/sourcecontainers/documentinfo.cpp
++++ b/qimgv/sourcecontainers/documentinfo.cpp
+@@ -271,10 +271,6 @@ void DocumentInfo::loadExifTags() {
+         //std::cout << "Caught Exiv2 exception '" << e.what() << "'\n";
+         return;
+     }
+-    catch (Exiv2::BasicError<CharType> e) {
+-        //std::cout << "Caught BasicError Exiv2 exception '" << e.what() << "'\n";
+-        return;
+-    }
+ #endif
+ }
+ 
diff --git a/srcpkgs/qimgv/template b/srcpkgs/qimgv/template
index 7eb30db33992c..dd341dfe1bfce 100644
--- a/srcpkgs/qimgv/template
+++ b/srcpkgs/qimgv/template
@@ -1,7 +1,7 @@
 # Template file for 'qimgv'
 pkgname=qimgv
 version=1.0.2
-revision=2
+revision=3
 build_style=cmake
 configure_args="$(vopt_if video -DVIDEO_SUPPORT=ON -DVIDEO_SUPPORT=OFF)
  $(vopt_if scale -DOPENCV_SUPPORT=ON -DOPENCV_SUPPORT=OFF)

From a0245ef55794b36923a6f915bb108463b65a0d3e Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 20/22] SIR: revbump for exiv2-0.28.0.

---
 srcpkgs/SIR/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/SIR/template b/srcpkgs/SIR/template
index 113077acad354..c6da4c26b6c71 100644
--- a/srcpkgs/SIR/template
+++ b/srcpkgs/SIR/template
@@ -1,7 +1,7 @@
 # Template file for 'SIR'
 pkgname=SIR
 version=3.2.2
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="pkg-config"
 makedepends="exiv2-devel qt5-svg-devel qt5-tools-devel"

From a0026ff29d58fdd9039a2622b9e3091518531c0f Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 21/22] viewnior: revbump for exiv2-0.28.0.

---
 srcpkgs/viewnior/patches/exiv2-0.28.patch | 147 ++++++++++++++++++++++
 srcpkgs/viewnior/template                 |   2 +-
 2 files changed, 148 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/viewnior/patches/exiv2-0.28.patch

diff --git a/srcpkgs/viewnior/patches/exiv2-0.28.patch b/srcpkgs/viewnior/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..71459dee15768
--- /dev/null
+++ b/srcpkgs/viewnior/patches/exiv2-0.28.patch
@@ -0,0 +1,147 @@
+Patch-Source: https://gitlab.archlinux.org/archlinux/packaging/packages/viewnior/-/blob/f206ce6c22a3ec5f1f9ea1bde4077584f80458dd/exiv2-0.28.patch
+--
+From b6bb81a1b46e911d15bbf9a730972523de177705 Mon Sep 17 00:00:00 2001
+From: tastytea <tastytea@tastytea.de>
+Date: Tue, 16 May 2023 10:54:40 +0200
+Subject: [PATCH 1/2] change exiv2 AutoPtr to unique_ptr
+
+exiv2-0.28.0 removed Exiv2::Image::AutoPtr and added
+Exiv2::Image::UniquePtr instead. since it's a typedef for
+std::unique_ptr<Image>, i'm using that directly instead of adding a
+condition on the exiv2 version.
+---
+ src/uni-exiv2.cpp | 21 +++++++++++----------
+ 1 file changed, 11 insertions(+), 10 deletions(-)
+
+diff --git a/src/uni-exiv2.cpp b/src/uni-exiv2.cpp
+index 0d14b9f..77064c2 100644
+--- a/src/uni-exiv2.cpp
++++ b/src/uni-exiv2.cpp
+@@ -22,12 +22,13 @@
+ 
+ #include <exiv2/exiv2.hpp>
+ #include <iostream>
++#include <memory>
+ 
+ #include "uni-exiv2.hpp"
+ 
+ #define ARRAY_SIZE(array) (sizeof array/sizeof(array[0]))
+ 
+-static Exiv2::Image::AutoPtr cached_image;
++static std::unique_ptr<Exiv2::Image> cached_image;
+ 
+ extern "C"
+ void
+@@ -35,8 +36,8 @@ uni_read_exiv2_map(const char *uri, void (*callback)(const char*, const char*, v
+ {
+     Exiv2::LogMsg::setLevel(Exiv2::LogMsg::mute);
+     try {
+-        Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open(uri);
+-        if ( image.get() == 0 ) {
++        std::unique_ptr<Exiv2::Image> image = Exiv2::ImageFactory::open(uri);
++        if (image == nullptr) {
+             return;
+         }
+ 
+@@ -91,14 +92,14 @@ uni_read_exiv2_to_cache(const char *uri)
+ {
+     Exiv2::LogMsg::setLevel(Exiv2::LogMsg::mute);
+ 
+-    if ( cached_image.get() != NULL ) {
++    if (cached_image != nullptr) {
+         cached_image->clearMetadata();
+-        cached_image.reset(NULL);
++        cached_image.reset(nullptr);
+     }
+ 
+     try {
+         cached_image = Exiv2::ImageFactory::open(uri);
+-        if ( cached_image.get() == 0 ) {
++        if (cached_image == nullptr) {
+             return 1;
+         }
+ 
+@@ -116,13 +117,13 @@ uni_write_exiv2_from_cache(const char *uri)
+ {
+     Exiv2::LogMsg::setLevel(Exiv2::LogMsg::mute);
+ 
+-    if ( cached_image.get() == NULL ) {
++    if (cached_image == nullptr) {
+         return 1;
+     }
+ 
+     try {
+-        Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open(uri);
+-        if ( image.get() == 0 ) {
++        std::unique_ptr<Exiv2::Image> image = Exiv2::ImageFactory::open(uri);
++        if (image == nullptr) {
+             return 2;
+         }
+ 
+@@ -130,7 +131,7 @@ uni_write_exiv2_from_cache(const char *uri)
+         image->writeMetadata();
+ 
+         cached_image->clearMetadata();
+-        cached_image.reset(NULL);
++        cached_image.reset(nullptr);
+ 
+         return 0;
+     } catch (Exiv2::AnyError& e) {
+
+From 47d0b98cb46526aa8aa035bebcabc14a11fa57ee Mon Sep 17 00:00:00 2001
+From: tastytea <tastytea@tastytea.de>
+Date: Tue, 16 May 2023 11:17:00 +0200
+Subject: [PATCH 2/2] add support for exiv-0.28.0 errors
+
+exiv2-0.28.0 changed Exiv2::AnyError to Exiv2::Error.
+---
+ src/uni-exiv2.cpp | 15 ++++++++++++---
+ 1 file changed, 12 insertions(+), 3 deletions(-)
+
+diff --git a/src/uni-exiv2.cpp b/src/uni-exiv2.cpp
+index 77064c2..567a50f 100644
+--- a/src/uni-exiv2.cpp
++++ b/src/uni-exiv2.cpp
+@@ -28,6 +28,15 @@
+ 
+ #define ARRAY_SIZE(array) (sizeof array/sizeof(array[0]))
+ 
++#define EXIV_ERROR Exiv2::AnyError
++#ifdef EXIV2_VERSION
++    #ifdef EXIV2_TEST_VERSION
++        #if EXIV2_TEST_VERSION(0,28,0)
++            #define EXIV_ERROR Exiv2::Error
++        #endif
++    #endif
++#endif
++
+ static std::unique_ptr<Exiv2::Image> cached_image;
+ 
+ extern "C"
+@@ -81,7 +90,7 @@ uni_read_exiv2_map(const char *uri, void (*callback)(const char*, const char*, v
+                 }
+             }
+         }
+-    } catch (Exiv2::AnyError& e) {
++    } catch (EXIV_ERROR& e) {
+         std::cerr << "Exiv2: '" << e << "'\n";
+     }
+ }
+@@ -104,7 +113,7 @@ uni_read_exiv2_to_cache(const char *uri)
+         }
+ 
+         cached_image->readMetadata();
+-    } catch (Exiv2::AnyError& e) {
++    } catch (EXIV_ERROR& e) {
+         std::cerr << "Exiv2: '" << e << "'\n";
+     }
+ 
+@@ -134,7 +143,7 @@ uni_write_exiv2_from_cache(const char *uri)
+         cached_image.reset(nullptr);
+ 
+         return 0;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (EXIV_ERROR& e) {
+         std::cerr << "Exiv2: '" << e << "'\n";
+     }
+ 
diff --git a/srcpkgs/viewnior/template b/srcpkgs/viewnior/template
index ea1e528a8651f..4c73226662ca0 100644
--- a/srcpkgs/viewnior/template
+++ b/srcpkgs/viewnior/template
@@ -1,7 +1,7 @@
 # Template file for 'viewnior'
 pkgname=viewnior
 version=1.8
-revision=1
+revision=2
 build_style=meson
 hostmakedepends="pkg-config intltool glib-devel gettext-devel"
 makedepends="gtk+-devel exiv2-devel"

From 089262cec61303214bd36807ecf8ed2dbd6519c9 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Mon, 23 Oct 2023 19:06:34 +0200
Subject: [PATCH 22/22] New package: nufraw-0.43.3

Co-authored-by: Mohammed Anas <triallax@tutanota.com>
---
 srcpkgs/nufraw-gimp                           |  1 +
 .../patches/0001-nufraw-glib-2.70.patch       | 20 +++++++
 srcpkgs/nufraw/patches/exiv-0.28.x.diff       | 59 +++++++++++++++++++
 srcpkgs/nufraw/template                       | 47 +++++++++++++++
 srcpkgs/removed-packages/template             |  8 ++-
 srcpkgs/ufraw                                 |  1 +
 .../ufraw/patches/001-no-gimp-remote.patch    | 12 ----
 srcpkgs/ufraw/patches/002-fix_abs_int.patch   | 11 ----
 .../ufraw/patches/03_fix-unsigned-char.patch  | 14 -----
 srcpkgs/ufraw/patches/exiv-0.27.patch         | 25 --------
 srcpkgs/ufraw/patches/glib-2.68.patch         | 30 ----------
 srcpkgs/ufraw/patches/iostream.patch          | 13 ----
 srcpkgs/ufraw/template                        | 38 ------------
 13 files changed, 133 insertions(+), 146 deletions(-)
 create mode 120000 srcpkgs/nufraw-gimp
 create mode 100644 srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch
 create mode 100644 srcpkgs/nufraw/patches/exiv-0.28.x.diff
 create mode 100644 srcpkgs/nufraw/template
 create mode 120000 srcpkgs/ufraw
 delete mode 100644 srcpkgs/ufraw/patches/001-no-gimp-remote.patch
 delete mode 100644 srcpkgs/ufraw/patches/002-fix_abs_int.patch
 delete mode 100644 srcpkgs/ufraw/patches/03_fix-unsigned-char.patch
 delete mode 100644 srcpkgs/ufraw/patches/exiv-0.27.patch
 delete mode 100644 srcpkgs/ufraw/patches/glib-2.68.patch
 delete mode 100644 srcpkgs/ufraw/patches/iostream.patch
 delete mode 100644 srcpkgs/ufraw/template

diff --git a/srcpkgs/nufraw-gimp b/srcpkgs/nufraw-gimp
new file mode 120000
index 0000000000000..0bd1459b2a16f
--- /dev/null
+++ b/srcpkgs/nufraw-gimp
@@ -0,0 +1 @@
+nufraw
\ No newline at end of file
diff --git a/srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch b/srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch
new file mode 100644
index 0000000000000..41f10bfbafa1f
--- /dev/null
+++ b/srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch
@@ -0,0 +1,20 @@
+diff -ru nufraw/uf_glib.h nufraw/uf_glib.h
+--- nufraw/uf_glib.h	2022-02-23 09:03:44.700472919 +0100
++++ nufraw/uf_glib.h	2022-02-23 09:04:50.260308805 +0100
+@@ -13,13 +13,13 @@
+ #ifndef _UF_GLIB_H
+ #define _UF_GLIB_H
+ 
++#include <glib.h>
++#include <glib/gstdio.h>
++
+ #ifdef __cplusplus
+ extern "C" {
+ #endif
+ 
+-#include <glib.h>
+-#include <glib/gstdio.h>
+-
+ // g_win32_locale_filename_from_utf8 is needed only on win32
+ #ifdef _WIN32
+ #define uf_win32_locale_filename_from_utf8(__some_string__) \
diff --git a/srcpkgs/nufraw/patches/exiv-0.28.x.diff b/srcpkgs/nufraw/patches/exiv-0.28.x.diff
new file mode 100644
index 0000000000000..6c23359bf706c
--- /dev/null
+++ b/srcpkgs/nufraw/patches/exiv-0.28.x.diff
@@ -0,0 +1,59 @@
+Patch taken from AUR package: https://aur.archlinux.org/cgit/aur.git/tree/exiv2-error.patch?h=nufraw&id=29e467f2c297fcd0f36548642d6d2cab6428d08f
+diff --git a/nufraw_exiv2.cc b/nufraw_exiv2.cc
+index 2de4cc3..45aea87 100644
+--- a/nufraw_exiv2.cc
++++ b/nufraw_exiv2.cc
+@@ -54,7 +54,7 @@ extern "C" int nufraw_exif_read_input(nufraw_data *uf)
+         uf->inputExifBuf = NULL;
+         uf->inputExifBufLen = 0;
+ 
+-        Exiv2::Image::AutoPtr image;
++        Exiv2::Image::UniquePtr image;
+         if (uf->unzippedBuf != NULL) {
+             image = Exiv2::ImageFactory::open(
+                         (const Exiv2::byte*)uf->unzippedBuf, uf->unzippedBufLen);
+@@ -135,7 +135,7 @@ extern "C" int nufraw_exif_read_input(nufraw_data *uf)
+         nufraw_message(NUFRAW_SET_LOG, "%s\n", stderror.str().c_str());
+ 
+         return NUFRAW_SUCCESS;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (Exiv2::Error& e) {
+         std::cerr.rdbuf(savecerr);
+         std::string s(e.what());
+         nufraw_message(NUFRAW_SET_WARNING, "%s\n", s.c_str());
+@@ -156,7 +156,7 @@ static Exiv2::ExifData nufraw_prepare_exifdata(nufraw_data *uf)
+         if ((pos = exifData.findKey(Exiv2::ExifKey("Exif.Image.Orientation")))
+                 != exifData.end()) {
+             nufraw_message(NUFRAW_SET_LOG, "Resetting %s from '%d' to '1'\n",
+-                          pos->key().c_str(), pos->value().toLong());
++                          pos->key().c_str(), pos->value().toInt64());
+             pos->setValue("1"); /* 1 = Normal orientation */
+         }
+     }
+@@ -327,7 +327,7 @@ extern "C" int nufraw_exif_prepare_output(nufraw_data *uf)
+         nufraw_message(NUFRAW_SET_LOG, "%s\n", stderror.str().c_str());
+ 
+         return NUFRAW_SUCCESS;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (Exiv2::Error& e) {
+         std::cerr.rdbuf(savecerr);
+         std::string s(e.what());
+         nufraw_message(NUFRAW_SET_WARNING, "%s\n", s.c_str());
+@@ -347,7 +347,7 @@ extern "C" int nufraw_exif_write(nufraw_data *uf)
+ 
+         char *filename =
+             uf_win32_locale_filename_from_utf8(uf->conf->outputFilename);
+-        Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open(filename);
++        Exiv2::Image::UniquePtr image = Exiv2::ImageFactory::open(filename);
+         uf_win32_locale_filename_free(filename);
+         assert(image.get() != 0);
+ 
+@@ -367,7 +367,7 @@ extern "C" int nufraw_exif_write(nufraw_data *uf)
+         nufraw_message(NUFRAW_SET_LOG, "%s\n", stderror.str().c_str());
+ 
+         return NUFRAW_SUCCESS;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (Exiv2::Error& e) {
+         std::cerr.rdbuf(savecerr);
+         std::string s(e.what());
+         nufraw_message(NUFRAW_SET_WARNING, "%s\n", s.c_str());
diff --git a/srcpkgs/nufraw/template b/srcpkgs/nufraw/template
new file mode 100644
index 0000000000000..3e5d7d190b335
--- /dev/null
+++ b/srcpkgs/nufraw/template
@@ -0,0 +1,47 @@
+# Template file for 'nufraw'
+pkgname=nufraw
+version=0.43.3
+revision=1
+_ver="${version%.*}-${version##*.}"
+build_style=gnu-configure
+configure_args="--enable-contrast --enable-mime --enable-openmp --with-gimp
+ --enable-extras"
+hostmakedepends="pkg-config automake libtool"
+makedepends="exiv2-devel gimp-devel glib-devel gtkimageview-devel lcms2-devel lensfun-devel
+ jasper-devel"
+depends="desktop-file-utils"
+short_desc="Utility to read and manipulate raw images from digital cameras"
+maintainer="John <me@johnnynator.dev>"
+license="GPL-2.0-or-later"
+homepage="https://sourceforge.net/projects/nufraw/"
+distfiles="${SOURCEFORGE_SITE}/nufraw/nufraw-${_ver}.tar.gz"
+checksum=2c7dcc1590993ec267b3112562b2433010d6f94f6acc6506c76aa29cf8c6c32c
+
+pre_configure() {
+	autoreconf -fi
+}
+
+pre_build() {
+	mv nufraw.desktop{.desktop,}
+	chmod +x generate_schemas.sh
+}
+
+nufraw-gimp_package() {
+	depends="${sourcepkg}>=${version}_${revision}"
+	short_desc+=" - gimp plugin"
+	pkg_install() {
+		vmove usr/lib/gimp
+	}
+}
+
+ufraw_package() {
+	depends="${sourcepkg}>=${version}_${revision}"
+	build_style=meta
+	short_desc+=" (transitional dummy package)"
+}
+
+ufraw-gimp_package() {
+	depends="nufraw-gimp>=${version}_${revision}"
+	build_style=meta
+	short_desc+=" - gimp plugin (transitional dummy package)"
+}
diff --git a/srcpkgs/removed-packages/template b/srcpkgs/removed-packages/template
index abedf26f739b6..f3d81a8afe04c 100644
--- a/srcpkgs/removed-packages/template
+++ b/srcpkgs/removed-packages/template
@@ -1,6 +1,6 @@
 # Template file for 'removed-packages'
 pkgname=removed-packages
-version=0.1.20231019
+version=0.1.20231101
 revision=1
 build_style=meta
 short_desc="Uninstalls packages removed from repository"
@@ -590,8 +590,8 @@ replaces="
  python3-Flask-Assets<=0.12_9
  python3-Flask-Mail<=0.9.1_5
  python3-Flask-OAuthlib<=0.9.6_4
- python3-Flask-Script<=2.0.6_7
  python3-Flask-SQLAlchemy<=2.5.1_4
+ python3-Flask-Script<=2.0.6_7
  python3-Flask-User<=1.0.2.2_6
  python3-SPARQLWrapper<=1.8.4_4
  python3-aiohttp-cors2<=0.7.0_3
@@ -642,8 +642,8 @@ replaces="
  raul-devel<=0.8.0_6
  raul<=0.8.0_6
  redkite<=1.3.1_1
- rem<=2.10.0_1
  rem-devel<=2.10.0_1
+ rem<=2.10.0_1
  reminiscence<=0.4.6_1
  rkt-stage1-coreos<=1.30.0_3
  rkt-stage1-fly<=1.30.0_3
@@ -675,6 +675,8 @@ replaces="
  traverso<=0.49.6_2
  ttyload-git<=20141117_4
  tuxc<=1.1_3
+ ufraw-gimp<=0.22_5
+ ufraw<=0.22_5
  unicorn-python<=1.0.2_2
  upwork<=5.6.10.0_1
  urlmatch-git<=20141116_2
diff --git a/srcpkgs/ufraw b/srcpkgs/ufraw
new file mode 120000
index 0000000000000..0bd1459b2a16f
--- /dev/null
+++ b/srcpkgs/ufraw
@@ -0,0 +1 @@
+nufraw
\ No newline at end of file
diff --git a/srcpkgs/ufraw/patches/001-no-gimp-remote.patch b/srcpkgs/ufraw/patches/001-no-gimp-remote.patch
deleted file mode 100644
index ca4f4beb6240f..0000000000000
--- a/srcpkgs/ufraw/patches/001-no-gimp-remote.patch
+++ /dev/null
@@ -1,12 +0,0 @@
-Don't use gimp-remote since gimp 2.4 already includes gimp-remote functionality
---- a/ufraw_conf.c
-+++ b/ufraw_conf.c
-@@ -137,7 +137,7 @@
- #elif HAVE_GIMP_2_4
-     "gimp", /* remoteGimpCommand */
- #else
--    "gimp-remote", /* remoteGimpCommand */
-+    "gimp", /* remoteGimpCommand */
- #endif
- 
-     /* EXIF data */
diff --git a/srcpkgs/ufraw/patches/002-fix_abs_int.patch b/srcpkgs/ufraw/patches/002-fix_abs_int.patch
deleted file mode 100644
index 6fc552769c9f8..0000000000000
--- a/srcpkgs/ufraw/patches/002-fix_abs_int.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- a/dcraw.cc	2015-06-16 05:58:38.000000000 +0200
-+++ b/dcraw.cc	2018-02-04 14:46:54.489951076 +0100
-@@ -9242,7 +9242,7 @@
-     if (make[0] == 'O') {
-       i = find_green (12, 32, 1188864, 3576832);
-       c = find_green (12, 32, 2383920, 2387016);
--      if (abs(i) < abs(c)) {
-+      if (abs((int)i) < abs((int)c)) {
- 	SWAP(i,c);
- 	load_flags = 24;
-       }
diff --git a/srcpkgs/ufraw/patches/03_fix-unsigned-char.patch b/srcpkgs/ufraw/patches/03_fix-unsigned-char.patch
deleted file mode 100644
index 8690f87ca7d59..0000000000000
--- a/srcpkgs/ufraw/patches/03_fix-unsigned-char.patch
+++ /dev/null
@@ -1,14 +0,0 @@
-Source: written by John Paul Adrian Glaubitz for Debian
-Upstream: https://sourceforge.net/p/ufraw/bugs/417
-Reason: fixes a compilation failure on arm architectures
---- a/dcraw.cc
-+++ b/dcraw.cc
-@@ -2285,7 +2285,7 @@ void CLASS quicktake_100_load_raw()
- 
- void CLASS kodak_radc_load_raw()
- {
--  static const char src[] = {
-+  static const signed char src[] = {
-     1,1, 2,3, 3,4, 4,2, 5,7, 6,5, 7,6, 7,8,
-     1,0, 2,1, 3,3, 4,4, 5,2, 6,7, 7,6, 8,5, 8,8,
-     2,1, 2,3, 3,0, 3,2, 3,4, 4,6, 5,5, 6,7, 6,8,
diff --git a/srcpkgs/ufraw/patches/exiv-0.27.patch b/srcpkgs/ufraw/patches/exiv-0.27.patch
deleted file mode 100644
index b5b4140fff8ed..0000000000000
--- a/srcpkgs/ufraw/patches/exiv-0.27.patch
+++ /dev/null
@@ -1,25 +0,0 @@
---- a/ufraw_exiv2.cc	2015-06-16 05:58:38.000000000 +0200
-+++ b/ufraw_exiv2.cc	2018-12-29 22:51:23.291894430 +0100
-@@ -15,9 +15,7 @@
- #include "ufraw.h"
- 
- #ifdef HAVE_EXIV2
--#include <exiv2/image.hpp>
--#include <exiv2/easyaccess.hpp>
--#include <exiv2/exif.hpp>
-+#include <exiv2/exiv2.hpp>
- #include <sstream>
- #include <cassert>
- 
-@@ -67,7 +65,11 @@
-         if (exifData.empty()) {
-             std::string error(uf->filename);
-             error += ": No Exif data found in the file";
-+#if EXIV2_TEST_VERSION(0,27,0)
-+            throw Exiv2::Error(Exiv2::kerErrorMessage, error);
-+#else
-             throw Exiv2::Error(1, error);
-+#endif
-         }
- 
-         /* List of tag names taken from exiv2's printSummary() in actions.cpp */
diff --git a/srcpkgs/ufraw/patches/glib-2.68.patch b/srcpkgs/ufraw/patches/glib-2.68.patch
deleted file mode 100644
index 5b61468f118aa..0000000000000
--- a/srcpkgs/ufraw/patches/glib-2.68.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-From c56f8be3caf1cf3d9a5c80597bdbaf1325faacc0 Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?S=C3=A9rgio=20M=2E=20Basto?= <sergio@serjux.com>
-Date: Tue, 13 Apr 2021 23:45:39 +0100
-Subject: [PATCH] Fix build against glib-2.68 fixes #10
-
----
- uf_glib.h | 6 +++---
- 1 file changed, 3 insertions(+), 3 deletions(-)
-
-diff --git a/uf_glib.h b/uf_glib.h
-index 21c10b19..56cd6971 100644
---- a/uf_glib.h
-+++ b/uf_glib.h
-@@ -13,13 +13,13 @@
- #ifndef _UF_GLIB_H
- #define _UF_GLIB_H
- 
-+#include <glib.h>
-+#include <glib/gstdio.h>
-+
- #ifdef __cplusplus
- extern "C" {
- #endif
- 
--#include <glib.h>
--#include <glib/gstdio.h>
--
- // g_win32_locale_filename_from_utf8 is needed only on win32
- #ifdef _WIN32
- #define uf_win32_locale_filename_from_utf8(__some_string__) \
diff --git a/srcpkgs/ufraw/patches/iostream.patch b/srcpkgs/ufraw/patches/iostream.patch
deleted file mode 100644
index 6d15869f63db8..0000000000000
--- a/srcpkgs/ufraw/patches/iostream.patch
+++ /dev/null
@@ -1,13 +0,0 @@
-ufraw_exiv2.cc:343:10: note: 'std::cerr' is defined in header '<iostream>'
-ufraw_exiv2.cc:365:14: error: 'cerr' is not a member of 'std'
-
---- a/ufraw_exiv2.cc
-+++ b/ufraw_exiv2.cc
-@@ -17,6 +17,7 @@
- #ifdef HAVE_EXIV2
- #include <exiv2/exiv2.hpp>
- #include <sstream>
-+#include <iostream>
- #include <cassert>
- 
- /*
diff --git a/srcpkgs/ufraw/template b/srcpkgs/ufraw/template
deleted file mode 100644
index ceddcacacefb2..0000000000000
--- a/srcpkgs/ufraw/template
+++ /dev/null
@@ -1,38 +0,0 @@
-# Template file for 'ufraw'
-pkgname=ufraw
-version=0.22
-revision=5
-build_style=gnu-configure
-configure_args="--enable-contrast --enable-mime --enable-openmp --with-gimp
- $(vopt_enable extras)"
-hostmakedepends="pkg-config dcraw gettext"
-makedepends="exiv2-devel gimp-devel glib-devel gtkimageview-devel lcms2-devel lensfun-devel
- jasper-devel"
-depends="desktop-file-utils"
-short_desc="Utility to read and manipulate raw images from digital cameras"
-maintainer="John <me@johnnynator.dev>"
-license="GPL-2.0-or-later"
-homepage="http://ufraw.sourceforge.net/"
-distfiles="${SOURCEFORGE_SITE}/ufraw/ufraw/ufraw-${version}/ufraw-${version}.tar.gz"
-checksum=f7abd28ce587db2a74b4c54149bd8a2523a7ddc09bedf4f923246ff0ae09a25e
-
-build_options="extras"
-
-post_patch() {
-	vsed -e 's/default(none)//g' \
-		-i dcraw_indi.c \
-		-i dcraw_api.cc \
-		-i ufraw_ufraw.c \
-		-i ufraw_developer.c
-	vsed -i -e '/DATADIRNAME=/s/=.*/=share/' configure
-	vsed -i -e "s,^localedir =.*,localedir = /usr/share/locale," \
-		po/Makefile.in.in
-}
-
-ufraw-gimp_package() {
-	depends="${sourcepkg}>=${version}_${revision}"
-	short_desc+=" - gimp plugin"
-	pkg_install() {
-		vmove usr/lib/gimp
-	}
-}

^ permalink raw reply	[flat|nested] 27+ messages in thread

* Re: [PR PATCH] [Updated] exiv2: update to 0.28.0.
  2023-10-23  0:10 [PR PATCH] exiv2: update to 0.28.0 mhmdanas
  2023-10-23  0:20 ` [PR PATCH] [Updated] " mhmdanas
  2023-11-01 17:23 ` mhmdanas
@ 2023-11-01 17:26 ` mhmdanas
  2023-11-01 18:11 ` mhmdanas
                   ` (22 subsequent siblings)
  25 siblings, 0 replies; 27+ messages in thread
From: mhmdanas @ 2023-11-01 17:26 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 1855 bytes --]

There is an updated pull request by mhmdanas against master on the void-packages repository

https://github.com/mhmdanas/void-packages exiv2-0.28.0
https://github.com/void-linux/void-packages/pull/46838

exiv2: update to 0.28.0.
<!-- Uncomment relevant sections and delete options which are not applicable -->

#### Testing the changes
- I tested the changes in this PR: **briefly**

TODO:
- [x] Fix `gwenview`'s failed checks (not really fixed but the exact same tests fail on master as well)

@Johnnynator ufraw has been [unmaintained since December 2016](https://sourceforge.net/p/ufraw/discussion/434060/thread/30b4249b/), and it doesn't build with this PR; here are the options:
- remove the package entirely
- replace it with the newer [nufraw](https://sourceforge.net/projects/nufraw/), which already has [an exiv 0.28.x patch floating around](https://aur.archlinux.org/cgit/aur.git/tree/exiv2-error.patch?h=nufraw)
- patch it to build with this PR

What do you think?

<!--
#### New package
- This new package conforms to the [package requirements](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#package-requirements): **YES**|**NO**
-->

<!-- Note: If the build is likely to take more than 2 hours, please add ci skip tag as described in
https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration
and test at least one native build and, if supported, at least one cross build.
Ignore this section if this PR is not skipping CI.
-->
<!--
#### Local build testing
- I built this PR locally for my native architecture, (ARCH-LIBC)
- I built this PR locally for these architectures (if supported. mark crossbuilds):
  - aarch64-musl
  - armv7l
  - armv6l-musl
-->


A patch file from https://github.com/void-linux/void-packages/pull/46838.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-exiv2-0.28.0-46838.patch --]
[-- Type: text/x-diff, Size: 61425 bytes --]

From c24ded872bb81ede65102d92b828d9575252b4f9 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Mon, 23 Oct 2023 01:20:09 +0100
Subject: [PATCH 01/22] inih: add `libINIReader.so.0` common/shlibs entry.

---
 common/shlibs | 1 +
 1 file changed, 1 insertion(+)

diff --git a/common/shlibs b/common/shlibs
index 9036a675c1ae5..8f03a38a16789 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -3905,6 +3905,7 @@ libnotcurses++.so.3 notcurses-3.0.5_1
 libnotcurses-ffi.so.3 notcurses-3.0.5_1
 libevemu.so.3 evemu-2.7.0_1
 libinih.so.0 inih-52_1
+libINIReader.so.0 inih-57_1
 libpcaudio.so.0 pcaudiolib-1.1_1
 libdcerpc-samr.so.0 samba-4.13.2_1
 libdcerpc-server-core.so.0 samba-4.13.2_1

From 3cb90b2a57497f5e65cbfa759bacceee267febf6 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:12 +0100
Subject: [PATCH 02/22] exiv2: update to 0.28.0.

---
 common/shlibs                        |  2 +-
 srcpkgs/exiv2/patches/fix-tests.diff | 31 ++++++++++++++++++++++++++++
 srcpkgs/exiv2/template               | 14 ++++++++-----
 3 files changed, 41 insertions(+), 6 deletions(-)
 create mode 100644 srcpkgs/exiv2/patches/fix-tests.diff

diff --git a/common/shlibs b/common/shlibs
index 8f03a38a16789..0b1d0c89d3e51 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -555,7 +555,7 @@ libgimpcolor-2.0.so.0 libgimp-2.10.0_1
 libgimpmodule-2.0.so.0 libgimp-2.10.0_1
 libgmic.so.3 gmic-3.1.6_1
 libcgmic.so.3 gmic-3.1.6_1
-libexiv2.so.27 exiv2-0.27_1
+libexiv2.so.28 exiv2-0.28.0_1
 libKF5Holidays.so.5 kholidays-5.47.0_1
 libPhabricatorHelpers.so.5 purpose-5.48.0_1
 libKF5PurposeWidgets.so.5 purpose-5.48.0_1
diff --git a/srcpkgs/exiv2/patches/fix-tests.diff b/srcpkgs/exiv2/patches/fix-tests.diff
new file mode 100644
index 0000000000000..3eb7adc1635f3
--- /dev/null
+++ b/srcpkgs/exiv2/patches/fix-tests.diff
@@ -0,0 +1,31 @@
+diff --git a/tests/tiff_test/test_tag_compare.py b/tests/tiff_test/test_tag_compare.py
+index a8538bd2..974d1a9a 100644
+--- a/tests/tiff_test/test_tag_compare.py
++++ b/tests/tiff_test/test_tag_compare.py
+@@ -28,8 +28,8 @@ class OutputTagExtract(metaclass=system_tests.CaseMeta):
+             tmp = line.split()
+ 
+             exif, image, tag = tmp[0].split('.')
+-            self.assertEquals(exif, "Exif")
+-            self.assertEquals(image, "Image")
++            self.assertEqual(exif, "Exif")
++            self.assertEqual(image, "Image")
+ 
+             data.append({
+                 "tag": tag,
+@@ -87,13 +87,13 @@ class OutputTagExtract(metaclass=system_tests.CaseMeta):
+         """
+         for pa_elem, pS_elem in zip(self.pa_data, self.pS_data):
+             for key in ["tag", "type", "len"]:
+-                self.assertEquals(pa_elem[key], pS_elem[key])
++                self.assertEqual(pa_elem[key], pS_elem[key])
+ 
+             if pa_elem["tag"] in [
+                     "ImageWidth", "ImageLength", "BitsPerSample",
+                     "DocumentName", "ImageDescription", "StripOffsets",
+                     "SamplesPerPixel", "StripByteCounts"]:
+-                self.assertEquals(pa_elem["val"], pS_elem["val"])
++                self.assertEqual(pa_elem["val"], pS_elem["val"])
+ 
+     def compare_stdout(self, i, command, got_stdout, expected_stdout):
+         super().compare_stdout(i, command, got_stdout, expected_stdout)
diff --git a/srcpkgs/exiv2/template b/srcpkgs/exiv2/template
index 49985fe82cc14..876b253541d00 100644
--- a/srcpkgs/exiv2/template
+++ b/srcpkgs/exiv2/template
@@ -1,17 +1,17 @@
 # Template file for 'exiv2'
 pkgname=exiv2
-version=0.27.6
+version=0.28.0
 revision=1
 build_style=cmake
 configure_args="-DEXIV2_BUILD_SAMPLES=OFF -DEXIV2_ENABLE_BMFF=ON"
-makedepends="zlib-devel expat-devel"
-checkdepends="gtest-devel"
+makedepends="zlib-devel brotli-devel expat-devel inih-devel"
+checkdepends="gtest-devel python3"
 short_desc="Image metadata manipulation"
 maintainer="Enno Boland <gottox@voidlinux.org>"
 license="GPL-2.0-or-later"
 homepage="https://www.exiv2.org"
 distfiles="https://github.com/Exiv2/exiv2/releases/download/v${version}/exiv2-${version}-Source.tar.gz"
-checksum=4c192483a1125dc59a3d70b30d30d32edace9e14adf52802d2f853abf72db8a6
+checksum=89af3b5ef7277753ef7a7b5374ae017c6b9e304db3b688f1948e73e103491f3d
 
 if [ -n "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DEXIV2_BUILD_UNIT_TESTS=ON"
@@ -21,6 +21,11 @@ if [ -n "$XBPS_CCACHE" ]; then
 	configure_args+=" -DBUILD_WITH_CCACHE=ON"
 fi
 
+pre_check() {
+	# https://github.com/Exiv2/exiv2/issues/2762
+	rm -f tests/bugfixes/github/test_issue_2427.py
+}
+
 exiv2-devel_package() {
 	depends="${makedepends} ${sourcepkg}-${version}_${revision}"
 	short_desc+=" - development files"
@@ -28,7 +33,6 @@ exiv2-devel_package() {
 		vmove usr/include
 		vmove usr/lib/cmake
 		vmove usr/lib/pkgconfig
-		vmove "usr/lib/*.a"
 		vmove "usr/lib/*.so"
 	}
 }

From c770db7b4c73e4a05854124fed22690af0553595 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:37 +0100
Subject: [PATCH 03/22] ART: revbump for exiv2-0.28.0.

---
 srcpkgs/ART/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/ART/template b/srcpkgs/ART/template
index b6c47fc6c4cdf..94c7aa0378061 100644
--- a/srcpkgs/ART/template
+++ b/srcpkgs/ART/template
@@ -1,7 +1,7 @@
 # Template file for 'ART'
 pkgname=ART
 version=1.20.2
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="pkg-config"
 makedepends="fftw-devel gtkmm-devel lensfun-devel

From 0d3804c726646adf7e379cbe692d26d242e6e580 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 04/22] darktable: revbump for exiv2-0.28.0.

---
 srcpkgs/darktable/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/darktable/template b/srcpkgs/darktable/template
index 60415a34dc018..3d35571239a93 100644
--- a/srcpkgs/darktable/template
+++ b/srcpkgs/darktable/template
@@ -1,7 +1,7 @@
 # Template file for 'darktable'
 pkgname=darktable
 version=4.4.2
-revision=2
+revision=3
 # upstream only supports these archs:
 archs="x86_64* aarch64* ppc64le*"
 build_style=cmake

From 7e8d45a2e180cd2036b1c81054e20689d00b5a06 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 05/22] digikam: revbump for exiv2-0.28.0.

---
 srcpkgs/digikam/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/digikam/template b/srcpkgs/digikam/template
index 206185f565488..4784bf7d62a8e 100644
--- a/srcpkgs/digikam/template
+++ b/srcpkgs/digikam/template
@@ -1,7 +1,7 @@
 # Template file for 'digikam'
 pkgname=digikam
 version=8.1.0
-revision=1
+revision=2
 build_style=cmake
 configure_args="-DBUILD_TESTING=OFF"
 hostmakedepends="extra-cmake-modules gettext pkg-config bison flex qt5-qmake

From 27a5d8f2a60ae766ad1be21809edb672abb319b8 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 06/22] geeqie: revbump for exiv2-0.28.0.

---
 srcpkgs/geeqie/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/geeqie/template b/srcpkgs/geeqie/template
index b5f958f854c1b..b494bc149e957 100644
--- a/srcpkgs/geeqie/template
+++ b/srcpkgs/geeqie/template
@@ -1,7 +1,7 @@
 # Template file for 'geeqie'
 pkgname=geeqie
 version=2.1
-revision=1
+revision=2
 build_style=meson
 hostmakedepends="pkg-config gettext xxd gdk-pixbuf-devel glib-devel"
 makedepends="gtk+3-devel glib-devel lcms2-devel exiv2-devel libheif-devel

From 096ef0a8962dcae5f6c4de4d702858a861a50189 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 07/22] gthumb: revbump for exiv2-0.28.0.

---
 srcpkgs/gthumb/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/gthumb/template b/srcpkgs/gthumb/template
index c8e19f0dedb61..732d5e1c6089f 100644
--- a/srcpkgs/gthumb/template
+++ b/srcpkgs/gthumb/template
@@ -1,7 +1,7 @@
 # Template file for 'gthumb'
 pkgname=gthumb
 version=3.12.3
-revision=1
+revision=2
 build_style=meson
 hostmakedepends="gettext pkg-config itstool glib-devel"
 makedepends="webkit2gtk-devel json-glib-devel libsecret-devel librsvg-devel

From fb9c21d01088e0f7aa4ca4fe99fa5497c34f6e45 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 08/22] gwenview: revbump for exiv2-0.28.0.

---
 srcpkgs/gwenview/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/gwenview/template b/srcpkgs/gwenview/template
index 73d450a458c4d..eb876cfadcfe8 100644
--- a/srcpkgs/gwenview/template
+++ b/srcpkgs/gwenview/template
@@ -1,7 +1,7 @@
 # Template file for 'gwenview'
 pkgname=gwenview
 version=23.08.2
-revision=1
+revision=2
 build_style=cmake
 build_helper=qemu
 hostmakedepends="extra-cmake-modules pkg-config qt5-qmake qt5-host-tools

From 803aa9fc8cd0eda481b635a9633ac0ef52368c9d Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 09/22] hugin: revbump for exiv2-0.28.0.

---
 srcpkgs/hugin/patches/exiv2-0.28.patch | 77 ++++++++++++++++++++++++++
 srcpkgs/hugin/template                 |  2 +-
 2 files changed, 78 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/hugin/patches/exiv2-0.28.patch

diff --git a/srcpkgs/hugin/patches/exiv2-0.28.patch b/srcpkgs/hugin/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..49f0518117020
--- /dev/null
+++ b/srcpkgs/hugin/patches/exiv2-0.28.patch
@@ -0,0 +1,77 @@
+Patch-Source: https://gitlab.archlinux.org/archlinux/packaging/packages/hugin/-/blob/main/exiv2-0.28.patch
+diff -r 79cd11a7a66f src/hugin_base/panodata/Exiv2Helper.cpp
+--- a/src/hugin_base/panodata/Exiv2Helper.cpp	Wed May 24 19:13:20 2023 +0200
++++ b/src/hugin_base/panodata/Exiv2Helper.cpp	Mon Jun 05 00:31:19 2023 +0200
+@@ -40,7 +40,7 @@
+             Exiv2::ExifData::iterator itr = exifData.findKey(Exiv2::ExifKey(keyName));
+             if (itr != exifData.end() && itr->count())
+             {
+-                value = itr->toLong();
++                value = itr->toUint32();
+                 return true;
+             }
+             else
+@@ -165,7 +165,7 @@
+         {
+             if(it!=exifData.end() && it->count())
+             {
+-                return it->toLong();
++                return it->toUint32();
+             }
+             return 0;
+         };
+@@ -600,4 +600,4 @@
+         };
+ 
+     }; //namespace Exiv2Helper
+-}; //namespace HuginBase
+\ No newline at end of file
++}; //namespace HuginBase
+diff -r 79cd11a7a66f src/hugin_base/panodata/SrcPanoImage.cpp
+--- a/src/hugin_base/panodata/SrcPanoImage.cpp	Wed May 24 19:13:20 2023 +0200
++++ b/src/hugin_base/panodata/SrcPanoImage.cpp	Mon Jun 05 00:31:19 2023 +0200
+@@ -384,7 +384,7 @@
+                     pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaImageWidthPixels"));
+                     if (pos != xmpData.end())
+                     {
+-                        croppedWidth = pos->toLong();
++                        croppedWidth = pos->toUint32();
+                     }
+                     else
+                     {
+@@ -394,7 +394,7 @@
+                     pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaImageHeightPixels"));
+                     if (pos != xmpData.end())
+                     {
+-                        croppedHeight = pos->toLong();
++                        croppedHeight = pos->toUint32();
+                     }
+                     else
+                     {
+@@ -408,7 +408,7 @@
+                         double hfov = 0;
+                         if (pos != xmpData.end())
+                         {
+-                            hfov = 360 * croppedWidth / (double)pos->toLong();
++                            hfov = 360 * croppedWidth / (double)pos->toUint32();
+                         }
+                         else
+                         {
+@@ -419,7 +419,7 @@
+                         pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.FullPanoHeightPixels"));
+                         if (pos != xmpData.end())
+                         {
+-                            fullHeight = pos->toLong();
++                            fullHeight = pos->toUint32();
+                         }
+                         else
+                         {
+@@ -430,7 +430,7 @@
+                         pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaTopPixels"));
+                         if (pos != xmpData.end())
+                         {
+-                            cropTop = pos->toLong();
++                            cropTop = pos->toUint32();
+                         }
+                         else
+                         {
diff --git a/srcpkgs/hugin/template b/srcpkgs/hugin/template
index f96d2f6e27d42..ce71f6e4cbb2d 100644
--- a/srcpkgs/hugin/template
+++ b/srcpkgs/hugin/template
@@ -1,7 +1,7 @@
 # Template file for 'hugin'
 pkgname=hugin
 version=2022.0.0
-revision=10
+revision=11
 build_style=cmake
 build_helper=cmake-wxWidgets-gtk3
 pycompile_dirs="usr/share/hugin/data/plugins usr/share/hugin/data/plugins-templates"

From ecb668d882d5e51f45a26666473251717ca0b6c3 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 10/22] kfilemetadata5: revbump for exiv2-0.28.0.

---
 srcpkgs/kfilemetadata5/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/kfilemetadata5/template b/srcpkgs/kfilemetadata5/template
index 00f7a98cf6399..e294ae5af947c 100644
--- a/srcpkgs/kfilemetadata5/template
+++ b/srcpkgs/kfilemetadata5/template
@@ -1,7 +1,7 @@
 # Template file for 'kfilemetadata5'
 pkgname=kfilemetadata5
 version=5.111.0
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="kcoreaddons extra-cmake-modules pkg-config qt5-host-tools qt5-qmake
  gettext kcoreaddons python3"

From 710c8361aa0e2e5f40a075533e5c68c726573b7f Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 11/22] krename: revbump for exiv2-0.28.0.

---
 srcpkgs/krename/patches/e7dd767a.patch | 90 ++++++++++++++++++++++++++
 srcpkgs/krename/template               |  2 +-
 2 files changed, 91 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/krename/patches/e7dd767a.patch

diff --git a/srcpkgs/krename/patches/e7dd767a.patch b/srcpkgs/krename/patches/e7dd767a.patch
new file mode 100644
index 0000000000000..a0ef428ce46b1
--- /dev/null
+++ b/srcpkgs/krename/patches/e7dd767a.patch
@@ -0,0 +1,90 @@
+Patch-Source: https://invent.kde.org/utilities/krename/-/commit/e7dd767a
+From e7dd767a9a1068ee1fe1502c4d619b57d3b12add Mon Sep 17 00:00:00 2001
+From: Andreas Sturmlechner <asturm@gentoo.org>
+Date: Fri, 26 May 2023 23:23:10 +0200
+Subject: [PATCH] Fix build with >=exiv2-0.28, raise minimum to 0.27
+
+- enables use of EXIV2_TEST_VERSION macro
+- exiv2 headers cleanup
+
+Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>
+---
+ CMakeLists.txt         |  6 +-----
+ config-krename.h.cmake |  3 ---
+ src/exiv2plugin.cpp    | 17 +++++------------
+ 3 files changed, 6 insertions(+), 20 deletions(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 0bda8ac..72e7297 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -56,13 +56,9 @@ set_package_properties(Taglib PROPERTIES
+     TYPE OPTIONAL)
+ 
+ # Find exiv2
+-find_package(LibExiv2 0.13) # AccessMode was added in 0.13
++find_package(LibExiv2 0.27) # EXIV2_TEST_VERSION was added in 0.27
+ set_package_properties(LibExiv2 PROPERTIES TYPE OPTIONAL)
+ 
+-if (LibExiv2_VERSION VERSION_GREATER_EQUAL "0.27")
+-    set(HAVE_LIBEXIV2_0_27 TRUE)
+-endif()
+-
+ # Find podofo
+ find_package(PoDoFo)
+ set_package_properties(PoDoFo PROPERTIES
+diff --git a/config-krename.h.cmake b/config-krename.h.cmake
+index 76c3d30..862e40b 100644
+--- a/config-krename.h.cmake
++++ b/config-krename.h.cmake
+@@ -6,9 +6,6 @@
+ /* have Exiv2 */
+ #cmakedefine01 HAVE_EXIV2
+ 
+-/* Defined if we have libexiv2 >= 0.27 */
+-#cmakedefine HAVE_LIBEXIV2_0_27
+-
+ /* have PoDoFo */
+ #cmakedefine01 HAVE_PODOFO
+ 
+diff --git a/src/exiv2plugin.cpp b/src/exiv2plugin.cpp
+index 5694d8c..25e8869 100644
+--- a/src/exiv2plugin.cpp
++++ b/src/exiv2plugin.cpp
+@@ -3,20 +3,9 @@
+ 
+ #include "exiv2plugin.h"
+ 
+-#include "../config-krename.h"
+-
+ #include <KLocalizedString>
+ 
+-#include <exiv2/error.hpp>
+-#include <exiv2/exif.hpp>
+-#include <exiv2/image.hpp>
+-#include <exiv2/iptc.hpp>
+-#ifdef HAVE_LIBEXIV2_0_27
+-    #include <exiv2/xmp_exiv2.hpp>
+-#else
+-    #include <exiv2/xmp.hpp>
+-#endif
+-#include <exiv2/tags.hpp>
++#include <exiv2/exiv2.hpp>
+ 
+ #include "batchrenamer.h"
+ #include "tokenhelpdialog.h"
+@@ -381,7 +370,11 @@ QString Exiv2Plugin::processFile(BatchRenamer *b, int index, const QString &file
+     std::string strFilename(asc.constData(), asc.length());
+ 
+     try {
++#if EXIV2_TEST_VERSION(0,28,0)
++        Image::UniquePtr image = Exiv2::ImageFactory::open(strFilename);
++#else
+         Image::AutoPtr image = Exiv2::ImageFactory::open(strFilename);
++#endif
+         if (image.get() != nullptr && image->good()) {
+             image->readMetadata();
+ 
+-- 
+GitLab
+
diff --git a/srcpkgs/krename/template b/srcpkgs/krename/template
index 66023163e3293..df5535007714a 100644
--- a/srcpkgs/krename/template
+++ b/srcpkgs/krename/template
@@ -1,7 +1,7 @@
 # Template file for 'krename'
 pkgname=krename
 version=5.0.2
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="extra-cmake-modules gettext kcoreaddons pkg-config qt5-host-tools qt5-qmake"
 makedepends="exiv2-devel freetype-devel kjs-devel kparts-devel libpodofo-devel

From 86e47a7365d59ef2ae477e4dc591e0a8954786d2 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 12/22] krita: revbump for exiv2-0.28.0.

---
 srcpkgs/krita/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/krita/template b/srcpkgs/krita/template
index a4d3de04b049f..b479e0db798ee 100644
--- a/srcpkgs/krita/template
+++ b/srcpkgs/krita/template
@@ -1,7 +1,7 @@
 # Template file for 'krita'
 pkgname=krita
 version=5.2.0
-revision=1
+revision=2
 build_style=cmake
 configure_args="-Wno-dev -DBUILD_TESTING=OFF"
 hostmakedepends="extra-cmake-modules gettext pkg-config python3

From 19f8c98058c10e2fc1a7a2abaedcf7ae04668c14 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 13/22] libextractor: revbump for exiv2-0.28.0.

---
 srcpkgs/libextractor/patches/exiv2-0.28.patch | 286 ++++++++++++++++++
 srcpkgs/libextractor/template                 |   2 +-
 2 files changed, 287 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/libextractor/patches/exiv2-0.28.patch

diff --git a/srcpkgs/libextractor/patches/exiv2-0.28.patch b/srcpkgs/libextractor/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..270a626d8ab06
--- /dev/null
+++ b/srcpkgs/libextractor/patches/exiv2-0.28.patch
@@ -0,0 +1,286 @@
+Patch-Source: https://gitlab.archlinux.org/archlinux/packaging/packages/libextractor/-/blob/main/exiv2-0.28.patch
+diff --git a/src/plugins/exiv2_extractor.cc b/src/plugins/exiv2_extractor.cc
+index 78f9bda..d32ed6a 100644
+--- a/src/plugins/exiv2_extractor.cc
++++ b/src/plugins/exiv2_extractor.cc
+@@ -90,7 +90,11 @@ virtual int close ();
+  * @param rcount number of bytes to read
+  * @return buffer with data read, empty buffer (!) on failure (!)
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++virtual Exiv2::DataBuf read (size_t rcount);
++#else
+ virtual Exiv2::DataBuf read (long rcount);
++#endif
+ 
+ /**
+  * Read up to 'rcount' bytes into 'buf'.
+@@ -99,8 +103,17 @@ virtual Exiv2::DataBuf read (long rcount);
+  * @param rcount size of 'buf'
+  * @return number of bytes read successfully, 0 on failure (!)
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++virtual size_t read (Exiv2::byte *buf,
++                   size_t rcount);
++#else
+ virtual long read (Exiv2::byte *buf,
+                    long rcount);
++#endif
++
++#if EXIV2_TEST_VERSION (0,28,0)
++virtual void populateFakeData();
++#endif
+ 
+ /**
+  * Read a single character.
+@@ -117,8 +130,13 @@ virtual int getb ();
+  * @param wcount how many bytes to write
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual size_t write (const Exiv2::byte *data,
++                    size_t wcount);
++#else
+ virtual long write (const Exiv2::byte *data,
+                     long wcount);
++#endif
+ 
+ /**
+  * Write to stream.
+@@ -126,7 +144,11 @@ virtual long write (const Exiv2::byte *data,
+  * @param src stream to copy
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual size_t write (Exiv2::BasicIo &src);
++#else
+ virtual long write (Exiv2::BasicIo &src);
++#endif
+ 
+ /**
+  * Write a single byte.
+@@ -172,7 +194,11 @@ virtual int munmap ();
+  *
+  * @return -1 on error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual size_t tell (void) const;
++#else
+ virtual long int tell (void) const;
++#endif
+ 
+ /**
+  * Return overall size of the file.
+@@ -213,7 +239,11 @@ virtual bool eof () const;
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual const std::string& path () const noexcept;
++#else
+ virtual std::string path () const;
++#endif
+ 
+ #ifdef EXV_UNICODE_PATH
+ /**
+@@ -230,7 +260,11 @@ virtual std::wstring wpath () const;
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual Exiv2::BasicIo::UniquePtr temporary () const;
++#else
+ virtual Exiv2::BasicIo::AutoPtr temporary () const;
++#endif
+ 
+ };
+ 
+@@ -266,7 +300,11 @@ ExtractorIO::close ()
+  * @return buffer with data read, empty buffer (!) on failure (!)
+  */
+ Exiv2::DataBuf
++#if EXIV2_TEST_VERSION (0,28,0)
++ExtractorIO::read (size_t rcount)
++#else
+ ExtractorIO::read (long rcount)
++#endif
+ {
+   void *data;
+   ssize_t ret;
+@@ -284,9 +322,15 @@ ExtractorIO::read (long rcount)
+  * @param rcount size of 'buf'
+  * @return number of bytes read successfully, 0 on failure (!)
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++size_t
++ExtractorIO::read (Exiv2::byte *buf,
++                   size_t rcount)
++#else
+ long
+ ExtractorIO::read (Exiv2::byte *buf,
+                    long rcount)
++#endif
+ {
+   void *data;
+   ssize_t ret;
+@@ -305,6 +349,12 @@ ExtractorIO::read (Exiv2::byte *buf,
+   return got;
+ }
+ 
++#if EXIV2_TEST_VERSION (0,28,0)
++void ExtractorIO::populateFakeData()
++{
++  return;
++}
++#endif
+ 
+ /**
+  * Read a single character.
+@@ -319,7 +369,9 @@ ExtractorIO::getb ()
+   const unsigned char *r;
+ 
+   if (1 != ec->read (ec->cls, &data, 1))
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION(0,28,0)
++    throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+     throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+     throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -336,9 +388,15 @@ ExtractorIO::getb ()
+  * @param wcount how many bytes to write
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++size_t
++ExtractorIO::write (const Exiv2::byte *data,
++                    size_t wcount)
++#else
+ long
+ ExtractorIO::write (const Exiv2::byte *data,
+                     long wcount)
++#endif
+ {
+   return -1;
+ }
+@@ -350,7 +408,11 @@ ExtractorIO::write (const Exiv2::byte *data,
+  * @param src stream to copy
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++size_t
++#else
+ long
++#endif
+ ExtractorIO::write (Exiv2::BasicIo &src)
+ {
+   return -1;
+@@ -378,7 +440,9 @@ ExtractorIO::putb (Exiv2::byte data)
+ void
+ ExtractorIO::transfer (Exiv2::BasicIo& src)
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION(0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -427,7 +491,9 @@ ExtractorIO::seek (long offset,
+ Exiv2::byte *
+ ExtractorIO::mmap (bool isWritable)
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION (0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -452,7 +518,11 @@ ExtractorIO::munmap ()
+  *
+  * @return -1 on error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++size_t
++#else
+ long int
++#endif
+ ExtractorIO::tell (void) const
+ {
+   return (long) ec->seek (ec->cls, 0, SEEK_CUR);
+@@ -516,10 +586,17 @@ ExtractorIO::eof () const
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++const std::string&
++ExtractorIO::path () const noexcept
++#else
+ std::string
+ ExtractorIO::path () const
++#endif
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION (0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -536,7 +613,9 @@ ExtractorIO::path () const
+ std::wstring
+ ExtractorIO::wpath () const
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION (0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -552,11 +631,17 @@ ExtractorIO::wpath () const
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++Exiv2::BasicIo::UniquePtr
++#else
+ Exiv2::BasicIo::AutoPtr
++#endif
+ ExtractorIO::temporary () const
+ {
+   fprintf (stderr, "throwing temporary error\n");
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION(0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -737,8 +822,13 @@ EXTRACTOR_exiv2_extract_method (struct EXTRACTOR_ExtractContext *ec)
+ #if ! EXIV2_TEST_VERSION (0,24,0)
+     Exiv2::LogMsg::setLevel (Exiv2::LogMsg::mute);
+ #endif
++#if EXIV2_TEST_VERSION(0,28,0)
++    std::unique_ptr<Exiv2::BasicIo> eio (new ExtractorIO (ec));
++    Exiv2::Image::UniquePtr image = Exiv2::ImageFactory::open (std::move(eio));
++#else
+     std::auto_ptr<Exiv2::BasicIo> eio (new ExtractorIO (ec));
+     Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open (eio);
++#endif
+     if (0 == image.get ())
+       return;
+     image->readMetadata ();
+@@ -822,7 +912,11 @@ EXTRACTOR_exiv2_extract_method (struct EXTRACTOR_ExtractContext *ec)
+       ADDXMP ("Xmp.lr.hierarchicalSubject", EXTRACTOR_METATYPE_SUBJECT);
+     }
+   }
++#if EXIV2_TEST_VERSION (0,28,0)
++  catch (const Exiv2::Error& e)
++#else
+   catch (const Exiv2::AnyError& e)
++#endif
+   {
+ #if DEBUG
+     std::cerr << "Caught Exiv2 exception '" << e << "'\n";
diff --git a/srcpkgs/libextractor/template b/srcpkgs/libextractor/template
index ddd4790f93e88..bfcea979a308c 100644
--- a/srcpkgs/libextractor/template
+++ b/srcpkgs/libextractor/template
@@ -1,7 +1,7 @@
 # Template file for 'libextractor'
 pkgname=libextractor
 version=1.11
-revision=2
+revision=3
 build_style=gnu-configure
 configure_args="--disable-static"
 hostmakedepends="pkg-config"

From ffff9172b168a9a5cbef1b8bbc6619c091ed6c86 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 14/22] libgexiv2: update to 0.14.2.

---
 srcpkgs/libgexiv2/template | 14 +++++++-------
 1 file changed, 7 insertions(+), 7 deletions(-)

diff --git a/srcpkgs/libgexiv2/template b/srcpkgs/libgexiv2/template
index 23780e5397dc4..91dbcaa9aca52 100644
--- a/srcpkgs/libgexiv2/template
+++ b/srcpkgs/libgexiv2/template
@@ -1,19 +1,19 @@
 # Template file for 'libgexiv2'
 pkgname=libgexiv2
-version=0.14.0
-revision=3
+version=0.14.2
+revision=1
 build_style=meson
 build_helper="gir"
-configure_args="-Dintrospection=$(vopt_if gir true false)
- -Dvapi=$(vopt_if vala true false)"
+configure_args="$(vopt_bool gir introspection) $(vopt_bool vala vapi)"
 hostmakedepends="pkg-config glib-devel $(vopt_if vala 'vala') python3-gobject"
 makedepends="libglib-devel exiv2-devel"
 short_desc="GObject-based wrapper around the Exiv2 library"
 maintainer="Enno Boland <gottox@voidlinux.org>"
 license="GPL-2.0-or-later"
 homepage="https://wiki.gnome.org/Projects/gexiv2"
-distfiles="${GNOME_SITE}/gexiv2/${version%.*}/${pkgname/lib/}-${version}.tar.xz"
-checksum=e58279a6ff20b6f64fa499615da5e9b57cf65ba7850b72fafdf17221a9d6d69e
+changelog="https://gitlab.gnome.org/GNOME/gexiv2/-/raw/master/NEWS"
+distfiles="${GNOME_SITE}/gexiv2/${version%.*}/gexiv2-${version}.tar.xz"
+checksum=2a0c9cf48fbe8b3435008866ffd40b8eddb0667d2212b42396fdf688e93ce0be
 
 build_options="gir vala"
 build_options_default="gir vala"
@@ -23,7 +23,7 @@ libgexiv2-devel_package() {
 	short_desc+=" - development files"
 	pkg_install() {
 		vmove usr/include
-		vmove usr/lib/*.so
+		vmove "usr/lib/*.so"
 		vmove usr/lib/pkgconfig
 		if [ "$build_option_vala" ]; then
 			vmove usr/share/vala

From fd0e905656e5bb90b5d58bc4c5180d424b55ee2e Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 15/22] libkexiv25: update to 23.08.2.

---
 srcpkgs/libkexiv25/template | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/srcpkgs/libkexiv25/template b/srcpkgs/libkexiv25/template
index b439a42ef2b97..4d7f9600572ea 100644
--- a/srcpkgs/libkexiv25/template
+++ b/srcpkgs/libkexiv25/template
@@ -1,6 +1,6 @@
 # Template file for 'libkexiv25'
 pkgname=libkexiv25
-version=23.04.0
+version=23.08.2
 revision=1
 build_style=cmake
 configure_args="-DBUILD_TESTING=OFF"
@@ -11,7 +11,7 @@ maintainer="Orphaned <orphan@voidlinux.org>"
 license="GPL-2.0-or-later"
 homepage="https://invent.kde.org/graphics/libkexiv2"
 distfiles="${KDE_SITE}/release-service/${version}/src/libkexiv2-${version}.tar.xz"
-checksum=18d3eed06df9d1e31d8434ed9887e305aba176d0856e19a8cd3bdb555b80d391
+checksum=d06e36a408bf2e846a18056a1f15e61d981fa2a1fceb81f7c15136604319d033
 
 libkexiv25-devel_package() {
 	short_desc+=" - development files"

From 5b521eed1195e26ac1f2825a421c9ed0ac1493b3 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 16/22] nomacs: update to 3.17.2287.

---
 srcpkgs/nomacs/template | 17 +++++++++++++----
 1 file changed, 13 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/nomacs/template b/srcpkgs/nomacs/template
index c52cd54e294db..956bd21ebb129 100644
--- a/srcpkgs/nomacs/template
+++ b/srcpkgs/nomacs/template
@@ -1,7 +1,8 @@
 # Template file for 'nomacs'
 pkgname=nomacs
-version=3.16.224
-revision=5
+version=3.17.2287
+revision=1
+_plugins_ver=3.17.2285
 build_wrksrc=ImageLounge
 build_style=cmake
 configure_args="-DCMAKE_BUILD_TYPE=None -DENABLE_TRANSLATIONS=1
@@ -13,5 +14,13 @@ short_desc="Simple yet powerful Qt imageviewer"
 maintainer="Orphaned <orphan@voidlinux.org>"
 license="GPL-3.0-or-later"
 homepage="https://github.com/nomacs/nomacs"
-distfiles="https://github.com/nomacs/nomacs/archive/${version}.tar.gz"
-checksum=bbc7e9048026ef9e0d2b64902c88050f17a679ef3d3c009de2c3b7de5d1d217c
+distfiles="https://github.com/nomacs/nomacs/archive/${version}.tar.gz
+ https://github.com/novomesk/nomacs-plugins/archive/refs/tags/${_plugins_ver}.tar.gz>plugins.tar.gz"
+checksum="6905ea615358f84a0c83d5b1b7077871dea0526ec667500a1951448cb845a92c
+ 946b2d754be9ecca5cb155f7ecc5dcafb164f6c3dcc7bf5c3c0610d3b47774aa"
+skip_extraction="plugins.tar.gz"
+
+post_extract() {
+ cd ${build_wrksrc}
+ vsrcextract -C plugins "plugins.tar.gz"
+}

From 99075796b9f5817b6fe88fa95de3c6e8b503ae4c Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 17/22] pdf2djvu: revbump for exiv2-0.28.0.

---
 srcpkgs/pdf2djvu/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/pdf2djvu/template b/srcpkgs/pdf2djvu/template
index ef7433c0c98ae..5a6f3ddf4ed35 100644
--- a/srcpkgs/pdf2djvu/template
+++ b/srcpkgs/pdf2djvu/template
@@ -1,7 +1,7 @@
 # Template file for 'pdf2djvu'
 pkgname=pdf2djvu
 version=0.9.19
-revision=4
+revision=5
 build_style=gnu-configure
 hostmakedepends="pkg-config djvulibre gettext"
 makedepends="djvulibre-devel poppler-devel libgraphicsmagick-devel exiv2-devel libuuid-devel"

From 8359c0be8f4dc078f30bbb53c7ae9859f31d60c4 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 18/22] phototonic: revbump for exiv2-0.28.0.

---
 srcpkgs/phototonic/patches/exiv2-0.28.patch | 135 ++++++++++++++++++++
 srcpkgs/phototonic/template                 |   2 +-
 2 files changed, 136 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/phototonic/patches/exiv2-0.28.patch

diff --git a/srcpkgs/phototonic/patches/exiv2-0.28.patch b/srcpkgs/phototonic/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..1c75b628dab33
--- /dev/null
+++ b/srcpkgs/phototonic/patches/exiv2-0.28.patch
@@ -0,0 +1,135 @@
+From 923a3fc14de0b779a45696c5f0aef34c74d84f13 Mon Sep 17 00:00:00 2001
+From: Andreas Sturmlechner <asturm@gentoo.org>
+Date: Sun, 28 May 2023 18:54:10 +0200
+Subject: [PATCH] Fix build with exiv2-0.28
+
+Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>
+---
+ ImageViewer.cpp   | 9 +++++++++
+ MetadataCache.cpp | 8 ++++++++
+ Phototonic.cpp    | 4 ++++
+ Tags.cpp          | 8 ++++++++
+ ThumbsViewer.cpp  | 4 ++++
+ 5 files changed, 33 insertions(+)
+
+diff --git a/ImageViewer.cpp b/ImageViewer.cpp
+index 357d223..df3ac43 100644
+--- a/ImageViewer.cpp
++++ b/ImageViewer.cpp
+@@ -945,7 +945,11 @@ void ImageViewer::keyMoveEvent(int direction) {
+ }
+ 
+ void ImageViewer::saveImage() {
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr image;
++#else
+     Exiv2::Image::AutoPtr image;
++#endif
+     bool exifError = false;
+ 
+     if (newImage) {
+@@ -985,8 +989,13 @@ void ImageViewer::saveImage() {
+ }
+ 
+ void ImageViewer::saveImageAs() {
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++    Exiv2::Image::UniquePtr newExifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
+     Exiv2::Image::AutoPtr newExifImage;
++#endif
+     bool exifError = false;
+ 
+     setCursorHiding(false);
+diff --git a/MetadataCache.cpp b/MetadataCache.cpp
+index 524ae74..5ddd4c8 100644
+--- a/MetadataCache.cpp
++++ b/MetadataCache.cpp
+@@ -64,7 +64,11 @@ void MetadataCache::clear() {
+ }
+ 
+ bool MetadataCache::loadImageMetadata(const QString &imageFullPath) {
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
++#endif
+     QSet<QString> tags;
+     long orientation = 0;
+ 
+@@ -78,7 +82,11 @@ bool MetadataCache::loadImageMetadata(const QString &imageFullPath) {
+     try {
+         Exiv2::ExifData &exifData = exifImage->exifData();
+         if (!exifData.empty()) {
++#if EXIV2_TEST_VERSION(0,28,0)
++            orientation = exifData["Exif.Image.Orientation"].value().toUint32();
++#else
+             orientation = exifData["Exif.Image.Orientation"].value().toLong();
++#endif
+         }
+     } catch (Exiv2::Error &error) {
+         qWarning() << "Failed to read Exif metadata";
+diff --git a/Phototonic.cpp b/Phototonic.cpp
+index 6cc95b3..bd5497d 100644
+--- a/Phototonic.cpp
++++ b/Phototonic.cpp
+@@ -3151,7 +3151,11 @@ void Phototonic::removeMetadata() {
+ 
+     if (ret == MessageBox::Yes) {
+         for (int file = 0; file < fileList.size(); ++file) {
++#if EXIV2_TEST_VERSION(0,28,0)
++            Exiv2::Image::UniquePtr image;
++#else
+             Exiv2::Image::AutoPtr image;
++#endif
+             try {
+                 image = Exiv2::ImageFactory::open(fileList[file].toStdString());
+                 image->clearMetadata();
+diff --git a/Tags.cpp b/Tags.cpp
+index 84eea16..a62da9d 100644
+--- a/Tags.cpp
++++ b/Tags.cpp
+@@ -136,7 +136,11 @@ void ImageTags::addTag(QString tagName, bool tagChecked) {
+ 
+ bool ImageTags::writeTagsToImage(QString &imageFileName, QSet<QString> &newTags) {
+     QSet<QString> imageTags;
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
++#endif
+ 
+     try {
+         exifImage = Exiv2::ImageFactory::open(imageFileName.toStdString());
+@@ -160,7 +164,11 @@ bool ImageTags::writeTagsToImage(QString &imageFileName, QSet<QString> &newTags)
+         QSetIterator<QString> newTagsIt(newTags);
+         while (newTagsIt.hasNext()) {
+             QString tag = newTagsIt.next();
++#if EXIV2_TEST_VERSION(0,28,0)
++            Exiv2::Value::UniquePtr value = Exiv2::Value::create(Exiv2::string);
++#else
+             Exiv2::Value::AutoPtr value = Exiv2::Value::create(Exiv2::string);
++#endif
+             value->read(tag.toStdString());
+             Exiv2::IptcKey key("Iptc.Application2.Keywords");
+             newIptcData.add(key, value.get());
+diff --git a/ThumbsViewer.cpp b/ThumbsViewer.cpp
+index 77a6189..4a11475 100644
+--- a/ThumbsViewer.cpp
++++ b/ThumbsViewer.cpp
+@@ -210,7 +210,11 @@ void ThumbsViewer::updateImageInfoViewer(QString imageFullPath) {
+         infoView->addEntry(key, val);
+     }
+ 
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
++#endif
+     try {
+         exifImage = Exiv2::ImageFactory::open(imageFullPath.toStdString());
+         exifImage->readMetadata();
+-- 
+2.40.1
+
diff --git a/srcpkgs/phototonic/template b/srcpkgs/phototonic/template
index 77ae8bf6a4406..4af006cb7da41 100644
--- a/srcpkgs/phototonic/template
+++ b/srcpkgs/phototonic/template
@@ -1,7 +1,7 @@
 # Template file for 'phototonic'
 pkgname=phototonic
 version=2.1
-revision=3
+revision=4
 build_style=qmake
 hostmakedepends="pkg-config qt5-qmake qt5-host-tools"
 makedepends="qt5-svg-devel exiv2-devel"

From 9677bc84cd49885c0422c230011c5447ccc542ea Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 19/22] qimgv: revbump for exiv2-0.28.0.

---
 srcpkgs/qimgv/patches/exiv2-0.28.patch | 16 ++++++++++++++++
 srcpkgs/qimgv/template                 |  2 +-
 2 files changed, 17 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/qimgv/patches/exiv2-0.28.patch

diff --git a/srcpkgs/qimgv/patches/exiv2-0.28.patch b/srcpkgs/qimgv/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..11f37b5ae2be3
--- /dev/null
+++ b/srcpkgs/qimgv/patches/exiv2-0.28.patch
@@ -0,0 +1,16 @@
+Patch-Source: https://git.alpinelinux.org/aports/tree/community/qimgv/exiv2-0.28.patch
+diff --git a/qimgv/sourcecontainers/documentinfo.cpp b/qimgv/sourcecontainers/documentinfo.cpp
+index 98a68f7..c062474 100644
+--- a/qimgv/sourcecontainers/documentinfo.cpp
++++ b/qimgv/sourcecontainers/documentinfo.cpp
+@@ -271,10 +271,6 @@ void DocumentInfo::loadExifTags() {
+         //std::cout << "Caught Exiv2 exception '" << e.what() << "'\n";
+         return;
+     }
+-    catch (Exiv2::BasicError<CharType> e) {
+-        //std::cout << "Caught BasicError Exiv2 exception '" << e.what() << "'\n";
+-        return;
+-    }
+ #endif
+ }
+ 
diff --git a/srcpkgs/qimgv/template b/srcpkgs/qimgv/template
index 7eb30db33992c..dd341dfe1bfce 100644
--- a/srcpkgs/qimgv/template
+++ b/srcpkgs/qimgv/template
@@ -1,7 +1,7 @@
 # Template file for 'qimgv'
 pkgname=qimgv
 version=1.0.2
-revision=2
+revision=3
 build_style=cmake
 configure_args="$(vopt_if video -DVIDEO_SUPPORT=ON -DVIDEO_SUPPORT=OFF)
  $(vopt_if scale -DOPENCV_SUPPORT=ON -DOPENCV_SUPPORT=OFF)

From a0245ef55794b36923a6f915bb108463b65a0d3e Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 20/22] SIR: revbump for exiv2-0.28.0.

---
 srcpkgs/SIR/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/SIR/template b/srcpkgs/SIR/template
index 113077acad354..c6da4c26b6c71 100644
--- a/srcpkgs/SIR/template
+++ b/srcpkgs/SIR/template
@@ -1,7 +1,7 @@
 # Template file for 'SIR'
 pkgname=SIR
 version=3.2.2
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="pkg-config"
 makedepends="exiv2-devel qt5-svg-devel qt5-tools-devel"

From a0026ff29d58fdd9039a2622b9e3091518531c0f Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 21/22] viewnior: revbump for exiv2-0.28.0.

---
 srcpkgs/viewnior/patches/exiv2-0.28.patch | 147 ++++++++++++++++++++++
 srcpkgs/viewnior/template                 |   2 +-
 2 files changed, 148 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/viewnior/patches/exiv2-0.28.patch

diff --git a/srcpkgs/viewnior/patches/exiv2-0.28.patch b/srcpkgs/viewnior/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..71459dee15768
--- /dev/null
+++ b/srcpkgs/viewnior/patches/exiv2-0.28.patch
@@ -0,0 +1,147 @@
+Patch-Source: https://gitlab.archlinux.org/archlinux/packaging/packages/viewnior/-/blob/f206ce6c22a3ec5f1f9ea1bde4077584f80458dd/exiv2-0.28.patch
+--
+From b6bb81a1b46e911d15bbf9a730972523de177705 Mon Sep 17 00:00:00 2001
+From: tastytea <tastytea@tastytea.de>
+Date: Tue, 16 May 2023 10:54:40 +0200
+Subject: [PATCH 1/2] change exiv2 AutoPtr to unique_ptr
+
+exiv2-0.28.0 removed Exiv2::Image::AutoPtr and added
+Exiv2::Image::UniquePtr instead. since it's a typedef for
+std::unique_ptr<Image>, i'm using that directly instead of adding a
+condition on the exiv2 version.
+---
+ src/uni-exiv2.cpp | 21 +++++++++++----------
+ 1 file changed, 11 insertions(+), 10 deletions(-)
+
+diff --git a/src/uni-exiv2.cpp b/src/uni-exiv2.cpp
+index 0d14b9f..77064c2 100644
+--- a/src/uni-exiv2.cpp
++++ b/src/uni-exiv2.cpp
+@@ -22,12 +22,13 @@
+ 
+ #include <exiv2/exiv2.hpp>
+ #include <iostream>
++#include <memory>
+ 
+ #include "uni-exiv2.hpp"
+ 
+ #define ARRAY_SIZE(array) (sizeof array/sizeof(array[0]))
+ 
+-static Exiv2::Image::AutoPtr cached_image;
++static std::unique_ptr<Exiv2::Image> cached_image;
+ 
+ extern "C"
+ void
+@@ -35,8 +36,8 @@ uni_read_exiv2_map(const char *uri, void (*callback)(const char*, const char*, v
+ {
+     Exiv2::LogMsg::setLevel(Exiv2::LogMsg::mute);
+     try {
+-        Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open(uri);
+-        if ( image.get() == 0 ) {
++        std::unique_ptr<Exiv2::Image> image = Exiv2::ImageFactory::open(uri);
++        if (image == nullptr) {
+             return;
+         }
+ 
+@@ -91,14 +92,14 @@ uni_read_exiv2_to_cache(const char *uri)
+ {
+     Exiv2::LogMsg::setLevel(Exiv2::LogMsg::mute);
+ 
+-    if ( cached_image.get() != NULL ) {
++    if (cached_image != nullptr) {
+         cached_image->clearMetadata();
+-        cached_image.reset(NULL);
++        cached_image.reset(nullptr);
+     }
+ 
+     try {
+         cached_image = Exiv2::ImageFactory::open(uri);
+-        if ( cached_image.get() == 0 ) {
++        if (cached_image == nullptr) {
+             return 1;
+         }
+ 
+@@ -116,13 +117,13 @@ uni_write_exiv2_from_cache(const char *uri)
+ {
+     Exiv2::LogMsg::setLevel(Exiv2::LogMsg::mute);
+ 
+-    if ( cached_image.get() == NULL ) {
++    if (cached_image == nullptr) {
+         return 1;
+     }
+ 
+     try {
+-        Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open(uri);
+-        if ( image.get() == 0 ) {
++        std::unique_ptr<Exiv2::Image> image = Exiv2::ImageFactory::open(uri);
++        if (image == nullptr) {
+             return 2;
+         }
+ 
+@@ -130,7 +131,7 @@ uni_write_exiv2_from_cache(const char *uri)
+         image->writeMetadata();
+ 
+         cached_image->clearMetadata();
+-        cached_image.reset(NULL);
++        cached_image.reset(nullptr);
+ 
+         return 0;
+     } catch (Exiv2::AnyError& e) {
+
+From 47d0b98cb46526aa8aa035bebcabc14a11fa57ee Mon Sep 17 00:00:00 2001
+From: tastytea <tastytea@tastytea.de>
+Date: Tue, 16 May 2023 11:17:00 +0200
+Subject: [PATCH 2/2] add support for exiv-0.28.0 errors
+
+exiv2-0.28.0 changed Exiv2::AnyError to Exiv2::Error.
+---
+ src/uni-exiv2.cpp | 15 ++++++++++++---
+ 1 file changed, 12 insertions(+), 3 deletions(-)
+
+diff --git a/src/uni-exiv2.cpp b/src/uni-exiv2.cpp
+index 77064c2..567a50f 100644
+--- a/src/uni-exiv2.cpp
++++ b/src/uni-exiv2.cpp
+@@ -28,6 +28,15 @@
+ 
+ #define ARRAY_SIZE(array) (sizeof array/sizeof(array[0]))
+ 
++#define EXIV_ERROR Exiv2::AnyError
++#ifdef EXIV2_VERSION
++    #ifdef EXIV2_TEST_VERSION
++        #if EXIV2_TEST_VERSION(0,28,0)
++            #define EXIV_ERROR Exiv2::Error
++        #endif
++    #endif
++#endif
++
+ static std::unique_ptr<Exiv2::Image> cached_image;
+ 
+ extern "C"
+@@ -81,7 +90,7 @@ uni_read_exiv2_map(const char *uri, void (*callback)(const char*, const char*, v
+                 }
+             }
+         }
+-    } catch (Exiv2::AnyError& e) {
++    } catch (EXIV_ERROR& e) {
+         std::cerr << "Exiv2: '" << e << "'\n";
+     }
+ }
+@@ -104,7 +113,7 @@ uni_read_exiv2_to_cache(const char *uri)
+         }
+ 
+         cached_image->readMetadata();
+-    } catch (Exiv2::AnyError& e) {
++    } catch (EXIV_ERROR& e) {
+         std::cerr << "Exiv2: '" << e << "'\n";
+     }
+ 
+@@ -134,7 +143,7 @@ uni_write_exiv2_from_cache(const char *uri)
+         cached_image.reset(nullptr);
+ 
+         return 0;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (EXIV_ERROR& e) {
+         std::cerr << "Exiv2: '" << e << "'\n";
+     }
+ 
diff --git a/srcpkgs/viewnior/template b/srcpkgs/viewnior/template
index ea1e528a8651f..4c73226662ca0 100644
--- a/srcpkgs/viewnior/template
+++ b/srcpkgs/viewnior/template
@@ -1,7 +1,7 @@
 # Template file for 'viewnior'
 pkgname=viewnior
 version=1.8
-revision=1
+revision=2
 build_style=meson
 hostmakedepends="pkg-config intltool glib-devel gettext-devel"
 makedepends="gtk+-devel exiv2-devel"

From d0d0844d750308425919615a2795ae897f9cf193 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Mon, 23 Oct 2023 19:06:34 +0200
Subject: [PATCH 22/22] New package: nufraw-0.43.3

Co-authored-by: Mohammed Anas <triallax@tutanota.com>
---
 srcpkgs/nufraw-gimp                           |  1 +
 .../patches/0001-nufraw-glib-2.70.patch       | 20 +++++++
 srcpkgs/nufraw/patches/exiv-0.28.x.diff       | 59 +++++++++++++++++++
 srcpkgs/nufraw/template                       | 47 +++++++++++++++
 srcpkgs/removed-packages/template             |  8 ++-
 srcpkgs/ufraw                                 |  1 +
 srcpkgs/ufraw-gimp                            |  2 +-
 .../ufraw/patches/001-no-gimp-remote.patch    | 12 ----
 srcpkgs/ufraw/patches/002-fix_abs_int.patch   | 11 ----
 .../ufraw/patches/03_fix-unsigned-char.patch  | 14 -----
 srcpkgs/ufraw/patches/exiv-0.27.patch         | 25 --------
 srcpkgs/ufraw/patches/glib-2.68.patch         | 30 ----------
 srcpkgs/ufraw/patches/iostream.patch          | 13 ----
 srcpkgs/ufraw/template                        | 38 ------------
 14 files changed, 134 insertions(+), 147 deletions(-)
 create mode 120000 srcpkgs/nufraw-gimp
 create mode 100644 srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch
 create mode 100644 srcpkgs/nufraw/patches/exiv-0.28.x.diff
 create mode 100644 srcpkgs/nufraw/template
 create mode 120000 srcpkgs/ufraw
 delete mode 100644 srcpkgs/ufraw/patches/001-no-gimp-remote.patch
 delete mode 100644 srcpkgs/ufraw/patches/002-fix_abs_int.patch
 delete mode 100644 srcpkgs/ufraw/patches/03_fix-unsigned-char.patch
 delete mode 100644 srcpkgs/ufraw/patches/exiv-0.27.patch
 delete mode 100644 srcpkgs/ufraw/patches/glib-2.68.patch
 delete mode 100644 srcpkgs/ufraw/patches/iostream.patch
 delete mode 100644 srcpkgs/ufraw/template

diff --git a/srcpkgs/nufraw-gimp b/srcpkgs/nufraw-gimp
new file mode 120000
index 0000000000000..0bd1459b2a16f
--- /dev/null
+++ b/srcpkgs/nufraw-gimp
@@ -0,0 +1 @@
+nufraw
\ No newline at end of file
diff --git a/srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch b/srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch
new file mode 100644
index 0000000000000..41f10bfbafa1f
--- /dev/null
+++ b/srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch
@@ -0,0 +1,20 @@
+diff -ru nufraw/uf_glib.h nufraw/uf_glib.h
+--- nufraw/uf_glib.h	2022-02-23 09:03:44.700472919 +0100
++++ nufraw/uf_glib.h	2022-02-23 09:04:50.260308805 +0100
+@@ -13,13 +13,13 @@
+ #ifndef _UF_GLIB_H
+ #define _UF_GLIB_H
+ 
++#include <glib.h>
++#include <glib/gstdio.h>
++
+ #ifdef __cplusplus
+ extern "C" {
+ #endif
+ 
+-#include <glib.h>
+-#include <glib/gstdio.h>
+-
+ // g_win32_locale_filename_from_utf8 is needed only on win32
+ #ifdef _WIN32
+ #define uf_win32_locale_filename_from_utf8(__some_string__) \
diff --git a/srcpkgs/nufraw/patches/exiv-0.28.x.diff b/srcpkgs/nufraw/patches/exiv-0.28.x.diff
new file mode 100644
index 0000000000000..6c23359bf706c
--- /dev/null
+++ b/srcpkgs/nufraw/patches/exiv-0.28.x.diff
@@ -0,0 +1,59 @@
+Patch taken from AUR package: https://aur.archlinux.org/cgit/aur.git/tree/exiv2-error.patch?h=nufraw&id=29e467f2c297fcd0f36548642d6d2cab6428d08f
+diff --git a/nufraw_exiv2.cc b/nufraw_exiv2.cc
+index 2de4cc3..45aea87 100644
+--- a/nufraw_exiv2.cc
++++ b/nufraw_exiv2.cc
+@@ -54,7 +54,7 @@ extern "C" int nufraw_exif_read_input(nufraw_data *uf)
+         uf->inputExifBuf = NULL;
+         uf->inputExifBufLen = 0;
+ 
+-        Exiv2::Image::AutoPtr image;
++        Exiv2::Image::UniquePtr image;
+         if (uf->unzippedBuf != NULL) {
+             image = Exiv2::ImageFactory::open(
+                         (const Exiv2::byte*)uf->unzippedBuf, uf->unzippedBufLen);
+@@ -135,7 +135,7 @@ extern "C" int nufraw_exif_read_input(nufraw_data *uf)
+         nufraw_message(NUFRAW_SET_LOG, "%s\n", stderror.str().c_str());
+ 
+         return NUFRAW_SUCCESS;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (Exiv2::Error& e) {
+         std::cerr.rdbuf(savecerr);
+         std::string s(e.what());
+         nufraw_message(NUFRAW_SET_WARNING, "%s\n", s.c_str());
+@@ -156,7 +156,7 @@ static Exiv2::ExifData nufraw_prepare_exifdata(nufraw_data *uf)
+         if ((pos = exifData.findKey(Exiv2::ExifKey("Exif.Image.Orientation")))
+                 != exifData.end()) {
+             nufraw_message(NUFRAW_SET_LOG, "Resetting %s from '%d' to '1'\n",
+-                          pos->key().c_str(), pos->value().toLong());
++                          pos->key().c_str(), pos->value().toInt64());
+             pos->setValue("1"); /* 1 = Normal orientation */
+         }
+     }
+@@ -327,7 +327,7 @@ extern "C" int nufraw_exif_prepare_output(nufraw_data *uf)
+         nufraw_message(NUFRAW_SET_LOG, "%s\n", stderror.str().c_str());
+ 
+         return NUFRAW_SUCCESS;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (Exiv2::Error& e) {
+         std::cerr.rdbuf(savecerr);
+         std::string s(e.what());
+         nufraw_message(NUFRAW_SET_WARNING, "%s\n", s.c_str());
+@@ -347,7 +347,7 @@ extern "C" int nufraw_exif_write(nufraw_data *uf)
+ 
+         char *filename =
+             uf_win32_locale_filename_from_utf8(uf->conf->outputFilename);
+-        Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open(filename);
++        Exiv2::Image::UniquePtr image = Exiv2::ImageFactory::open(filename);
+         uf_win32_locale_filename_free(filename);
+         assert(image.get() != 0);
+ 
+@@ -367,7 +367,7 @@ extern "C" int nufraw_exif_write(nufraw_data *uf)
+         nufraw_message(NUFRAW_SET_LOG, "%s\n", stderror.str().c_str());
+ 
+         return NUFRAW_SUCCESS;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (Exiv2::Error& e) {
+         std::cerr.rdbuf(savecerr);
+         std::string s(e.what());
+         nufraw_message(NUFRAW_SET_WARNING, "%s\n", s.c_str());
diff --git a/srcpkgs/nufraw/template b/srcpkgs/nufraw/template
new file mode 100644
index 0000000000000..3e5d7d190b335
--- /dev/null
+++ b/srcpkgs/nufraw/template
@@ -0,0 +1,47 @@
+# Template file for 'nufraw'
+pkgname=nufraw
+version=0.43.3
+revision=1
+_ver="${version%.*}-${version##*.}"
+build_style=gnu-configure
+configure_args="--enable-contrast --enable-mime --enable-openmp --with-gimp
+ --enable-extras"
+hostmakedepends="pkg-config automake libtool"
+makedepends="exiv2-devel gimp-devel glib-devel gtkimageview-devel lcms2-devel lensfun-devel
+ jasper-devel"
+depends="desktop-file-utils"
+short_desc="Utility to read and manipulate raw images from digital cameras"
+maintainer="John <me@johnnynator.dev>"
+license="GPL-2.0-or-later"
+homepage="https://sourceforge.net/projects/nufraw/"
+distfiles="${SOURCEFORGE_SITE}/nufraw/nufraw-${_ver}.tar.gz"
+checksum=2c7dcc1590993ec267b3112562b2433010d6f94f6acc6506c76aa29cf8c6c32c
+
+pre_configure() {
+	autoreconf -fi
+}
+
+pre_build() {
+	mv nufraw.desktop{.desktop,}
+	chmod +x generate_schemas.sh
+}
+
+nufraw-gimp_package() {
+	depends="${sourcepkg}>=${version}_${revision}"
+	short_desc+=" - gimp plugin"
+	pkg_install() {
+		vmove usr/lib/gimp
+	}
+}
+
+ufraw_package() {
+	depends="${sourcepkg}>=${version}_${revision}"
+	build_style=meta
+	short_desc+=" (transitional dummy package)"
+}
+
+ufraw-gimp_package() {
+	depends="nufraw-gimp>=${version}_${revision}"
+	build_style=meta
+	short_desc+=" - gimp plugin (transitional dummy package)"
+}
diff --git a/srcpkgs/removed-packages/template b/srcpkgs/removed-packages/template
index abedf26f739b6..f3d81a8afe04c 100644
--- a/srcpkgs/removed-packages/template
+++ b/srcpkgs/removed-packages/template
@@ -1,6 +1,6 @@
 # Template file for 'removed-packages'
 pkgname=removed-packages
-version=0.1.20231019
+version=0.1.20231101
 revision=1
 build_style=meta
 short_desc="Uninstalls packages removed from repository"
@@ -590,8 +590,8 @@ replaces="
  python3-Flask-Assets<=0.12_9
  python3-Flask-Mail<=0.9.1_5
  python3-Flask-OAuthlib<=0.9.6_4
- python3-Flask-Script<=2.0.6_7
  python3-Flask-SQLAlchemy<=2.5.1_4
+ python3-Flask-Script<=2.0.6_7
  python3-Flask-User<=1.0.2.2_6
  python3-SPARQLWrapper<=1.8.4_4
  python3-aiohttp-cors2<=0.7.0_3
@@ -642,8 +642,8 @@ replaces="
  raul-devel<=0.8.0_6
  raul<=0.8.0_6
  redkite<=1.3.1_1
- rem<=2.10.0_1
  rem-devel<=2.10.0_1
+ rem<=2.10.0_1
  reminiscence<=0.4.6_1
  rkt-stage1-coreos<=1.30.0_3
  rkt-stage1-fly<=1.30.0_3
@@ -675,6 +675,8 @@ replaces="
  traverso<=0.49.6_2
  ttyload-git<=20141117_4
  tuxc<=1.1_3
+ ufraw-gimp<=0.22_5
+ ufraw<=0.22_5
  unicorn-python<=1.0.2_2
  upwork<=5.6.10.0_1
  urlmatch-git<=20141116_2
diff --git a/srcpkgs/ufraw b/srcpkgs/ufraw
new file mode 120000
index 0000000000000..0bd1459b2a16f
--- /dev/null
+++ b/srcpkgs/ufraw
@@ -0,0 +1 @@
+nufraw
\ No newline at end of file
diff --git a/srcpkgs/ufraw-gimp b/srcpkgs/ufraw-gimp
index 967dc902dd02b..0bd1459b2a16f 120000
--- a/srcpkgs/ufraw-gimp
+++ b/srcpkgs/ufraw-gimp
@@ -1 +1 @@
-ufraw
\ No newline at end of file
+nufraw
\ No newline at end of file
diff --git a/srcpkgs/ufraw/patches/001-no-gimp-remote.patch b/srcpkgs/ufraw/patches/001-no-gimp-remote.patch
deleted file mode 100644
index ca4f4beb6240f..0000000000000
--- a/srcpkgs/ufraw/patches/001-no-gimp-remote.patch
+++ /dev/null
@@ -1,12 +0,0 @@
-Don't use gimp-remote since gimp 2.4 already includes gimp-remote functionality
---- a/ufraw_conf.c
-+++ b/ufraw_conf.c
-@@ -137,7 +137,7 @@
- #elif HAVE_GIMP_2_4
-     "gimp", /* remoteGimpCommand */
- #else
--    "gimp-remote", /* remoteGimpCommand */
-+    "gimp", /* remoteGimpCommand */
- #endif
- 
-     /* EXIF data */
diff --git a/srcpkgs/ufraw/patches/002-fix_abs_int.patch b/srcpkgs/ufraw/patches/002-fix_abs_int.patch
deleted file mode 100644
index 6fc552769c9f8..0000000000000
--- a/srcpkgs/ufraw/patches/002-fix_abs_int.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- a/dcraw.cc	2015-06-16 05:58:38.000000000 +0200
-+++ b/dcraw.cc	2018-02-04 14:46:54.489951076 +0100
-@@ -9242,7 +9242,7 @@
-     if (make[0] == 'O') {
-       i = find_green (12, 32, 1188864, 3576832);
-       c = find_green (12, 32, 2383920, 2387016);
--      if (abs(i) < abs(c)) {
-+      if (abs((int)i) < abs((int)c)) {
- 	SWAP(i,c);
- 	load_flags = 24;
-       }
diff --git a/srcpkgs/ufraw/patches/03_fix-unsigned-char.patch b/srcpkgs/ufraw/patches/03_fix-unsigned-char.patch
deleted file mode 100644
index 8690f87ca7d59..0000000000000
--- a/srcpkgs/ufraw/patches/03_fix-unsigned-char.patch
+++ /dev/null
@@ -1,14 +0,0 @@
-Source: written by John Paul Adrian Glaubitz for Debian
-Upstream: https://sourceforge.net/p/ufraw/bugs/417
-Reason: fixes a compilation failure on arm architectures
---- a/dcraw.cc
-+++ b/dcraw.cc
-@@ -2285,7 +2285,7 @@ void CLASS quicktake_100_load_raw()
- 
- void CLASS kodak_radc_load_raw()
- {
--  static const char src[] = {
-+  static const signed char src[] = {
-     1,1, 2,3, 3,4, 4,2, 5,7, 6,5, 7,6, 7,8,
-     1,0, 2,1, 3,3, 4,4, 5,2, 6,7, 7,6, 8,5, 8,8,
-     2,1, 2,3, 3,0, 3,2, 3,4, 4,6, 5,5, 6,7, 6,8,
diff --git a/srcpkgs/ufraw/patches/exiv-0.27.patch b/srcpkgs/ufraw/patches/exiv-0.27.patch
deleted file mode 100644
index b5b4140fff8ed..0000000000000
--- a/srcpkgs/ufraw/patches/exiv-0.27.patch
+++ /dev/null
@@ -1,25 +0,0 @@
---- a/ufraw_exiv2.cc	2015-06-16 05:58:38.000000000 +0200
-+++ b/ufraw_exiv2.cc	2018-12-29 22:51:23.291894430 +0100
-@@ -15,9 +15,7 @@
- #include "ufraw.h"
- 
- #ifdef HAVE_EXIV2
--#include <exiv2/image.hpp>
--#include <exiv2/easyaccess.hpp>
--#include <exiv2/exif.hpp>
-+#include <exiv2/exiv2.hpp>
- #include <sstream>
- #include <cassert>
- 
-@@ -67,7 +65,11 @@
-         if (exifData.empty()) {
-             std::string error(uf->filename);
-             error += ": No Exif data found in the file";
-+#if EXIV2_TEST_VERSION(0,27,0)
-+            throw Exiv2::Error(Exiv2::kerErrorMessage, error);
-+#else
-             throw Exiv2::Error(1, error);
-+#endif
-         }
- 
-         /* List of tag names taken from exiv2's printSummary() in actions.cpp */
diff --git a/srcpkgs/ufraw/patches/glib-2.68.patch b/srcpkgs/ufraw/patches/glib-2.68.patch
deleted file mode 100644
index 5b61468f118aa..0000000000000
--- a/srcpkgs/ufraw/patches/glib-2.68.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-From c56f8be3caf1cf3d9a5c80597bdbaf1325faacc0 Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?S=C3=A9rgio=20M=2E=20Basto?= <sergio@serjux.com>
-Date: Tue, 13 Apr 2021 23:45:39 +0100
-Subject: [PATCH] Fix build against glib-2.68 fixes #10
-
----
- uf_glib.h | 6 +++---
- 1 file changed, 3 insertions(+), 3 deletions(-)
-
-diff --git a/uf_glib.h b/uf_glib.h
-index 21c10b19..56cd6971 100644
---- a/uf_glib.h
-+++ b/uf_glib.h
-@@ -13,13 +13,13 @@
- #ifndef _UF_GLIB_H
- #define _UF_GLIB_H
- 
-+#include <glib.h>
-+#include <glib/gstdio.h>
-+
- #ifdef __cplusplus
- extern "C" {
- #endif
- 
--#include <glib.h>
--#include <glib/gstdio.h>
--
- // g_win32_locale_filename_from_utf8 is needed only on win32
- #ifdef _WIN32
- #define uf_win32_locale_filename_from_utf8(__some_string__) \
diff --git a/srcpkgs/ufraw/patches/iostream.patch b/srcpkgs/ufraw/patches/iostream.patch
deleted file mode 100644
index 6d15869f63db8..0000000000000
--- a/srcpkgs/ufraw/patches/iostream.patch
+++ /dev/null
@@ -1,13 +0,0 @@
-ufraw_exiv2.cc:343:10: note: 'std::cerr' is defined in header '<iostream>'
-ufraw_exiv2.cc:365:14: error: 'cerr' is not a member of 'std'
-
---- a/ufraw_exiv2.cc
-+++ b/ufraw_exiv2.cc
-@@ -17,6 +17,7 @@
- #ifdef HAVE_EXIV2
- #include <exiv2/exiv2.hpp>
- #include <sstream>
-+#include <iostream>
- #include <cassert>
- 
- /*
diff --git a/srcpkgs/ufraw/template b/srcpkgs/ufraw/template
deleted file mode 100644
index ceddcacacefb2..0000000000000
--- a/srcpkgs/ufraw/template
+++ /dev/null
@@ -1,38 +0,0 @@
-# Template file for 'ufraw'
-pkgname=ufraw
-version=0.22
-revision=5
-build_style=gnu-configure
-configure_args="--enable-contrast --enable-mime --enable-openmp --with-gimp
- $(vopt_enable extras)"
-hostmakedepends="pkg-config dcraw gettext"
-makedepends="exiv2-devel gimp-devel glib-devel gtkimageview-devel lcms2-devel lensfun-devel
- jasper-devel"
-depends="desktop-file-utils"
-short_desc="Utility to read and manipulate raw images from digital cameras"
-maintainer="John <me@johnnynator.dev>"
-license="GPL-2.0-or-later"
-homepage="http://ufraw.sourceforge.net/"
-distfiles="${SOURCEFORGE_SITE}/ufraw/ufraw/ufraw-${version}/ufraw-${version}.tar.gz"
-checksum=f7abd28ce587db2a74b4c54149bd8a2523a7ddc09bedf4f923246ff0ae09a25e
-
-build_options="extras"
-
-post_patch() {
-	vsed -e 's/default(none)//g' \
-		-i dcraw_indi.c \
-		-i dcraw_api.cc \
-		-i ufraw_ufraw.c \
-		-i ufraw_developer.c
-	vsed -i -e '/DATADIRNAME=/s/=.*/=share/' configure
-	vsed -i -e "s,^localedir =.*,localedir = /usr/share/locale," \
-		po/Makefile.in.in
-}
-
-ufraw-gimp_package() {
-	depends="${sourcepkg}>=${version}_${revision}"
-	short_desc+=" - gimp plugin"
-	pkg_install() {
-		vmove usr/lib/gimp
-	}
-}

^ permalink raw reply	[flat|nested] 27+ messages in thread

* Re: [PR PATCH] [Updated] exiv2: update to 0.28.0.
  2023-10-23  0:10 [PR PATCH] exiv2: update to 0.28.0 mhmdanas
                   ` (2 preceding siblings ...)
  2023-11-01 17:26 ` mhmdanas
@ 2023-11-01 18:11 ` mhmdanas
  2023-11-02 19:42 ` biopsin
                   ` (21 subsequent siblings)
  25 siblings, 0 replies; 27+ messages in thread
From: mhmdanas @ 2023-11-01 18:11 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 1910 bytes --]

There is an updated pull request by mhmdanas against master on the void-packages repository

https://github.com/mhmdanas/void-packages exiv2-0.28.0
https://github.com/void-linux/void-packages/pull/46838

exiv2: update to 0.28.0.
<!-- Uncomment relevant sections and delete options which are not applicable -->

#### Testing the changes
- I tested the changes in this PR: **briefly**

TODO:
- [x] Fix `gwenview`'s failed checks (not really fixed but the exact same tests fail on master as well)
- [ ] `test_exiv2` fails for `libextractor`

@Johnnynator ufraw has been [unmaintained since December 2016](https://sourceforge.net/p/ufraw/discussion/434060/thread/30b4249b/), and it doesn't build with this PR; here are the options:
- remove the package entirely
- replace it with the newer [nufraw](https://sourceforge.net/projects/nufraw/), which already has [an exiv 0.28.x patch floating around](https://aur.archlinux.org/cgit/aur.git/tree/exiv2-error.patch?h=nufraw)
- patch it to build with this PR

What do you think?

<!--
#### New package
- This new package conforms to the [package requirements](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTItest_exiv2NG.md#package-requirements): **YES**|**NO**
-->

<!-- Note: If the build is likely to take more than 2 hours, please add ci skip tag as described in
https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration
and test at least one native build and, if supported, at least one cross build.
Ignore this section if this PR is not skipping CI.
-->
<!--
#### Local build testing
- I built this PR locally for my native architecture, (ARCH-LIBC)
- I built this PR locally for these architectures (if supported. mark crossbuilds):
  - aarch64-musl
  - armv7l
  - armv6l-musl
-->


A patch file from https://github.com/void-linux/void-packages/pull/46838.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-exiv2-0.28.0-46838.patch --]
[-- Type: text/x-diff, Size: 61913 bytes --]

From c24ded872bb81ede65102d92b828d9575252b4f9 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Mon, 23 Oct 2023 01:20:09 +0100
Subject: [PATCH 01/22] inih: add `libINIReader.so.0` common/shlibs entry.

---
 common/shlibs | 1 +
 1 file changed, 1 insertion(+)

diff --git a/common/shlibs b/common/shlibs
index 9036a675c1ae5..8f03a38a16789 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -3905,6 +3905,7 @@ libnotcurses++.so.3 notcurses-3.0.5_1
 libnotcurses-ffi.so.3 notcurses-3.0.5_1
 libevemu.so.3 evemu-2.7.0_1
 libinih.so.0 inih-52_1
+libINIReader.so.0 inih-57_1
 libpcaudio.so.0 pcaudiolib-1.1_1
 libdcerpc-samr.so.0 samba-4.13.2_1
 libdcerpc-server-core.so.0 samba-4.13.2_1

From 3cb90b2a57497f5e65cbfa759bacceee267febf6 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:12 +0100
Subject: [PATCH 02/22] exiv2: update to 0.28.0.

---
 common/shlibs                        |  2 +-
 srcpkgs/exiv2/patches/fix-tests.diff | 31 ++++++++++++++++++++++++++++
 srcpkgs/exiv2/template               | 14 ++++++++-----
 3 files changed, 41 insertions(+), 6 deletions(-)
 create mode 100644 srcpkgs/exiv2/patches/fix-tests.diff

diff --git a/common/shlibs b/common/shlibs
index 8f03a38a16789..0b1d0c89d3e51 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -555,7 +555,7 @@ libgimpcolor-2.0.so.0 libgimp-2.10.0_1
 libgimpmodule-2.0.so.0 libgimp-2.10.0_1
 libgmic.so.3 gmic-3.1.6_1
 libcgmic.so.3 gmic-3.1.6_1
-libexiv2.so.27 exiv2-0.27_1
+libexiv2.so.28 exiv2-0.28.0_1
 libKF5Holidays.so.5 kholidays-5.47.0_1
 libPhabricatorHelpers.so.5 purpose-5.48.0_1
 libKF5PurposeWidgets.so.5 purpose-5.48.0_1
diff --git a/srcpkgs/exiv2/patches/fix-tests.diff b/srcpkgs/exiv2/patches/fix-tests.diff
new file mode 100644
index 0000000000000..3eb7adc1635f3
--- /dev/null
+++ b/srcpkgs/exiv2/patches/fix-tests.diff
@@ -0,0 +1,31 @@
+diff --git a/tests/tiff_test/test_tag_compare.py b/tests/tiff_test/test_tag_compare.py
+index a8538bd2..974d1a9a 100644
+--- a/tests/tiff_test/test_tag_compare.py
++++ b/tests/tiff_test/test_tag_compare.py
+@@ -28,8 +28,8 @@ class OutputTagExtract(metaclass=system_tests.CaseMeta):
+             tmp = line.split()
+ 
+             exif, image, tag = tmp[0].split('.')
+-            self.assertEquals(exif, "Exif")
+-            self.assertEquals(image, "Image")
++            self.assertEqual(exif, "Exif")
++            self.assertEqual(image, "Image")
+ 
+             data.append({
+                 "tag": tag,
+@@ -87,13 +87,13 @@ class OutputTagExtract(metaclass=system_tests.CaseMeta):
+         """
+         for pa_elem, pS_elem in zip(self.pa_data, self.pS_data):
+             for key in ["tag", "type", "len"]:
+-                self.assertEquals(pa_elem[key], pS_elem[key])
++                self.assertEqual(pa_elem[key], pS_elem[key])
+ 
+             if pa_elem["tag"] in [
+                     "ImageWidth", "ImageLength", "BitsPerSample",
+                     "DocumentName", "ImageDescription", "StripOffsets",
+                     "SamplesPerPixel", "StripByteCounts"]:
+-                self.assertEquals(pa_elem["val"], pS_elem["val"])
++                self.assertEqual(pa_elem["val"], pS_elem["val"])
+ 
+     def compare_stdout(self, i, command, got_stdout, expected_stdout):
+         super().compare_stdout(i, command, got_stdout, expected_stdout)
diff --git a/srcpkgs/exiv2/template b/srcpkgs/exiv2/template
index 49985fe82cc14..876b253541d00 100644
--- a/srcpkgs/exiv2/template
+++ b/srcpkgs/exiv2/template
@@ -1,17 +1,17 @@
 # Template file for 'exiv2'
 pkgname=exiv2
-version=0.27.6
+version=0.28.0
 revision=1
 build_style=cmake
 configure_args="-DEXIV2_BUILD_SAMPLES=OFF -DEXIV2_ENABLE_BMFF=ON"
-makedepends="zlib-devel expat-devel"
-checkdepends="gtest-devel"
+makedepends="zlib-devel brotli-devel expat-devel inih-devel"
+checkdepends="gtest-devel python3"
 short_desc="Image metadata manipulation"
 maintainer="Enno Boland <gottox@voidlinux.org>"
 license="GPL-2.0-or-later"
 homepage="https://www.exiv2.org"
 distfiles="https://github.com/Exiv2/exiv2/releases/download/v${version}/exiv2-${version}-Source.tar.gz"
-checksum=4c192483a1125dc59a3d70b30d30d32edace9e14adf52802d2f853abf72db8a6
+checksum=89af3b5ef7277753ef7a7b5374ae017c6b9e304db3b688f1948e73e103491f3d
 
 if [ -n "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DEXIV2_BUILD_UNIT_TESTS=ON"
@@ -21,6 +21,11 @@ if [ -n "$XBPS_CCACHE" ]; then
 	configure_args+=" -DBUILD_WITH_CCACHE=ON"
 fi
 
+pre_check() {
+	# https://github.com/Exiv2/exiv2/issues/2762
+	rm -f tests/bugfixes/github/test_issue_2427.py
+}
+
 exiv2-devel_package() {
 	depends="${makedepends} ${sourcepkg}-${version}_${revision}"
 	short_desc+=" - development files"
@@ -28,7 +33,6 @@ exiv2-devel_package() {
 		vmove usr/include
 		vmove usr/lib/cmake
 		vmove usr/lib/pkgconfig
-		vmove "usr/lib/*.a"
 		vmove "usr/lib/*.so"
 	}
 }

From c770db7b4c73e4a05854124fed22690af0553595 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:37 +0100
Subject: [PATCH 03/22] ART: revbump for exiv2-0.28.0.

---
 srcpkgs/ART/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/ART/template b/srcpkgs/ART/template
index b6c47fc6c4cdf..94c7aa0378061 100644
--- a/srcpkgs/ART/template
+++ b/srcpkgs/ART/template
@@ -1,7 +1,7 @@
 # Template file for 'ART'
 pkgname=ART
 version=1.20.2
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="pkg-config"
 makedepends="fftw-devel gtkmm-devel lensfun-devel

From 0d3804c726646adf7e379cbe692d26d242e6e580 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 04/22] darktable: revbump for exiv2-0.28.0.

---
 srcpkgs/darktable/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/darktable/template b/srcpkgs/darktable/template
index 60415a34dc018..3d35571239a93 100644
--- a/srcpkgs/darktable/template
+++ b/srcpkgs/darktable/template
@@ -1,7 +1,7 @@
 # Template file for 'darktable'
 pkgname=darktable
 version=4.4.2
-revision=2
+revision=3
 # upstream only supports these archs:
 archs="x86_64* aarch64* ppc64le*"
 build_style=cmake

From 7e8d45a2e180cd2036b1c81054e20689d00b5a06 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 05/22] digikam: revbump for exiv2-0.28.0.

---
 srcpkgs/digikam/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/digikam/template b/srcpkgs/digikam/template
index 206185f565488..4784bf7d62a8e 100644
--- a/srcpkgs/digikam/template
+++ b/srcpkgs/digikam/template
@@ -1,7 +1,7 @@
 # Template file for 'digikam'
 pkgname=digikam
 version=8.1.0
-revision=1
+revision=2
 build_style=cmake
 configure_args="-DBUILD_TESTING=OFF"
 hostmakedepends="extra-cmake-modules gettext pkg-config bison flex qt5-qmake

From 27a5d8f2a60ae766ad1be21809edb672abb319b8 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 06/22] geeqie: revbump for exiv2-0.28.0.

---
 srcpkgs/geeqie/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/geeqie/template b/srcpkgs/geeqie/template
index b5f958f854c1b..b494bc149e957 100644
--- a/srcpkgs/geeqie/template
+++ b/srcpkgs/geeqie/template
@@ -1,7 +1,7 @@
 # Template file for 'geeqie'
 pkgname=geeqie
 version=2.1
-revision=1
+revision=2
 build_style=meson
 hostmakedepends="pkg-config gettext xxd gdk-pixbuf-devel glib-devel"
 makedepends="gtk+3-devel glib-devel lcms2-devel exiv2-devel libheif-devel

From 096ef0a8962dcae5f6c4de4d702858a861a50189 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 07/22] gthumb: revbump for exiv2-0.28.0.

---
 srcpkgs/gthumb/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/gthumb/template b/srcpkgs/gthumb/template
index c8e19f0dedb61..732d5e1c6089f 100644
--- a/srcpkgs/gthumb/template
+++ b/srcpkgs/gthumb/template
@@ -1,7 +1,7 @@
 # Template file for 'gthumb'
 pkgname=gthumb
 version=3.12.3
-revision=1
+revision=2
 build_style=meson
 hostmakedepends="gettext pkg-config itstool glib-devel"
 makedepends="webkit2gtk-devel json-glib-devel libsecret-devel librsvg-devel

From fb9c21d01088e0f7aa4ca4fe99fa5497c34f6e45 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 08/22] gwenview: revbump for exiv2-0.28.0.

---
 srcpkgs/gwenview/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/gwenview/template b/srcpkgs/gwenview/template
index 73d450a458c4d..eb876cfadcfe8 100644
--- a/srcpkgs/gwenview/template
+++ b/srcpkgs/gwenview/template
@@ -1,7 +1,7 @@
 # Template file for 'gwenview'
 pkgname=gwenview
 version=23.08.2
-revision=1
+revision=2
 build_style=cmake
 build_helper=qemu
 hostmakedepends="extra-cmake-modules pkg-config qt5-qmake qt5-host-tools

From 803aa9fc8cd0eda481b635a9633ac0ef52368c9d Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 09/22] hugin: revbump for exiv2-0.28.0.

---
 srcpkgs/hugin/patches/exiv2-0.28.patch | 77 ++++++++++++++++++++++++++
 srcpkgs/hugin/template                 |  2 +-
 2 files changed, 78 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/hugin/patches/exiv2-0.28.patch

diff --git a/srcpkgs/hugin/patches/exiv2-0.28.patch b/srcpkgs/hugin/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..49f0518117020
--- /dev/null
+++ b/srcpkgs/hugin/patches/exiv2-0.28.patch
@@ -0,0 +1,77 @@
+Patch-Source: https://gitlab.archlinux.org/archlinux/packaging/packages/hugin/-/blob/main/exiv2-0.28.patch
+diff -r 79cd11a7a66f src/hugin_base/panodata/Exiv2Helper.cpp
+--- a/src/hugin_base/panodata/Exiv2Helper.cpp	Wed May 24 19:13:20 2023 +0200
++++ b/src/hugin_base/panodata/Exiv2Helper.cpp	Mon Jun 05 00:31:19 2023 +0200
+@@ -40,7 +40,7 @@
+             Exiv2::ExifData::iterator itr = exifData.findKey(Exiv2::ExifKey(keyName));
+             if (itr != exifData.end() && itr->count())
+             {
+-                value = itr->toLong();
++                value = itr->toUint32();
+                 return true;
+             }
+             else
+@@ -165,7 +165,7 @@
+         {
+             if(it!=exifData.end() && it->count())
+             {
+-                return it->toLong();
++                return it->toUint32();
+             }
+             return 0;
+         };
+@@ -600,4 +600,4 @@
+         };
+ 
+     }; //namespace Exiv2Helper
+-}; //namespace HuginBase
+\ No newline at end of file
++}; //namespace HuginBase
+diff -r 79cd11a7a66f src/hugin_base/panodata/SrcPanoImage.cpp
+--- a/src/hugin_base/panodata/SrcPanoImage.cpp	Wed May 24 19:13:20 2023 +0200
++++ b/src/hugin_base/panodata/SrcPanoImage.cpp	Mon Jun 05 00:31:19 2023 +0200
+@@ -384,7 +384,7 @@
+                     pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaImageWidthPixels"));
+                     if (pos != xmpData.end())
+                     {
+-                        croppedWidth = pos->toLong();
++                        croppedWidth = pos->toUint32();
+                     }
+                     else
+                     {
+@@ -394,7 +394,7 @@
+                     pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaImageHeightPixels"));
+                     if (pos != xmpData.end())
+                     {
+-                        croppedHeight = pos->toLong();
++                        croppedHeight = pos->toUint32();
+                     }
+                     else
+                     {
+@@ -408,7 +408,7 @@
+                         double hfov = 0;
+                         if (pos != xmpData.end())
+                         {
+-                            hfov = 360 * croppedWidth / (double)pos->toLong();
++                            hfov = 360 * croppedWidth / (double)pos->toUint32();
+                         }
+                         else
+                         {
+@@ -419,7 +419,7 @@
+                         pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.FullPanoHeightPixels"));
+                         if (pos != xmpData.end())
+                         {
+-                            fullHeight = pos->toLong();
++                            fullHeight = pos->toUint32();
+                         }
+                         else
+                         {
+@@ -430,7 +430,7 @@
+                         pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaTopPixels"));
+                         if (pos != xmpData.end())
+                         {
+-                            cropTop = pos->toLong();
++                            cropTop = pos->toUint32();
+                         }
+                         else
+                         {
diff --git a/srcpkgs/hugin/template b/srcpkgs/hugin/template
index f96d2f6e27d42..ce71f6e4cbb2d 100644
--- a/srcpkgs/hugin/template
+++ b/srcpkgs/hugin/template
@@ -1,7 +1,7 @@
 # Template file for 'hugin'
 pkgname=hugin
 version=2022.0.0
-revision=10
+revision=11
 build_style=cmake
 build_helper=cmake-wxWidgets-gtk3
 pycompile_dirs="usr/share/hugin/data/plugins usr/share/hugin/data/plugins-templates"

From ecb668d882d5e51f45a26666473251717ca0b6c3 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 10/22] kfilemetadata5: revbump for exiv2-0.28.0.

---
 srcpkgs/kfilemetadata5/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/kfilemetadata5/template b/srcpkgs/kfilemetadata5/template
index 00f7a98cf6399..e294ae5af947c 100644
--- a/srcpkgs/kfilemetadata5/template
+++ b/srcpkgs/kfilemetadata5/template
@@ -1,7 +1,7 @@
 # Template file for 'kfilemetadata5'
 pkgname=kfilemetadata5
 version=5.111.0
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="kcoreaddons extra-cmake-modules pkg-config qt5-host-tools qt5-qmake
  gettext kcoreaddons python3"

From 710c8361aa0e2e5f40a075533e5c68c726573b7f Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 11/22] krename: revbump for exiv2-0.28.0.

---
 srcpkgs/krename/patches/e7dd767a.patch | 90 ++++++++++++++++++++++++++
 srcpkgs/krename/template               |  2 +-
 2 files changed, 91 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/krename/patches/e7dd767a.patch

diff --git a/srcpkgs/krename/patches/e7dd767a.patch b/srcpkgs/krename/patches/e7dd767a.patch
new file mode 100644
index 0000000000000..a0ef428ce46b1
--- /dev/null
+++ b/srcpkgs/krename/patches/e7dd767a.patch
@@ -0,0 +1,90 @@
+Patch-Source: https://invent.kde.org/utilities/krename/-/commit/e7dd767a
+From e7dd767a9a1068ee1fe1502c4d619b57d3b12add Mon Sep 17 00:00:00 2001
+From: Andreas Sturmlechner <asturm@gentoo.org>
+Date: Fri, 26 May 2023 23:23:10 +0200
+Subject: [PATCH] Fix build with >=exiv2-0.28, raise minimum to 0.27
+
+- enables use of EXIV2_TEST_VERSION macro
+- exiv2 headers cleanup
+
+Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>
+---
+ CMakeLists.txt         |  6 +-----
+ config-krename.h.cmake |  3 ---
+ src/exiv2plugin.cpp    | 17 +++++------------
+ 3 files changed, 6 insertions(+), 20 deletions(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 0bda8ac..72e7297 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -56,13 +56,9 @@ set_package_properties(Taglib PROPERTIES
+     TYPE OPTIONAL)
+ 
+ # Find exiv2
+-find_package(LibExiv2 0.13) # AccessMode was added in 0.13
++find_package(LibExiv2 0.27) # EXIV2_TEST_VERSION was added in 0.27
+ set_package_properties(LibExiv2 PROPERTIES TYPE OPTIONAL)
+ 
+-if (LibExiv2_VERSION VERSION_GREATER_EQUAL "0.27")
+-    set(HAVE_LIBEXIV2_0_27 TRUE)
+-endif()
+-
+ # Find podofo
+ find_package(PoDoFo)
+ set_package_properties(PoDoFo PROPERTIES
+diff --git a/config-krename.h.cmake b/config-krename.h.cmake
+index 76c3d30..862e40b 100644
+--- a/config-krename.h.cmake
++++ b/config-krename.h.cmake
+@@ -6,9 +6,6 @@
+ /* have Exiv2 */
+ #cmakedefine01 HAVE_EXIV2
+ 
+-/* Defined if we have libexiv2 >= 0.27 */
+-#cmakedefine HAVE_LIBEXIV2_0_27
+-
+ /* have PoDoFo */
+ #cmakedefine01 HAVE_PODOFO
+ 
+diff --git a/src/exiv2plugin.cpp b/src/exiv2plugin.cpp
+index 5694d8c..25e8869 100644
+--- a/src/exiv2plugin.cpp
++++ b/src/exiv2plugin.cpp
+@@ -3,20 +3,9 @@
+ 
+ #include "exiv2plugin.h"
+ 
+-#include "../config-krename.h"
+-
+ #include <KLocalizedString>
+ 
+-#include <exiv2/error.hpp>
+-#include <exiv2/exif.hpp>
+-#include <exiv2/image.hpp>
+-#include <exiv2/iptc.hpp>
+-#ifdef HAVE_LIBEXIV2_0_27
+-    #include <exiv2/xmp_exiv2.hpp>
+-#else
+-    #include <exiv2/xmp.hpp>
+-#endif
+-#include <exiv2/tags.hpp>
++#include <exiv2/exiv2.hpp>
+ 
+ #include "batchrenamer.h"
+ #include "tokenhelpdialog.h"
+@@ -381,7 +370,11 @@ QString Exiv2Plugin::processFile(BatchRenamer *b, int index, const QString &file
+     std::string strFilename(asc.constData(), asc.length());
+ 
+     try {
++#if EXIV2_TEST_VERSION(0,28,0)
++        Image::UniquePtr image = Exiv2::ImageFactory::open(strFilename);
++#else
+         Image::AutoPtr image = Exiv2::ImageFactory::open(strFilename);
++#endif
+         if (image.get() != nullptr && image->good()) {
+             image->readMetadata();
+ 
+-- 
+GitLab
+
diff --git a/srcpkgs/krename/template b/srcpkgs/krename/template
index 66023163e3293..df5535007714a 100644
--- a/srcpkgs/krename/template
+++ b/srcpkgs/krename/template
@@ -1,7 +1,7 @@
 # Template file for 'krename'
 pkgname=krename
 version=5.0.2
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="extra-cmake-modules gettext kcoreaddons pkg-config qt5-host-tools qt5-qmake"
 makedepends="exiv2-devel freetype-devel kjs-devel kparts-devel libpodofo-devel

From 86e47a7365d59ef2ae477e4dc591e0a8954786d2 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 12/22] krita: revbump for exiv2-0.28.0.

---
 srcpkgs/krita/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/krita/template b/srcpkgs/krita/template
index a4d3de04b049f..b479e0db798ee 100644
--- a/srcpkgs/krita/template
+++ b/srcpkgs/krita/template
@@ -1,7 +1,7 @@
 # Template file for 'krita'
 pkgname=krita
 version=5.2.0
-revision=1
+revision=2
 build_style=cmake
 configure_args="-Wno-dev -DBUILD_TESTING=OFF"
 hostmakedepends="extra-cmake-modules gettext pkg-config python3

From 19f8c98058c10e2fc1a7a2abaedcf7ae04668c14 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 13/22] libextractor: revbump for exiv2-0.28.0.

---
 srcpkgs/libextractor/patches/exiv2-0.28.patch | 286 ++++++++++++++++++
 srcpkgs/libextractor/template                 |   2 +-
 2 files changed, 287 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/libextractor/patches/exiv2-0.28.patch

diff --git a/srcpkgs/libextractor/patches/exiv2-0.28.patch b/srcpkgs/libextractor/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..270a626d8ab06
--- /dev/null
+++ b/srcpkgs/libextractor/patches/exiv2-0.28.patch
@@ -0,0 +1,286 @@
+Patch-Source: https://gitlab.archlinux.org/archlinux/packaging/packages/libextractor/-/blob/main/exiv2-0.28.patch
+diff --git a/src/plugins/exiv2_extractor.cc b/src/plugins/exiv2_extractor.cc
+index 78f9bda..d32ed6a 100644
+--- a/src/plugins/exiv2_extractor.cc
++++ b/src/plugins/exiv2_extractor.cc
+@@ -90,7 +90,11 @@ virtual int close ();
+  * @param rcount number of bytes to read
+  * @return buffer with data read, empty buffer (!) on failure (!)
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++virtual Exiv2::DataBuf read (size_t rcount);
++#else
+ virtual Exiv2::DataBuf read (long rcount);
++#endif
+ 
+ /**
+  * Read up to 'rcount' bytes into 'buf'.
+@@ -99,8 +103,17 @@ virtual Exiv2::DataBuf read (long rcount);
+  * @param rcount size of 'buf'
+  * @return number of bytes read successfully, 0 on failure (!)
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++virtual size_t read (Exiv2::byte *buf,
++                   size_t rcount);
++#else
+ virtual long read (Exiv2::byte *buf,
+                    long rcount);
++#endif
++
++#if EXIV2_TEST_VERSION (0,28,0)
++virtual void populateFakeData();
++#endif
+ 
+ /**
+  * Read a single character.
+@@ -117,8 +130,13 @@ virtual int getb ();
+  * @param wcount how many bytes to write
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual size_t write (const Exiv2::byte *data,
++                    size_t wcount);
++#else
+ virtual long write (const Exiv2::byte *data,
+                     long wcount);
++#endif
+ 
+ /**
+  * Write to stream.
+@@ -126,7 +144,11 @@ virtual long write (const Exiv2::byte *data,
+  * @param src stream to copy
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual size_t write (Exiv2::BasicIo &src);
++#else
+ virtual long write (Exiv2::BasicIo &src);
++#endif
+ 
+ /**
+  * Write a single byte.
+@@ -172,7 +194,11 @@ virtual int munmap ();
+  *
+  * @return -1 on error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual size_t tell (void) const;
++#else
+ virtual long int tell (void) const;
++#endif
+ 
+ /**
+  * Return overall size of the file.
+@@ -213,7 +239,11 @@ virtual bool eof () const;
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual const std::string& path () const noexcept;
++#else
+ virtual std::string path () const;
++#endif
+ 
+ #ifdef EXV_UNICODE_PATH
+ /**
+@@ -230,7 +260,11 @@ virtual std::wstring wpath () const;
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual Exiv2::BasicIo::UniquePtr temporary () const;
++#else
+ virtual Exiv2::BasicIo::AutoPtr temporary () const;
++#endif
+ 
+ };
+ 
+@@ -266,7 +300,11 @@ ExtractorIO::close ()
+  * @return buffer with data read, empty buffer (!) on failure (!)
+  */
+ Exiv2::DataBuf
++#if EXIV2_TEST_VERSION (0,28,0)
++ExtractorIO::read (size_t rcount)
++#else
+ ExtractorIO::read (long rcount)
++#endif
+ {
+   void *data;
+   ssize_t ret;
+@@ -284,9 +322,15 @@ ExtractorIO::read (long rcount)
+  * @param rcount size of 'buf'
+  * @return number of bytes read successfully, 0 on failure (!)
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++size_t
++ExtractorIO::read (Exiv2::byte *buf,
++                   size_t rcount)
++#else
+ long
+ ExtractorIO::read (Exiv2::byte *buf,
+                    long rcount)
++#endif
+ {
+   void *data;
+   ssize_t ret;
+@@ -305,6 +349,12 @@ ExtractorIO::read (Exiv2::byte *buf,
+   return got;
+ }
+ 
++#if EXIV2_TEST_VERSION (0,28,0)
++void ExtractorIO::populateFakeData()
++{
++  return;
++}
++#endif
+ 
+ /**
+  * Read a single character.
+@@ -319,7 +369,9 @@ ExtractorIO::getb ()
+   const unsigned char *r;
+ 
+   if (1 != ec->read (ec->cls, &data, 1))
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION(0,28,0)
++    throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+     throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+     throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -336,9 +388,15 @@ ExtractorIO::getb ()
+  * @param wcount how many bytes to write
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++size_t
++ExtractorIO::write (const Exiv2::byte *data,
++                    size_t wcount)
++#else
+ long
+ ExtractorIO::write (const Exiv2::byte *data,
+                     long wcount)
++#endif
+ {
+   return -1;
+ }
+@@ -350,7 +408,11 @@ ExtractorIO::write (const Exiv2::byte *data,
+  * @param src stream to copy
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++size_t
++#else
+ long
++#endif
+ ExtractorIO::write (Exiv2::BasicIo &src)
+ {
+   return -1;
+@@ -378,7 +440,9 @@ ExtractorIO::putb (Exiv2::byte data)
+ void
+ ExtractorIO::transfer (Exiv2::BasicIo& src)
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION(0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -427,7 +491,9 @@ ExtractorIO::seek (long offset,
+ Exiv2::byte *
+ ExtractorIO::mmap (bool isWritable)
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION (0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -452,7 +518,11 @@ ExtractorIO::munmap ()
+  *
+  * @return -1 on error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++size_t
++#else
+ long int
++#endif
+ ExtractorIO::tell (void) const
+ {
+   return (long) ec->seek (ec->cls, 0, SEEK_CUR);
+@@ -516,10 +586,17 @@ ExtractorIO::eof () const
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++const std::string&
++ExtractorIO::path () const noexcept
++#else
+ std::string
+ ExtractorIO::path () const
++#endif
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION (0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -536,7 +613,9 @@ ExtractorIO::path () const
+ std::wstring
+ ExtractorIO::wpath () const
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION (0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -552,11 +631,17 @@ ExtractorIO::wpath () const
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++Exiv2::BasicIo::UniquePtr
++#else
+ Exiv2::BasicIo::AutoPtr
++#endif
+ ExtractorIO::temporary () const
+ {
+   fprintf (stderr, "throwing temporary error\n");
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION(0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -737,8 +822,13 @@ EXTRACTOR_exiv2_extract_method (struct EXTRACTOR_ExtractContext *ec)
+ #if ! EXIV2_TEST_VERSION (0,24,0)
+     Exiv2::LogMsg::setLevel (Exiv2::LogMsg::mute);
+ #endif
++#if EXIV2_TEST_VERSION(0,28,0)
++    std::unique_ptr<Exiv2::BasicIo> eio (new ExtractorIO (ec));
++    Exiv2::Image::UniquePtr image = Exiv2::ImageFactory::open (std::move(eio));
++#else
+     std::auto_ptr<Exiv2::BasicIo> eio (new ExtractorIO (ec));
+     Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open (eio);
++#endif
+     if (0 == image.get ())
+       return;
+     image->readMetadata ();
+@@ -822,7 +912,11 @@ EXTRACTOR_exiv2_extract_method (struct EXTRACTOR_ExtractContext *ec)
+       ADDXMP ("Xmp.lr.hierarchicalSubject", EXTRACTOR_METATYPE_SUBJECT);
+     }
+   }
++#if EXIV2_TEST_VERSION (0,28,0)
++  catch (const Exiv2::Error& e)
++#else
+   catch (const Exiv2::AnyError& e)
++#endif
+   {
+ #if DEBUG
+     std::cerr << "Caught Exiv2 exception '" << e << "'\n";
diff --git a/srcpkgs/libextractor/template b/srcpkgs/libextractor/template
index ddd4790f93e88..bfcea979a308c 100644
--- a/srcpkgs/libextractor/template
+++ b/srcpkgs/libextractor/template
@@ -1,7 +1,7 @@
 # Template file for 'libextractor'
 pkgname=libextractor
 version=1.11
-revision=2
+revision=3
 build_style=gnu-configure
 configure_args="--disable-static"
 hostmakedepends="pkg-config"

From ffff9172b168a9a5cbef1b8bbc6619c091ed6c86 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 14/22] libgexiv2: update to 0.14.2.

---
 srcpkgs/libgexiv2/template | 14 +++++++-------
 1 file changed, 7 insertions(+), 7 deletions(-)

diff --git a/srcpkgs/libgexiv2/template b/srcpkgs/libgexiv2/template
index 23780e5397dc4..91dbcaa9aca52 100644
--- a/srcpkgs/libgexiv2/template
+++ b/srcpkgs/libgexiv2/template
@@ -1,19 +1,19 @@
 # Template file for 'libgexiv2'
 pkgname=libgexiv2
-version=0.14.0
-revision=3
+version=0.14.2
+revision=1
 build_style=meson
 build_helper="gir"
-configure_args="-Dintrospection=$(vopt_if gir true false)
- -Dvapi=$(vopt_if vala true false)"
+configure_args="$(vopt_bool gir introspection) $(vopt_bool vala vapi)"
 hostmakedepends="pkg-config glib-devel $(vopt_if vala 'vala') python3-gobject"
 makedepends="libglib-devel exiv2-devel"
 short_desc="GObject-based wrapper around the Exiv2 library"
 maintainer="Enno Boland <gottox@voidlinux.org>"
 license="GPL-2.0-or-later"
 homepage="https://wiki.gnome.org/Projects/gexiv2"
-distfiles="${GNOME_SITE}/gexiv2/${version%.*}/${pkgname/lib/}-${version}.tar.xz"
-checksum=e58279a6ff20b6f64fa499615da5e9b57cf65ba7850b72fafdf17221a9d6d69e
+changelog="https://gitlab.gnome.org/GNOME/gexiv2/-/raw/master/NEWS"
+distfiles="${GNOME_SITE}/gexiv2/${version%.*}/gexiv2-${version}.tar.xz"
+checksum=2a0c9cf48fbe8b3435008866ffd40b8eddb0667d2212b42396fdf688e93ce0be
 
 build_options="gir vala"
 build_options_default="gir vala"
@@ -23,7 +23,7 @@ libgexiv2-devel_package() {
 	short_desc+=" - development files"
 	pkg_install() {
 		vmove usr/include
-		vmove usr/lib/*.so
+		vmove "usr/lib/*.so"
 		vmove usr/lib/pkgconfig
 		if [ "$build_option_vala" ]; then
 			vmove usr/share/vala

From fd0e905656e5bb90b5d58bc4c5180d424b55ee2e Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 15/22] libkexiv25: update to 23.08.2.

---
 srcpkgs/libkexiv25/template | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/srcpkgs/libkexiv25/template b/srcpkgs/libkexiv25/template
index b439a42ef2b97..4d7f9600572ea 100644
--- a/srcpkgs/libkexiv25/template
+++ b/srcpkgs/libkexiv25/template
@@ -1,6 +1,6 @@
 # Template file for 'libkexiv25'
 pkgname=libkexiv25
-version=23.04.0
+version=23.08.2
 revision=1
 build_style=cmake
 configure_args="-DBUILD_TESTING=OFF"
@@ -11,7 +11,7 @@ maintainer="Orphaned <orphan@voidlinux.org>"
 license="GPL-2.0-or-later"
 homepage="https://invent.kde.org/graphics/libkexiv2"
 distfiles="${KDE_SITE}/release-service/${version}/src/libkexiv2-${version}.tar.xz"
-checksum=18d3eed06df9d1e31d8434ed9887e305aba176d0856e19a8cd3bdb555b80d391
+checksum=d06e36a408bf2e846a18056a1f15e61d981fa2a1fceb81f7c15136604319d033
 
 libkexiv25-devel_package() {
 	short_desc+=" - development files"

From 5b521eed1195e26ac1f2825a421c9ed0ac1493b3 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 16/22] nomacs: update to 3.17.2287.

---
 srcpkgs/nomacs/template | 17 +++++++++++++----
 1 file changed, 13 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/nomacs/template b/srcpkgs/nomacs/template
index c52cd54e294db..956bd21ebb129 100644
--- a/srcpkgs/nomacs/template
+++ b/srcpkgs/nomacs/template
@@ -1,7 +1,8 @@
 # Template file for 'nomacs'
 pkgname=nomacs
-version=3.16.224
-revision=5
+version=3.17.2287
+revision=1
+_plugins_ver=3.17.2285
 build_wrksrc=ImageLounge
 build_style=cmake
 configure_args="-DCMAKE_BUILD_TYPE=None -DENABLE_TRANSLATIONS=1
@@ -13,5 +14,13 @@ short_desc="Simple yet powerful Qt imageviewer"
 maintainer="Orphaned <orphan@voidlinux.org>"
 license="GPL-3.0-or-later"
 homepage="https://github.com/nomacs/nomacs"
-distfiles="https://github.com/nomacs/nomacs/archive/${version}.tar.gz"
-checksum=bbc7e9048026ef9e0d2b64902c88050f17a679ef3d3c009de2c3b7de5d1d217c
+distfiles="https://github.com/nomacs/nomacs/archive/${version}.tar.gz
+ https://github.com/novomesk/nomacs-plugins/archive/refs/tags/${_plugins_ver}.tar.gz>plugins.tar.gz"
+checksum="6905ea615358f84a0c83d5b1b7077871dea0526ec667500a1951448cb845a92c
+ 946b2d754be9ecca5cb155f7ecc5dcafb164f6c3dcc7bf5c3c0610d3b47774aa"
+skip_extraction="plugins.tar.gz"
+
+post_extract() {
+ cd ${build_wrksrc}
+ vsrcextract -C plugins "plugins.tar.gz"
+}

From 99075796b9f5817b6fe88fa95de3c6e8b503ae4c Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 17/22] pdf2djvu: revbump for exiv2-0.28.0.

---
 srcpkgs/pdf2djvu/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/pdf2djvu/template b/srcpkgs/pdf2djvu/template
index ef7433c0c98ae..5a6f3ddf4ed35 100644
--- a/srcpkgs/pdf2djvu/template
+++ b/srcpkgs/pdf2djvu/template
@@ -1,7 +1,7 @@
 # Template file for 'pdf2djvu'
 pkgname=pdf2djvu
 version=0.9.19
-revision=4
+revision=5
 build_style=gnu-configure
 hostmakedepends="pkg-config djvulibre gettext"
 makedepends="djvulibre-devel poppler-devel libgraphicsmagick-devel exiv2-devel libuuid-devel"

From 8359c0be8f4dc078f30bbb53c7ae9859f31d60c4 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 18/22] phototonic: revbump for exiv2-0.28.0.

---
 srcpkgs/phototonic/patches/exiv2-0.28.patch | 135 ++++++++++++++++++++
 srcpkgs/phototonic/template                 |   2 +-
 2 files changed, 136 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/phototonic/patches/exiv2-0.28.patch

diff --git a/srcpkgs/phototonic/patches/exiv2-0.28.patch b/srcpkgs/phototonic/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..1c75b628dab33
--- /dev/null
+++ b/srcpkgs/phototonic/patches/exiv2-0.28.patch
@@ -0,0 +1,135 @@
+From 923a3fc14de0b779a45696c5f0aef34c74d84f13 Mon Sep 17 00:00:00 2001
+From: Andreas Sturmlechner <asturm@gentoo.org>
+Date: Sun, 28 May 2023 18:54:10 +0200
+Subject: [PATCH] Fix build with exiv2-0.28
+
+Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>
+---
+ ImageViewer.cpp   | 9 +++++++++
+ MetadataCache.cpp | 8 ++++++++
+ Phototonic.cpp    | 4 ++++
+ Tags.cpp          | 8 ++++++++
+ ThumbsViewer.cpp  | 4 ++++
+ 5 files changed, 33 insertions(+)
+
+diff --git a/ImageViewer.cpp b/ImageViewer.cpp
+index 357d223..df3ac43 100644
+--- a/ImageViewer.cpp
++++ b/ImageViewer.cpp
+@@ -945,7 +945,11 @@ void ImageViewer::keyMoveEvent(int direction) {
+ }
+ 
+ void ImageViewer::saveImage() {
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr image;
++#else
+     Exiv2::Image::AutoPtr image;
++#endif
+     bool exifError = false;
+ 
+     if (newImage) {
+@@ -985,8 +989,13 @@ void ImageViewer::saveImage() {
+ }
+ 
+ void ImageViewer::saveImageAs() {
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++    Exiv2::Image::UniquePtr newExifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
+     Exiv2::Image::AutoPtr newExifImage;
++#endif
+     bool exifError = false;
+ 
+     setCursorHiding(false);
+diff --git a/MetadataCache.cpp b/MetadataCache.cpp
+index 524ae74..5ddd4c8 100644
+--- a/MetadataCache.cpp
++++ b/MetadataCache.cpp
+@@ -64,7 +64,11 @@ void MetadataCache::clear() {
+ }
+ 
+ bool MetadataCache::loadImageMetadata(const QString &imageFullPath) {
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
++#endif
+     QSet<QString> tags;
+     long orientation = 0;
+ 
+@@ -78,7 +82,11 @@ bool MetadataCache::loadImageMetadata(const QString &imageFullPath) {
+     try {
+         Exiv2::ExifData &exifData = exifImage->exifData();
+         if (!exifData.empty()) {
++#if EXIV2_TEST_VERSION(0,28,0)
++            orientation = exifData["Exif.Image.Orientation"].value().toUint32();
++#else
+             orientation = exifData["Exif.Image.Orientation"].value().toLong();
++#endif
+         }
+     } catch (Exiv2::Error &error) {
+         qWarning() << "Failed to read Exif metadata";
+diff --git a/Phototonic.cpp b/Phototonic.cpp
+index 6cc95b3..bd5497d 100644
+--- a/Phototonic.cpp
++++ b/Phototonic.cpp
+@@ -3151,7 +3151,11 @@ void Phototonic::removeMetadata() {
+ 
+     if (ret == MessageBox::Yes) {
+         for (int file = 0; file < fileList.size(); ++file) {
++#if EXIV2_TEST_VERSION(0,28,0)
++            Exiv2::Image::UniquePtr image;
++#else
+             Exiv2::Image::AutoPtr image;
++#endif
+             try {
+                 image = Exiv2::ImageFactory::open(fileList[file].toStdString());
+                 image->clearMetadata();
+diff --git a/Tags.cpp b/Tags.cpp
+index 84eea16..a62da9d 100644
+--- a/Tags.cpp
++++ b/Tags.cpp
+@@ -136,7 +136,11 @@ void ImageTags::addTag(QString tagName, bool tagChecked) {
+ 
+ bool ImageTags::writeTagsToImage(QString &imageFileName, QSet<QString> &newTags) {
+     QSet<QString> imageTags;
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
++#endif
+ 
+     try {
+         exifImage = Exiv2::ImageFactory::open(imageFileName.toStdString());
+@@ -160,7 +164,11 @@ bool ImageTags::writeTagsToImage(QString &imageFileName, QSet<QString> &newTags)
+         QSetIterator<QString> newTagsIt(newTags);
+         while (newTagsIt.hasNext()) {
+             QString tag = newTagsIt.next();
++#if EXIV2_TEST_VERSION(0,28,0)
++            Exiv2::Value::UniquePtr value = Exiv2::Value::create(Exiv2::string);
++#else
+             Exiv2::Value::AutoPtr value = Exiv2::Value::create(Exiv2::string);
++#endif
+             value->read(tag.toStdString());
+             Exiv2::IptcKey key("Iptc.Application2.Keywords");
+             newIptcData.add(key, value.get());
+diff --git a/ThumbsViewer.cpp b/ThumbsViewer.cpp
+index 77a6189..4a11475 100644
+--- a/ThumbsViewer.cpp
++++ b/ThumbsViewer.cpp
+@@ -210,7 +210,11 @@ void ThumbsViewer::updateImageInfoViewer(QString imageFullPath) {
+         infoView->addEntry(key, val);
+     }
+ 
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
++#endif
+     try {
+         exifImage = Exiv2::ImageFactory::open(imageFullPath.toStdString());
+         exifImage->readMetadata();
+-- 
+2.40.1
+
diff --git a/srcpkgs/phototonic/template b/srcpkgs/phototonic/template
index 77ae8bf6a4406..4af006cb7da41 100644
--- a/srcpkgs/phototonic/template
+++ b/srcpkgs/phototonic/template
@@ -1,7 +1,7 @@
 # Template file for 'phototonic'
 pkgname=phototonic
 version=2.1
-revision=3
+revision=4
 build_style=qmake
 hostmakedepends="pkg-config qt5-qmake qt5-host-tools"
 makedepends="qt5-svg-devel exiv2-devel"

From 9677bc84cd49885c0422c230011c5447ccc542ea Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 19/22] qimgv: revbump for exiv2-0.28.0.

---
 srcpkgs/qimgv/patches/exiv2-0.28.patch | 16 ++++++++++++++++
 srcpkgs/qimgv/template                 |  2 +-
 2 files changed, 17 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/qimgv/patches/exiv2-0.28.patch

diff --git a/srcpkgs/qimgv/patches/exiv2-0.28.patch b/srcpkgs/qimgv/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..11f37b5ae2be3
--- /dev/null
+++ b/srcpkgs/qimgv/patches/exiv2-0.28.patch
@@ -0,0 +1,16 @@
+Patch-Source: https://git.alpinelinux.org/aports/tree/community/qimgv/exiv2-0.28.patch
+diff --git a/qimgv/sourcecontainers/documentinfo.cpp b/qimgv/sourcecontainers/documentinfo.cpp
+index 98a68f7..c062474 100644
+--- a/qimgv/sourcecontainers/documentinfo.cpp
++++ b/qimgv/sourcecontainers/documentinfo.cpp
+@@ -271,10 +271,6 @@ void DocumentInfo::loadExifTags() {
+         //std::cout << "Caught Exiv2 exception '" << e.what() << "'\n";
+         return;
+     }
+-    catch (Exiv2::BasicError<CharType> e) {
+-        //std::cout << "Caught BasicError Exiv2 exception '" << e.what() << "'\n";
+-        return;
+-    }
+ #endif
+ }
+ 
diff --git a/srcpkgs/qimgv/template b/srcpkgs/qimgv/template
index 7eb30db33992c..dd341dfe1bfce 100644
--- a/srcpkgs/qimgv/template
+++ b/srcpkgs/qimgv/template
@@ -1,7 +1,7 @@
 # Template file for 'qimgv'
 pkgname=qimgv
 version=1.0.2
-revision=2
+revision=3
 build_style=cmake
 configure_args="$(vopt_if video -DVIDEO_SUPPORT=ON -DVIDEO_SUPPORT=OFF)
  $(vopt_if scale -DOPENCV_SUPPORT=ON -DOPENCV_SUPPORT=OFF)

From a0245ef55794b36923a6f915bb108463b65a0d3e Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 20/22] SIR: revbump for exiv2-0.28.0.

---
 srcpkgs/SIR/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/SIR/template b/srcpkgs/SIR/template
index 113077acad354..c6da4c26b6c71 100644
--- a/srcpkgs/SIR/template
+++ b/srcpkgs/SIR/template
@@ -1,7 +1,7 @@
 # Template file for 'SIR'
 pkgname=SIR
 version=3.2.2
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="pkg-config"
 makedepends="exiv2-devel qt5-svg-devel qt5-tools-devel"

From a0026ff29d58fdd9039a2622b9e3091518531c0f Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 21/22] viewnior: revbump for exiv2-0.28.0.

---
 srcpkgs/viewnior/patches/exiv2-0.28.patch | 147 ++++++++++++++++++++++
 srcpkgs/viewnior/template                 |   2 +-
 2 files changed, 148 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/viewnior/patches/exiv2-0.28.patch

diff --git a/srcpkgs/viewnior/patches/exiv2-0.28.patch b/srcpkgs/viewnior/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..71459dee15768
--- /dev/null
+++ b/srcpkgs/viewnior/patches/exiv2-0.28.patch
@@ -0,0 +1,147 @@
+Patch-Source: https://gitlab.archlinux.org/archlinux/packaging/packages/viewnior/-/blob/f206ce6c22a3ec5f1f9ea1bde4077584f80458dd/exiv2-0.28.patch
+--
+From b6bb81a1b46e911d15bbf9a730972523de177705 Mon Sep 17 00:00:00 2001
+From: tastytea <tastytea@tastytea.de>
+Date: Tue, 16 May 2023 10:54:40 +0200
+Subject: [PATCH 1/2] change exiv2 AutoPtr to unique_ptr
+
+exiv2-0.28.0 removed Exiv2::Image::AutoPtr and added
+Exiv2::Image::UniquePtr instead. since it's a typedef for
+std::unique_ptr<Image>, i'm using that directly instead of adding a
+condition on the exiv2 version.
+---
+ src/uni-exiv2.cpp | 21 +++++++++++----------
+ 1 file changed, 11 insertions(+), 10 deletions(-)
+
+diff --git a/src/uni-exiv2.cpp b/src/uni-exiv2.cpp
+index 0d14b9f..77064c2 100644
+--- a/src/uni-exiv2.cpp
++++ b/src/uni-exiv2.cpp
+@@ -22,12 +22,13 @@
+ 
+ #include <exiv2/exiv2.hpp>
+ #include <iostream>
++#include <memory>
+ 
+ #include "uni-exiv2.hpp"
+ 
+ #define ARRAY_SIZE(array) (sizeof array/sizeof(array[0]))
+ 
+-static Exiv2::Image::AutoPtr cached_image;
++static std::unique_ptr<Exiv2::Image> cached_image;
+ 
+ extern "C"
+ void
+@@ -35,8 +36,8 @@ uni_read_exiv2_map(const char *uri, void (*callback)(const char*, const char*, v
+ {
+     Exiv2::LogMsg::setLevel(Exiv2::LogMsg::mute);
+     try {
+-        Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open(uri);
+-        if ( image.get() == 0 ) {
++        std::unique_ptr<Exiv2::Image> image = Exiv2::ImageFactory::open(uri);
++        if (image == nullptr) {
+             return;
+         }
+ 
+@@ -91,14 +92,14 @@ uni_read_exiv2_to_cache(const char *uri)
+ {
+     Exiv2::LogMsg::setLevel(Exiv2::LogMsg::mute);
+ 
+-    if ( cached_image.get() != NULL ) {
++    if (cached_image != nullptr) {
+         cached_image->clearMetadata();
+-        cached_image.reset(NULL);
++        cached_image.reset(nullptr);
+     }
+ 
+     try {
+         cached_image = Exiv2::ImageFactory::open(uri);
+-        if ( cached_image.get() == 0 ) {
++        if (cached_image == nullptr) {
+             return 1;
+         }
+ 
+@@ -116,13 +117,13 @@ uni_write_exiv2_from_cache(const char *uri)
+ {
+     Exiv2::LogMsg::setLevel(Exiv2::LogMsg::mute);
+ 
+-    if ( cached_image.get() == NULL ) {
++    if (cached_image == nullptr) {
+         return 1;
+     }
+ 
+     try {
+-        Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open(uri);
+-        if ( image.get() == 0 ) {
++        std::unique_ptr<Exiv2::Image> image = Exiv2::ImageFactory::open(uri);
++        if (image == nullptr) {
+             return 2;
+         }
+ 
+@@ -130,7 +131,7 @@ uni_write_exiv2_from_cache(const char *uri)
+         image->writeMetadata();
+ 
+         cached_image->clearMetadata();
+-        cached_image.reset(NULL);
++        cached_image.reset(nullptr);
+ 
+         return 0;
+     } catch (Exiv2::AnyError& e) {
+
+From 47d0b98cb46526aa8aa035bebcabc14a11fa57ee Mon Sep 17 00:00:00 2001
+From: tastytea <tastytea@tastytea.de>
+Date: Tue, 16 May 2023 11:17:00 +0200
+Subject: [PATCH 2/2] add support for exiv-0.28.0 errors
+
+exiv2-0.28.0 changed Exiv2::AnyError to Exiv2::Error.
+---
+ src/uni-exiv2.cpp | 15 ++++++++++++---
+ 1 file changed, 12 insertions(+), 3 deletions(-)
+
+diff --git a/src/uni-exiv2.cpp b/src/uni-exiv2.cpp
+index 77064c2..567a50f 100644
+--- a/src/uni-exiv2.cpp
++++ b/src/uni-exiv2.cpp
+@@ -28,6 +28,15 @@
+ 
+ #define ARRAY_SIZE(array) (sizeof array/sizeof(array[0]))
+ 
++#define EXIV_ERROR Exiv2::AnyError
++#ifdef EXIV2_VERSION
++    #ifdef EXIV2_TEST_VERSION
++        #if EXIV2_TEST_VERSION(0,28,0)
++            #define EXIV_ERROR Exiv2::Error
++        #endif
++    #endif
++#endif
++
+ static std::unique_ptr<Exiv2::Image> cached_image;
+ 
+ extern "C"
+@@ -81,7 +90,7 @@ uni_read_exiv2_map(const char *uri, void (*callback)(const char*, const char*, v
+                 }
+             }
+         }
+-    } catch (Exiv2::AnyError& e) {
++    } catch (EXIV_ERROR& e) {
+         std::cerr << "Exiv2: '" << e << "'\n";
+     }
+ }
+@@ -104,7 +113,7 @@ uni_read_exiv2_to_cache(const char *uri)
+         }
+ 
+         cached_image->readMetadata();
+-    } catch (Exiv2::AnyError& e) {
++    } catch (EXIV_ERROR& e) {
+         std::cerr << "Exiv2: '" << e << "'\n";
+     }
+ 
+@@ -134,7 +143,7 @@ uni_write_exiv2_from_cache(const char *uri)
+         cached_image.reset(nullptr);
+ 
+         return 0;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (EXIV_ERROR& e) {
+         std::cerr << "Exiv2: '" << e << "'\n";
+     }
+ 
diff --git a/srcpkgs/viewnior/template b/srcpkgs/viewnior/template
index ea1e528a8651f..4c73226662ca0 100644
--- a/srcpkgs/viewnior/template
+++ b/srcpkgs/viewnior/template
@@ -1,7 +1,7 @@
 # Template file for 'viewnior'
 pkgname=viewnior
 version=1.8
-revision=1
+revision=2
 build_style=meson
 hostmakedepends="pkg-config intltool glib-devel gettext-devel"
 makedepends="gtk+-devel exiv2-devel"

From 57d08ca151d987dc580f557eda958fe3f33304ad Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Mon, 23 Oct 2023 19:06:34 +0200
Subject: [PATCH 22/22] New package: nufraw-0.43.3

Co-authored-by: Mohammed Anas <triallax@tutanota.com>
---
 common/travis/changed_templates.sh            |  1 +
 srcpkgs/nufraw-gimp                           |  1 +
 .../patches/0001-nufraw-glib-2.70.patch       | 20 +++++++
 srcpkgs/nufraw/patches/exiv-0.28.x.diff       | 59 +++++++++++++++++++
 srcpkgs/nufraw/template                       | 47 +++++++++++++++
 srcpkgs/removed-packages/template             |  8 ++-
 srcpkgs/ufraw                                 |  1 +
 srcpkgs/ufraw-gimp                            |  2 +-
 .../ufraw/patches/001-no-gimp-remote.patch    | 12 ----
 srcpkgs/ufraw/patches/002-fix_abs_int.patch   | 11 ----
 .../ufraw/patches/03_fix-unsigned-char.patch  | 14 -----
 srcpkgs/ufraw/patches/exiv-0.27.patch         | 25 --------
 srcpkgs/ufraw/patches/glib-2.68.patch         | 30 ----------
 srcpkgs/ufraw/patches/iostream.patch          | 13 ----
 srcpkgs/ufraw/template                        | 38 ------------
 15 files changed, 135 insertions(+), 147 deletions(-)
 create mode 120000 srcpkgs/nufraw-gimp
 create mode 100644 srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch
 create mode 100644 srcpkgs/nufraw/patches/exiv-0.28.x.diff
 create mode 100644 srcpkgs/nufraw/template
 create mode 120000 srcpkgs/ufraw
 delete mode 100644 srcpkgs/ufraw/patches/001-no-gimp-remote.patch
 delete mode 100644 srcpkgs/ufraw/patches/002-fix_abs_int.patch
 delete mode 100644 srcpkgs/ufraw/patches/03_fix-unsigned-char.patch
 delete mode 100644 srcpkgs/ufraw/patches/exiv-0.27.patch
 delete mode 100644 srcpkgs/ufraw/patches/glib-2.68.patch
 delete mode 100644 srcpkgs/ufraw/patches/iostream.patch
 delete mode 100644 srcpkgs/ufraw/template

diff --git a/common/travis/changed_templates.sh b/common/travis/changed_templates.sh
index 91af1f1a3c1a9..074c991d33afe 100755
--- a/common/travis/changed_templates.sh
+++ b/common/travis/changed_templates.sh
@@ -24,5 +24,6 @@ git diff-tree -r --no-renames --name-only --diff-filter=AM \
 	"$base" "$tip" \
 	-- 'srcpkgs/*/template' |
 	cut -d/ -f 2 |
+	xargs ./xbps-src sort-dependencies |
 	tee /tmp/templates |
 	sed "s/^/  /" >&2
diff --git a/srcpkgs/nufraw-gimp b/srcpkgs/nufraw-gimp
new file mode 120000
index 0000000000000..0bd1459b2a16f
--- /dev/null
+++ b/srcpkgs/nufraw-gimp
@@ -0,0 +1 @@
+nufraw
\ No newline at end of file
diff --git a/srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch b/srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch
new file mode 100644
index 0000000000000..41f10bfbafa1f
--- /dev/null
+++ b/srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch
@@ -0,0 +1,20 @@
+diff -ru nufraw/uf_glib.h nufraw/uf_glib.h
+--- nufraw/uf_glib.h	2022-02-23 09:03:44.700472919 +0100
++++ nufraw/uf_glib.h	2022-02-23 09:04:50.260308805 +0100
+@@ -13,13 +13,13 @@
+ #ifndef _UF_GLIB_H
+ #define _UF_GLIB_H
+ 
++#include <glib.h>
++#include <glib/gstdio.h>
++
+ #ifdef __cplusplus
+ extern "C" {
+ #endif
+ 
+-#include <glib.h>
+-#include <glib/gstdio.h>
+-
+ // g_win32_locale_filename_from_utf8 is needed only on win32
+ #ifdef _WIN32
+ #define uf_win32_locale_filename_from_utf8(__some_string__) \
diff --git a/srcpkgs/nufraw/patches/exiv-0.28.x.diff b/srcpkgs/nufraw/patches/exiv-0.28.x.diff
new file mode 100644
index 0000000000000..6c23359bf706c
--- /dev/null
+++ b/srcpkgs/nufraw/patches/exiv-0.28.x.diff
@@ -0,0 +1,59 @@
+Patch taken from AUR package: https://aur.archlinux.org/cgit/aur.git/tree/exiv2-error.patch?h=nufraw&id=29e467f2c297fcd0f36548642d6d2cab6428d08f
+diff --git a/nufraw_exiv2.cc b/nufraw_exiv2.cc
+index 2de4cc3..45aea87 100644
+--- a/nufraw_exiv2.cc
++++ b/nufraw_exiv2.cc
+@@ -54,7 +54,7 @@ extern "C" int nufraw_exif_read_input(nufraw_data *uf)
+         uf->inputExifBuf = NULL;
+         uf->inputExifBufLen = 0;
+ 
+-        Exiv2::Image::AutoPtr image;
++        Exiv2::Image::UniquePtr image;
+         if (uf->unzippedBuf != NULL) {
+             image = Exiv2::ImageFactory::open(
+                         (const Exiv2::byte*)uf->unzippedBuf, uf->unzippedBufLen);
+@@ -135,7 +135,7 @@ extern "C" int nufraw_exif_read_input(nufraw_data *uf)
+         nufraw_message(NUFRAW_SET_LOG, "%s\n", stderror.str().c_str());
+ 
+         return NUFRAW_SUCCESS;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (Exiv2::Error& e) {
+         std::cerr.rdbuf(savecerr);
+         std::string s(e.what());
+         nufraw_message(NUFRAW_SET_WARNING, "%s\n", s.c_str());
+@@ -156,7 +156,7 @@ static Exiv2::ExifData nufraw_prepare_exifdata(nufraw_data *uf)
+         if ((pos = exifData.findKey(Exiv2::ExifKey("Exif.Image.Orientation")))
+                 != exifData.end()) {
+             nufraw_message(NUFRAW_SET_LOG, "Resetting %s from '%d' to '1'\n",
+-                          pos->key().c_str(), pos->value().toLong());
++                          pos->key().c_str(), pos->value().toInt64());
+             pos->setValue("1"); /* 1 = Normal orientation */
+         }
+     }
+@@ -327,7 +327,7 @@ extern "C" int nufraw_exif_prepare_output(nufraw_data *uf)
+         nufraw_message(NUFRAW_SET_LOG, "%s\n", stderror.str().c_str());
+ 
+         return NUFRAW_SUCCESS;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (Exiv2::Error& e) {
+         std::cerr.rdbuf(savecerr);
+         std::string s(e.what());
+         nufraw_message(NUFRAW_SET_WARNING, "%s\n", s.c_str());
+@@ -347,7 +347,7 @@ extern "C" int nufraw_exif_write(nufraw_data *uf)
+ 
+         char *filename =
+             uf_win32_locale_filename_from_utf8(uf->conf->outputFilename);
+-        Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open(filename);
++        Exiv2::Image::UniquePtr image = Exiv2::ImageFactory::open(filename);
+         uf_win32_locale_filename_free(filename);
+         assert(image.get() != 0);
+ 
+@@ -367,7 +367,7 @@ extern "C" int nufraw_exif_write(nufraw_data *uf)
+         nufraw_message(NUFRAW_SET_LOG, "%s\n", stderror.str().c_str());
+ 
+         return NUFRAW_SUCCESS;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (Exiv2::Error& e) {
+         std::cerr.rdbuf(savecerr);
+         std::string s(e.what());
+         nufraw_message(NUFRAW_SET_WARNING, "%s\n", s.c_str());
diff --git a/srcpkgs/nufraw/template b/srcpkgs/nufraw/template
new file mode 100644
index 0000000000000..3e5d7d190b335
--- /dev/null
+++ b/srcpkgs/nufraw/template
@@ -0,0 +1,47 @@
+# Template file for 'nufraw'
+pkgname=nufraw
+version=0.43.3
+revision=1
+_ver="${version%.*}-${version##*.}"
+build_style=gnu-configure
+configure_args="--enable-contrast --enable-mime --enable-openmp --with-gimp
+ --enable-extras"
+hostmakedepends="pkg-config automake libtool"
+makedepends="exiv2-devel gimp-devel glib-devel gtkimageview-devel lcms2-devel lensfun-devel
+ jasper-devel"
+depends="desktop-file-utils"
+short_desc="Utility to read and manipulate raw images from digital cameras"
+maintainer="John <me@johnnynator.dev>"
+license="GPL-2.0-or-later"
+homepage="https://sourceforge.net/projects/nufraw/"
+distfiles="${SOURCEFORGE_SITE}/nufraw/nufraw-${_ver}.tar.gz"
+checksum=2c7dcc1590993ec267b3112562b2433010d6f94f6acc6506c76aa29cf8c6c32c
+
+pre_configure() {
+	autoreconf -fi
+}
+
+pre_build() {
+	mv nufraw.desktop{.desktop,}
+	chmod +x generate_schemas.sh
+}
+
+nufraw-gimp_package() {
+	depends="${sourcepkg}>=${version}_${revision}"
+	short_desc+=" - gimp plugin"
+	pkg_install() {
+		vmove usr/lib/gimp
+	}
+}
+
+ufraw_package() {
+	depends="${sourcepkg}>=${version}_${revision}"
+	build_style=meta
+	short_desc+=" (transitional dummy package)"
+}
+
+ufraw-gimp_package() {
+	depends="nufraw-gimp>=${version}_${revision}"
+	build_style=meta
+	short_desc+=" - gimp plugin (transitional dummy package)"
+}
diff --git a/srcpkgs/removed-packages/template b/srcpkgs/removed-packages/template
index abedf26f739b6..f3d81a8afe04c 100644
--- a/srcpkgs/removed-packages/template
+++ b/srcpkgs/removed-packages/template
@@ -1,6 +1,6 @@
 # Template file for 'removed-packages'
 pkgname=removed-packages
-version=0.1.20231019
+version=0.1.20231101
 revision=1
 build_style=meta
 short_desc="Uninstalls packages removed from repository"
@@ -590,8 +590,8 @@ replaces="
  python3-Flask-Assets<=0.12_9
  python3-Flask-Mail<=0.9.1_5
  python3-Flask-OAuthlib<=0.9.6_4
- python3-Flask-Script<=2.0.6_7
  python3-Flask-SQLAlchemy<=2.5.1_4
+ python3-Flask-Script<=2.0.6_7
  python3-Flask-User<=1.0.2.2_6
  python3-SPARQLWrapper<=1.8.4_4
  python3-aiohttp-cors2<=0.7.0_3
@@ -642,8 +642,8 @@ replaces="
  raul-devel<=0.8.0_6
  raul<=0.8.0_6
  redkite<=1.3.1_1
- rem<=2.10.0_1
  rem-devel<=2.10.0_1
+ rem<=2.10.0_1
  reminiscence<=0.4.6_1
  rkt-stage1-coreos<=1.30.0_3
  rkt-stage1-fly<=1.30.0_3
@@ -675,6 +675,8 @@ replaces="
  traverso<=0.49.6_2
  ttyload-git<=20141117_4
  tuxc<=1.1_3
+ ufraw-gimp<=0.22_5
+ ufraw<=0.22_5
  unicorn-python<=1.0.2_2
  upwork<=5.6.10.0_1
  urlmatch-git<=20141116_2
diff --git a/srcpkgs/ufraw b/srcpkgs/ufraw
new file mode 120000
index 0000000000000..0bd1459b2a16f
--- /dev/null
+++ b/srcpkgs/ufraw
@@ -0,0 +1 @@
+nufraw
\ No newline at end of file
diff --git a/srcpkgs/ufraw-gimp b/srcpkgs/ufraw-gimp
index 967dc902dd02b..0bd1459b2a16f 120000
--- a/srcpkgs/ufraw-gimp
+++ b/srcpkgs/ufraw-gimp
@@ -1 +1 @@
-ufraw
\ No newline at end of file
+nufraw
\ No newline at end of file
diff --git a/srcpkgs/ufraw/patches/001-no-gimp-remote.patch b/srcpkgs/ufraw/patches/001-no-gimp-remote.patch
deleted file mode 100644
index ca4f4beb6240f..0000000000000
--- a/srcpkgs/ufraw/patches/001-no-gimp-remote.patch
+++ /dev/null
@@ -1,12 +0,0 @@
-Don't use gimp-remote since gimp 2.4 already includes gimp-remote functionality
---- a/ufraw_conf.c
-+++ b/ufraw_conf.c
-@@ -137,7 +137,7 @@
- #elif HAVE_GIMP_2_4
-     "gimp", /* remoteGimpCommand */
- #else
--    "gimp-remote", /* remoteGimpCommand */
-+    "gimp", /* remoteGimpCommand */
- #endif
- 
-     /* EXIF data */
diff --git a/srcpkgs/ufraw/patches/002-fix_abs_int.patch b/srcpkgs/ufraw/patches/002-fix_abs_int.patch
deleted file mode 100644
index 6fc552769c9f8..0000000000000
--- a/srcpkgs/ufraw/patches/002-fix_abs_int.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- a/dcraw.cc	2015-06-16 05:58:38.000000000 +0200
-+++ b/dcraw.cc	2018-02-04 14:46:54.489951076 +0100
-@@ -9242,7 +9242,7 @@
-     if (make[0] == 'O') {
-       i = find_green (12, 32, 1188864, 3576832);
-       c = find_green (12, 32, 2383920, 2387016);
--      if (abs(i) < abs(c)) {
-+      if (abs((int)i) < abs((int)c)) {
- 	SWAP(i,c);
- 	load_flags = 24;
-       }
diff --git a/srcpkgs/ufraw/patches/03_fix-unsigned-char.patch b/srcpkgs/ufraw/patches/03_fix-unsigned-char.patch
deleted file mode 100644
index 8690f87ca7d59..0000000000000
--- a/srcpkgs/ufraw/patches/03_fix-unsigned-char.patch
+++ /dev/null
@@ -1,14 +0,0 @@
-Source: written by John Paul Adrian Glaubitz for Debian
-Upstream: https://sourceforge.net/p/ufraw/bugs/417
-Reason: fixes a compilation failure on arm architectures
---- a/dcraw.cc
-+++ b/dcraw.cc
-@@ -2285,7 +2285,7 @@ void CLASS quicktake_100_load_raw()
- 
- void CLASS kodak_radc_load_raw()
- {
--  static const char src[] = {
-+  static const signed char src[] = {
-     1,1, 2,3, 3,4, 4,2, 5,7, 6,5, 7,6, 7,8,
-     1,0, 2,1, 3,3, 4,4, 5,2, 6,7, 7,6, 8,5, 8,8,
-     2,1, 2,3, 3,0, 3,2, 3,4, 4,6, 5,5, 6,7, 6,8,
diff --git a/srcpkgs/ufraw/patches/exiv-0.27.patch b/srcpkgs/ufraw/patches/exiv-0.27.patch
deleted file mode 100644
index b5b4140fff8ed..0000000000000
--- a/srcpkgs/ufraw/patches/exiv-0.27.patch
+++ /dev/null
@@ -1,25 +0,0 @@
---- a/ufraw_exiv2.cc	2015-06-16 05:58:38.000000000 +0200
-+++ b/ufraw_exiv2.cc	2018-12-29 22:51:23.291894430 +0100
-@@ -15,9 +15,7 @@
- #include "ufraw.h"
- 
- #ifdef HAVE_EXIV2
--#include <exiv2/image.hpp>
--#include <exiv2/easyaccess.hpp>
--#include <exiv2/exif.hpp>
-+#include <exiv2/exiv2.hpp>
- #include <sstream>
- #include <cassert>
- 
-@@ -67,7 +65,11 @@
-         if (exifData.empty()) {
-             std::string error(uf->filename);
-             error += ": No Exif data found in the file";
-+#if EXIV2_TEST_VERSION(0,27,0)
-+            throw Exiv2::Error(Exiv2::kerErrorMessage, error);
-+#else
-             throw Exiv2::Error(1, error);
-+#endif
-         }
- 
-         /* List of tag names taken from exiv2's printSummary() in actions.cpp */
diff --git a/srcpkgs/ufraw/patches/glib-2.68.patch b/srcpkgs/ufraw/patches/glib-2.68.patch
deleted file mode 100644
index 5b61468f118aa..0000000000000
--- a/srcpkgs/ufraw/patches/glib-2.68.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-From c56f8be3caf1cf3d9a5c80597bdbaf1325faacc0 Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?S=C3=A9rgio=20M=2E=20Basto?= <sergio@serjux.com>
-Date: Tue, 13 Apr 2021 23:45:39 +0100
-Subject: [PATCH] Fix build against glib-2.68 fixes #10
-
----
- uf_glib.h | 6 +++---
- 1 file changed, 3 insertions(+), 3 deletions(-)
-
-diff --git a/uf_glib.h b/uf_glib.h
-index 21c10b19..56cd6971 100644
---- a/uf_glib.h
-+++ b/uf_glib.h
-@@ -13,13 +13,13 @@
- #ifndef _UF_GLIB_H
- #define _UF_GLIB_H
- 
-+#include <glib.h>
-+#include <glib/gstdio.h>
-+
- #ifdef __cplusplus
- extern "C" {
- #endif
- 
--#include <glib.h>
--#include <glib/gstdio.h>
--
- // g_win32_locale_filename_from_utf8 is needed only on win32
- #ifdef _WIN32
- #define uf_win32_locale_filename_from_utf8(__some_string__) \
diff --git a/srcpkgs/ufraw/patches/iostream.patch b/srcpkgs/ufraw/patches/iostream.patch
deleted file mode 100644
index 6d15869f63db8..0000000000000
--- a/srcpkgs/ufraw/patches/iostream.patch
+++ /dev/null
@@ -1,13 +0,0 @@
-ufraw_exiv2.cc:343:10: note: 'std::cerr' is defined in header '<iostream>'
-ufraw_exiv2.cc:365:14: error: 'cerr' is not a member of 'std'
-
---- a/ufraw_exiv2.cc
-+++ b/ufraw_exiv2.cc
-@@ -17,6 +17,7 @@
- #ifdef HAVE_EXIV2
- #include <exiv2/exiv2.hpp>
- #include <sstream>
-+#include <iostream>
- #include <cassert>
- 
- /*
diff --git a/srcpkgs/ufraw/template b/srcpkgs/ufraw/template
deleted file mode 100644
index ceddcacacefb2..0000000000000
--- a/srcpkgs/ufraw/template
+++ /dev/null
@@ -1,38 +0,0 @@
-# Template file for 'ufraw'
-pkgname=ufraw
-version=0.22
-revision=5
-build_style=gnu-configure
-configure_args="--enable-contrast --enable-mime --enable-openmp --with-gimp
- $(vopt_enable extras)"
-hostmakedepends="pkg-config dcraw gettext"
-makedepends="exiv2-devel gimp-devel glib-devel gtkimageview-devel lcms2-devel lensfun-devel
- jasper-devel"
-depends="desktop-file-utils"
-short_desc="Utility to read and manipulate raw images from digital cameras"
-maintainer="John <me@johnnynator.dev>"
-license="GPL-2.0-or-later"
-homepage="http://ufraw.sourceforge.net/"
-distfiles="${SOURCEFORGE_SITE}/ufraw/ufraw/ufraw-${version}/ufraw-${version}.tar.gz"
-checksum=f7abd28ce587db2a74b4c54149bd8a2523a7ddc09bedf4f923246ff0ae09a25e
-
-build_options="extras"
-
-post_patch() {
-	vsed -e 's/default(none)//g' \
-		-i dcraw_indi.c \
-		-i dcraw_api.cc \
-		-i ufraw_ufraw.c \
-		-i ufraw_developer.c
-	vsed -i -e '/DATADIRNAME=/s/=.*/=share/' configure
-	vsed -i -e "s,^localedir =.*,localedir = /usr/share/locale," \
-		po/Makefile.in.in
-}
-
-ufraw-gimp_package() {
-	depends="${sourcepkg}>=${version}_${revision}"
-	short_desc+=" - gimp plugin"
-	pkg_install() {
-		vmove usr/lib/gimp
-	}
-}

^ permalink raw reply	[flat|nested] 27+ messages in thread

* Re: exiv2: update to 0.28.0.
  2023-10-23  0:10 [PR PATCH] exiv2: update to 0.28.0 mhmdanas
                   ` (3 preceding siblings ...)
  2023-11-01 18:11 ` mhmdanas
@ 2023-11-02 19:42 ` biopsin
  2023-11-03 20:00 ` [PR PATCH] [Updated] " mhmdanas
                   ` (20 subsequent siblings)
  25 siblings, 0 replies; 27+ messages in thread
From: biopsin @ 2023-11-02 19:42 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 352 bytes --]

New comment by biopsin on void-packages repository

https://github.com/void-linux/void-packages/pull/46838#issuecomment-1791440221

Comment:
@mhmdanas
Tested against viewnior without issues, also I use nufraw for couple of years without issues however I've not had the time to rebuild it against this PR, I might make some time this weekend and test.

^ permalink raw reply	[flat|nested] 27+ messages in thread

* Re: [PR PATCH] [Updated] exiv2: update to 0.28.0.
  2023-10-23  0:10 [PR PATCH] exiv2: update to 0.28.0 mhmdanas
                   ` (4 preceding siblings ...)
  2023-11-02 19:42 ` biopsin
@ 2023-11-03 20:00 ` mhmdanas
  2023-11-03 20:18 ` mhmdanas
                   ` (19 subsequent siblings)
  25 siblings, 0 replies; 27+ messages in thread
From: mhmdanas @ 2023-11-03 20:00 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 1945 bytes --]

There is an updated pull request by mhmdanas against master on the void-packages repository

https://github.com/mhmdanas/void-packages exiv2-0.28.0
https://github.com/void-linux/void-packages/pull/46838

exiv2: update to 0.28.0.
<!-- Uncomment relevant sections and delete options which are not applicable -->

#### Testing the changes
- I tested the changes in this PR: **briefly**

TODO:
- [x] Fix `gwenview`'s failed checks (not really fixed but the exact same tests fail on master as well)
- [ ] `test_exiv2` fails for `libextractor`
- [ ] `kfilemetadata5` tests fail

@Johnnynator ufraw has been [unmaintained since December 2016](https://sourceforge.net/p/ufraw/discussion/434060/thread/30b4249b/), and it doesn't build with this PR; here are the options:
- remove the package entirely
- replace it with the newer [nufraw](https://sourceforge.net/projects/nufraw/), which already has [an exiv 0.28.x patch floating around](https://aur.archlinux.org/cgit/aur.git/tree/exiv2-error.patch?h=nufraw)
- patch it to build with this PR

What do you think?

<!--
#### New package
- This new package conforms to the [package requirements](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTItest_exiv2NG.md#package-requirements): **YES**|**NO**
-->

<!-- Note: If the build is likely to take more than 2 hours, please add ci skip tag as described in
https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration
and test at least one native build and, if supported, at least one cross build.
Ignore this section if this PR is not skipping CI.
-->
<!--
#### Local build testing
- I built this PR locally for my native architecture, (ARCH-LIBC)
- I built this PR locally for these architectures (if supported. mark crossbuilds):
  - aarch64-musl
  - armv7l
  - armv6l-musl
-->


A patch file from https://github.com/void-linux/void-packages/pull/46838.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-exiv2-0.28.0-46838.patch --]
[-- Type: text/x-diff, Size: 62570 bytes --]

From 9136c0daffaf5dbffe90d87f66d763b7b84a57d4 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Mon, 23 Oct 2023 01:20:09 +0100
Subject: [PATCH 01/22] inih: add `libINIReader.so.0` common/shlibs entry.

---
 common/shlibs | 1 +
 1 file changed, 1 insertion(+)

diff --git a/common/shlibs b/common/shlibs
index 9036a675c1ae5..8f03a38a16789 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -3905,6 +3905,7 @@ libnotcurses++.so.3 notcurses-3.0.5_1
 libnotcurses-ffi.so.3 notcurses-3.0.5_1
 libevemu.so.3 evemu-2.7.0_1
 libinih.so.0 inih-52_1
+libINIReader.so.0 inih-57_1
 libpcaudio.so.0 pcaudiolib-1.1_1
 libdcerpc-samr.so.0 samba-4.13.2_1
 libdcerpc-server-core.so.0 samba-4.13.2_1

From b838df17f556cc5ffa12add190b50c6f4a9f2e10 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:12 +0100
Subject: [PATCH 02/22] exiv2: update to 0.28.0.

---
 common/shlibs                        |  2 +-
 srcpkgs/exiv2/patches/fix-tests.diff | 31 ++++++++++++++++++++++++++++
 srcpkgs/exiv2/template               | 14 ++++++++-----
 3 files changed, 41 insertions(+), 6 deletions(-)
 create mode 100644 srcpkgs/exiv2/patches/fix-tests.diff

diff --git a/common/shlibs b/common/shlibs
index 8f03a38a16789..0b1d0c89d3e51 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -555,7 +555,7 @@ libgimpcolor-2.0.so.0 libgimp-2.10.0_1
 libgimpmodule-2.0.so.0 libgimp-2.10.0_1
 libgmic.so.3 gmic-3.1.6_1
 libcgmic.so.3 gmic-3.1.6_1
-libexiv2.so.27 exiv2-0.27_1
+libexiv2.so.28 exiv2-0.28.0_1
 libKF5Holidays.so.5 kholidays-5.47.0_1
 libPhabricatorHelpers.so.5 purpose-5.48.0_1
 libKF5PurposeWidgets.so.5 purpose-5.48.0_1
diff --git a/srcpkgs/exiv2/patches/fix-tests.diff b/srcpkgs/exiv2/patches/fix-tests.diff
new file mode 100644
index 0000000000000..3eb7adc1635f3
--- /dev/null
+++ b/srcpkgs/exiv2/patches/fix-tests.diff
@@ -0,0 +1,31 @@
+diff --git a/tests/tiff_test/test_tag_compare.py b/tests/tiff_test/test_tag_compare.py
+index a8538bd2..974d1a9a 100644
+--- a/tests/tiff_test/test_tag_compare.py
++++ b/tests/tiff_test/test_tag_compare.py
+@@ -28,8 +28,8 @@ class OutputTagExtract(metaclass=system_tests.CaseMeta):
+             tmp = line.split()
+ 
+             exif, image, tag = tmp[0].split('.')
+-            self.assertEquals(exif, "Exif")
+-            self.assertEquals(image, "Image")
++            self.assertEqual(exif, "Exif")
++            self.assertEqual(image, "Image")
+ 
+             data.append({
+                 "tag": tag,
+@@ -87,13 +87,13 @@ class OutputTagExtract(metaclass=system_tests.CaseMeta):
+         """
+         for pa_elem, pS_elem in zip(self.pa_data, self.pS_data):
+             for key in ["tag", "type", "len"]:
+-                self.assertEquals(pa_elem[key], pS_elem[key])
++                self.assertEqual(pa_elem[key], pS_elem[key])
+ 
+             if pa_elem["tag"] in [
+                     "ImageWidth", "ImageLength", "BitsPerSample",
+                     "DocumentName", "ImageDescription", "StripOffsets",
+                     "SamplesPerPixel", "StripByteCounts"]:
+-                self.assertEquals(pa_elem["val"], pS_elem["val"])
++                self.assertEqual(pa_elem["val"], pS_elem["val"])
+ 
+     def compare_stdout(self, i, command, got_stdout, expected_stdout):
+         super().compare_stdout(i, command, got_stdout, expected_stdout)
diff --git a/srcpkgs/exiv2/template b/srcpkgs/exiv2/template
index 49985fe82cc14..876b253541d00 100644
--- a/srcpkgs/exiv2/template
+++ b/srcpkgs/exiv2/template
@@ -1,17 +1,17 @@
 # Template file for 'exiv2'
 pkgname=exiv2
-version=0.27.6
+version=0.28.0
 revision=1
 build_style=cmake
 configure_args="-DEXIV2_BUILD_SAMPLES=OFF -DEXIV2_ENABLE_BMFF=ON"
-makedepends="zlib-devel expat-devel"
-checkdepends="gtest-devel"
+makedepends="zlib-devel brotli-devel expat-devel inih-devel"
+checkdepends="gtest-devel python3"
 short_desc="Image metadata manipulation"
 maintainer="Enno Boland <gottox@voidlinux.org>"
 license="GPL-2.0-or-later"
 homepage="https://www.exiv2.org"
 distfiles="https://github.com/Exiv2/exiv2/releases/download/v${version}/exiv2-${version}-Source.tar.gz"
-checksum=4c192483a1125dc59a3d70b30d30d32edace9e14adf52802d2f853abf72db8a6
+checksum=89af3b5ef7277753ef7a7b5374ae017c6b9e304db3b688f1948e73e103491f3d
 
 if [ -n "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DEXIV2_BUILD_UNIT_TESTS=ON"
@@ -21,6 +21,11 @@ if [ -n "$XBPS_CCACHE" ]; then
 	configure_args+=" -DBUILD_WITH_CCACHE=ON"
 fi
 
+pre_check() {
+	# https://github.com/Exiv2/exiv2/issues/2762
+	rm -f tests/bugfixes/github/test_issue_2427.py
+}
+
 exiv2-devel_package() {
 	depends="${makedepends} ${sourcepkg}-${version}_${revision}"
 	short_desc+=" - development files"
@@ -28,7 +33,6 @@ exiv2-devel_package() {
 		vmove usr/include
 		vmove usr/lib/cmake
 		vmove usr/lib/pkgconfig
-		vmove "usr/lib/*.a"
 		vmove "usr/lib/*.so"
 	}
 }

From ab2f8249fc84f316fc37b81d241b8160806f6c31 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:37 +0100
Subject: [PATCH 03/22] ART: revbump for exiv2-0.28.0.

---
 srcpkgs/ART/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/ART/template b/srcpkgs/ART/template
index b6c47fc6c4cdf..94c7aa0378061 100644
--- a/srcpkgs/ART/template
+++ b/srcpkgs/ART/template
@@ -1,7 +1,7 @@
 # Template file for 'ART'
 pkgname=ART
 version=1.20.2
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="pkg-config"
 makedepends="fftw-devel gtkmm-devel lensfun-devel

From 8de21074357dee7f4eb04bb030bee1e2d230630b Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 04/22] darktable: revbump for exiv2-0.28.0.

---
 srcpkgs/darktable/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/darktable/template b/srcpkgs/darktable/template
index 60415a34dc018..3d35571239a93 100644
--- a/srcpkgs/darktable/template
+++ b/srcpkgs/darktable/template
@@ -1,7 +1,7 @@
 # Template file for 'darktable'
 pkgname=darktable
 version=4.4.2
-revision=2
+revision=3
 # upstream only supports these archs:
 archs="x86_64* aarch64* ppc64le*"
 build_style=cmake

From f02ec329c8549dfca5a035783ee7a363c7e9e325 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 05/22] digikam: revbump for exiv2-0.28.0.

---
 srcpkgs/digikam/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/digikam/template b/srcpkgs/digikam/template
index 206185f565488..4784bf7d62a8e 100644
--- a/srcpkgs/digikam/template
+++ b/srcpkgs/digikam/template
@@ -1,7 +1,7 @@
 # Template file for 'digikam'
 pkgname=digikam
 version=8.1.0
-revision=1
+revision=2
 build_style=cmake
 configure_args="-DBUILD_TESTING=OFF"
 hostmakedepends="extra-cmake-modules gettext pkg-config bison flex qt5-qmake

From a5befd600b8f1e6b679e62019958c9e682247c7f Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 06/22] geeqie: revbump for exiv2-0.28.0.

---
 srcpkgs/geeqie/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/geeqie/template b/srcpkgs/geeqie/template
index b5f958f854c1b..b494bc149e957 100644
--- a/srcpkgs/geeqie/template
+++ b/srcpkgs/geeqie/template
@@ -1,7 +1,7 @@
 # Template file for 'geeqie'
 pkgname=geeqie
 version=2.1
-revision=1
+revision=2
 build_style=meson
 hostmakedepends="pkg-config gettext xxd gdk-pixbuf-devel glib-devel"
 makedepends="gtk+3-devel glib-devel lcms2-devel exiv2-devel libheif-devel

From 6a58d030169e642852037230945de38b80029d40 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 07/22] gthumb: revbump for exiv2-0.28.0.

---
 srcpkgs/gthumb/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/gthumb/template b/srcpkgs/gthumb/template
index c8e19f0dedb61..732d5e1c6089f 100644
--- a/srcpkgs/gthumb/template
+++ b/srcpkgs/gthumb/template
@@ -1,7 +1,7 @@
 # Template file for 'gthumb'
 pkgname=gthumb
 version=3.12.3
-revision=1
+revision=2
 build_style=meson
 hostmakedepends="gettext pkg-config itstool glib-devel"
 makedepends="webkit2gtk-devel json-glib-devel libsecret-devel librsvg-devel

From b72081084ae9076ba967a9b397f83aa701c07557 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 08/22] gwenview: revbump for exiv2-0.28.0.

---
 srcpkgs/gwenview/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/gwenview/template b/srcpkgs/gwenview/template
index 73d450a458c4d..eb876cfadcfe8 100644
--- a/srcpkgs/gwenview/template
+++ b/srcpkgs/gwenview/template
@@ -1,7 +1,7 @@
 # Template file for 'gwenview'
 pkgname=gwenview
 version=23.08.2
-revision=1
+revision=2
 build_style=cmake
 build_helper=qemu
 hostmakedepends="extra-cmake-modules pkg-config qt5-qmake qt5-host-tools

From 7b6005232b3a616174fc59aa4d24370f43645ddd Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 09/22] hugin: revbump for exiv2-0.28.0.

---
 srcpkgs/hugin/patches/exiv2-0.28.patch | 77 ++++++++++++++++++++++++++
 srcpkgs/hugin/template                 |  2 +-
 2 files changed, 78 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/hugin/patches/exiv2-0.28.patch

diff --git a/srcpkgs/hugin/patches/exiv2-0.28.patch b/srcpkgs/hugin/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..49f0518117020
--- /dev/null
+++ b/srcpkgs/hugin/patches/exiv2-0.28.patch
@@ -0,0 +1,77 @@
+Patch-Source: https://gitlab.archlinux.org/archlinux/packaging/packages/hugin/-/blob/main/exiv2-0.28.patch
+diff -r 79cd11a7a66f src/hugin_base/panodata/Exiv2Helper.cpp
+--- a/src/hugin_base/panodata/Exiv2Helper.cpp	Wed May 24 19:13:20 2023 +0200
++++ b/src/hugin_base/panodata/Exiv2Helper.cpp	Mon Jun 05 00:31:19 2023 +0200
+@@ -40,7 +40,7 @@
+             Exiv2::ExifData::iterator itr = exifData.findKey(Exiv2::ExifKey(keyName));
+             if (itr != exifData.end() && itr->count())
+             {
+-                value = itr->toLong();
++                value = itr->toUint32();
+                 return true;
+             }
+             else
+@@ -165,7 +165,7 @@
+         {
+             if(it!=exifData.end() && it->count())
+             {
+-                return it->toLong();
++                return it->toUint32();
+             }
+             return 0;
+         };
+@@ -600,4 +600,4 @@
+         };
+ 
+     }; //namespace Exiv2Helper
+-}; //namespace HuginBase
+\ No newline at end of file
++}; //namespace HuginBase
+diff -r 79cd11a7a66f src/hugin_base/panodata/SrcPanoImage.cpp
+--- a/src/hugin_base/panodata/SrcPanoImage.cpp	Wed May 24 19:13:20 2023 +0200
++++ b/src/hugin_base/panodata/SrcPanoImage.cpp	Mon Jun 05 00:31:19 2023 +0200
+@@ -384,7 +384,7 @@
+                     pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaImageWidthPixels"));
+                     if (pos != xmpData.end())
+                     {
+-                        croppedWidth = pos->toLong();
++                        croppedWidth = pos->toUint32();
+                     }
+                     else
+                     {
+@@ -394,7 +394,7 @@
+                     pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaImageHeightPixels"));
+                     if (pos != xmpData.end())
+                     {
+-                        croppedHeight = pos->toLong();
++                        croppedHeight = pos->toUint32();
+                     }
+                     else
+                     {
+@@ -408,7 +408,7 @@
+                         double hfov = 0;
+                         if (pos != xmpData.end())
+                         {
+-                            hfov = 360 * croppedWidth / (double)pos->toLong();
++                            hfov = 360 * croppedWidth / (double)pos->toUint32();
+                         }
+                         else
+                         {
+@@ -419,7 +419,7 @@
+                         pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.FullPanoHeightPixels"));
+                         if (pos != xmpData.end())
+                         {
+-                            fullHeight = pos->toLong();
++                            fullHeight = pos->toUint32();
+                         }
+                         else
+                         {
+@@ -430,7 +430,7 @@
+                         pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaTopPixels"));
+                         if (pos != xmpData.end())
+                         {
+-                            cropTop = pos->toLong();
++                            cropTop = pos->toUint32();
+                         }
+                         else
+                         {
diff --git a/srcpkgs/hugin/template b/srcpkgs/hugin/template
index f96d2f6e27d42..ce71f6e4cbb2d 100644
--- a/srcpkgs/hugin/template
+++ b/srcpkgs/hugin/template
@@ -1,7 +1,7 @@
 # Template file for 'hugin'
 pkgname=hugin
 version=2022.0.0
-revision=10
+revision=11
 build_style=cmake
 build_helper=cmake-wxWidgets-gtk3
 pycompile_dirs="usr/share/hugin/data/plugins usr/share/hugin/data/plugins-templates"

From 95a0a070f1bbf822af57088274165e189d2488d4 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 10/22] kfilemetadata5: revbump for exiv2-0.28.0.

---
 srcpkgs/kfilemetadata5/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/kfilemetadata5/template b/srcpkgs/kfilemetadata5/template
index 00f7a98cf6399..e294ae5af947c 100644
--- a/srcpkgs/kfilemetadata5/template
+++ b/srcpkgs/kfilemetadata5/template
@@ -1,7 +1,7 @@
 # Template file for 'kfilemetadata5'
 pkgname=kfilemetadata5
 version=5.111.0
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="kcoreaddons extra-cmake-modules pkg-config qt5-host-tools qt5-qmake
  gettext kcoreaddons python3"

From bee20f6e736f82c5c06c1e879da1df36b82c7632 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 11/22] krename: revbump for exiv2-0.28.0.

---
 srcpkgs/krename/patches/e7dd767a.patch | 90 ++++++++++++++++++++++++++
 srcpkgs/krename/template               |  2 +-
 2 files changed, 91 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/krename/patches/e7dd767a.patch

diff --git a/srcpkgs/krename/patches/e7dd767a.patch b/srcpkgs/krename/patches/e7dd767a.patch
new file mode 100644
index 0000000000000..a0ef428ce46b1
--- /dev/null
+++ b/srcpkgs/krename/patches/e7dd767a.patch
@@ -0,0 +1,90 @@
+Patch-Source: https://invent.kde.org/utilities/krename/-/commit/e7dd767a
+From e7dd767a9a1068ee1fe1502c4d619b57d3b12add Mon Sep 17 00:00:00 2001
+From: Andreas Sturmlechner <asturm@gentoo.org>
+Date: Fri, 26 May 2023 23:23:10 +0200
+Subject: [PATCH] Fix build with >=exiv2-0.28, raise minimum to 0.27
+
+- enables use of EXIV2_TEST_VERSION macro
+- exiv2 headers cleanup
+
+Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>
+---
+ CMakeLists.txt         |  6 +-----
+ config-krename.h.cmake |  3 ---
+ src/exiv2plugin.cpp    | 17 +++++------------
+ 3 files changed, 6 insertions(+), 20 deletions(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 0bda8ac..72e7297 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -56,13 +56,9 @@ set_package_properties(Taglib PROPERTIES
+     TYPE OPTIONAL)
+ 
+ # Find exiv2
+-find_package(LibExiv2 0.13) # AccessMode was added in 0.13
++find_package(LibExiv2 0.27) # EXIV2_TEST_VERSION was added in 0.27
+ set_package_properties(LibExiv2 PROPERTIES TYPE OPTIONAL)
+ 
+-if (LibExiv2_VERSION VERSION_GREATER_EQUAL "0.27")
+-    set(HAVE_LIBEXIV2_0_27 TRUE)
+-endif()
+-
+ # Find podofo
+ find_package(PoDoFo)
+ set_package_properties(PoDoFo PROPERTIES
+diff --git a/config-krename.h.cmake b/config-krename.h.cmake
+index 76c3d30..862e40b 100644
+--- a/config-krename.h.cmake
++++ b/config-krename.h.cmake
+@@ -6,9 +6,6 @@
+ /* have Exiv2 */
+ #cmakedefine01 HAVE_EXIV2
+ 
+-/* Defined if we have libexiv2 >= 0.27 */
+-#cmakedefine HAVE_LIBEXIV2_0_27
+-
+ /* have PoDoFo */
+ #cmakedefine01 HAVE_PODOFO
+ 
+diff --git a/src/exiv2plugin.cpp b/src/exiv2plugin.cpp
+index 5694d8c..25e8869 100644
+--- a/src/exiv2plugin.cpp
++++ b/src/exiv2plugin.cpp
+@@ -3,20 +3,9 @@
+ 
+ #include "exiv2plugin.h"
+ 
+-#include "../config-krename.h"
+-
+ #include <KLocalizedString>
+ 
+-#include <exiv2/error.hpp>
+-#include <exiv2/exif.hpp>
+-#include <exiv2/image.hpp>
+-#include <exiv2/iptc.hpp>
+-#ifdef HAVE_LIBEXIV2_0_27
+-    #include <exiv2/xmp_exiv2.hpp>
+-#else
+-    #include <exiv2/xmp.hpp>
+-#endif
+-#include <exiv2/tags.hpp>
++#include <exiv2/exiv2.hpp>
+ 
+ #include "batchrenamer.h"
+ #include "tokenhelpdialog.h"
+@@ -381,7 +370,11 @@ QString Exiv2Plugin::processFile(BatchRenamer *b, int index, const QString &file
+     std::string strFilename(asc.constData(), asc.length());
+ 
+     try {
++#if EXIV2_TEST_VERSION(0,28,0)
++        Image::UniquePtr image = Exiv2::ImageFactory::open(strFilename);
++#else
+         Image::AutoPtr image = Exiv2::ImageFactory::open(strFilename);
++#endif
+         if (image.get() != nullptr && image->good()) {
+             image->readMetadata();
+ 
+-- 
+GitLab
+
diff --git a/srcpkgs/krename/template b/srcpkgs/krename/template
index 66023163e3293..df5535007714a 100644
--- a/srcpkgs/krename/template
+++ b/srcpkgs/krename/template
@@ -1,7 +1,7 @@
 # Template file for 'krename'
 pkgname=krename
 version=5.0.2
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="extra-cmake-modules gettext kcoreaddons pkg-config qt5-host-tools qt5-qmake"
 makedepends="exiv2-devel freetype-devel kjs-devel kparts-devel libpodofo-devel

From 05568e14ad8874a1401bfafa88e118ac631599ca Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 12/22] krita: revbump for exiv2-0.28.0.

---
 srcpkgs/krita/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/krita/template b/srcpkgs/krita/template
index 63ee0fbe9bceb..f4d665daf7c31 100644
--- a/srcpkgs/krita/template
+++ b/srcpkgs/krita/template
@@ -1,7 +1,7 @@
 # Template file for 'krita'
 pkgname=krita
 version=5.2.1
-revision=1
+revision=2
 build_style=cmake
 configure_args="-Wno-dev -DBUILD_TESTING=OFF"
 hostmakedepends="extra-cmake-modules gettext pkg-config python3

From 86cd1274de7909c3bd880c043f4ff16b8d47797c Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 13/22] libextractor: revbump for exiv2-0.28.0.

---
 srcpkgs/libextractor/patches/exiv2-0.28.patch | 286 ++++++++++++++++++
 srcpkgs/libextractor/patches/fix-tests.diff   |  24 ++
 srcpkgs/libextractor/template                 |   2 +-
 3 files changed, 311 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/libextractor/patches/exiv2-0.28.patch
 create mode 100644 srcpkgs/libextractor/patches/fix-tests.diff

diff --git a/srcpkgs/libextractor/patches/exiv2-0.28.patch b/srcpkgs/libextractor/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..270a626d8ab06
--- /dev/null
+++ b/srcpkgs/libextractor/patches/exiv2-0.28.patch
@@ -0,0 +1,286 @@
+Patch-Source: https://gitlab.archlinux.org/archlinux/packaging/packages/libextractor/-/blob/main/exiv2-0.28.patch
+diff --git a/src/plugins/exiv2_extractor.cc b/src/plugins/exiv2_extractor.cc
+index 78f9bda..d32ed6a 100644
+--- a/src/plugins/exiv2_extractor.cc
++++ b/src/plugins/exiv2_extractor.cc
+@@ -90,7 +90,11 @@ virtual int close ();
+  * @param rcount number of bytes to read
+  * @return buffer with data read, empty buffer (!) on failure (!)
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++virtual Exiv2::DataBuf read (size_t rcount);
++#else
+ virtual Exiv2::DataBuf read (long rcount);
++#endif
+ 
+ /**
+  * Read up to 'rcount' bytes into 'buf'.
+@@ -99,8 +103,17 @@ virtual Exiv2::DataBuf read (long rcount);
+  * @param rcount size of 'buf'
+  * @return number of bytes read successfully, 0 on failure (!)
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++virtual size_t read (Exiv2::byte *buf,
++                   size_t rcount);
++#else
+ virtual long read (Exiv2::byte *buf,
+                    long rcount);
++#endif
++
++#if EXIV2_TEST_VERSION (0,28,0)
++virtual void populateFakeData();
++#endif
+ 
+ /**
+  * Read a single character.
+@@ -117,8 +130,13 @@ virtual int getb ();
+  * @param wcount how many bytes to write
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual size_t write (const Exiv2::byte *data,
++                    size_t wcount);
++#else
+ virtual long write (const Exiv2::byte *data,
+                     long wcount);
++#endif
+ 
+ /**
+  * Write to stream.
+@@ -126,7 +144,11 @@ virtual long write (const Exiv2::byte *data,
+  * @param src stream to copy
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual size_t write (Exiv2::BasicIo &src);
++#else
+ virtual long write (Exiv2::BasicIo &src);
++#endif
+ 
+ /**
+  * Write a single byte.
+@@ -172,7 +194,11 @@ virtual int munmap ();
+  *
+  * @return -1 on error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual size_t tell (void) const;
++#else
+ virtual long int tell (void) const;
++#endif
+ 
+ /**
+  * Return overall size of the file.
+@@ -213,7 +239,11 @@ virtual bool eof () const;
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual const std::string& path () const noexcept;
++#else
+ virtual std::string path () const;
++#endif
+ 
+ #ifdef EXV_UNICODE_PATH
+ /**
+@@ -230,7 +260,11 @@ virtual std::wstring wpath () const;
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual Exiv2::BasicIo::UniquePtr temporary () const;
++#else
+ virtual Exiv2::BasicIo::AutoPtr temporary () const;
++#endif
+ 
+ };
+ 
+@@ -266,7 +300,11 @@ ExtractorIO::close ()
+  * @return buffer with data read, empty buffer (!) on failure (!)
+  */
+ Exiv2::DataBuf
++#if EXIV2_TEST_VERSION (0,28,0)
++ExtractorIO::read (size_t rcount)
++#else
+ ExtractorIO::read (long rcount)
++#endif
+ {
+   void *data;
+   ssize_t ret;
+@@ -284,9 +322,15 @@ ExtractorIO::read (long rcount)
+  * @param rcount size of 'buf'
+  * @return number of bytes read successfully, 0 on failure (!)
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++size_t
++ExtractorIO::read (Exiv2::byte *buf,
++                   size_t rcount)
++#else
+ long
+ ExtractorIO::read (Exiv2::byte *buf,
+                    long rcount)
++#endif
+ {
+   void *data;
+   ssize_t ret;
+@@ -305,6 +349,12 @@ ExtractorIO::read (Exiv2::byte *buf,
+   return got;
+ }
+ 
++#if EXIV2_TEST_VERSION (0,28,0)
++void ExtractorIO::populateFakeData()
++{
++  return;
++}
++#endif
+ 
+ /**
+  * Read a single character.
+@@ -319,7 +369,9 @@ ExtractorIO::getb ()
+   const unsigned char *r;
+ 
+   if (1 != ec->read (ec->cls, &data, 1))
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION(0,28,0)
++    throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+     throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+     throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -336,9 +388,15 @@ ExtractorIO::getb ()
+  * @param wcount how many bytes to write
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++size_t
++ExtractorIO::write (const Exiv2::byte *data,
++                    size_t wcount)
++#else
+ long
+ ExtractorIO::write (const Exiv2::byte *data,
+                     long wcount)
++#endif
+ {
+   return -1;
+ }
+@@ -350,7 +408,11 @@ ExtractorIO::write (const Exiv2::byte *data,
+  * @param src stream to copy
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++size_t
++#else
+ long
++#endif
+ ExtractorIO::write (Exiv2::BasicIo &src)
+ {
+   return -1;
+@@ -378,7 +440,9 @@ ExtractorIO::putb (Exiv2::byte data)
+ void
+ ExtractorIO::transfer (Exiv2::BasicIo& src)
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION(0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -427,7 +491,9 @@ ExtractorIO::seek (long offset,
+ Exiv2::byte *
+ ExtractorIO::mmap (bool isWritable)
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION (0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -452,7 +518,11 @@ ExtractorIO::munmap ()
+  *
+  * @return -1 on error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++size_t
++#else
+ long int
++#endif
+ ExtractorIO::tell (void) const
+ {
+   return (long) ec->seek (ec->cls, 0, SEEK_CUR);
+@@ -516,10 +586,17 @@ ExtractorIO::eof () const
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++const std::string&
++ExtractorIO::path () const noexcept
++#else
+ std::string
+ ExtractorIO::path () const
++#endif
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION (0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -536,7 +613,9 @@ ExtractorIO::path () const
+ std::wstring
+ ExtractorIO::wpath () const
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION (0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -552,11 +631,17 @@ ExtractorIO::wpath () const
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++Exiv2::BasicIo::UniquePtr
++#else
+ Exiv2::BasicIo::AutoPtr
++#endif
+ ExtractorIO::temporary () const
+ {
+   fprintf (stderr, "throwing temporary error\n");
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION(0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -737,8 +822,13 @@ EXTRACTOR_exiv2_extract_method (struct EXTRACTOR_ExtractContext *ec)
+ #if ! EXIV2_TEST_VERSION (0,24,0)
+     Exiv2::LogMsg::setLevel (Exiv2::LogMsg::mute);
+ #endif
++#if EXIV2_TEST_VERSION(0,28,0)
++    std::unique_ptr<Exiv2::BasicIo> eio (new ExtractorIO (ec));
++    Exiv2::Image::UniquePtr image = Exiv2::ImageFactory::open (std::move(eio));
++#else
+     std::auto_ptr<Exiv2::BasicIo> eio (new ExtractorIO (ec));
+     Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open (eio);
++#endif
+     if (0 == image.get ())
+       return;
+     image->readMetadata ();
+@@ -822,7 +912,11 @@ EXTRACTOR_exiv2_extract_method (struct EXTRACTOR_ExtractContext *ec)
+       ADDXMP ("Xmp.lr.hierarchicalSubject", EXTRACTOR_METATYPE_SUBJECT);
+     }
+   }
++#if EXIV2_TEST_VERSION (0,28,0)
++  catch (const Exiv2::Error& e)
++#else
+   catch (const Exiv2::AnyError& e)
++#endif
+   {
+ #if DEBUG
+     std::cerr << "Caught Exiv2 exception '" << e << "'\n";
diff --git a/srcpkgs/libextractor/patches/fix-tests.diff b/srcpkgs/libextractor/patches/fix-tests.diff
new file mode 100644
index 0000000000000..3b4ee7cbeea33
--- /dev/null
+++ b/srcpkgs/libextractor/patches/fix-tests.diff
@@ -0,0 +1,24 @@
+--- a/src/plugins/test_exiv2.c	2021-01-30 13:20:23.000000000 +0000
++++ b/src/plugins/test_exiv2.c	2023-11-03 19:39:43.115274492 +0000
+@@ -49,8 +49,8 @@
+       EXTRACTOR_METATYPE_GPS_LATITUDE,
+       EXTRACTOR_METAFORMAT_UTF8,
+       "text/plain",
+-      "28deg 8' (18|17.585)\" ?",
+-      strlen ("28deg 8' (18|17.585)\" ?") + 1,
++      "28 deg 8' (18|17.58)\" ?",
++      strlen ("28 deg 8' (18|17.58)\" ?") + 1,
+       0,
+       .regex = 1
+     },
+@@ -66,8 +66,8 @@
+       EXTRACTOR_METATYPE_GPS_LONGITUDE,
+       EXTRACTOR_METAFORMAT_UTF8,
+       "text/plain",
+-      "14deg 14' (22|21.713)\" ?",
+-      strlen ("14deg 14' (22|21.713)\" ?"),
++      "14 deg 14' (22|21.71)\" ?",
++      strlen ("14 deg 14' (22|21.71)\" ?"),
+       0,
+       .regex = 1
+     },
diff --git a/srcpkgs/libextractor/template b/srcpkgs/libextractor/template
index ddd4790f93e88..bfcea979a308c 100644
--- a/srcpkgs/libextractor/template
+++ b/srcpkgs/libextractor/template
@@ -1,7 +1,7 @@
 # Template file for 'libextractor'
 pkgname=libextractor
 version=1.11
-revision=2
+revision=3
 build_style=gnu-configure
 configure_args="--disable-static"
 hostmakedepends="pkg-config"

From cb83ab646157adb38a0e98ee784afdce03b0d147 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 14/22] libgexiv2: update to 0.14.2.

---
 srcpkgs/libgexiv2/template | 14 +++++++-------
 1 file changed, 7 insertions(+), 7 deletions(-)

diff --git a/srcpkgs/libgexiv2/template b/srcpkgs/libgexiv2/template
index 23780e5397dc4..91dbcaa9aca52 100644
--- a/srcpkgs/libgexiv2/template
+++ b/srcpkgs/libgexiv2/template
@@ -1,19 +1,19 @@
 # Template file for 'libgexiv2'
 pkgname=libgexiv2
-version=0.14.0
-revision=3
+version=0.14.2
+revision=1
 build_style=meson
 build_helper="gir"
-configure_args="-Dintrospection=$(vopt_if gir true false)
- -Dvapi=$(vopt_if vala true false)"
+configure_args="$(vopt_bool gir introspection) $(vopt_bool vala vapi)"
 hostmakedepends="pkg-config glib-devel $(vopt_if vala 'vala') python3-gobject"
 makedepends="libglib-devel exiv2-devel"
 short_desc="GObject-based wrapper around the Exiv2 library"
 maintainer="Enno Boland <gottox@voidlinux.org>"
 license="GPL-2.0-or-later"
 homepage="https://wiki.gnome.org/Projects/gexiv2"
-distfiles="${GNOME_SITE}/gexiv2/${version%.*}/${pkgname/lib/}-${version}.tar.xz"
-checksum=e58279a6ff20b6f64fa499615da5e9b57cf65ba7850b72fafdf17221a9d6d69e
+changelog="https://gitlab.gnome.org/GNOME/gexiv2/-/raw/master/NEWS"
+distfiles="${GNOME_SITE}/gexiv2/${version%.*}/gexiv2-${version}.tar.xz"
+checksum=2a0c9cf48fbe8b3435008866ffd40b8eddb0667d2212b42396fdf688e93ce0be
 
 build_options="gir vala"
 build_options_default="gir vala"
@@ -23,7 +23,7 @@ libgexiv2-devel_package() {
 	short_desc+=" - development files"
 	pkg_install() {
 		vmove usr/include
-		vmove usr/lib/*.so
+		vmove "usr/lib/*.so"
 		vmove usr/lib/pkgconfig
 		if [ "$build_option_vala" ]; then
 			vmove usr/share/vala

From 93a6f65be6a3effa0136ff7bbe07861b32c623a1 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 15/22] libkexiv25: update to 23.08.2.

---
 srcpkgs/libkexiv25/template | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/srcpkgs/libkexiv25/template b/srcpkgs/libkexiv25/template
index b439a42ef2b97..4d7f9600572ea 100644
--- a/srcpkgs/libkexiv25/template
+++ b/srcpkgs/libkexiv25/template
@@ -1,6 +1,6 @@
 # Template file for 'libkexiv25'
 pkgname=libkexiv25
-version=23.04.0
+version=23.08.2
 revision=1
 build_style=cmake
 configure_args="-DBUILD_TESTING=OFF"
@@ -11,7 +11,7 @@ maintainer="Orphaned <orphan@voidlinux.org>"
 license="GPL-2.0-or-later"
 homepage="https://invent.kde.org/graphics/libkexiv2"
 distfiles="${KDE_SITE}/release-service/${version}/src/libkexiv2-${version}.tar.xz"
-checksum=18d3eed06df9d1e31d8434ed9887e305aba176d0856e19a8cd3bdb555b80d391
+checksum=d06e36a408bf2e846a18056a1f15e61d981fa2a1fceb81f7c15136604319d033
 
 libkexiv25-devel_package() {
 	short_desc+=" - development files"

From 69c76a42fc1801014175f8fad320628e06d8d437 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 16/22] nomacs: update to 3.17.2287.

---
 srcpkgs/nomacs/template | 17 +++++++++++++----
 1 file changed, 13 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/nomacs/template b/srcpkgs/nomacs/template
index c52cd54e294db..956bd21ebb129 100644
--- a/srcpkgs/nomacs/template
+++ b/srcpkgs/nomacs/template
@@ -1,7 +1,8 @@
 # Template file for 'nomacs'
 pkgname=nomacs
-version=3.16.224
-revision=5
+version=3.17.2287
+revision=1
+_plugins_ver=3.17.2285
 build_wrksrc=ImageLounge
 build_style=cmake
 configure_args="-DCMAKE_BUILD_TYPE=None -DENABLE_TRANSLATIONS=1
@@ -13,5 +14,13 @@ short_desc="Simple yet powerful Qt imageviewer"
 maintainer="Orphaned <orphan@voidlinux.org>"
 license="GPL-3.0-or-later"
 homepage="https://github.com/nomacs/nomacs"
-distfiles="https://github.com/nomacs/nomacs/archive/${version}.tar.gz"
-checksum=bbc7e9048026ef9e0d2b64902c88050f17a679ef3d3c009de2c3b7de5d1d217c
+distfiles="https://github.com/nomacs/nomacs/archive/${version}.tar.gz
+ https://github.com/novomesk/nomacs-plugins/archive/refs/tags/${_plugins_ver}.tar.gz>plugins.tar.gz"
+checksum="6905ea615358f84a0c83d5b1b7077871dea0526ec667500a1951448cb845a92c
+ 946b2d754be9ecca5cb155f7ecc5dcafb164f6c3dcc7bf5c3c0610d3b47774aa"
+skip_extraction="plugins.tar.gz"
+
+post_extract() {
+ cd ${build_wrksrc}
+ vsrcextract -C plugins "plugins.tar.gz"
+}

From 2c5617145e7b1a640ea8d1a99e633f8da0183e19 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 17/22] pdf2djvu: revbump for exiv2-0.28.0.

---
 srcpkgs/pdf2djvu/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/pdf2djvu/template b/srcpkgs/pdf2djvu/template
index ef7433c0c98ae..5a6f3ddf4ed35 100644
--- a/srcpkgs/pdf2djvu/template
+++ b/srcpkgs/pdf2djvu/template
@@ -1,7 +1,7 @@
 # Template file for 'pdf2djvu'
 pkgname=pdf2djvu
 version=0.9.19
-revision=4
+revision=5
 build_style=gnu-configure
 hostmakedepends="pkg-config djvulibre gettext"
 makedepends="djvulibre-devel poppler-devel libgraphicsmagick-devel exiv2-devel libuuid-devel"

From 18a93e23d77ec37a189e97832501ff62c75d798a Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 18/22] phototonic: revbump for exiv2-0.28.0.

---
 srcpkgs/phototonic/patches/exiv2-0.28.patch | 135 ++++++++++++++++++++
 srcpkgs/phototonic/template                 |   2 +-
 2 files changed, 136 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/phototonic/patches/exiv2-0.28.patch

diff --git a/srcpkgs/phototonic/patches/exiv2-0.28.patch b/srcpkgs/phototonic/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..1c75b628dab33
--- /dev/null
+++ b/srcpkgs/phototonic/patches/exiv2-0.28.patch
@@ -0,0 +1,135 @@
+From 923a3fc14de0b779a45696c5f0aef34c74d84f13 Mon Sep 17 00:00:00 2001
+From: Andreas Sturmlechner <asturm@gentoo.org>
+Date: Sun, 28 May 2023 18:54:10 +0200
+Subject: [PATCH] Fix build with exiv2-0.28
+
+Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>
+---
+ ImageViewer.cpp   | 9 +++++++++
+ MetadataCache.cpp | 8 ++++++++
+ Phototonic.cpp    | 4 ++++
+ Tags.cpp          | 8 ++++++++
+ ThumbsViewer.cpp  | 4 ++++
+ 5 files changed, 33 insertions(+)
+
+diff --git a/ImageViewer.cpp b/ImageViewer.cpp
+index 357d223..df3ac43 100644
+--- a/ImageViewer.cpp
++++ b/ImageViewer.cpp
+@@ -945,7 +945,11 @@ void ImageViewer::keyMoveEvent(int direction) {
+ }
+ 
+ void ImageViewer::saveImage() {
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr image;
++#else
+     Exiv2::Image::AutoPtr image;
++#endif
+     bool exifError = false;
+ 
+     if (newImage) {
+@@ -985,8 +989,13 @@ void ImageViewer::saveImage() {
+ }
+ 
+ void ImageViewer::saveImageAs() {
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++    Exiv2::Image::UniquePtr newExifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
+     Exiv2::Image::AutoPtr newExifImage;
++#endif
+     bool exifError = false;
+ 
+     setCursorHiding(false);
+diff --git a/MetadataCache.cpp b/MetadataCache.cpp
+index 524ae74..5ddd4c8 100644
+--- a/MetadataCache.cpp
++++ b/MetadataCache.cpp
+@@ -64,7 +64,11 @@ void MetadataCache::clear() {
+ }
+ 
+ bool MetadataCache::loadImageMetadata(const QString &imageFullPath) {
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
++#endif
+     QSet<QString> tags;
+     long orientation = 0;
+ 
+@@ -78,7 +82,11 @@ bool MetadataCache::loadImageMetadata(const QString &imageFullPath) {
+     try {
+         Exiv2::ExifData &exifData = exifImage->exifData();
+         if (!exifData.empty()) {
++#if EXIV2_TEST_VERSION(0,28,0)
++            orientation = exifData["Exif.Image.Orientation"].value().toUint32();
++#else
+             orientation = exifData["Exif.Image.Orientation"].value().toLong();
++#endif
+         }
+     } catch (Exiv2::Error &error) {
+         qWarning() << "Failed to read Exif metadata";
+diff --git a/Phototonic.cpp b/Phototonic.cpp
+index 6cc95b3..bd5497d 100644
+--- a/Phototonic.cpp
++++ b/Phototonic.cpp
+@@ -3151,7 +3151,11 @@ void Phototonic::removeMetadata() {
+ 
+     if (ret == MessageBox::Yes) {
+         for (int file = 0; file < fileList.size(); ++file) {
++#if EXIV2_TEST_VERSION(0,28,0)
++            Exiv2::Image::UniquePtr image;
++#else
+             Exiv2::Image::AutoPtr image;
++#endif
+             try {
+                 image = Exiv2::ImageFactory::open(fileList[file].toStdString());
+                 image->clearMetadata();
+diff --git a/Tags.cpp b/Tags.cpp
+index 84eea16..a62da9d 100644
+--- a/Tags.cpp
++++ b/Tags.cpp
+@@ -136,7 +136,11 @@ void ImageTags::addTag(QString tagName, bool tagChecked) {
+ 
+ bool ImageTags::writeTagsToImage(QString &imageFileName, QSet<QString> &newTags) {
+     QSet<QString> imageTags;
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
++#endif
+ 
+     try {
+         exifImage = Exiv2::ImageFactory::open(imageFileName.toStdString());
+@@ -160,7 +164,11 @@ bool ImageTags::writeTagsToImage(QString &imageFileName, QSet<QString> &newTags)
+         QSetIterator<QString> newTagsIt(newTags);
+         while (newTagsIt.hasNext()) {
+             QString tag = newTagsIt.next();
++#if EXIV2_TEST_VERSION(0,28,0)
++            Exiv2::Value::UniquePtr value = Exiv2::Value::create(Exiv2::string);
++#else
+             Exiv2::Value::AutoPtr value = Exiv2::Value::create(Exiv2::string);
++#endif
+             value->read(tag.toStdString());
+             Exiv2::IptcKey key("Iptc.Application2.Keywords");
+             newIptcData.add(key, value.get());
+diff --git a/ThumbsViewer.cpp b/ThumbsViewer.cpp
+index 77a6189..4a11475 100644
+--- a/ThumbsViewer.cpp
++++ b/ThumbsViewer.cpp
+@@ -210,7 +210,11 @@ void ThumbsViewer::updateImageInfoViewer(QString imageFullPath) {
+         infoView->addEntry(key, val);
+     }
+ 
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
++#endif
+     try {
+         exifImage = Exiv2::ImageFactory::open(imageFullPath.toStdString());
+         exifImage->readMetadata();
+-- 
+2.40.1
+
diff --git a/srcpkgs/phototonic/template b/srcpkgs/phototonic/template
index 77ae8bf6a4406..4af006cb7da41 100644
--- a/srcpkgs/phototonic/template
+++ b/srcpkgs/phototonic/template
@@ -1,7 +1,7 @@
 # Template file for 'phototonic'
 pkgname=phototonic
 version=2.1
-revision=3
+revision=4
 build_style=qmake
 hostmakedepends="pkg-config qt5-qmake qt5-host-tools"
 makedepends="qt5-svg-devel exiv2-devel"

From 1bd6b9bfd5e2863f214a5fa4cc4d499146e847a9 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 19/22] qimgv: revbump for exiv2-0.28.0.

---
 srcpkgs/qimgv/patches/exiv2-0.28.patch | 16 ++++++++++++++++
 srcpkgs/qimgv/template                 |  2 +-
 2 files changed, 17 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/qimgv/patches/exiv2-0.28.patch

diff --git a/srcpkgs/qimgv/patches/exiv2-0.28.patch b/srcpkgs/qimgv/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..11f37b5ae2be3
--- /dev/null
+++ b/srcpkgs/qimgv/patches/exiv2-0.28.patch
@@ -0,0 +1,16 @@
+Patch-Source: https://git.alpinelinux.org/aports/tree/community/qimgv/exiv2-0.28.patch
+diff --git a/qimgv/sourcecontainers/documentinfo.cpp b/qimgv/sourcecontainers/documentinfo.cpp
+index 98a68f7..c062474 100644
+--- a/qimgv/sourcecontainers/documentinfo.cpp
++++ b/qimgv/sourcecontainers/documentinfo.cpp
+@@ -271,10 +271,6 @@ void DocumentInfo::loadExifTags() {
+         //std::cout << "Caught Exiv2 exception '" << e.what() << "'\n";
+         return;
+     }
+-    catch (Exiv2::BasicError<CharType> e) {
+-        //std::cout << "Caught BasicError Exiv2 exception '" << e.what() << "'\n";
+-        return;
+-    }
+ #endif
+ }
+ 
diff --git a/srcpkgs/qimgv/template b/srcpkgs/qimgv/template
index 7eb30db33992c..dd341dfe1bfce 100644
--- a/srcpkgs/qimgv/template
+++ b/srcpkgs/qimgv/template
@@ -1,7 +1,7 @@
 # Template file for 'qimgv'
 pkgname=qimgv
 version=1.0.2
-revision=2
+revision=3
 build_style=cmake
 configure_args="$(vopt_if video -DVIDEO_SUPPORT=ON -DVIDEO_SUPPORT=OFF)
  $(vopt_if scale -DOPENCV_SUPPORT=ON -DOPENCV_SUPPORT=OFF)

From 1dd9d0b2afa52689d3be8db16e1f4edbf135f30e Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 20/22] SIR: revbump for exiv2-0.28.0.

---
 srcpkgs/SIR/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/SIR/template b/srcpkgs/SIR/template
index 113077acad354..c6da4c26b6c71 100644
--- a/srcpkgs/SIR/template
+++ b/srcpkgs/SIR/template
@@ -1,7 +1,7 @@
 # Template file for 'SIR'
 pkgname=SIR
 version=3.2.2
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="pkg-config"
 makedepends="exiv2-devel qt5-svg-devel qt5-tools-devel"

From 390e24e4ff381159196ca3a8d53be62b43a55c61 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 21/22] viewnior: revbump for exiv2-0.28.0.

---
 srcpkgs/viewnior/patches/exiv2-0.28.patch | 147 ++++++++++++++++++++++
 srcpkgs/viewnior/template                 |   2 +-
 2 files changed, 148 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/viewnior/patches/exiv2-0.28.patch

diff --git a/srcpkgs/viewnior/patches/exiv2-0.28.patch b/srcpkgs/viewnior/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..71459dee15768
--- /dev/null
+++ b/srcpkgs/viewnior/patches/exiv2-0.28.patch
@@ -0,0 +1,147 @@
+Patch-Source: https://gitlab.archlinux.org/archlinux/packaging/packages/viewnior/-/blob/f206ce6c22a3ec5f1f9ea1bde4077584f80458dd/exiv2-0.28.patch
+--
+From b6bb81a1b46e911d15bbf9a730972523de177705 Mon Sep 17 00:00:00 2001
+From: tastytea <tastytea@tastytea.de>
+Date: Tue, 16 May 2023 10:54:40 +0200
+Subject: [PATCH 1/2] change exiv2 AutoPtr to unique_ptr
+
+exiv2-0.28.0 removed Exiv2::Image::AutoPtr and added
+Exiv2::Image::UniquePtr instead. since it's a typedef for
+std::unique_ptr<Image>, i'm using that directly instead of adding a
+condition on the exiv2 version.
+---
+ src/uni-exiv2.cpp | 21 +++++++++++----------
+ 1 file changed, 11 insertions(+), 10 deletions(-)
+
+diff --git a/src/uni-exiv2.cpp b/src/uni-exiv2.cpp
+index 0d14b9f..77064c2 100644
+--- a/src/uni-exiv2.cpp
++++ b/src/uni-exiv2.cpp
+@@ -22,12 +22,13 @@
+ 
+ #include <exiv2/exiv2.hpp>
+ #include <iostream>
++#include <memory>
+ 
+ #include "uni-exiv2.hpp"
+ 
+ #define ARRAY_SIZE(array) (sizeof array/sizeof(array[0]))
+ 
+-static Exiv2::Image::AutoPtr cached_image;
++static std::unique_ptr<Exiv2::Image> cached_image;
+ 
+ extern "C"
+ void
+@@ -35,8 +36,8 @@ uni_read_exiv2_map(const char *uri, void (*callback)(const char*, const char*, v
+ {
+     Exiv2::LogMsg::setLevel(Exiv2::LogMsg::mute);
+     try {
+-        Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open(uri);
+-        if ( image.get() == 0 ) {
++        std::unique_ptr<Exiv2::Image> image = Exiv2::ImageFactory::open(uri);
++        if (image == nullptr) {
+             return;
+         }
+ 
+@@ -91,14 +92,14 @@ uni_read_exiv2_to_cache(const char *uri)
+ {
+     Exiv2::LogMsg::setLevel(Exiv2::LogMsg::mute);
+ 
+-    if ( cached_image.get() != NULL ) {
++    if (cached_image != nullptr) {
+         cached_image->clearMetadata();
+-        cached_image.reset(NULL);
++        cached_image.reset(nullptr);
+     }
+ 
+     try {
+         cached_image = Exiv2::ImageFactory::open(uri);
+-        if ( cached_image.get() == 0 ) {
++        if (cached_image == nullptr) {
+             return 1;
+         }
+ 
+@@ -116,13 +117,13 @@ uni_write_exiv2_from_cache(const char *uri)
+ {
+     Exiv2::LogMsg::setLevel(Exiv2::LogMsg::mute);
+ 
+-    if ( cached_image.get() == NULL ) {
++    if (cached_image == nullptr) {
+         return 1;
+     }
+ 
+     try {
+-        Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open(uri);
+-        if ( image.get() == 0 ) {
++        std::unique_ptr<Exiv2::Image> image = Exiv2::ImageFactory::open(uri);
++        if (image == nullptr) {
+             return 2;
+         }
+ 
+@@ -130,7 +131,7 @@ uni_write_exiv2_from_cache(const char *uri)
+         image->writeMetadata();
+ 
+         cached_image->clearMetadata();
+-        cached_image.reset(NULL);
++        cached_image.reset(nullptr);
+ 
+         return 0;
+     } catch (Exiv2::AnyError& e) {
+
+From 47d0b98cb46526aa8aa035bebcabc14a11fa57ee Mon Sep 17 00:00:00 2001
+From: tastytea <tastytea@tastytea.de>
+Date: Tue, 16 May 2023 11:17:00 +0200
+Subject: [PATCH 2/2] add support for exiv-0.28.0 errors
+
+exiv2-0.28.0 changed Exiv2::AnyError to Exiv2::Error.
+---
+ src/uni-exiv2.cpp | 15 ++++++++++++---
+ 1 file changed, 12 insertions(+), 3 deletions(-)
+
+diff --git a/src/uni-exiv2.cpp b/src/uni-exiv2.cpp
+index 77064c2..567a50f 100644
+--- a/src/uni-exiv2.cpp
++++ b/src/uni-exiv2.cpp
+@@ -28,6 +28,15 @@
+ 
+ #define ARRAY_SIZE(array) (sizeof array/sizeof(array[0]))
+ 
++#define EXIV_ERROR Exiv2::AnyError
++#ifdef EXIV2_VERSION
++    #ifdef EXIV2_TEST_VERSION
++        #if EXIV2_TEST_VERSION(0,28,0)
++            #define EXIV_ERROR Exiv2::Error
++        #endif
++    #endif
++#endif
++
+ static std::unique_ptr<Exiv2::Image> cached_image;
+ 
+ extern "C"
+@@ -81,7 +90,7 @@ uni_read_exiv2_map(const char *uri, void (*callback)(const char*, const char*, v
+                 }
+             }
+         }
+-    } catch (Exiv2::AnyError& e) {
++    } catch (EXIV_ERROR& e) {
+         std::cerr << "Exiv2: '" << e << "'\n";
+     }
+ }
+@@ -104,7 +113,7 @@ uni_read_exiv2_to_cache(const char *uri)
+         }
+ 
+         cached_image->readMetadata();
+-    } catch (Exiv2::AnyError& e) {
++    } catch (EXIV_ERROR& e) {
+         std::cerr << "Exiv2: '" << e << "'\n";
+     }
+ 
+@@ -134,7 +143,7 @@ uni_write_exiv2_from_cache(const char *uri)
+         cached_image.reset(nullptr);
+ 
+         return 0;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (EXIV_ERROR& e) {
+         std::cerr << "Exiv2: '" << e << "'\n";
+     }
+ 
diff --git a/srcpkgs/viewnior/template b/srcpkgs/viewnior/template
index ea1e528a8651f..4c73226662ca0 100644
--- a/srcpkgs/viewnior/template
+++ b/srcpkgs/viewnior/template
@@ -1,7 +1,7 @@
 # Template file for 'viewnior'
 pkgname=viewnior
 version=1.8
-revision=1
+revision=2
 build_style=meson
 hostmakedepends="pkg-config intltool glib-devel gettext-devel"
 makedepends="gtk+-devel exiv2-devel"

From 30c7177fc8e435c1e42521d3d34600578220e8f3 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Mon, 23 Oct 2023 19:06:34 +0200
Subject: [PATCH 22/22] New package: nufraw-0.43.3

Co-authored-by: Mohammed Anas <triallax@tutanota.com>
---
 srcpkgs/nufraw-gimp                           |  1 +
 .../patches/0001-nufraw-glib-2.70.patch       | 20 +++++++
 srcpkgs/nufraw/patches/exiv-0.28.x.diff       | 59 +++++++++++++++++++
 srcpkgs/nufraw/template                       | 47 +++++++++++++++
 srcpkgs/removed-packages/template             |  8 ++-
 srcpkgs/ufraw                                 |  1 +
 srcpkgs/ufraw-gimp                            |  2 +-
 .../ufraw/patches/001-no-gimp-remote.patch    | 12 ----
 srcpkgs/ufraw/patches/002-fix_abs_int.patch   | 11 ----
 .../ufraw/patches/03_fix-unsigned-char.patch  | 14 -----
 srcpkgs/ufraw/patches/exiv-0.27.patch         | 25 --------
 srcpkgs/ufraw/patches/glib-2.68.patch         | 30 ----------
 srcpkgs/ufraw/patches/iostream.patch          | 13 ----
 srcpkgs/ufraw/template                        | 38 ------------
 14 files changed, 134 insertions(+), 147 deletions(-)
 create mode 120000 srcpkgs/nufraw-gimp
 create mode 100644 srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch
 create mode 100644 srcpkgs/nufraw/patches/exiv-0.28.x.diff
 create mode 100644 srcpkgs/nufraw/template
 create mode 120000 srcpkgs/ufraw
 delete mode 100644 srcpkgs/ufraw/patches/001-no-gimp-remote.patch
 delete mode 100644 srcpkgs/ufraw/patches/002-fix_abs_int.patch
 delete mode 100644 srcpkgs/ufraw/patches/03_fix-unsigned-char.patch
 delete mode 100644 srcpkgs/ufraw/patches/exiv-0.27.patch
 delete mode 100644 srcpkgs/ufraw/patches/glib-2.68.patch
 delete mode 100644 srcpkgs/ufraw/patches/iostream.patch
 delete mode 100644 srcpkgs/ufraw/template

diff --git a/srcpkgs/nufraw-gimp b/srcpkgs/nufraw-gimp
new file mode 120000
index 0000000000000..0bd1459b2a16f
--- /dev/null
+++ b/srcpkgs/nufraw-gimp
@@ -0,0 +1 @@
+nufraw
\ No newline at end of file
diff --git a/srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch b/srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch
new file mode 100644
index 0000000000000..41f10bfbafa1f
--- /dev/null
+++ b/srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch
@@ -0,0 +1,20 @@
+diff -ru nufraw/uf_glib.h nufraw/uf_glib.h
+--- nufraw/uf_glib.h	2022-02-23 09:03:44.700472919 +0100
++++ nufraw/uf_glib.h	2022-02-23 09:04:50.260308805 +0100
+@@ -13,13 +13,13 @@
+ #ifndef _UF_GLIB_H
+ #define _UF_GLIB_H
+ 
++#include <glib.h>
++#include <glib/gstdio.h>
++
+ #ifdef __cplusplus
+ extern "C" {
+ #endif
+ 
+-#include <glib.h>
+-#include <glib/gstdio.h>
+-
+ // g_win32_locale_filename_from_utf8 is needed only on win32
+ #ifdef _WIN32
+ #define uf_win32_locale_filename_from_utf8(__some_string__) \
diff --git a/srcpkgs/nufraw/patches/exiv-0.28.x.diff b/srcpkgs/nufraw/patches/exiv-0.28.x.diff
new file mode 100644
index 0000000000000..6c23359bf706c
--- /dev/null
+++ b/srcpkgs/nufraw/patches/exiv-0.28.x.diff
@@ -0,0 +1,59 @@
+Patch taken from AUR package: https://aur.archlinux.org/cgit/aur.git/tree/exiv2-error.patch?h=nufraw&id=29e467f2c297fcd0f36548642d6d2cab6428d08f
+diff --git a/nufraw_exiv2.cc b/nufraw_exiv2.cc
+index 2de4cc3..45aea87 100644
+--- a/nufraw_exiv2.cc
++++ b/nufraw_exiv2.cc
+@@ -54,7 +54,7 @@ extern "C" int nufraw_exif_read_input(nufraw_data *uf)
+         uf->inputExifBuf = NULL;
+         uf->inputExifBufLen = 0;
+ 
+-        Exiv2::Image::AutoPtr image;
++        Exiv2::Image::UniquePtr image;
+         if (uf->unzippedBuf != NULL) {
+             image = Exiv2::ImageFactory::open(
+                         (const Exiv2::byte*)uf->unzippedBuf, uf->unzippedBufLen);
+@@ -135,7 +135,7 @@ extern "C" int nufraw_exif_read_input(nufraw_data *uf)
+         nufraw_message(NUFRAW_SET_LOG, "%s\n", stderror.str().c_str());
+ 
+         return NUFRAW_SUCCESS;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (Exiv2::Error& e) {
+         std::cerr.rdbuf(savecerr);
+         std::string s(e.what());
+         nufraw_message(NUFRAW_SET_WARNING, "%s\n", s.c_str());
+@@ -156,7 +156,7 @@ static Exiv2::ExifData nufraw_prepare_exifdata(nufraw_data *uf)
+         if ((pos = exifData.findKey(Exiv2::ExifKey("Exif.Image.Orientation")))
+                 != exifData.end()) {
+             nufraw_message(NUFRAW_SET_LOG, "Resetting %s from '%d' to '1'\n",
+-                          pos->key().c_str(), pos->value().toLong());
++                          pos->key().c_str(), pos->value().toInt64());
+             pos->setValue("1"); /* 1 = Normal orientation */
+         }
+     }
+@@ -327,7 +327,7 @@ extern "C" int nufraw_exif_prepare_output(nufraw_data *uf)
+         nufraw_message(NUFRAW_SET_LOG, "%s\n", stderror.str().c_str());
+ 
+         return NUFRAW_SUCCESS;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (Exiv2::Error& e) {
+         std::cerr.rdbuf(savecerr);
+         std::string s(e.what());
+         nufraw_message(NUFRAW_SET_WARNING, "%s\n", s.c_str());
+@@ -347,7 +347,7 @@ extern "C" int nufraw_exif_write(nufraw_data *uf)
+ 
+         char *filename =
+             uf_win32_locale_filename_from_utf8(uf->conf->outputFilename);
+-        Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open(filename);
++        Exiv2::Image::UniquePtr image = Exiv2::ImageFactory::open(filename);
+         uf_win32_locale_filename_free(filename);
+         assert(image.get() != 0);
+ 
+@@ -367,7 +367,7 @@ extern "C" int nufraw_exif_write(nufraw_data *uf)
+         nufraw_message(NUFRAW_SET_LOG, "%s\n", stderror.str().c_str());
+ 
+         return NUFRAW_SUCCESS;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (Exiv2::Error& e) {
+         std::cerr.rdbuf(savecerr);
+         std::string s(e.what());
+         nufraw_message(NUFRAW_SET_WARNING, "%s\n", s.c_str());
diff --git a/srcpkgs/nufraw/template b/srcpkgs/nufraw/template
new file mode 100644
index 0000000000000..3e5d7d190b335
--- /dev/null
+++ b/srcpkgs/nufraw/template
@@ -0,0 +1,47 @@
+# Template file for 'nufraw'
+pkgname=nufraw
+version=0.43.3
+revision=1
+_ver="${version%.*}-${version##*.}"
+build_style=gnu-configure
+configure_args="--enable-contrast --enable-mime --enable-openmp --with-gimp
+ --enable-extras"
+hostmakedepends="pkg-config automake libtool"
+makedepends="exiv2-devel gimp-devel glib-devel gtkimageview-devel lcms2-devel lensfun-devel
+ jasper-devel"
+depends="desktop-file-utils"
+short_desc="Utility to read and manipulate raw images from digital cameras"
+maintainer="John <me@johnnynator.dev>"
+license="GPL-2.0-or-later"
+homepage="https://sourceforge.net/projects/nufraw/"
+distfiles="${SOURCEFORGE_SITE}/nufraw/nufraw-${_ver}.tar.gz"
+checksum=2c7dcc1590993ec267b3112562b2433010d6f94f6acc6506c76aa29cf8c6c32c
+
+pre_configure() {
+	autoreconf -fi
+}
+
+pre_build() {
+	mv nufraw.desktop{.desktop,}
+	chmod +x generate_schemas.sh
+}
+
+nufraw-gimp_package() {
+	depends="${sourcepkg}>=${version}_${revision}"
+	short_desc+=" - gimp plugin"
+	pkg_install() {
+		vmove usr/lib/gimp
+	}
+}
+
+ufraw_package() {
+	depends="${sourcepkg}>=${version}_${revision}"
+	build_style=meta
+	short_desc+=" (transitional dummy package)"
+}
+
+ufraw-gimp_package() {
+	depends="nufraw-gimp>=${version}_${revision}"
+	build_style=meta
+	short_desc+=" - gimp plugin (transitional dummy package)"
+}
diff --git a/srcpkgs/removed-packages/template b/srcpkgs/removed-packages/template
index abedf26f739b6..f3d81a8afe04c 100644
--- a/srcpkgs/removed-packages/template
+++ b/srcpkgs/removed-packages/template
@@ -1,6 +1,6 @@
 # Template file for 'removed-packages'
 pkgname=removed-packages
-version=0.1.20231019
+version=0.1.20231101
 revision=1
 build_style=meta
 short_desc="Uninstalls packages removed from repository"
@@ -590,8 +590,8 @@ replaces="
  python3-Flask-Assets<=0.12_9
  python3-Flask-Mail<=0.9.1_5
  python3-Flask-OAuthlib<=0.9.6_4
- python3-Flask-Script<=2.0.6_7
  python3-Flask-SQLAlchemy<=2.5.1_4
+ python3-Flask-Script<=2.0.6_7
  python3-Flask-User<=1.0.2.2_6
  python3-SPARQLWrapper<=1.8.4_4
  python3-aiohttp-cors2<=0.7.0_3
@@ -642,8 +642,8 @@ replaces="
  raul-devel<=0.8.0_6
  raul<=0.8.0_6
  redkite<=1.3.1_1
- rem<=2.10.0_1
  rem-devel<=2.10.0_1
+ rem<=2.10.0_1
  reminiscence<=0.4.6_1
  rkt-stage1-coreos<=1.30.0_3
  rkt-stage1-fly<=1.30.0_3
@@ -675,6 +675,8 @@ replaces="
  traverso<=0.49.6_2
  ttyload-git<=20141117_4
  tuxc<=1.1_3
+ ufraw-gimp<=0.22_5
+ ufraw<=0.22_5
  unicorn-python<=1.0.2_2
  upwork<=5.6.10.0_1
  urlmatch-git<=20141116_2
diff --git a/srcpkgs/ufraw b/srcpkgs/ufraw
new file mode 120000
index 0000000000000..0bd1459b2a16f
--- /dev/null
+++ b/srcpkgs/ufraw
@@ -0,0 +1 @@
+nufraw
\ No newline at end of file
diff --git a/srcpkgs/ufraw-gimp b/srcpkgs/ufraw-gimp
index 967dc902dd02b..0bd1459b2a16f 120000
--- a/srcpkgs/ufraw-gimp
+++ b/srcpkgs/ufraw-gimp
@@ -1 +1 @@
-ufraw
\ No newline at end of file
+nufraw
\ No newline at end of file
diff --git a/srcpkgs/ufraw/patches/001-no-gimp-remote.patch b/srcpkgs/ufraw/patches/001-no-gimp-remote.patch
deleted file mode 100644
index ca4f4beb6240f..0000000000000
--- a/srcpkgs/ufraw/patches/001-no-gimp-remote.patch
+++ /dev/null
@@ -1,12 +0,0 @@
-Don't use gimp-remote since gimp 2.4 already includes gimp-remote functionality
---- a/ufraw_conf.c
-+++ b/ufraw_conf.c
-@@ -137,7 +137,7 @@
- #elif HAVE_GIMP_2_4
-     "gimp", /* remoteGimpCommand */
- #else
--    "gimp-remote", /* remoteGimpCommand */
-+    "gimp", /* remoteGimpCommand */
- #endif
- 
-     /* EXIF data */
diff --git a/srcpkgs/ufraw/patches/002-fix_abs_int.patch b/srcpkgs/ufraw/patches/002-fix_abs_int.patch
deleted file mode 100644
index 6fc552769c9f8..0000000000000
--- a/srcpkgs/ufraw/patches/002-fix_abs_int.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- a/dcraw.cc	2015-06-16 05:58:38.000000000 +0200
-+++ b/dcraw.cc	2018-02-04 14:46:54.489951076 +0100
-@@ -9242,7 +9242,7 @@
-     if (make[0] == 'O') {
-       i = find_green (12, 32, 1188864, 3576832);
-       c = find_green (12, 32, 2383920, 2387016);
--      if (abs(i) < abs(c)) {
-+      if (abs((int)i) < abs((int)c)) {
- 	SWAP(i,c);
- 	load_flags = 24;
-       }
diff --git a/srcpkgs/ufraw/patches/03_fix-unsigned-char.patch b/srcpkgs/ufraw/patches/03_fix-unsigned-char.patch
deleted file mode 100644
index 8690f87ca7d59..0000000000000
--- a/srcpkgs/ufraw/patches/03_fix-unsigned-char.patch
+++ /dev/null
@@ -1,14 +0,0 @@
-Source: written by John Paul Adrian Glaubitz for Debian
-Upstream: https://sourceforge.net/p/ufraw/bugs/417
-Reason: fixes a compilation failure on arm architectures
---- a/dcraw.cc
-+++ b/dcraw.cc
-@@ -2285,7 +2285,7 @@ void CLASS quicktake_100_load_raw()
- 
- void CLASS kodak_radc_load_raw()
- {
--  static const char src[] = {
-+  static const signed char src[] = {
-     1,1, 2,3, 3,4, 4,2, 5,7, 6,5, 7,6, 7,8,
-     1,0, 2,1, 3,3, 4,4, 5,2, 6,7, 7,6, 8,5, 8,8,
-     2,1, 2,3, 3,0, 3,2, 3,4, 4,6, 5,5, 6,7, 6,8,
diff --git a/srcpkgs/ufraw/patches/exiv-0.27.patch b/srcpkgs/ufraw/patches/exiv-0.27.patch
deleted file mode 100644
index b5b4140fff8ed..0000000000000
--- a/srcpkgs/ufraw/patches/exiv-0.27.patch
+++ /dev/null
@@ -1,25 +0,0 @@
---- a/ufraw_exiv2.cc	2015-06-16 05:58:38.000000000 +0200
-+++ b/ufraw_exiv2.cc	2018-12-29 22:51:23.291894430 +0100
-@@ -15,9 +15,7 @@
- #include "ufraw.h"
- 
- #ifdef HAVE_EXIV2
--#include <exiv2/image.hpp>
--#include <exiv2/easyaccess.hpp>
--#include <exiv2/exif.hpp>
-+#include <exiv2/exiv2.hpp>
- #include <sstream>
- #include <cassert>
- 
-@@ -67,7 +65,11 @@
-         if (exifData.empty()) {
-             std::string error(uf->filename);
-             error += ": No Exif data found in the file";
-+#if EXIV2_TEST_VERSION(0,27,0)
-+            throw Exiv2::Error(Exiv2::kerErrorMessage, error);
-+#else
-             throw Exiv2::Error(1, error);
-+#endif
-         }
- 
-         /* List of tag names taken from exiv2's printSummary() in actions.cpp */
diff --git a/srcpkgs/ufraw/patches/glib-2.68.patch b/srcpkgs/ufraw/patches/glib-2.68.patch
deleted file mode 100644
index 5b61468f118aa..0000000000000
--- a/srcpkgs/ufraw/patches/glib-2.68.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-From c56f8be3caf1cf3d9a5c80597bdbaf1325faacc0 Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?S=C3=A9rgio=20M=2E=20Basto?= <sergio@serjux.com>
-Date: Tue, 13 Apr 2021 23:45:39 +0100
-Subject: [PATCH] Fix build against glib-2.68 fixes #10
-
----
- uf_glib.h | 6 +++---
- 1 file changed, 3 insertions(+), 3 deletions(-)
-
-diff --git a/uf_glib.h b/uf_glib.h
-index 21c10b19..56cd6971 100644
---- a/uf_glib.h
-+++ b/uf_glib.h
-@@ -13,13 +13,13 @@
- #ifndef _UF_GLIB_H
- #define _UF_GLIB_H
- 
-+#include <glib.h>
-+#include <glib/gstdio.h>
-+
- #ifdef __cplusplus
- extern "C" {
- #endif
- 
--#include <glib.h>
--#include <glib/gstdio.h>
--
- // g_win32_locale_filename_from_utf8 is needed only on win32
- #ifdef _WIN32
- #define uf_win32_locale_filename_from_utf8(__some_string__) \
diff --git a/srcpkgs/ufraw/patches/iostream.patch b/srcpkgs/ufraw/patches/iostream.patch
deleted file mode 100644
index 6d15869f63db8..0000000000000
--- a/srcpkgs/ufraw/patches/iostream.patch
+++ /dev/null
@@ -1,13 +0,0 @@
-ufraw_exiv2.cc:343:10: note: 'std::cerr' is defined in header '<iostream>'
-ufraw_exiv2.cc:365:14: error: 'cerr' is not a member of 'std'
-
---- a/ufraw_exiv2.cc
-+++ b/ufraw_exiv2.cc
-@@ -17,6 +17,7 @@
- #ifdef HAVE_EXIV2
- #include <exiv2/exiv2.hpp>
- #include <sstream>
-+#include <iostream>
- #include <cassert>
- 
- /*
diff --git a/srcpkgs/ufraw/template b/srcpkgs/ufraw/template
deleted file mode 100644
index ceddcacacefb2..0000000000000
--- a/srcpkgs/ufraw/template
+++ /dev/null
@@ -1,38 +0,0 @@
-# Template file for 'ufraw'
-pkgname=ufraw
-version=0.22
-revision=5
-build_style=gnu-configure
-configure_args="--enable-contrast --enable-mime --enable-openmp --with-gimp
- $(vopt_enable extras)"
-hostmakedepends="pkg-config dcraw gettext"
-makedepends="exiv2-devel gimp-devel glib-devel gtkimageview-devel lcms2-devel lensfun-devel
- jasper-devel"
-depends="desktop-file-utils"
-short_desc="Utility to read and manipulate raw images from digital cameras"
-maintainer="John <me@johnnynator.dev>"
-license="GPL-2.0-or-later"
-homepage="http://ufraw.sourceforge.net/"
-distfiles="${SOURCEFORGE_SITE}/ufraw/ufraw/ufraw-${version}/ufraw-${version}.tar.gz"
-checksum=f7abd28ce587db2a74b4c54149bd8a2523a7ddc09bedf4f923246ff0ae09a25e
-
-build_options="extras"
-
-post_patch() {
-	vsed -e 's/default(none)//g' \
-		-i dcraw_indi.c \
-		-i dcraw_api.cc \
-		-i ufraw_ufraw.c \
-		-i ufraw_developer.c
-	vsed -i -e '/DATADIRNAME=/s/=.*/=share/' configure
-	vsed -i -e "s,^localedir =.*,localedir = /usr/share/locale," \
-		po/Makefile.in.in
-}
-
-ufraw-gimp_package() {
-	depends="${sourcepkg}>=${version}_${revision}"
-	short_desc+=" - gimp plugin"
-	pkg_install() {
-		vmove usr/lib/gimp
-	}
-}

^ permalink raw reply	[flat|nested] 27+ messages in thread

* Re: exiv2: update to 0.28.0.
  2023-10-23  0:10 [PR PATCH] exiv2: update to 0.28.0 mhmdanas
                   ` (5 preceding siblings ...)
  2023-11-03 20:00 ` [PR PATCH] [Updated] " mhmdanas
@ 2023-11-03 20:18 ` mhmdanas
  2023-11-04 21:57 ` [PR PATCH] [Updated] " mhmdanas
                   ` (18 subsequent siblings)
  25 siblings, 0 replies; 27+ messages in thread
From: mhmdanas @ 2023-11-03 20:18 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 932 bytes --]

New comment by mhmdanas on void-packages repository

https://github.com/void-linux/void-packages/pull/46838#issuecomment-1793043864

Comment:
This should be ready; the only problem is this:

```
=> nufraw-0.43.3_1: installing host dependencies: pkg-config-0.29.2_3 automake-1.16.5_1 libtool-2.4.7_4 ...
=> nufraw-0.43.3_1: installing target dependencies: gimp-devel-2.10.34_2 glib-devel-2.78.0_3 gtkimageview-devel-1.6.4_3 lcms2-devel-2.15_1 lensfun-devel-0.3.3_3 jasper-devel-2.0.25_1 exiv2-devel-0.28.0_1 ...
=> nufraw-0.43.3_1: removing autodeps, please wait...
=> ERROR: nufraw-0.43.3_1: failed to install target dependencies! (error 8)
libgexiv2-0.14.0_3: broken, unresolvable shlib `libexiv2.so.27'
Transaction aborted due to unresolved shlibs.
=> ERROR: Please see above for the real error, exiting...
```

For some reason xbps-src isn't automatically building the bumped libgexif2, I'm not sure how to fix it...

^ permalink raw reply	[flat|nested] 27+ messages in thread

* Re: [PR PATCH] [Updated] exiv2: update to 0.28.0.
  2023-10-23  0:10 [PR PATCH] exiv2: update to 0.28.0 mhmdanas
                   ` (6 preceding siblings ...)
  2023-11-03 20:18 ` mhmdanas
@ 2023-11-04 21:57 ` mhmdanas
  2023-11-06 20:17 ` mhmdanas
                   ` (17 subsequent siblings)
  25 siblings, 0 replies; 27+ messages in thread
From: mhmdanas @ 2023-11-04 21:57 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 2022 bytes --]

There is an updated pull request by mhmdanas against master on the void-packages repository

https://github.com/mhmdanas/void-packages exiv2-0.28.0
https://github.com/void-linux/void-packages/pull/46838

exiv2: update to 0.28.0.
<!-- Uncomment relevant sections and delete options which are not applicable -->

#### Testing the changes
- I tested the changes in this PR: **briefly**

TODO:
- [x] Fix `gwenview`'s failed checks (not really fixed but the exact same tests fail on master as well)
- [x] `test_exiv2` fails for `libextractor`
- [x] `kfilemetadata5` tests fail (same tests fail on master)

@Johnnynator ufraw has been [unmaintained since December 2016](https://sourceforge.net/p/ufraw/discussion/434060/thread/30b4249b/), and it doesn't build with this PR; here are the options:
- remove the package entirely
- replace it with the newer [nufraw](https://sourceforge.net/projects/nufraw/), which already has [an exiv 0.28.x patch floating around](https://aur.archlinux.org/cgit/aur.git/tree/exiv2-error.patch?h=nufraw)
- patch it to build with this PR

What do you think? (edit: `nufraw` now replaces `ufraw` in this PR)

<!--
#### New package
- This new package conforms to the [package requirements](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTItest_exiv2NG.md#package-requirements): **YES**|**NO**
-->

<!-- Note: If the build is likely to take more than 2 hours, please add ci skip tag as described in
https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration
and test at least one native build and, if supported, at least one cross build.
Ignore this section if this PR is not skipping CI.
-->
<!--
#### Local build testing
- I built this PR locally for my native architecture, (ARCH-LIBC)
- I built this PR locally for these architectures (if supported. mark crossbuilds):
  - aarch64-musl
  - armv7l
  - armv6l-musl
-->


A patch file from https://github.com/void-linux/void-packages/pull/46838.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-exiv2-0.28.0-46838.patch --]
[-- Type: text/x-diff, Size: 62672 bytes --]

From b463090e7a2ad4c993796ed45a7c0c5115c285e9 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Mon, 23 Oct 2023 01:20:09 +0100
Subject: [PATCH 01/22] inih: add `libINIReader.so.0` common/shlibs entry.

---
 common/shlibs | 1 +
 1 file changed, 1 insertion(+)

diff --git a/common/shlibs b/common/shlibs
index 9036a675c1ae5..8f03a38a16789 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -3905,6 +3905,7 @@ libnotcurses++.so.3 notcurses-3.0.5_1
 libnotcurses-ffi.so.3 notcurses-3.0.5_1
 libevemu.so.3 evemu-2.7.0_1
 libinih.so.0 inih-52_1
+libINIReader.so.0 inih-57_1
 libpcaudio.so.0 pcaudiolib-1.1_1
 libdcerpc-samr.so.0 samba-4.13.2_1
 libdcerpc-server-core.so.0 samba-4.13.2_1

From 0a218665e86f34c18c83245fcfdc5591fb22a338 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:12 +0100
Subject: [PATCH 02/22] exiv2: update to 0.28.0.

---
 common/shlibs                        |  2 +-
 srcpkgs/exiv2/patches/fix-tests.diff | 31 ++++++++++++++++++++++++++++
 srcpkgs/exiv2/template               | 14 ++++++++-----
 3 files changed, 41 insertions(+), 6 deletions(-)
 create mode 100644 srcpkgs/exiv2/patches/fix-tests.diff

diff --git a/common/shlibs b/common/shlibs
index 8f03a38a16789..0b1d0c89d3e51 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -555,7 +555,7 @@ libgimpcolor-2.0.so.0 libgimp-2.10.0_1
 libgimpmodule-2.0.so.0 libgimp-2.10.0_1
 libgmic.so.3 gmic-3.1.6_1
 libcgmic.so.3 gmic-3.1.6_1
-libexiv2.so.27 exiv2-0.27_1
+libexiv2.so.28 exiv2-0.28.0_1
 libKF5Holidays.so.5 kholidays-5.47.0_1
 libPhabricatorHelpers.so.5 purpose-5.48.0_1
 libKF5PurposeWidgets.so.5 purpose-5.48.0_1
diff --git a/srcpkgs/exiv2/patches/fix-tests.diff b/srcpkgs/exiv2/patches/fix-tests.diff
new file mode 100644
index 0000000000000..3eb7adc1635f3
--- /dev/null
+++ b/srcpkgs/exiv2/patches/fix-tests.diff
@@ -0,0 +1,31 @@
+diff --git a/tests/tiff_test/test_tag_compare.py b/tests/tiff_test/test_tag_compare.py
+index a8538bd2..974d1a9a 100644
+--- a/tests/tiff_test/test_tag_compare.py
++++ b/tests/tiff_test/test_tag_compare.py
+@@ -28,8 +28,8 @@ class OutputTagExtract(metaclass=system_tests.CaseMeta):
+             tmp = line.split()
+ 
+             exif, image, tag = tmp[0].split('.')
+-            self.assertEquals(exif, "Exif")
+-            self.assertEquals(image, "Image")
++            self.assertEqual(exif, "Exif")
++            self.assertEqual(image, "Image")
+ 
+             data.append({
+                 "tag": tag,
+@@ -87,13 +87,13 @@ class OutputTagExtract(metaclass=system_tests.CaseMeta):
+         """
+         for pa_elem, pS_elem in zip(self.pa_data, self.pS_data):
+             for key in ["tag", "type", "len"]:
+-                self.assertEquals(pa_elem[key], pS_elem[key])
++                self.assertEqual(pa_elem[key], pS_elem[key])
+ 
+             if pa_elem["tag"] in [
+                     "ImageWidth", "ImageLength", "BitsPerSample",
+                     "DocumentName", "ImageDescription", "StripOffsets",
+                     "SamplesPerPixel", "StripByteCounts"]:
+-                self.assertEquals(pa_elem["val"], pS_elem["val"])
++                self.assertEqual(pa_elem["val"], pS_elem["val"])
+ 
+     def compare_stdout(self, i, command, got_stdout, expected_stdout):
+         super().compare_stdout(i, command, got_stdout, expected_stdout)
diff --git a/srcpkgs/exiv2/template b/srcpkgs/exiv2/template
index 49985fe82cc14..876b253541d00 100644
--- a/srcpkgs/exiv2/template
+++ b/srcpkgs/exiv2/template
@@ -1,17 +1,17 @@
 # Template file for 'exiv2'
 pkgname=exiv2
-version=0.27.6
+version=0.28.0
 revision=1
 build_style=cmake
 configure_args="-DEXIV2_BUILD_SAMPLES=OFF -DEXIV2_ENABLE_BMFF=ON"
-makedepends="zlib-devel expat-devel"
-checkdepends="gtest-devel"
+makedepends="zlib-devel brotli-devel expat-devel inih-devel"
+checkdepends="gtest-devel python3"
 short_desc="Image metadata manipulation"
 maintainer="Enno Boland <gottox@voidlinux.org>"
 license="GPL-2.0-or-later"
 homepage="https://www.exiv2.org"
 distfiles="https://github.com/Exiv2/exiv2/releases/download/v${version}/exiv2-${version}-Source.tar.gz"
-checksum=4c192483a1125dc59a3d70b30d30d32edace9e14adf52802d2f853abf72db8a6
+checksum=89af3b5ef7277753ef7a7b5374ae017c6b9e304db3b688f1948e73e103491f3d
 
 if [ -n "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DEXIV2_BUILD_UNIT_TESTS=ON"
@@ -21,6 +21,11 @@ if [ -n "$XBPS_CCACHE" ]; then
 	configure_args+=" -DBUILD_WITH_CCACHE=ON"
 fi
 
+pre_check() {
+	# https://github.com/Exiv2/exiv2/issues/2762
+	rm -f tests/bugfixes/github/test_issue_2427.py
+}
+
 exiv2-devel_package() {
 	depends="${makedepends} ${sourcepkg}-${version}_${revision}"
 	short_desc+=" - development files"
@@ -28,7 +33,6 @@ exiv2-devel_package() {
 		vmove usr/include
 		vmove usr/lib/cmake
 		vmove usr/lib/pkgconfig
-		vmove "usr/lib/*.a"
 		vmove "usr/lib/*.so"
 	}
 }

From ed17da8795d4100522a1bb221c5a8b6082942ead Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:37 +0100
Subject: [PATCH 03/22] ART: revbump for exiv2-0.28.0.

---
 srcpkgs/ART/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/ART/template b/srcpkgs/ART/template
index b6c47fc6c4cdf..94c7aa0378061 100644
--- a/srcpkgs/ART/template
+++ b/srcpkgs/ART/template
@@ -1,7 +1,7 @@
 # Template file for 'ART'
 pkgname=ART
 version=1.20.2
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="pkg-config"
 makedepends="fftw-devel gtkmm-devel lensfun-devel

From 9d2764a675a76eb3d51b3392780d4dc9061b6c3b Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 04/22] darktable: revbump for exiv2-0.28.0.

---
 srcpkgs/darktable/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/darktable/template b/srcpkgs/darktable/template
index 60415a34dc018..3d35571239a93 100644
--- a/srcpkgs/darktable/template
+++ b/srcpkgs/darktable/template
@@ -1,7 +1,7 @@
 # Template file for 'darktable'
 pkgname=darktable
 version=4.4.2
-revision=2
+revision=3
 # upstream only supports these archs:
 archs="x86_64* aarch64* ppc64le*"
 build_style=cmake

From dd8ed924939220e380354259a7958bb865073a16 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 05/22] digikam: revbump for exiv2-0.28.0.

---
 srcpkgs/digikam/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/digikam/template b/srcpkgs/digikam/template
index 206185f565488..4784bf7d62a8e 100644
--- a/srcpkgs/digikam/template
+++ b/srcpkgs/digikam/template
@@ -1,7 +1,7 @@
 # Template file for 'digikam'
 pkgname=digikam
 version=8.1.0
-revision=1
+revision=2
 build_style=cmake
 configure_args="-DBUILD_TESTING=OFF"
 hostmakedepends="extra-cmake-modules gettext pkg-config bison flex qt5-qmake

From 72774fdfb20ea692f3309c56c34db18a07144f48 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 06/22] geeqie: revbump for exiv2-0.28.0.

---
 srcpkgs/geeqie/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/geeqie/template b/srcpkgs/geeqie/template
index b5f958f854c1b..b494bc149e957 100644
--- a/srcpkgs/geeqie/template
+++ b/srcpkgs/geeqie/template
@@ -1,7 +1,7 @@
 # Template file for 'geeqie'
 pkgname=geeqie
 version=2.1
-revision=1
+revision=2
 build_style=meson
 hostmakedepends="pkg-config gettext xxd gdk-pixbuf-devel glib-devel"
 makedepends="gtk+3-devel glib-devel lcms2-devel exiv2-devel libheif-devel

From 23f9db2a070f0487ec3266ea236a03ece9152b6a Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 07/22] gthumb: revbump for exiv2-0.28.0.

---
 srcpkgs/gthumb/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/gthumb/template b/srcpkgs/gthumb/template
index c8e19f0dedb61..732d5e1c6089f 100644
--- a/srcpkgs/gthumb/template
+++ b/srcpkgs/gthumb/template
@@ -1,7 +1,7 @@
 # Template file for 'gthumb'
 pkgname=gthumb
 version=3.12.3
-revision=1
+revision=2
 build_style=meson
 hostmakedepends="gettext pkg-config itstool glib-devel"
 makedepends="webkit2gtk-devel json-glib-devel libsecret-devel librsvg-devel

From fe822579c26a9cb023217fcc7387d0e5590ddf7c Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 08/22] gwenview: revbump for exiv2-0.28.0.

---
 srcpkgs/gwenview/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/gwenview/template b/srcpkgs/gwenview/template
index 73d450a458c4d..eb876cfadcfe8 100644
--- a/srcpkgs/gwenview/template
+++ b/srcpkgs/gwenview/template
@@ -1,7 +1,7 @@
 # Template file for 'gwenview'
 pkgname=gwenview
 version=23.08.2
-revision=1
+revision=2
 build_style=cmake
 build_helper=qemu
 hostmakedepends="extra-cmake-modules pkg-config qt5-qmake qt5-host-tools

From cbaa7295761921f96582a0aa0f7c7bca820cc572 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 09/22] hugin: revbump for exiv2-0.28.0.

---
 srcpkgs/hugin/patches/exiv2-0.28.patch | 77 ++++++++++++++++++++++++++
 srcpkgs/hugin/template                 |  2 +-
 2 files changed, 78 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/hugin/patches/exiv2-0.28.patch

diff --git a/srcpkgs/hugin/patches/exiv2-0.28.patch b/srcpkgs/hugin/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..49f0518117020
--- /dev/null
+++ b/srcpkgs/hugin/patches/exiv2-0.28.patch
@@ -0,0 +1,77 @@
+Patch-Source: https://gitlab.archlinux.org/archlinux/packaging/packages/hugin/-/blob/main/exiv2-0.28.patch
+diff -r 79cd11a7a66f src/hugin_base/panodata/Exiv2Helper.cpp
+--- a/src/hugin_base/panodata/Exiv2Helper.cpp	Wed May 24 19:13:20 2023 +0200
++++ b/src/hugin_base/panodata/Exiv2Helper.cpp	Mon Jun 05 00:31:19 2023 +0200
+@@ -40,7 +40,7 @@
+             Exiv2::ExifData::iterator itr = exifData.findKey(Exiv2::ExifKey(keyName));
+             if (itr != exifData.end() && itr->count())
+             {
+-                value = itr->toLong();
++                value = itr->toUint32();
+                 return true;
+             }
+             else
+@@ -165,7 +165,7 @@
+         {
+             if(it!=exifData.end() && it->count())
+             {
+-                return it->toLong();
++                return it->toUint32();
+             }
+             return 0;
+         };
+@@ -600,4 +600,4 @@
+         };
+ 
+     }; //namespace Exiv2Helper
+-}; //namespace HuginBase
+\ No newline at end of file
++}; //namespace HuginBase
+diff -r 79cd11a7a66f src/hugin_base/panodata/SrcPanoImage.cpp
+--- a/src/hugin_base/panodata/SrcPanoImage.cpp	Wed May 24 19:13:20 2023 +0200
++++ b/src/hugin_base/panodata/SrcPanoImage.cpp	Mon Jun 05 00:31:19 2023 +0200
+@@ -384,7 +384,7 @@
+                     pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaImageWidthPixels"));
+                     if (pos != xmpData.end())
+                     {
+-                        croppedWidth = pos->toLong();
++                        croppedWidth = pos->toUint32();
+                     }
+                     else
+                     {
+@@ -394,7 +394,7 @@
+                     pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaImageHeightPixels"));
+                     if (pos != xmpData.end())
+                     {
+-                        croppedHeight = pos->toLong();
++                        croppedHeight = pos->toUint32();
+                     }
+                     else
+                     {
+@@ -408,7 +408,7 @@
+                         double hfov = 0;
+                         if (pos != xmpData.end())
+                         {
+-                            hfov = 360 * croppedWidth / (double)pos->toLong();
++                            hfov = 360 * croppedWidth / (double)pos->toUint32();
+                         }
+                         else
+                         {
+@@ -419,7 +419,7 @@
+                         pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.FullPanoHeightPixels"));
+                         if (pos != xmpData.end())
+                         {
+-                            fullHeight = pos->toLong();
++                            fullHeight = pos->toUint32();
+                         }
+                         else
+                         {
+@@ -430,7 +430,7 @@
+                         pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaTopPixels"));
+                         if (pos != xmpData.end())
+                         {
+-                            cropTop = pos->toLong();
++                            cropTop = pos->toUint32();
+                         }
+                         else
+                         {
diff --git a/srcpkgs/hugin/template b/srcpkgs/hugin/template
index f96d2f6e27d42..ce71f6e4cbb2d 100644
--- a/srcpkgs/hugin/template
+++ b/srcpkgs/hugin/template
@@ -1,7 +1,7 @@
 # Template file for 'hugin'
 pkgname=hugin
 version=2022.0.0
-revision=10
+revision=11
 build_style=cmake
 build_helper=cmake-wxWidgets-gtk3
 pycompile_dirs="usr/share/hugin/data/plugins usr/share/hugin/data/plugins-templates"

From eefba671f5dc46c0b7e271a502f1fcd5e56c37a5 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 10/22] kfilemetadata5: revbump for exiv2-0.28.0.

---
 srcpkgs/kfilemetadata5/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/kfilemetadata5/template b/srcpkgs/kfilemetadata5/template
index 00f7a98cf6399..e294ae5af947c 100644
--- a/srcpkgs/kfilemetadata5/template
+++ b/srcpkgs/kfilemetadata5/template
@@ -1,7 +1,7 @@
 # Template file for 'kfilemetadata5'
 pkgname=kfilemetadata5
 version=5.111.0
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="kcoreaddons extra-cmake-modules pkg-config qt5-host-tools qt5-qmake
  gettext kcoreaddons python3"

From ffbccaf1290c4da568646e32e6115053ec23b05e Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 11/22] krename: revbump for exiv2-0.28.0.

---
 srcpkgs/krename/patches/e7dd767a.patch | 90 ++++++++++++++++++++++++++
 srcpkgs/krename/template               |  2 +-
 2 files changed, 91 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/krename/patches/e7dd767a.patch

diff --git a/srcpkgs/krename/patches/e7dd767a.patch b/srcpkgs/krename/patches/e7dd767a.patch
new file mode 100644
index 0000000000000..a0ef428ce46b1
--- /dev/null
+++ b/srcpkgs/krename/patches/e7dd767a.patch
@@ -0,0 +1,90 @@
+Patch-Source: https://invent.kde.org/utilities/krename/-/commit/e7dd767a
+From e7dd767a9a1068ee1fe1502c4d619b57d3b12add Mon Sep 17 00:00:00 2001
+From: Andreas Sturmlechner <asturm@gentoo.org>
+Date: Fri, 26 May 2023 23:23:10 +0200
+Subject: [PATCH] Fix build with >=exiv2-0.28, raise minimum to 0.27
+
+- enables use of EXIV2_TEST_VERSION macro
+- exiv2 headers cleanup
+
+Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>
+---
+ CMakeLists.txt         |  6 +-----
+ config-krename.h.cmake |  3 ---
+ src/exiv2plugin.cpp    | 17 +++++------------
+ 3 files changed, 6 insertions(+), 20 deletions(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 0bda8ac..72e7297 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -56,13 +56,9 @@ set_package_properties(Taglib PROPERTIES
+     TYPE OPTIONAL)
+ 
+ # Find exiv2
+-find_package(LibExiv2 0.13) # AccessMode was added in 0.13
++find_package(LibExiv2 0.27) # EXIV2_TEST_VERSION was added in 0.27
+ set_package_properties(LibExiv2 PROPERTIES TYPE OPTIONAL)
+ 
+-if (LibExiv2_VERSION VERSION_GREATER_EQUAL "0.27")
+-    set(HAVE_LIBEXIV2_0_27 TRUE)
+-endif()
+-
+ # Find podofo
+ find_package(PoDoFo)
+ set_package_properties(PoDoFo PROPERTIES
+diff --git a/config-krename.h.cmake b/config-krename.h.cmake
+index 76c3d30..862e40b 100644
+--- a/config-krename.h.cmake
++++ b/config-krename.h.cmake
+@@ -6,9 +6,6 @@
+ /* have Exiv2 */
+ #cmakedefine01 HAVE_EXIV2
+ 
+-/* Defined if we have libexiv2 >= 0.27 */
+-#cmakedefine HAVE_LIBEXIV2_0_27
+-
+ /* have PoDoFo */
+ #cmakedefine01 HAVE_PODOFO
+ 
+diff --git a/src/exiv2plugin.cpp b/src/exiv2plugin.cpp
+index 5694d8c..25e8869 100644
+--- a/src/exiv2plugin.cpp
++++ b/src/exiv2plugin.cpp
+@@ -3,20 +3,9 @@
+ 
+ #include "exiv2plugin.h"
+ 
+-#include "../config-krename.h"
+-
+ #include <KLocalizedString>
+ 
+-#include <exiv2/error.hpp>
+-#include <exiv2/exif.hpp>
+-#include <exiv2/image.hpp>
+-#include <exiv2/iptc.hpp>
+-#ifdef HAVE_LIBEXIV2_0_27
+-    #include <exiv2/xmp_exiv2.hpp>
+-#else
+-    #include <exiv2/xmp.hpp>
+-#endif
+-#include <exiv2/tags.hpp>
++#include <exiv2/exiv2.hpp>
+ 
+ #include "batchrenamer.h"
+ #include "tokenhelpdialog.h"
+@@ -381,7 +370,11 @@ QString Exiv2Plugin::processFile(BatchRenamer *b, int index, const QString &file
+     std::string strFilename(asc.constData(), asc.length());
+ 
+     try {
++#if EXIV2_TEST_VERSION(0,28,0)
++        Image::UniquePtr image = Exiv2::ImageFactory::open(strFilename);
++#else
+         Image::AutoPtr image = Exiv2::ImageFactory::open(strFilename);
++#endif
+         if (image.get() != nullptr && image->good()) {
+             image->readMetadata();
+ 
+-- 
+GitLab
+
diff --git a/srcpkgs/krename/template b/srcpkgs/krename/template
index 66023163e3293..df5535007714a 100644
--- a/srcpkgs/krename/template
+++ b/srcpkgs/krename/template
@@ -1,7 +1,7 @@
 # Template file for 'krename'
 pkgname=krename
 version=5.0.2
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="extra-cmake-modules gettext kcoreaddons pkg-config qt5-host-tools qt5-qmake"
 makedepends="exiv2-devel freetype-devel kjs-devel kparts-devel libpodofo-devel

From 56134c0e1bd795adb0d6d8314c9fa81465157ecf Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 12/22] krita: revbump for exiv2-0.28.0.

---
 srcpkgs/krita/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/krita/template b/srcpkgs/krita/template
index 63ee0fbe9bceb..f4d665daf7c31 100644
--- a/srcpkgs/krita/template
+++ b/srcpkgs/krita/template
@@ -1,7 +1,7 @@
 # Template file for 'krita'
 pkgname=krita
 version=5.2.1
-revision=1
+revision=2
 build_style=cmake
 configure_args="-Wno-dev -DBUILD_TESTING=OFF"
 hostmakedepends="extra-cmake-modules gettext pkg-config python3

From 718afcaaa1e2f7eea06848c929837af2c21d95d1 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 13/22] libextractor: revbump for exiv2-0.28.0.

---
 srcpkgs/libextractor/patches/exiv2-0.28.patch | 286 ++++++++++++++++++
 srcpkgs/libextractor/patches/fix-tests.diff   |  24 ++
 srcpkgs/libextractor/template                 |   2 +-
 3 files changed, 311 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/libextractor/patches/exiv2-0.28.patch
 create mode 100644 srcpkgs/libextractor/patches/fix-tests.diff

diff --git a/srcpkgs/libextractor/patches/exiv2-0.28.patch b/srcpkgs/libextractor/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..270a626d8ab06
--- /dev/null
+++ b/srcpkgs/libextractor/patches/exiv2-0.28.patch
@@ -0,0 +1,286 @@
+Patch-Source: https://gitlab.archlinux.org/archlinux/packaging/packages/libextractor/-/blob/main/exiv2-0.28.patch
+diff --git a/src/plugins/exiv2_extractor.cc b/src/plugins/exiv2_extractor.cc
+index 78f9bda..d32ed6a 100644
+--- a/src/plugins/exiv2_extractor.cc
++++ b/src/plugins/exiv2_extractor.cc
+@@ -90,7 +90,11 @@ virtual int close ();
+  * @param rcount number of bytes to read
+  * @return buffer with data read, empty buffer (!) on failure (!)
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++virtual Exiv2::DataBuf read (size_t rcount);
++#else
+ virtual Exiv2::DataBuf read (long rcount);
++#endif
+ 
+ /**
+  * Read up to 'rcount' bytes into 'buf'.
+@@ -99,8 +103,17 @@ virtual Exiv2::DataBuf read (long rcount);
+  * @param rcount size of 'buf'
+  * @return number of bytes read successfully, 0 on failure (!)
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++virtual size_t read (Exiv2::byte *buf,
++                   size_t rcount);
++#else
+ virtual long read (Exiv2::byte *buf,
+                    long rcount);
++#endif
++
++#if EXIV2_TEST_VERSION (0,28,0)
++virtual void populateFakeData();
++#endif
+ 
+ /**
+  * Read a single character.
+@@ -117,8 +130,13 @@ virtual int getb ();
+  * @param wcount how many bytes to write
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual size_t write (const Exiv2::byte *data,
++                    size_t wcount);
++#else
+ virtual long write (const Exiv2::byte *data,
+                     long wcount);
++#endif
+ 
+ /**
+  * Write to stream.
+@@ -126,7 +144,11 @@ virtual long write (const Exiv2::byte *data,
+  * @param src stream to copy
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual size_t write (Exiv2::BasicIo &src);
++#else
+ virtual long write (Exiv2::BasicIo &src);
++#endif
+ 
+ /**
+  * Write a single byte.
+@@ -172,7 +194,11 @@ virtual int munmap ();
+  *
+  * @return -1 on error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual size_t tell (void) const;
++#else
+ virtual long int tell (void) const;
++#endif
+ 
+ /**
+  * Return overall size of the file.
+@@ -213,7 +239,11 @@ virtual bool eof () const;
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual const std::string& path () const noexcept;
++#else
+ virtual std::string path () const;
++#endif
+ 
+ #ifdef EXV_UNICODE_PATH
+ /**
+@@ -230,7 +260,11 @@ virtual std::wstring wpath () const;
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual Exiv2::BasicIo::UniquePtr temporary () const;
++#else
+ virtual Exiv2::BasicIo::AutoPtr temporary () const;
++#endif
+ 
+ };
+ 
+@@ -266,7 +300,11 @@ ExtractorIO::close ()
+  * @return buffer with data read, empty buffer (!) on failure (!)
+  */
+ Exiv2::DataBuf
++#if EXIV2_TEST_VERSION (0,28,0)
++ExtractorIO::read (size_t rcount)
++#else
+ ExtractorIO::read (long rcount)
++#endif
+ {
+   void *data;
+   ssize_t ret;
+@@ -284,9 +322,15 @@ ExtractorIO::read (long rcount)
+  * @param rcount size of 'buf'
+  * @return number of bytes read successfully, 0 on failure (!)
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++size_t
++ExtractorIO::read (Exiv2::byte *buf,
++                   size_t rcount)
++#else
+ long
+ ExtractorIO::read (Exiv2::byte *buf,
+                    long rcount)
++#endif
+ {
+   void *data;
+   ssize_t ret;
+@@ -305,6 +349,12 @@ ExtractorIO::read (Exiv2::byte *buf,
+   return got;
+ }
+ 
++#if EXIV2_TEST_VERSION (0,28,0)
++void ExtractorIO::populateFakeData()
++{
++  return;
++}
++#endif
+ 
+ /**
+  * Read a single character.
+@@ -319,7 +369,9 @@ ExtractorIO::getb ()
+   const unsigned char *r;
+ 
+   if (1 != ec->read (ec->cls, &data, 1))
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION(0,28,0)
++    throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+     throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+     throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -336,9 +388,15 @@ ExtractorIO::getb ()
+  * @param wcount how many bytes to write
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++size_t
++ExtractorIO::write (const Exiv2::byte *data,
++                    size_t wcount)
++#else
+ long
+ ExtractorIO::write (const Exiv2::byte *data,
+                     long wcount)
++#endif
+ {
+   return -1;
+ }
+@@ -350,7 +408,11 @@ ExtractorIO::write (const Exiv2::byte *data,
+  * @param src stream to copy
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++size_t
++#else
+ long
++#endif
+ ExtractorIO::write (Exiv2::BasicIo &src)
+ {
+   return -1;
+@@ -378,7 +440,9 @@ ExtractorIO::putb (Exiv2::byte data)
+ void
+ ExtractorIO::transfer (Exiv2::BasicIo& src)
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION(0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -427,7 +491,9 @@ ExtractorIO::seek (long offset,
+ Exiv2::byte *
+ ExtractorIO::mmap (bool isWritable)
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION (0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -452,7 +518,11 @@ ExtractorIO::munmap ()
+  *
+  * @return -1 on error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++size_t
++#else
+ long int
++#endif
+ ExtractorIO::tell (void) const
+ {
+   return (long) ec->seek (ec->cls, 0, SEEK_CUR);
+@@ -516,10 +586,17 @@ ExtractorIO::eof () const
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++const std::string&
++ExtractorIO::path () const noexcept
++#else
+ std::string
+ ExtractorIO::path () const
++#endif
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION (0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -536,7 +613,9 @@ ExtractorIO::path () const
+ std::wstring
+ ExtractorIO::wpath () const
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION (0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -552,11 +631,17 @@ ExtractorIO::wpath () const
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++Exiv2::BasicIo::UniquePtr
++#else
+ Exiv2::BasicIo::AutoPtr
++#endif
+ ExtractorIO::temporary () const
+ {
+   fprintf (stderr, "throwing temporary error\n");
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION(0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -737,8 +822,13 @@ EXTRACTOR_exiv2_extract_method (struct EXTRACTOR_ExtractContext *ec)
+ #if ! EXIV2_TEST_VERSION (0,24,0)
+     Exiv2::LogMsg::setLevel (Exiv2::LogMsg::mute);
+ #endif
++#if EXIV2_TEST_VERSION(0,28,0)
++    std::unique_ptr<Exiv2::BasicIo> eio (new ExtractorIO (ec));
++    Exiv2::Image::UniquePtr image = Exiv2::ImageFactory::open (std::move(eio));
++#else
+     std::auto_ptr<Exiv2::BasicIo> eio (new ExtractorIO (ec));
+     Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open (eio);
++#endif
+     if (0 == image.get ())
+       return;
+     image->readMetadata ();
+@@ -822,7 +912,11 @@ EXTRACTOR_exiv2_extract_method (struct EXTRACTOR_ExtractContext *ec)
+       ADDXMP ("Xmp.lr.hierarchicalSubject", EXTRACTOR_METATYPE_SUBJECT);
+     }
+   }
++#if EXIV2_TEST_VERSION (0,28,0)
++  catch (const Exiv2::Error& e)
++#else
+   catch (const Exiv2::AnyError& e)
++#endif
+   {
+ #if DEBUG
+     std::cerr << "Caught Exiv2 exception '" << e << "'\n";
diff --git a/srcpkgs/libextractor/patches/fix-tests.diff b/srcpkgs/libextractor/patches/fix-tests.diff
new file mode 100644
index 0000000000000..3b4ee7cbeea33
--- /dev/null
+++ b/srcpkgs/libextractor/patches/fix-tests.diff
@@ -0,0 +1,24 @@
+--- a/src/plugins/test_exiv2.c	2021-01-30 13:20:23.000000000 +0000
++++ b/src/plugins/test_exiv2.c	2023-11-03 19:39:43.115274492 +0000
+@@ -49,8 +49,8 @@
+       EXTRACTOR_METATYPE_GPS_LATITUDE,
+       EXTRACTOR_METAFORMAT_UTF8,
+       "text/plain",
+-      "28deg 8' (18|17.585)\" ?",
+-      strlen ("28deg 8' (18|17.585)\" ?") + 1,
++      "28 deg 8' (18|17.58)\" ?",
++      strlen ("28 deg 8' (18|17.58)\" ?") + 1,
+       0,
+       .regex = 1
+     },
+@@ -66,8 +66,8 @@
+       EXTRACTOR_METATYPE_GPS_LONGITUDE,
+       EXTRACTOR_METAFORMAT_UTF8,
+       "text/plain",
+-      "14deg 14' (22|21.713)\" ?",
+-      strlen ("14deg 14' (22|21.713)\" ?"),
++      "14 deg 14' (22|21.71)\" ?",
++      strlen ("14 deg 14' (22|21.71)\" ?"),
+       0,
+       .regex = 1
+     },
diff --git a/srcpkgs/libextractor/template b/srcpkgs/libextractor/template
index ddd4790f93e88..bfcea979a308c 100644
--- a/srcpkgs/libextractor/template
+++ b/srcpkgs/libextractor/template
@@ -1,7 +1,7 @@
 # Template file for 'libextractor'
 pkgname=libextractor
 version=1.11
-revision=2
+revision=3
 build_style=gnu-configure
 configure_args="--disable-static"
 hostmakedepends="pkg-config"

From 086919cad507dd058434d3b026a0bb2c54b6132b Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 14/22] libgexiv2: update to 0.14.2.

---
 srcpkgs/libgexiv2/template | 14 +++++++-------
 1 file changed, 7 insertions(+), 7 deletions(-)

diff --git a/srcpkgs/libgexiv2/template b/srcpkgs/libgexiv2/template
index 23780e5397dc4..91dbcaa9aca52 100644
--- a/srcpkgs/libgexiv2/template
+++ b/srcpkgs/libgexiv2/template
@@ -1,19 +1,19 @@
 # Template file for 'libgexiv2'
 pkgname=libgexiv2
-version=0.14.0
-revision=3
+version=0.14.2
+revision=1
 build_style=meson
 build_helper="gir"
-configure_args="-Dintrospection=$(vopt_if gir true false)
- -Dvapi=$(vopt_if vala true false)"
+configure_args="$(vopt_bool gir introspection) $(vopt_bool vala vapi)"
 hostmakedepends="pkg-config glib-devel $(vopt_if vala 'vala') python3-gobject"
 makedepends="libglib-devel exiv2-devel"
 short_desc="GObject-based wrapper around the Exiv2 library"
 maintainer="Enno Boland <gottox@voidlinux.org>"
 license="GPL-2.0-or-later"
 homepage="https://wiki.gnome.org/Projects/gexiv2"
-distfiles="${GNOME_SITE}/gexiv2/${version%.*}/${pkgname/lib/}-${version}.tar.xz"
-checksum=e58279a6ff20b6f64fa499615da5e9b57cf65ba7850b72fafdf17221a9d6d69e
+changelog="https://gitlab.gnome.org/GNOME/gexiv2/-/raw/master/NEWS"
+distfiles="${GNOME_SITE}/gexiv2/${version%.*}/gexiv2-${version}.tar.xz"
+checksum=2a0c9cf48fbe8b3435008866ffd40b8eddb0667d2212b42396fdf688e93ce0be
 
 build_options="gir vala"
 build_options_default="gir vala"
@@ -23,7 +23,7 @@ libgexiv2-devel_package() {
 	short_desc+=" - development files"
 	pkg_install() {
 		vmove usr/include
-		vmove usr/lib/*.so
+		vmove "usr/lib/*.so"
 		vmove usr/lib/pkgconfig
 		if [ "$build_option_vala" ]; then
 			vmove usr/share/vala

From 8428151965ecea737a3dddb239abc50d306b0ddc Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 15/22] libkexiv25: update to 23.08.2.

---
 srcpkgs/libkexiv25/template | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/srcpkgs/libkexiv25/template b/srcpkgs/libkexiv25/template
index b439a42ef2b97..4d7f9600572ea 100644
--- a/srcpkgs/libkexiv25/template
+++ b/srcpkgs/libkexiv25/template
@@ -1,6 +1,6 @@
 # Template file for 'libkexiv25'
 pkgname=libkexiv25
-version=23.04.0
+version=23.08.2
 revision=1
 build_style=cmake
 configure_args="-DBUILD_TESTING=OFF"
@@ -11,7 +11,7 @@ maintainer="Orphaned <orphan@voidlinux.org>"
 license="GPL-2.0-or-later"
 homepage="https://invent.kde.org/graphics/libkexiv2"
 distfiles="${KDE_SITE}/release-service/${version}/src/libkexiv2-${version}.tar.xz"
-checksum=18d3eed06df9d1e31d8434ed9887e305aba176d0856e19a8cd3bdb555b80d391
+checksum=d06e36a408bf2e846a18056a1f15e61d981fa2a1fceb81f7c15136604319d033
 
 libkexiv25-devel_package() {
 	short_desc+=" - development files"

From da1edbccaa249a271227af4a7a8ada5403ebb713 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 16/22] nomacs: update to 3.17.2287.

---
 srcpkgs/nomacs/template | 17 +++++++++++++----
 1 file changed, 13 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/nomacs/template b/srcpkgs/nomacs/template
index c52cd54e294db..956bd21ebb129 100644
--- a/srcpkgs/nomacs/template
+++ b/srcpkgs/nomacs/template
@@ -1,7 +1,8 @@
 # Template file for 'nomacs'
 pkgname=nomacs
-version=3.16.224
-revision=5
+version=3.17.2287
+revision=1
+_plugins_ver=3.17.2285
 build_wrksrc=ImageLounge
 build_style=cmake
 configure_args="-DCMAKE_BUILD_TYPE=None -DENABLE_TRANSLATIONS=1
@@ -13,5 +14,13 @@ short_desc="Simple yet powerful Qt imageviewer"
 maintainer="Orphaned <orphan@voidlinux.org>"
 license="GPL-3.0-or-later"
 homepage="https://github.com/nomacs/nomacs"
-distfiles="https://github.com/nomacs/nomacs/archive/${version}.tar.gz"
-checksum=bbc7e9048026ef9e0d2b64902c88050f17a679ef3d3c009de2c3b7de5d1d217c
+distfiles="https://github.com/nomacs/nomacs/archive/${version}.tar.gz
+ https://github.com/novomesk/nomacs-plugins/archive/refs/tags/${_plugins_ver}.tar.gz>plugins.tar.gz"
+checksum="6905ea615358f84a0c83d5b1b7077871dea0526ec667500a1951448cb845a92c
+ 946b2d754be9ecca5cb155f7ecc5dcafb164f6c3dcc7bf5c3c0610d3b47774aa"
+skip_extraction="plugins.tar.gz"
+
+post_extract() {
+ cd ${build_wrksrc}
+ vsrcextract -C plugins "plugins.tar.gz"
+}

From 749e8ebf84f000e550eb75c61621b6d9e104a294 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 17/22] pdf2djvu: revbump for exiv2-0.28.0.

---
 srcpkgs/pdf2djvu/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/pdf2djvu/template b/srcpkgs/pdf2djvu/template
index ef7433c0c98ae..5a6f3ddf4ed35 100644
--- a/srcpkgs/pdf2djvu/template
+++ b/srcpkgs/pdf2djvu/template
@@ -1,7 +1,7 @@
 # Template file for 'pdf2djvu'
 pkgname=pdf2djvu
 version=0.9.19
-revision=4
+revision=5
 build_style=gnu-configure
 hostmakedepends="pkg-config djvulibre gettext"
 makedepends="djvulibre-devel poppler-devel libgraphicsmagick-devel exiv2-devel libuuid-devel"

From cf559592d18acf2f993976c2eb99f4bf27c6bbd3 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 18/22] phototonic: revbump for exiv2-0.28.0.

---
 srcpkgs/phototonic/patches/exiv2-0.28.patch | 135 ++++++++++++++++++++
 srcpkgs/phototonic/template                 |   2 +-
 2 files changed, 136 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/phototonic/patches/exiv2-0.28.patch

diff --git a/srcpkgs/phototonic/patches/exiv2-0.28.patch b/srcpkgs/phototonic/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..1c75b628dab33
--- /dev/null
+++ b/srcpkgs/phototonic/patches/exiv2-0.28.patch
@@ -0,0 +1,135 @@
+From 923a3fc14de0b779a45696c5f0aef34c74d84f13 Mon Sep 17 00:00:00 2001
+From: Andreas Sturmlechner <asturm@gentoo.org>
+Date: Sun, 28 May 2023 18:54:10 +0200
+Subject: [PATCH] Fix build with exiv2-0.28
+
+Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>
+---
+ ImageViewer.cpp   | 9 +++++++++
+ MetadataCache.cpp | 8 ++++++++
+ Phototonic.cpp    | 4 ++++
+ Tags.cpp          | 8 ++++++++
+ ThumbsViewer.cpp  | 4 ++++
+ 5 files changed, 33 insertions(+)
+
+diff --git a/ImageViewer.cpp b/ImageViewer.cpp
+index 357d223..df3ac43 100644
+--- a/ImageViewer.cpp
++++ b/ImageViewer.cpp
+@@ -945,7 +945,11 @@ void ImageViewer::keyMoveEvent(int direction) {
+ }
+ 
+ void ImageViewer::saveImage() {
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr image;
++#else
+     Exiv2::Image::AutoPtr image;
++#endif
+     bool exifError = false;
+ 
+     if (newImage) {
+@@ -985,8 +989,13 @@ void ImageViewer::saveImage() {
+ }
+ 
+ void ImageViewer::saveImageAs() {
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++    Exiv2::Image::UniquePtr newExifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
+     Exiv2::Image::AutoPtr newExifImage;
++#endif
+     bool exifError = false;
+ 
+     setCursorHiding(false);
+diff --git a/MetadataCache.cpp b/MetadataCache.cpp
+index 524ae74..5ddd4c8 100644
+--- a/MetadataCache.cpp
++++ b/MetadataCache.cpp
+@@ -64,7 +64,11 @@ void MetadataCache::clear() {
+ }
+ 
+ bool MetadataCache::loadImageMetadata(const QString &imageFullPath) {
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
++#endif
+     QSet<QString> tags;
+     long orientation = 0;
+ 
+@@ -78,7 +82,11 @@ bool MetadataCache::loadImageMetadata(const QString &imageFullPath) {
+     try {
+         Exiv2::ExifData &exifData = exifImage->exifData();
+         if (!exifData.empty()) {
++#if EXIV2_TEST_VERSION(0,28,0)
++            orientation = exifData["Exif.Image.Orientation"].value().toUint32();
++#else
+             orientation = exifData["Exif.Image.Orientation"].value().toLong();
++#endif
+         }
+     } catch (Exiv2::Error &error) {
+         qWarning() << "Failed to read Exif metadata";
+diff --git a/Phototonic.cpp b/Phototonic.cpp
+index 6cc95b3..bd5497d 100644
+--- a/Phototonic.cpp
++++ b/Phototonic.cpp
+@@ -3151,7 +3151,11 @@ void Phototonic::removeMetadata() {
+ 
+     if (ret == MessageBox::Yes) {
+         for (int file = 0; file < fileList.size(); ++file) {
++#if EXIV2_TEST_VERSION(0,28,0)
++            Exiv2::Image::UniquePtr image;
++#else
+             Exiv2::Image::AutoPtr image;
++#endif
+             try {
+                 image = Exiv2::ImageFactory::open(fileList[file].toStdString());
+                 image->clearMetadata();
+diff --git a/Tags.cpp b/Tags.cpp
+index 84eea16..a62da9d 100644
+--- a/Tags.cpp
++++ b/Tags.cpp
+@@ -136,7 +136,11 @@ void ImageTags::addTag(QString tagName, bool tagChecked) {
+ 
+ bool ImageTags::writeTagsToImage(QString &imageFileName, QSet<QString> &newTags) {
+     QSet<QString> imageTags;
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
++#endif
+ 
+     try {
+         exifImage = Exiv2::ImageFactory::open(imageFileName.toStdString());
+@@ -160,7 +164,11 @@ bool ImageTags::writeTagsToImage(QString &imageFileName, QSet<QString> &newTags)
+         QSetIterator<QString> newTagsIt(newTags);
+         while (newTagsIt.hasNext()) {
+             QString tag = newTagsIt.next();
++#if EXIV2_TEST_VERSION(0,28,0)
++            Exiv2::Value::UniquePtr value = Exiv2::Value::create(Exiv2::string);
++#else
+             Exiv2::Value::AutoPtr value = Exiv2::Value::create(Exiv2::string);
++#endif
+             value->read(tag.toStdString());
+             Exiv2::IptcKey key("Iptc.Application2.Keywords");
+             newIptcData.add(key, value.get());
+diff --git a/ThumbsViewer.cpp b/ThumbsViewer.cpp
+index 77a6189..4a11475 100644
+--- a/ThumbsViewer.cpp
++++ b/ThumbsViewer.cpp
+@@ -210,7 +210,11 @@ void ThumbsViewer::updateImageInfoViewer(QString imageFullPath) {
+         infoView->addEntry(key, val);
+     }
+ 
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
++#endif
+     try {
+         exifImage = Exiv2::ImageFactory::open(imageFullPath.toStdString());
+         exifImage->readMetadata();
+-- 
+2.40.1
+
diff --git a/srcpkgs/phototonic/template b/srcpkgs/phototonic/template
index 77ae8bf6a4406..4af006cb7da41 100644
--- a/srcpkgs/phototonic/template
+++ b/srcpkgs/phototonic/template
@@ -1,7 +1,7 @@
 # Template file for 'phototonic'
 pkgname=phototonic
 version=2.1
-revision=3
+revision=4
 build_style=qmake
 hostmakedepends="pkg-config qt5-qmake qt5-host-tools"
 makedepends="qt5-svg-devel exiv2-devel"

From 2af8cfa79d2c92b73716b5040ccca29ae41e5b9e Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 19/22] qimgv: revbump for exiv2-0.28.0.

---
 srcpkgs/qimgv/patches/exiv2-0.28.patch | 16 ++++++++++++++++
 srcpkgs/qimgv/template                 |  2 +-
 2 files changed, 17 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/qimgv/patches/exiv2-0.28.patch

diff --git a/srcpkgs/qimgv/patches/exiv2-0.28.patch b/srcpkgs/qimgv/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..11f37b5ae2be3
--- /dev/null
+++ b/srcpkgs/qimgv/patches/exiv2-0.28.patch
@@ -0,0 +1,16 @@
+Patch-Source: https://git.alpinelinux.org/aports/tree/community/qimgv/exiv2-0.28.patch
+diff --git a/qimgv/sourcecontainers/documentinfo.cpp b/qimgv/sourcecontainers/documentinfo.cpp
+index 98a68f7..c062474 100644
+--- a/qimgv/sourcecontainers/documentinfo.cpp
++++ b/qimgv/sourcecontainers/documentinfo.cpp
+@@ -271,10 +271,6 @@ void DocumentInfo::loadExifTags() {
+         //std::cout << "Caught Exiv2 exception '" << e.what() << "'\n";
+         return;
+     }
+-    catch (Exiv2::BasicError<CharType> e) {
+-        //std::cout << "Caught BasicError Exiv2 exception '" << e.what() << "'\n";
+-        return;
+-    }
+ #endif
+ }
+ 
diff --git a/srcpkgs/qimgv/template b/srcpkgs/qimgv/template
index 7eb30db33992c..dd341dfe1bfce 100644
--- a/srcpkgs/qimgv/template
+++ b/srcpkgs/qimgv/template
@@ -1,7 +1,7 @@
 # Template file for 'qimgv'
 pkgname=qimgv
 version=1.0.2
-revision=2
+revision=3
 build_style=cmake
 configure_args="$(vopt_if video -DVIDEO_SUPPORT=ON -DVIDEO_SUPPORT=OFF)
  $(vopt_if scale -DOPENCV_SUPPORT=ON -DOPENCV_SUPPORT=OFF)

From b555381e50660026d805dea2535e27b7f2c1416c Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 20/22] SIR: revbump for exiv2-0.28.0.

---
 srcpkgs/SIR/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/SIR/template b/srcpkgs/SIR/template
index 113077acad354..c6da4c26b6c71 100644
--- a/srcpkgs/SIR/template
+++ b/srcpkgs/SIR/template
@@ -1,7 +1,7 @@
 # Template file for 'SIR'
 pkgname=SIR
 version=3.2.2
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="pkg-config"
 makedepends="exiv2-devel qt5-svg-devel qt5-tools-devel"

From 14cd5aec657e1c763cc7ea20f548ef3cf7f94263 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 21/22] viewnior: revbump for exiv2-0.28.0.

---
 srcpkgs/viewnior/patches/exiv2-0.28.patch | 147 ++++++++++++++++++++++
 srcpkgs/viewnior/template                 |   2 +-
 2 files changed, 148 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/viewnior/patches/exiv2-0.28.patch

diff --git a/srcpkgs/viewnior/patches/exiv2-0.28.patch b/srcpkgs/viewnior/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..71459dee15768
--- /dev/null
+++ b/srcpkgs/viewnior/patches/exiv2-0.28.patch
@@ -0,0 +1,147 @@
+Patch-Source: https://gitlab.archlinux.org/archlinux/packaging/packages/viewnior/-/blob/f206ce6c22a3ec5f1f9ea1bde4077584f80458dd/exiv2-0.28.patch
+--
+From b6bb81a1b46e911d15bbf9a730972523de177705 Mon Sep 17 00:00:00 2001
+From: tastytea <tastytea@tastytea.de>
+Date: Tue, 16 May 2023 10:54:40 +0200
+Subject: [PATCH 1/2] change exiv2 AutoPtr to unique_ptr
+
+exiv2-0.28.0 removed Exiv2::Image::AutoPtr and added
+Exiv2::Image::UniquePtr instead. since it's a typedef for
+std::unique_ptr<Image>, i'm using that directly instead of adding a
+condition on the exiv2 version.
+---
+ src/uni-exiv2.cpp | 21 +++++++++++----------
+ 1 file changed, 11 insertions(+), 10 deletions(-)
+
+diff --git a/src/uni-exiv2.cpp b/src/uni-exiv2.cpp
+index 0d14b9f..77064c2 100644
+--- a/src/uni-exiv2.cpp
++++ b/src/uni-exiv2.cpp
+@@ -22,12 +22,13 @@
+ 
+ #include <exiv2/exiv2.hpp>
+ #include <iostream>
++#include <memory>
+ 
+ #include "uni-exiv2.hpp"
+ 
+ #define ARRAY_SIZE(array) (sizeof array/sizeof(array[0]))
+ 
+-static Exiv2::Image::AutoPtr cached_image;
++static std::unique_ptr<Exiv2::Image> cached_image;
+ 
+ extern "C"
+ void
+@@ -35,8 +36,8 @@ uni_read_exiv2_map(const char *uri, void (*callback)(const char*, const char*, v
+ {
+     Exiv2::LogMsg::setLevel(Exiv2::LogMsg::mute);
+     try {
+-        Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open(uri);
+-        if ( image.get() == 0 ) {
++        std::unique_ptr<Exiv2::Image> image = Exiv2::ImageFactory::open(uri);
++        if (image == nullptr) {
+             return;
+         }
+ 
+@@ -91,14 +92,14 @@ uni_read_exiv2_to_cache(const char *uri)
+ {
+     Exiv2::LogMsg::setLevel(Exiv2::LogMsg::mute);
+ 
+-    if ( cached_image.get() != NULL ) {
++    if (cached_image != nullptr) {
+         cached_image->clearMetadata();
+-        cached_image.reset(NULL);
++        cached_image.reset(nullptr);
+     }
+ 
+     try {
+         cached_image = Exiv2::ImageFactory::open(uri);
+-        if ( cached_image.get() == 0 ) {
++        if (cached_image == nullptr) {
+             return 1;
+         }
+ 
+@@ -116,13 +117,13 @@ uni_write_exiv2_from_cache(const char *uri)
+ {
+     Exiv2::LogMsg::setLevel(Exiv2::LogMsg::mute);
+ 
+-    if ( cached_image.get() == NULL ) {
++    if (cached_image == nullptr) {
+         return 1;
+     }
+ 
+     try {
+-        Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open(uri);
+-        if ( image.get() == 0 ) {
++        std::unique_ptr<Exiv2::Image> image = Exiv2::ImageFactory::open(uri);
++        if (image == nullptr) {
+             return 2;
+         }
+ 
+@@ -130,7 +131,7 @@ uni_write_exiv2_from_cache(const char *uri)
+         image->writeMetadata();
+ 
+         cached_image->clearMetadata();
+-        cached_image.reset(NULL);
++        cached_image.reset(nullptr);
+ 
+         return 0;
+     } catch (Exiv2::AnyError& e) {
+
+From 47d0b98cb46526aa8aa035bebcabc14a11fa57ee Mon Sep 17 00:00:00 2001
+From: tastytea <tastytea@tastytea.de>
+Date: Tue, 16 May 2023 11:17:00 +0200
+Subject: [PATCH 2/2] add support for exiv-0.28.0 errors
+
+exiv2-0.28.0 changed Exiv2::AnyError to Exiv2::Error.
+---
+ src/uni-exiv2.cpp | 15 ++++++++++++---
+ 1 file changed, 12 insertions(+), 3 deletions(-)
+
+diff --git a/src/uni-exiv2.cpp b/src/uni-exiv2.cpp
+index 77064c2..567a50f 100644
+--- a/src/uni-exiv2.cpp
++++ b/src/uni-exiv2.cpp
+@@ -28,6 +28,15 @@
+ 
+ #define ARRAY_SIZE(array) (sizeof array/sizeof(array[0]))
+ 
++#define EXIV_ERROR Exiv2::AnyError
++#ifdef EXIV2_VERSION
++    #ifdef EXIV2_TEST_VERSION
++        #if EXIV2_TEST_VERSION(0,28,0)
++            #define EXIV_ERROR Exiv2::Error
++        #endif
++    #endif
++#endif
++
+ static std::unique_ptr<Exiv2::Image> cached_image;
+ 
+ extern "C"
+@@ -81,7 +90,7 @@ uni_read_exiv2_map(const char *uri, void (*callback)(const char*, const char*, v
+                 }
+             }
+         }
+-    } catch (Exiv2::AnyError& e) {
++    } catch (EXIV_ERROR& e) {
+         std::cerr << "Exiv2: '" << e << "'\n";
+     }
+ }
+@@ -104,7 +113,7 @@ uni_read_exiv2_to_cache(const char *uri)
+         }
+ 
+         cached_image->readMetadata();
+-    } catch (Exiv2::AnyError& e) {
++    } catch (EXIV_ERROR& e) {
+         std::cerr << "Exiv2: '" << e << "'\n";
+     }
+ 
+@@ -134,7 +143,7 @@ uni_write_exiv2_from_cache(const char *uri)
+         cached_image.reset(nullptr);
+ 
+         return 0;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (EXIV_ERROR& e) {
+         std::cerr << "Exiv2: '" << e << "'\n";
+     }
+ 
diff --git a/srcpkgs/viewnior/template b/srcpkgs/viewnior/template
index ea1e528a8651f..4c73226662ca0 100644
--- a/srcpkgs/viewnior/template
+++ b/srcpkgs/viewnior/template
@@ -1,7 +1,7 @@
 # Template file for 'viewnior'
 pkgname=viewnior
 version=1.8
-revision=1
+revision=2
 build_style=meson
 hostmakedepends="pkg-config intltool glib-devel gettext-devel"
 makedepends="gtk+-devel exiv2-devel"

From 841d0936317fa29444babdf3256be88750764e6e Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Mon, 23 Oct 2023 19:06:34 +0200
Subject: [PATCH 22/22] New package: nufraw-0.43.3

Co-authored-by: Mohammed Anas <triallax@tutanota.com>
---
 srcpkgs/nufraw-gimp                           |  1 +
 .../patches/0001-nufraw-glib-2.70.patch       | 20 +++++++
 srcpkgs/nufraw/patches/exiv-0.28.x.diff       | 59 +++++++++++++++++++
 srcpkgs/nufraw/template                       | 49 +++++++++++++++
 srcpkgs/removed-packages/template             |  8 ++-
 srcpkgs/ufraw                                 |  1 +
 srcpkgs/ufraw-gimp                            |  2 +-
 .../ufraw/patches/001-no-gimp-remote.patch    | 12 ----
 srcpkgs/ufraw/patches/002-fix_abs_int.patch   | 11 ----
 .../ufraw/patches/03_fix-unsigned-char.patch  | 14 -----
 srcpkgs/ufraw/patches/exiv-0.27.patch         | 25 --------
 srcpkgs/ufraw/patches/glib-2.68.patch         | 30 ----------
 srcpkgs/ufraw/patches/iostream.patch          | 13 ----
 srcpkgs/ufraw/template                        | 38 ------------
 14 files changed, 136 insertions(+), 147 deletions(-)
 create mode 120000 srcpkgs/nufraw-gimp
 create mode 100644 srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch
 create mode 100644 srcpkgs/nufraw/patches/exiv-0.28.x.diff
 create mode 100644 srcpkgs/nufraw/template
 create mode 120000 srcpkgs/ufraw
 delete mode 100644 srcpkgs/ufraw/patches/001-no-gimp-remote.patch
 delete mode 100644 srcpkgs/ufraw/patches/002-fix_abs_int.patch
 delete mode 100644 srcpkgs/ufraw/patches/03_fix-unsigned-char.patch
 delete mode 100644 srcpkgs/ufraw/patches/exiv-0.27.patch
 delete mode 100644 srcpkgs/ufraw/patches/glib-2.68.patch
 delete mode 100644 srcpkgs/ufraw/patches/iostream.patch
 delete mode 100644 srcpkgs/ufraw/template

diff --git a/srcpkgs/nufraw-gimp b/srcpkgs/nufraw-gimp
new file mode 120000
index 0000000000000..0bd1459b2a16f
--- /dev/null
+++ b/srcpkgs/nufraw-gimp
@@ -0,0 +1 @@
+nufraw
\ No newline at end of file
diff --git a/srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch b/srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch
new file mode 100644
index 0000000000000..41f10bfbafa1f
--- /dev/null
+++ b/srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch
@@ -0,0 +1,20 @@
+diff -ru nufraw/uf_glib.h nufraw/uf_glib.h
+--- nufraw/uf_glib.h	2022-02-23 09:03:44.700472919 +0100
++++ nufraw/uf_glib.h	2022-02-23 09:04:50.260308805 +0100
+@@ -13,13 +13,13 @@
+ #ifndef _UF_GLIB_H
+ #define _UF_GLIB_H
+ 
++#include <glib.h>
++#include <glib/gstdio.h>
++
+ #ifdef __cplusplus
+ extern "C" {
+ #endif
+ 
+-#include <glib.h>
+-#include <glib/gstdio.h>
+-
+ // g_win32_locale_filename_from_utf8 is needed only on win32
+ #ifdef _WIN32
+ #define uf_win32_locale_filename_from_utf8(__some_string__) \
diff --git a/srcpkgs/nufraw/patches/exiv-0.28.x.diff b/srcpkgs/nufraw/patches/exiv-0.28.x.diff
new file mode 100644
index 0000000000000..6c23359bf706c
--- /dev/null
+++ b/srcpkgs/nufraw/patches/exiv-0.28.x.diff
@@ -0,0 +1,59 @@
+Patch taken from AUR package: https://aur.archlinux.org/cgit/aur.git/tree/exiv2-error.patch?h=nufraw&id=29e467f2c297fcd0f36548642d6d2cab6428d08f
+diff --git a/nufraw_exiv2.cc b/nufraw_exiv2.cc
+index 2de4cc3..45aea87 100644
+--- a/nufraw_exiv2.cc
++++ b/nufraw_exiv2.cc
+@@ -54,7 +54,7 @@ extern "C" int nufraw_exif_read_input(nufraw_data *uf)
+         uf->inputExifBuf = NULL;
+         uf->inputExifBufLen = 0;
+ 
+-        Exiv2::Image::AutoPtr image;
++        Exiv2::Image::UniquePtr image;
+         if (uf->unzippedBuf != NULL) {
+             image = Exiv2::ImageFactory::open(
+                         (const Exiv2::byte*)uf->unzippedBuf, uf->unzippedBufLen);
+@@ -135,7 +135,7 @@ extern "C" int nufraw_exif_read_input(nufraw_data *uf)
+         nufraw_message(NUFRAW_SET_LOG, "%s\n", stderror.str().c_str());
+ 
+         return NUFRAW_SUCCESS;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (Exiv2::Error& e) {
+         std::cerr.rdbuf(savecerr);
+         std::string s(e.what());
+         nufraw_message(NUFRAW_SET_WARNING, "%s\n", s.c_str());
+@@ -156,7 +156,7 @@ static Exiv2::ExifData nufraw_prepare_exifdata(nufraw_data *uf)
+         if ((pos = exifData.findKey(Exiv2::ExifKey("Exif.Image.Orientation")))
+                 != exifData.end()) {
+             nufraw_message(NUFRAW_SET_LOG, "Resetting %s from '%d' to '1'\n",
+-                          pos->key().c_str(), pos->value().toLong());
++                          pos->key().c_str(), pos->value().toInt64());
+             pos->setValue("1"); /* 1 = Normal orientation */
+         }
+     }
+@@ -327,7 +327,7 @@ extern "C" int nufraw_exif_prepare_output(nufraw_data *uf)
+         nufraw_message(NUFRAW_SET_LOG, "%s\n", stderror.str().c_str());
+ 
+         return NUFRAW_SUCCESS;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (Exiv2::Error& e) {
+         std::cerr.rdbuf(savecerr);
+         std::string s(e.what());
+         nufraw_message(NUFRAW_SET_WARNING, "%s\n", s.c_str());
+@@ -347,7 +347,7 @@ extern "C" int nufraw_exif_write(nufraw_data *uf)
+ 
+         char *filename =
+             uf_win32_locale_filename_from_utf8(uf->conf->outputFilename);
+-        Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open(filename);
++        Exiv2::Image::UniquePtr image = Exiv2::ImageFactory::open(filename);
+         uf_win32_locale_filename_free(filename);
+         assert(image.get() != 0);
+ 
+@@ -367,7 +367,7 @@ extern "C" int nufraw_exif_write(nufraw_data *uf)
+         nufraw_message(NUFRAW_SET_LOG, "%s\n", stderror.str().c_str());
+ 
+         return NUFRAW_SUCCESS;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (Exiv2::Error& e) {
+         std::cerr.rdbuf(savecerr);
+         std::string s(e.what());
+         nufraw_message(NUFRAW_SET_WARNING, "%s\n", s.c_str());
diff --git a/srcpkgs/nufraw/template b/srcpkgs/nufraw/template
new file mode 100644
index 0000000000000..f1d10dd87c9ba
--- /dev/null
+++ b/srcpkgs/nufraw/template
@@ -0,0 +1,49 @@
+# Template file for 'nufraw'
+pkgname=nufraw
+version=0.43.3
+revision=1
+_ver="${version%.*}-${version##*.}"
+build_style=gnu-configure
+configure_args="--enable-contrast --enable-mime --enable-openmp --with-gimp
+ --enable-extras"
+hostmakedepends="pkg-config automake libtool"
+# libgexiv2-devel is only here to fix build order, remove on next template
+# change
+makedepends="exiv2-devel gimp-devel glib-devel gtkimageview-devel lcms2-devel
+ lensfun-devel jasper-devel libgexiv2-devel"
+depends="desktop-file-utils"
+short_desc="Utility to read and manipulate raw images from digital cameras"
+maintainer="John <me@johnnynator.dev>"
+license="GPL-2.0-or-later"
+homepage="https://sourceforge.net/projects/nufraw/"
+distfiles="${SOURCEFORGE_SITE}/nufraw/nufraw-${_ver}.tar.gz"
+checksum=2c7dcc1590993ec267b3112562b2433010d6f94f6acc6506c76aa29cf8c6c32c
+
+pre_configure() {
+	autoreconf -fi
+}
+
+pre_build() {
+	mv nufraw.desktop{.desktop,}
+	chmod +x generate_schemas.sh
+}
+
+nufraw-gimp_package() {
+	depends="${sourcepkg}>=${version}_${revision}"
+	short_desc+=" - gimp plugin"
+	pkg_install() {
+		vmove usr/lib/gimp
+	}
+}
+
+ufraw_package() {
+	depends="${sourcepkg}>=${version}_${revision}"
+	build_style=meta
+	short_desc+=" (transitional dummy package)"
+}
+
+ufraw-gimp_package() {
+	depends="nufraw-gimp>=${version}_${revision}"
+	build_style=meta
+	short_desc+=" - gimp plugin (transitional dummy package)"
+}
diff --git a/srcpkgs/removed-packages/template b/srcpkgs/removed-packages/template
index abedf26f739b6..f3d81a8afe04c 100644
--- a/srcpkgs/removed-packages/template
+++ b/srcpkgs/removed-packages/template
@@ -1,6 +1,6 @@
 # Template file for 'removed-packages'
 pkgname=removed-packages
-version=0.1.20231019
+version=0.1.20231101
 revision=1
 build_style=meta
 short_desc="Uninstalls packages removed from repository"
@@ -590,8 +590,8 @@ replaces="
  python3-Flask-Assets<=0.12_9
  python3-Flask-Mail<=0.9.1_5
  python3-Flask-OAuthlib<=0.9.6_4
- python3-Flask-Script<=2.0.6_7
  python3-Flask-SQLAlchemy<=2.5.1_4
+ python3-Flask-Script<=2.0.6_7
  python3-Flask-User<=1.0.2.2_6
  python3-SPARQLWrapper<=1.8.4_4
  python3-aiohttp-cors2<=0.7.0_3
@@ -642,8 +642,8 @@ replaces="
  raul-devel<=0.8.0_6
  raul<=0.8.0_6
  redkite<=1.3.1_1
- rem<=2.10.0_1
  rem-devel<=2.10.0_1
+ rem<=2.10.0_1
  reminiscence<=0.4.6_1
  rkt-stage1-coreos<=1.30.0_3
  rkt-stage1-fly<=1.30.0_3
@@ -675,6 +675,8 @@ replaces="
  traverso<=0.49.6_2
  ttyload-git<=20141117_4
  tuxc<=1.1_3
+ ufraw-gimp<=0.22_5
+ ufraw<=0.22_5
  unicorn-python<=1.0.2_2
  upwork<=5.6.10.0_1
  urlmatch-git<=20141116_2
diff --git a/srcpkgs/ufraw b/srcpkgs/ufraw
new file mode 120000
index 0000000000000..0bd1459b2a16f
--- /dev/null
+++ b/srcpkgs/ufraw
@@ -0,0 +1 @@
+nufraw
\ No newline at end of file
diff --git a/srcpkgs/ufraw-gimp b/srcpkgs/ufraw-gimp
index 967dc902dd02b..0bd1459b2a16f 120000
--- a/srcpkgs/ufraw-gimp
+++ b/srcpkgs/ufraw-gimp
@@ -1 +1 @@
-ufraw
\ No newline at end of file
+nufraw
\ No newline at end of file
diff --git a/srcpkgs/ufraw/patches/001-no-gimp-remote.patch b/srcpkgs/ufraw/patches/001-no-gimp-remote.patch
deleted file mode 100644
index ca4f4beb6240f..0000000000000
--- a/srcpkgs/ufraw/patches/001-no-gimp-remote.patch
+++ /dev/null
@@ -1,12 +0,0 @@
-Don't use gimp-remote since gimp 2.4 already includes gimp-remote functionality
---- a/ufraw_conf.c
-+++ b/ufraw_conf.c
-@@ -137,7 +137,7 @@
- #elif HAVE_GIMP_2_4
-     "gimp", /* remoteGimpCommand */
- #else
--    "gimp-remote", /* remoteGimpCommand */
-+    "gimp", /* remoteGimpCommand */
- #endif
- 
-     /* EXIF data */
diff --git a/srcpkgs/ufraw/patches/002-fix_abs_int.patch b/srcpkgs/ufraw/patches/002-fix_abs_int.patch
deleted file mode 100644
index 6fc552769c9f8..0000000000000
--- a/srcpkgs/ufraw/patches/002-fix_abs_int.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- a/dcraw.cc	2015-06-16 05:58:38.000000000 +0200
-+++ b/dcraw.cc	2018-02-04 14:46:54.489951076 +0100
-@@ -9242,7 +9242,7 @@
-     if (make[0] == 'O') {
-       i = find_green (12, 32, 1188864, 3576832);
-       c = find_green (12, 32, 2383920, 2387016);
--      if (abs(i) < abs(c)) {
-+      if (abs((int)i) < abs((int)c)) {
- 	SWAP(i,c);
- 	load_flags = 24;
-       }
diff --git a/srcpkgs/ufraw/patches/03_fix-unsigned-char.patch b/srcpkgs/ufraw/patches/03_fix-unsigned-char.patch
deleted file mode 100644
index 8690f87ca7d59..0000000000000
--- a/srcpkgs/ufraw/patches/03_fix-unsigned-char.patch
+++ /dev/null
@@ -1,14 +0,0 @@
-Source: written by John Paul Adrian Glaubitz for Debian
-Upstream: https://sourceforge.net/p/ufraw/bugs/417
-Reason: fixes a compilation failure on arm architectures
---- a/dcraw.cc
-+++ b/dcraw.cc
-@@ -2285,7 +2285,7 @@ void CLASS quicktake_100_load_raw()
- 
- void CLASS kodak_radc_load_raw()
- {
--  static const char src[] = {
-+  static const signed char src[] = {
-     1,1, 2,3, 3,4, 4,2, 5,7, 6,5, 7,6, 7,8,
-     1,0, 2,1, 3,3, 4,4, 5,2, 6,7, 7,6, 8,5, 8,8,
-     2,1, 2,3, 3,0, 3,2, 3,4, 4,6, 5,5, 6,7, 6,8,
diff --git a/srcpkgs/ufraw/patches/exiv-0.27.patch b/srcpkgs/ufraw/patches/exiv-0.27.patch
deleted file mode 100644
index b5b4140fff8ed..0000000000000
--- a/srcpkgs/ufraw/patches/exiv-0.27.patch
+++ /dev/null
@@ -1,25 +0,0 @@
---- a/ufraw_exiv2.cc	2015-06-16 05:58:38.000000000 +0200
-+++ b/ufraw_exiv2.cc	2018-12-29 22:51:23.291894430 +0100
-@@ -15,9 +15,7 @@
- #include "ufraw.h"
- 
- #ifdef HAVE_EXIV2
--#include <exiv2/image.hpp>
--#include <exiv2/easyaccess.hpp>
--#include <exiv2/exif.hpp>
-+#include <exiv2/exiv2.hpp>
- #include <sstream>
- #include <cassert>
- 
-@@ -67,7 +65,11 @@
-         if (exifData.empty()) {
-             std::string error(uf->filename);
-             error += ": No Exif data found in the file";
-+#if EXIV2_TEST_VERSION(0,27,0)
-+            throw Exiv2::Error(Exiv2::kerErrorMessage, error);
-+#else
-             throw Exiv2::Error(1, error);
-+#endif
-         }
- 
-         /* List of tag names taken from exiv2's printSummary() in actions.cpp */
diff --git a/srcpkgs/ufraw/patches/glib-2.68.patch b/srcpkgs/ufraw/patches/glib-2.68.patch
deleted file mode 100644
index 5b61468f118aa..0000000000000
--- a/srcpkgs/ufraw/patches/glib-2.68.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-From c56f8be3caf1cf3d9a5c80597bdbaf1325faacc0 Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?S=C3=A9rgio=20M=2E=20Basto?= <sergio@serjux.com>
-Date: Tue, 13 Apr 2021 23:45:39 +0100
-Subject: [PATCH] Fix build against glib-2.68 fixes #10
-
----
- uf_glib.h | 6 +++---
- 1 file changed, 3 insertions(+), 3 deletions(-)
-
-diff --git a/uf_glib.h b/uf_glib.h
-index 21c10b19..56cd6971 100644
---- a/uf_glib.h
-+++ b/uf_glib.h
-@@ -13,13 +13,13 @@
- #ifndef _UF_GLIB_H
- #define _UF_GLIB_H
- 
-+#include <glib.h>
-+#include <glib/gstdio.h>
-+
- #ifdef __cplusplus
- extern "C" {
- #endif
- 
--#include <glib.h>
--#include <glib/gstdio.h>
--
- // g_win32_locale_filename_from_utf8 is needed only on win32
- #ifdef _WIN32
- #define uf_win32_locale_filename_from_utf8(__some_string__) \
diff --git a/srcpkgs/ufraw/patches/iostream.patch b/srcpkgs/ufraw/patches/iostream.patch
deleted file mode 100644
index 6d15869f63db8..0000000000000
--- a/srcpkgs/ufraw/patches/iostream.patch
+++ /dev/null
@@ -1,13 +0,0 @@
-ufraw_exiv2.cc:343:10: note: 'std::cerr' is defined in header '<iostream>'
-ufraw_exiv2.cc:365:14: error: 'cerr' is not a member of 'std'
-
---- a/ufraw_exiv2.cc
-+++ b/ufraw_exiv2.cc
-@@ -17,6 +17,7 @@
- #ifdef HAVE_EXIV2
- #include <exiv2/exiv2.hpp>
- #include <sstream>
-+#include <iostream>
- #include <cassert>
- 
- /*
diff --git a/srcpkgs/ufraw/template b/srcpkgs/ufraw/template
deleted file mode 100644
index ceddcacacefb2..0000000000000
--- a/srcpkgs/ufraw/template
+++ /dev/null
@@ -1,38 +0,0 @@
-# Template file for 'ufraw'
-pkgname=ufraw
-version=0.22
-revision=5
-build_style=gnu-configure
-configure_args="--enable-contrast --enable-mime --enable-openmp --with-gimp
- $(vopt_enable extras)"
-hostmakedepends="pkg-config dcraw gettext"
-makedepends="exiv2-devel gimp-devel glib-devel gtkimageview-devel lcms2-devel lensfun-devel
- jasper-devel"
-depends="desktop-file-utils"
-short_desc="Utility to read and manipulate raw images from digital cameras"
-maintainer="John <me@johnnynator.dev>"
-license="GPL-2.0-or-later"
-homepage="http://ufraw.sourceforge.net/"
-distfiles="${SOURCEFORGE_SITE}/ufraw/ufraw/ufraw-${version}/ufraw-${version}.tar.gz"
-checksum=f7abd28ce587db2a74b4c54149bd8a2523a7ddc09bedf4f923246ff0ae09a25e
-
-build_options="extras"
-
-post_patch() {
-	vsed -e 's/default(none)//g' \
-		-i dcraw_indi.c \
-		-i dcraw_api.cc \
-		-i ufraw_ufraw.c \
-		-i ufraw_developer.c
-	vsed -i -e '/DATADIRNAME=/s/=.*/=share/' configure
-	vsed -i -e "s,^localedir =.*,localedir = /usr/share/locale," \
-		po/Makefile.in.in
-}
-
-ufraw-gimp_package() {
-	depends="${sourcepkg}>=${version}_${revision}"
-	short_desc+=" - gimp plugin"
-	pkg_install() {
-		vmove usr/lib/gimp
-	}
-}

^ permalink raw reply	[flat|nested] 27+ messages in thread

* Re: [PR PATCH] [Updated] exiv2: update to 0.28.0.
  2023-10-23  0:10 [PR PATCH] exiv2: update to 0.28.0 mhmdanas
                   ` (7 preceding siblings ...)
  2023-11-04 21:57 ` [PR PATCH] [Updated] " mhmdanas
@ 2023-11-06 20:17 ` mhmdanas
  2023-11-06 20:18 ` mhmdanas
                   ` (16 subsequent siblings)
  25 siblings, 0 replies; 27+ messages in thread
From: mhmdanas @ 2023-11-06 20:17 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 2054 bytes --]

There is an updated pull request by mhmdanas against master on the void-packages repository

https://github.com/mhmdanas/void-packages exiv2-0.28.0
https://github.com/void-linux/void-packages/pull/46838

exiv2: update to 0.28.0.
<!-- Uncomment relevant sections and delete options which are not applicable -->

#### Testing the changes
- I tested the changes in this PR: **briefly**

TODO:
- [x] Fix `gwenview`'s failed checks (not really fixed but the exact same tests fail on master as well)
- [x] `test_exiv2` fails for `libextractor`
- [x] `kfilemetadata5` tests fail (same tests fail on master)
- [ ] Fix `nufraw` cross-build

@Johnnynator ufraw has been [unmaintained since December 2016](https://sourceforge.net/p/ufraw/discussion/434060/thread/30b4249b/), and it doesn't build with this PR; here are the options:
- remove the package entirely
- replace it with the newer [nufraw](https://sourceforge.net/projects/nufraw/), which already has [an exiv 0.28.x patch floating around](https://aur.archlinux.org/cgit/aur.git/tree/exiv2-error.patch?h=nufraw)
- patch it to build with this PR

What do you think? (edit: `nufraw` now replaces `ufraw` in this PR)

<!--
#### New package
- This new package conforms to the [package requirements](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTItest_exiv2NG.md#package-requirements): **YES**|**NO**
-->

<!-- Note: If the build is likely to take more than 2 hours, please add ci skip tag as described in
https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration
and test at least one native build and, if supported, at least one cross build.
Ignore this section if this PR is not skipping CI.
-->
<!--
#### Local build testing
- I built this PR locally for my native architecture, (ARCH-LIBC)
- I built this PR locally for these architectures (if supported. mark crossbuilds):
  - aarch64-musl
  - armv7l
  - armv6l-musl
-->


A patch file from https://github.com/void-linux/void-packages/pull/46838.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-exiv2-0.28.0-46838.patch --]
[-- Type: text/x-diff, Size: 60901 bytes --]

From c287c36c4507d4589e2b8e658c67f286f3e63f96 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Mon, 23 Oct 2023 01:20:09 +0100
Subject: [PATCH 01/22] inih: add `libINIReader.so.0` common/shlibs entry.

---
 common/shlibs | 1 +
 1 file changed, 1 insertion(+)

diff --git a/common/shlibs b/common/shlibs
index 9036a675c1ae5..8f03a38a16789 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -3905,6 +3905,7 @@ libnotcurses++.so.3 notcurses-3.0.5_1
 libnotcurses-ffi.so.3 notcurses-3.0.5_1
 libevemu.so.3 evemu-2.7.0_1
 libinih.so.0 inih-52_1
+libINIReader.so.0 inih-57_1
 libpcaudio.so.0 pcaudiolib-1.1_1
 libdcerpc-samr.so.0 samba-4.13.2_1
 libdcerpc-server-core.so.0 samba-4.13.2_1

From 06a890abedb74bb755f00830e661c649ae7a3464 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:12 +0100
Subject: [PATCH 02/22] exiv2: update to 0.28.0.

---
 common/shlibs          |  2 +-
 srcpkgs/exiv2/template | 18 +++++++++++-------
 2 files changed, 12 insertions(+), 8 deletions(-)

diff --git a/common/shlibs b/common/shlibs
index 8f03a38a16789..0b1d0c89d3e51 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -555,7 +555,7 @@ libgimpcolor-2.0.so.0 libgimp-2.10.0_1
 libgimpmodule-2.0.so.0 libgimp-2.10.0_1
 libgmic.so.3 gmic-3.1.6_1
 libcgmic.so.3 gmic-3.1.6_1
-libexiv2.so.27 exiv2-0.27_1
+libexiv2.so.28 exiv2-0.28.0_1
 libKF5Holidays.so.5 kholidays-5.47.0_1
 libPhabricatorHelpers.so.5 purpose-5.48.0_1
 libKF5PurposeWidgets.so.5 purpose-5.48.0_1
diff --git a/srcpkgs/exiv2/template b/srcpkgs/exiv2/template
index 49985fe82cc14..4517906521b4e 100644
--- a/srcpkgs/exiv2/template
+++ b/srcpkgs/exiv2/template
@@ -1,17 +1,17 @@
 # Template file for 'exiv2'
 pkgname=exiv2
-version=0.27.6
+version=0.28.1
 revision=1
 build_style=cmake
 configure_args="-DEXIV2_BUILD_SAMPLES=OFF -DEXIV2_ENABLE_BMFF=ON"
-makedepends="zlib-devel expat-devel"
-checkdepends="gtest-devel"
+makedepends="zlib-devel brotli-devel expat-devel inih-devel"
+checkdepends="gtest-devel python3"
 short_desc="Image metadata manipulation"
 maintainer="Enno Boland <gottox@voidlinux.org>"
 license="GPL-2.0-or-later"
 homepage="https://www.exiv2.org"
-distfiles="https://github.com/Exiv2/exiv2/releases/download/v${version}/exiv2-${version}-Source.tar.gz"
-checksum=4c192483a1125dc59a3d70b30d30d32edace9e14adf52802d2f853abf72db8a6
+distfiles="https://github.com/Exiv2/exiv2/archive/refs/tags/v${version}.zip"
+checksum=eab4c4b919930905e2128c56cb15919cb8105d431ccef8712f98fd4871f3d09a
 
 if [ -n "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DEXIV2_BUILD_UNIT_TESTS=ON"
@@ -21,14 +21,18 @@ if [ -n "$XBPS_CCACHE" ]; then
 	configure_args+=" -DBUILD_WITH_CCACHE=ON"
 fi
 
+pre_check() {
+	# https://github.com/Exiv2/exiv2/issues/2762
+	rm -f tests/bugfixes/github/test_issue_2427.py
+}
+
 exiv2-devel_package() {
 	depends="${makedepends} ${sourcepkg}-${version}_${revision}"
 	short_desc+=" - development files"
 	pkg_install() {
 		vmove usr/include
-		vmove usr/lib/cmake
 		vmove usr/lib/pkgconfig
-		vmove "usr/lib/*.a"
+		vmove usr/share/cmake
 		vmove "usr/lib/*.so"
 	}
 }

From 2574aad4337ccce013880a910191d6ac4263f2b1 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:37 +0100
Subject: [PATCH 03/22] ART: revbump for exiv2-0.28.0.

---
 srcpkgs/ART/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/ART/template b/srcpkgs/ART/template
index b6c47fc6c4cdf..94c7aa0378061 100644
--- a/srcpkgs/ART/template
+++ b/srcpkgs/ART/template
@@ -1,7 +1,7 @@
 # Template file for 'ART'
 pkgname=ART
 version=1.20.2
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="pkg-config"
 makedepends="fftw-devel gtkmm-devel lensfun-devel

From e656a49ca7874e6b2c9a038bb3c9d6d92f66b805 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 04/22] darktable: revbump for exiv2-0.28.0.

---
 srcpkgs/darktable/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/darktable/template b/srcpkgs/darktable/template
index 60415a34dc018..3d35571239a93 100644
--- a/srcpkgs/darktable/template
+++ b/srcpkgs/darktable/template
@@ -1,7 +1,7 @@
 # Template file for 'darktable'
 pkgname=darktable
 version=4.4.2
-revision=2
+revision=3
 # upstream only supports these archs:
 archs="x86_64* aarch64* ppc64le*"
 build_style=cmake

From c2d7e52bf364c39b07fa240e07e3100f3e7ae180 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 05/22] digikam: revbump for exiv2-0.28.0.

---
 srcpkgs/digikam/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/digikam/template b/srcpkgs/digikam/template
index 206185f565488..4784bf7d62a8e 100644
--- a/srcpkgs/digikam/template
+++ b/srcpkgs/digikam/template
@@ -1,7 +1,7 @@
 # Template file for 'digikam'
 pkgname=digikam
 version=8.1.0
-revision=1
+revision=2
 build_style=cmake
 configure_args="-DBUILD_TESTING=OFF"
 hostmakedepends="extra-cmake-modules gettext pkg-config bison flex qt5-qmake

From 9d5bff3c61d77a12024d5b0005613380785dae77 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 06/22] geeqie: revbump for exiv2-0.28.0.

---
 srcpkgs/geeqie/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/geeqie/template b/srcpkgs/geeqie/template
index b5f958f854c1b..b494bc149e957 100644
--- a/srcpkgs/geeqie/template
+++ b/srcpkgs/geeqie/template
@@ -1,7 +1,7 @@
 # Template file for 'geeqie'
 pkgname=geeqie
 version=2.1
-revision=1
+revision=2
 build_style=meson
 hostmakedepends="pkg-config gettext xxd gdk-pixbuf-devel glib-devel"
 makedepends="gtk+3-devel glib-devel lcms2-devel exiv2-devel libheif-devel

From db6cd54e098cf0025294e72a8bf743db22732101 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 07/22] gthumb: revbump for exiv2-0.28.0.

---
 srcpkgs/gthumb/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/gthumb/template b/srcpkgs/gthumb/template
index c8e19f0dedb61..732d5e1c6089f 100644
--- a/srcpkgs/gthumb/template
+++ b/srcpkgs/gthumb/template
@@ -1,7 +1,7 @@
 # Template file for 'gthumb'
 pkgname=gthumb
 version=3.12.3
-revision=1
+revision=2
 build_style=meson
 hostmakedepends="gettext pkg-config itstool glib-devel"
 makedepends="webkit2gtk-devel json-glib-devel libsecret-devel librsvg-devel

From a852724d381fbcf4629d70a75bccbf49e84e99c2 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 08/22] gwenview: revbump for exiv2-0.28.0.

---
 srcpkgs/gwenview/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/gwenview/template b/srcpkgs/gwenview/template
index 73d450a458c4d..eb876cfadcfe8 100644
--- a/srcpkgs/gwenview/template
+++ b/srcpkgs/gwenview/template
@@ -1,7 +1,7 @@
 # Template file for 'gwenview'
 pkgname=gwenview
 version=23.08.2
-revision=1
+revision=2
 build_style=cmake
 build_helper=qemu
 hostmakedepends="extra-cmake-modules pkg-config qt5-qmake qt5-host-tools

From 722d30ff0af1b1422274563b50d6d0414aec4b3c Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 09/22] hugin: revbump for exiv2-0.28.0.

---
 srcpkgs/hugin/patches/exiv2-0.28.patch | 77 ++++++++++++++++++++++++++
 srcpkgs/hugin/template                 |  2 +-
 2 files changed, 78 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/hugin/patches/exiv2-0.28.patch

diff --git a/srcpkgs/hugin/patches/exiv2-0.28.patch b/srcpkgs/hugin/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..49f0518117020
--- /dev/null
+++ b/srcpkgs/hugin/patches/exiv2-0.28.patch
@@ -0,0 +1,77 @@
+Patch-Source: https://gitlab.archlinux.org/archlinux/packaging/packages/hugin/-/blob/main/exiv2-0.28.patch
+diff -r 79cd11a7a66f src/hugin_base/panodata/Exiv2Helper.cpp
+--- a/src/hugin_base/panodata/Exiv2Helper.cpp	Wed May 24 19:13:20 2023 +0200
++++ b/src/hugin_base/panodata/Exiv2Helper.cpp	Mon Jun 05 00:31:19 2023 +0200
+@@ -40,7 +40,7 @@
+             Exiv2::ExifData::iterator itr = exifData.findKey(Exiv2::ExifKey(keyName));
+             if (itr != exifData.end() && itr->count())
+             {
+-                value = itr->toLong();
++                value = itr->toUint32();
+                 return true;
+             }
+             else
+@@ -165,7 +165,7 @@
+         {
+             if(it!=exifData.end() && it->count())
+             {
+-                return it->toLong();
++                return it->toUint32();
+             }
+             return 0;
+         };
+@@ -600,4 +600,4 @@
+         };
+ 
+     }; //namespace Exiv2Helper
+-}; //namespace HuginBase
+\ No newline at end of file
++}; //namespace HuginBase
+diff -r 79cd11a7a66f src/hugin_base/panodata/SrcPanoImage.cpp
+--- a/src/hugin_base/panodata/SrcPanoImage.cpp	Wed May 24 19:13:20 2023 +0200
++++ b/src/hugin_base/panodata/SrcPanoImage.cpp	Mon Jun 05 00:31:19 2023 +0200
+@@ -384,7 +384,7 @@
+                     pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaImageWidthPixels"));
+                     if (pos != xmpData.end())
+                     {
+-                        croppedWidth = pos->toLong();
++                        croppedWidth = pos->toUint32();
+                     }
+                     else
+                     {
+@@ -394,7 +394,7 @@
+                     pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaImageHeightPixels"));
+                     if (pos != xmpData.end())
+                     {
+-                        croppedHeight = pos->toLong();
++                        croppedHeight = pos->toUint32();
+                     }
+                     else
+                     {
+@@ -408,7 +408,7 @@
+                         double hfov = 0;
+                         if (pos != xmpData.end())
+                         {
+-                            hfov = 360 * croppedWidth / (double)pos->toLong();
++                            hfov = 360 * croppedWidth / (double)pos->toUint32();
+                         }
+                         else
+                         {
+@@ -419,7 +419,7 @@
+                         pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.FullPanoHeightPixels"));
+                         if (pos != xmpData.end())
+                         {
+-                            fullHeight = pos->toLong();
++                            fullHeight = pos->toUint32();
+                         }
+                         else
+                         {
+@@ -430,7 +430,7 @@
+                         pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaTopPixels"));
+                         if (pos != xmpData.end())
+                         {
+-                            cropTop = pos->toLong();
++                            cropTop = pos->toUint32();
+                         }
+                         else
+                         {
diff --git a/srcpkgs/hugin/template b/srcpkgs/hugin/template
index f96d2f6e27d42..ce71f6e4cbb2d 100644
--- a/srcpkgs/hugin/template
+++ b/srcpkgs/hugin/template
@@ -1,7 +1,7 @@
 # Template file for 'hugin'
 pkgname=hugin
 version=2022.0.0
-revision=10
+revision=11
 build_style=cmake
 build_helper=cmake-wxWidgets-gtk3
 pycompile_dirs="usr/share/hugin/data/plugins usr/share/hugin/data/plugins-templates"

From b09d091225cbb038ba79656add101a7f7ee56845 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 10/22] kfilemetadata5: revbump for exiv2-0.28.0.

---
 srcpkgs/kfilemetadata5/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/kfilemetadata5/template b/srcpkgs/kfilemetadata5/template
index 00f7a98cf6399..e294ae5af947c 100644
--- a/srcpkgs/kfilemetadata5/template
+++ b/srcpkgs/kfilemetadata5/template
@@ -1,7 +1,7 @@
 # Template file for 'kfilemetadata5'
 pkgname=kfilemetadata5
 version=5.111.0
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="kcoreaddons extra-cmake-modules pkg-config qt5-host-tools qt5-qmake
  gettext kcoreaddons python3"

From 25752cf46b25c1a4fe59f790d9f7f2929b5c5e9c Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 11/22] krename: revbump for exiv2-0.28.0.

---
 srcpkgs/krename/patches/e7dd767a.patch | 90 ++++++++++++++++++++++++++
 srcpkgs/krename/template               |  2 +-
 2 files changed, 91 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/krename/patches/e7dd767a.patch

diff --git a/srcpkgs/krename/patches/e7dd767a.patch b/srcpkgs/krename/patches/e7dd767a.patch
new file mode 100644
index 0000000000000..a0ef428ce46b1
--- /dev/null
+++ b/srcpkgs/krename/patches/e7dd767a.patch
@@ -0,0 +1,90 @@
+Patch-Source: https://invent.kde.org/utilities/krename/-/commit/e7dd767a
+From e7dd767a9a1068ee1fe1502c4d619b57d3b12add Mon Sep 17 00:00:00 2001
+From: Andreas Sturmlechner <asturm@gentoo.org>
+Date: Fri, 26 May 2023 23:23:10 +0200
+Subject: [PATCH] Fix build with >=exiv2-0.28, raise minimum to 0.27
+
+- enables use of EXIV2_TEST_VERSION macro
+- exiv2 headers cleanup
+
+Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>
+---
+ CMakeLists.txt         |  6 +-----
+ config-krename.h.cmake |  3 ---
+ src/exiv2plugin.cpp    | 17 +++++------------
+ 3 files changed, 6 insertions(+), 20 deletions(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 0bda8ac..72e7297 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -56,13 +56,9 @@ set_package_properties(Taglib PROPERTIES
+     TYPE OPTIONAL)
+ 
+ # Find exiv2
+-find_package(LibExiv2 0.13) # AccessMode was added in 0.13
++find_package(LibExiv2 0.27) # EXIV2_TEST_VERSION was added in 0.27
+ set_package_properties(LibExiv2 PROPERTIES TYPE OPTIONAL)
+ 
+-if (LibExiv2_VERSION VERSION_GREATER_EQUAL "0.27")
+-    set(HAVE_LIBEXIV2_0_27 TRUE)
+-endif()
+-
+ # Find podofo
+ find_package(PoDoFo)
+ set_package_properties(PoDoFo PROPERTIES
+diff --git a/config-krename.h.cmake b/config-krename.h.cmake
+index 76c3d30..862e40b 100644
+--- a/config-krename.h.cmake
++++ b/config-krename.h.cmake
+@@ -6,9 +6,6 @@
+ /* have Exiv2 */
+ #cmakedefine01 HAVE_EXIV2
+ 
+-/* Defined if we have libexiv2 >= 0.27 */
+-#cmakedefine HAVE_LIBEXIV2_0_27
+-
+ /* have PoDoFo */
+ #cmakedefine01 HAVE_PODOFO
+ 
+diff --git a/src/exiv2plugin.cpp b/src/exiv2plugin.cpp
+index 5694d8c..25e8869 100644
+--- a/src/exiv2plugin.cpp
++++ b/src/exiv2plugin.cpp
+@@ -3,20 +3,9 @@
+ 
+ #include "exiv2plugin.h"
+ 
+-#include "../config-krename.h"
+-
+ #include <KLocalizedString>
+ 
+-#include <exiv2/error.hpp>
+-#include <exiv2/exif.hpp>
+-#include <exiv2/image.hpp>
+-#include <exiv2/iptc.hpp>
+-#ifdef HAVE_LIBEXIV2_0_27
+-    #include <exiv2/xmp_exiv2.hpp>
+-#else
+-    #include <exiv2/xmp.hpp>
+-#endif
+-#include <exiv2/tags.hpp>
++#include <exiv2/exiv2.hpp>
+ 
+ #include "batchrenamer.h"
+ #include "tokenhelpdialog.h"
+@@ -381,7 +370,11 @@ QString Exiv2Plugin::processFile(BatchRenamer *b, int index, const QString &file
+     std::string strFilename(asc.constData(), asc.length());
+ 
+     try {
++#if EXIV2_TEST_VERSION(0,28,0)
++        Image::UniquePtr image = Exiv2::ImageFactory::open(strFilename);
++#else
+         Image::AutoPtr image = Exiv2::ImageFactory::open(strFilename);
++#endif
+         if (image.get() != nullptr && image->good()) {
+             image->readMetadata();
+ 
+-- 
+GitLab
+
diff --git a/srcpkgs/krename/template b/srcpkgs/krename/template
index 66023163e3293..df5535007714a 100644
--- a/srcpkgs/krename/template
+++ b/srcpkgs/krename/template
@@ -1,7 +1,7 @@
 # Template file for 'krename'
 pkgname=krename
 version=5.0.2
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="extra-cmake-modules gettext kcoreaddons pkg-config qt5-host-tools qt5-qmake"
 makedepends="exiv2-devel freetype-devel kjs-devel kparts-devel libpodofo-devel

From 2c4216297307d1ae5e8ede1ec8300ebc00e1dd4c Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 12/22] krita: revbump for exiv2-0.28.0.

---
 srcpkgs/krita/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/krita/template b/srcpkgs/krita/template
index 63ee0fbe9bceb..f4d665daf7c31 100644
--- a/srcpkgs/krita/template
+++ b/srcpkgs/krita/template
@@ -1,7 +1,7 @@
 # Template file for 'krita'
 pkgname=krita
 version=5.2.1
-revision=1
+revision=2
 build_style=cmake
 configure_args="-Wno-dev -DBUILD_TESTING=OFF"
 hostmakedepends="extra-cmake-modules gettext pkg-config python3

From 4cd3a85eaef05dad5127a4e0fe33ea7f2c1675e4 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 13/22] libextractor: revbump for exiv2-0.28.0.

---
 srcpkgs/libextractor/patches/exiv2-0.28.patch | 286 ++++++++++++++++++
 srcpkgs/libextractor/patches/fix-tests.diff   |  24 ++
 srcpkgs/libextractor/template                 |   2 +-
 3 files changed, 311 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/libextractor/patches/exiv2-0.28.patch
 create mode 100644 srcpkgs/libextractor/patches/fix-tests.diff

diff --git a/srcpkgs/libextractor/patches/exiv2-0.28.patch b/srcpkgs/libextractor/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..270a626d8ab06
--- /dev/null
+++ b/srcpkgs/libextractor/patches/exiv2-0.28.patch
@@ -0,0 +1,286 @@
+Patch-Source: https://gitlab.archlinux.org/archlinux/packaging/packages/libextractor/-/blob/main/exiv2-0.28.patch
+diff --git a/src/plugins/exiv2_extractor.cc b/src/plugins/exiv2_extractor.cc
+index 78f9bda..d32ed6a 100644
+--- a/src/plugins/exiv2_extractor.cc
++++ b/src/plugins/exiv2_extractor.cc
+@@ -90,7 +90,11 @@ virtual int close ();
+  * @param rcount number of bytes to read
+  * @return buffer with data read, empty buffer (!) on failure (!)
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++virtual Exiv2::DataBuf read (size_t rcount);
++#else
+ virtual Exiv2::DataBuf read (long rcount);
++#endif
+ 
+ /**
+  * Read up to 'rcount' bytes into 'buf'.
+@@ -99,8 +103,17 @@ virtual Exiv2::DataBuf read (long rcount);
+  * @param rcount size of 'buf'
+  * @return number of bytes read successfully, 0 on failure (!)
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++virtual size_t read (Exiv2::byte *buf,
++                   size_t rcount);
++#else
+ virtual long read (Exiv2::byte *buf,
+                    long rcount);
++#endif
++
++#if EXIV2_TEST_VERSION (0,28,0)
++virtual void populateFakeData();
++#endif
+ 
+ /**
+  * Read a single character.
+@@ -117,8 +130,13 @@ virtual int getb ();
+  * @param wcount how many bytes to write
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual size_t write (const Exiv2::byte *data,
++                    size_t wcount);
++#else
+ virtual long write (const Exiv2::byte *data,
+                     long wcount);
++#endif
+ 
+ /**
+  * Write to stream.
+@@ -126,7 +144,11 @@ virtual long write (const Exiv2::byte *data,
+  * @param src stream to copy
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual size_t write (Exiv2::BasicIo &src);
++#else
+ virtual long write (Exiv2::BasicIo &src);
++#endif
+ 
+ /**
+  * Write a single byte.
+@@ -172,7 +194,11 @@ virtual int munmap ();
+  *
+  * @return -1 on error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual size_t tell (void) const;
++#else
+ virtual long int tell (void) const;
++#endif
+ 
+ /**
+  * Return overall size of the file.
+@@ -213,7 +239,11 @@ virtual bool eof () const;
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual const std::string& path () const noexcept;
++#else
+ virtual std::string path () const;
++#endif
+ 
+ #ifdef EXV_UNICODE_PATH
+ /**
+@@ -230,7 +260,11 @@ virtual std::wstring wpath () const;
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual Exiv2::BasicIo::UniquePtr temporary () const;
++#else
+ virtual Exiv2::BasicIo::AutoPtr temporary () const;
++#endif
+ 
+ };
+ 
+@@ -266,7 +300,11 @@ ExtractorIO::close ()
+  * @return buffer with data read, empty buffer (!) on failure (!)
+  */
+ Exiv2::DataBuf
++#if EXIV2_TEST_VERSION (0,28,0)
++ExtractorIO::read (size_t rcount)
++#else
+ ExtractorIO::read (long rcount)
++#endif
+ {
+   void *data;
+   ssize_t ret;
+@@ -284,9 +322,15 @@ ExtractorIO::read (long rcount)
+  * @param rcount size of 'buf'
+  * @return number of bytes read successfully, 0 on failure (!)
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++size_t
++ExtractorIO::read (Exiv2::byte *buf,
++                   size_t rcount)
++#else
+ long
+ ExtractorIO::read (Exiv2::byte *buf,
+                    long rcount)
++#endif
+ {
+   void *data;
+   ssize_t ret;
+@@ -305,6 +349,12 @@ ExtractorIO::read (Exiv2::byte *buf,
+   return got;
+ }
+ 
++#if EXIV2_TEST_VERSION (0,28,0)
++void ExtractorIO::populateFakeData()
++{
++  return;
++}
++#endif
+ 
+ /**
+  * Read a single character.
+@@ -319,7 +369,9 @@ ExtractorIO::getb ()
+   const unsigned char *r;
+ 
+   if (1 != ec->read (ec->cls, &data, 1))
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION(0,28,0)
++    throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+     throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+     throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -336,9 +388,15 @@ ExtractorIO::getb ()
+  * @param wcount how many bytes to write
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++size_t
++ExtractorIO::write (const Exiv2::byte *data,
++                    size_t wcount)
++#else
+ long
+ ExtractorIO::write (const Exiv2::byte *data,
+                     long wcount)
++#endif
+ {
+   return -1;
+ }
+@@ -350,7 +408,11 @@ ExtractorIO::write (const Exiv2::byte *data,
+  * @param src stream to copy
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++size_t
++#else
+ long
++#endif
+ ExtractorIO::write (Exiv2::BasicIo &src)
+ {
+   return -1;
+@@ -378,7 +440,9 @@ ExtractorIO::putb (Exiv2::byte data)
+ void
+ ExtractorIO::transfer (Exiv2::BasicIo& src)
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION(0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -427,7 +491,9 @@ ExtractorIO::seek (long offset,
+ Exiv2::byte *
+ ExtractorIO::mmap (bool isWritable)
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION (0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -452,7 +518,11 @@ ExtractorIO::munmap ()
+  *
+  * @return -1 on error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++size_t
++#else
+ long int
++#endif
+ ExtractorIO::tell (void) const
+ {
+   return (long) ec->seek (ec->cls, 0, SEEK_CUR);
+@@ -516,10 +586,17 @@ ExtractorIO::eof () const
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++const std::string&
++ExtractorIO::path () const noexcept
++#else
+ std::string
+ ExtractorIO::path () const
++#endif
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION (0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -536,7 +613,9 @@ ExtractorIO::path () const
+ std::wstring
+ ExtractorIO::wpath () const
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION (0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -552,11 +631,17 @@ ExtractorIO::wpath () const
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++Exiv2::BasicIo::UniquePtr
++#else
+ Exiv2::BasicIo::AutoPtr
++#endif
+ ExtractorIO::temporary () const
+ {
+   fprintf (stderr, "throwing temporary error\n");
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION(0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -737,8 +822,13 @@ EXTRACTOR_exiv2_extract_method (struct EXTRACTOR_ExtractContext *ec)
+ #if ! EXIV2_TEST_VERSION (0,24,0)
+     Exiv2::LogMsg::setLevel (Exiv2::LogMsg::mute);
+ #endif
++#if EXIV2_TEST_VERSION(0,28,0)
++    std::unique_ptr<Exiv2::BasicIo> eio (new ExtractorIO (ec));
++    Exiv2::Image::UniquePtr image = Exiv2::ImageFactory::open (std::move(eio));
++#else
+     std::auto_ptr<Exiv2::BasicIo> eio (new ExtractorIO (ec));
+     Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open (eio);
++#endif
+     if (0 == image.get ())
+       return;
+     image->readMetadata ();
+@@ -822,7 +912,11 @@ EXTRACTOR_exiv2_extract_method (struct EXTRACTOR_ExtractContext *ec)
+       ADDXMP ("Xmp.lr.hierarchicalSubject", EXTRACTOR_METATYPE_SUBJECT);
+     }
+   }
++#if EXIV2_TEST_VERSION (0,28,0)
++  catch (const Exiv2::Error& e)
++#else
+   catch (const Exiv2::AnyError& e)
++#endif
+   {
+ #if DEBUG
+     std::cerr << "Caught Exiv2 exception '" << e << "'\n";
diff --git a/srcpkgs/libextractor/patches/fix-tests.diff b/srcpkgs/libextractor/patches/fix-tests.diff
new file mode 100644
index 0000000000000..3b4ee7cbeea33
--- /dev/null
+++ b/srcpkgs/libextractor/patches/fix-tests.diff
@@ -0,0 +1,24 @@
+--- a/src/plugins/test_exiv2.c	2021-01-30 13:20:23.000000000 +0000
++++ b/src/plugins/test_exiv2.c	2023-11-03 19:39:43.115274492 +0000
+@@ -49,8 +49,8 @@
+       EXTRACTOR_METATYPE_GPS_LATITUDE,
+       EXTRACTOR_METAFORMAT_UTF8,
+       "text/plain",
+-      "28deg 8' (18|17.585)\" ?",
+-      strlen ("28deg 8' (18|17.585)\" ?") + 1,
++      "28 deg 8' (18|17.58)\" ?",
++      strlen ("28 deg 8' (18|17.58)\" ?") + 1,
+       0,
+       .regex = 1
+     },
+@@ -66,8 +66,8 @@
+       EXTRACTOR_METATYPE_GPS_LONGITUDE,
+       EXTRACTOR_METAFORMAT_UTF8,
+       "text/plain",
+-      "14deg 14' (22|21.713)\" ?",
+-      strlen ("14deg 14' (22|21.713)\" ?"),
++      "14 deg 14' (22|21.71)\" ?",
++      strlen ("14 deg 14' (22|21.71)\" ?"),
+       0,
+       .regex = 1
+     },
diff --git a/srcpkgs/libextractor/template b/srcpkgs/libextractor/template
index ddd4790f93e88..bfcea979a308c 100644
--- a/srcpkgs/libextractor/template
+++ b/srcpkgs/libextractor/template
@@ -1,7 +1,7 @@
 # Template file for 'libextractor'
 pkgname=libextractor
 version=1.11
-revision=2
+revision=3
 build_style=gnu-configure
 configure_args="--disable-static"
 hostmakedepends="pkg-config"

From 3b6d90ee4bc1340cf2e960b3bde16d7dfce72a35 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 14/22] libgexiv2: update to 0.14.2.

---
 srcpkgs/libgexiv2/template | 14 +++++++-------
 1 file changed, 7 insertions(+), 7 deletions(-)

diff --git a/srcpkgs/libgexiv2/template b/srcpkgs/libgexiv2/template
index 23780e5397dc4..91dbcaa9aca52 100644
--- a/srcpkgs/libgexiv2/template
+++ b/srcpkgs/libgexiv2/template
@@ -1,19 +1,19 @@
 # Template file for 'libgexiv2'
 pkgname=libgexiv2
-version=0.14.0
-revision=3
+version=0.14.2
+revision=1
 build_style=meson
 build_helper="gir"
-configure_args="-Dintrospection=$(vopt_if gir true false)
- -Dvapi=$(vopt_if vala true false)"
+configure_args="$(vopt_bool gir introspection) $(vopt_bool vala vapi)"
 hostmakedepends="pkg-config glib-devel $(vopt_if vala 'vala') python3-gobject"
 makedepends="libglib-devel exiv2-devel"
 short_desc="GObject-based wrapper around the Exiv2 library"
 maintainer="Enno Boland <gottox@voidlinux.org>"
 license="GPL-2.0-or-later"
 homepage="https://wiki.gnome.org/Projects/gexiv2"
-distfiles="${GNOME_SITE}/gexiv2/${version%.*}/${pkgname/lib/}-${version}.tar.xz"
-checksum=e58279a6ff20b6f64fa499615da5e9b57cf65ba7850b72fafdf17221a9d6d69e
+changelog="https://gitlab.gnome.org/GNOME/gexiv2/-/raw/master/NEWS"
+distfiles="${GNOME_SITE}/gexiv2/${version%.*}/gexiv2-${version}.tar.xz"
+checksum=2a0c9cf48fbe8b3435008866ffd40b8eddb0667d2212b42396fdf688e93ce0be
 
 build_options="gir vala"
 build_options_default="gir vala"
@@ -23,7 +23,7 @@ libgexiv2-devel_package() {
 	short_desc+=" - development files"
 	pkg_install() {
 		vmove usr/include
-		vmove usr/lib/*.so
+		vmove "usr/lib/*.so"
 		vmove usr/lib/pkgconfig
 		if [ "$build_option_vala" ]; then
 			vmove usr/share/vala

From de998029b9d172f155bc8390fdd6fe8b990f2b99 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 15/22] libkexiv25: update to 23.08.2.

---
 srcpkgs/libkexiv25/template | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/srcpkgs/libkexiv25/template b/srcpkgs/libkexiv25/template
index b439a42ef2b97..4d7f9600572ea 100644
--- a/srcpkgs/libkexiv25/template
+++ b/srcpkgs/libkexiv25/template
@@ -1,6 +1,6 @@
 # Template file for 'libkexiv25'
 pkgname=libkexiv25
-version=23.04.0
+version=23.08.2
 revision=1
 build_style=cmake
 configure_args="-DBUILD_TESTING=OFF"
@@ -11,7 +11,7 @@ maintainer="Orphaned <orphan@voidlinux.org>"
 license="GPL-2.0-or-later"
 homepage="https://invent.kde.org/graphics/libkexiv2"
 distfiles="${KDE_SITE}/release-service/${version}/src/libkexiv2-${version}.tar.xz"
-checksum=18d3eed06df9d1e31d8434ed9887e305aba176d0856e19a8cd3bdb555b80d391
+checksum=d06e36a408bf2e846a18056a1f15e61d981fa2a1fceb81f7c15136604319d033
 
 libkexiv25-devel_package() {
 	short_desc+=" - development files"

From bc2bcc624924aaa841ece4293875eef642d7be5c Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 16/22] nomacs: update to 3.17.2287.

---
 srcpkgs/nomacs/template | 17 +++++++++++++----
 1 file changed, 13 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/nomacs/template b/srcpkgs/nomacs/template
index c52cd54e294db..956bd21ebb129 100644
--- a/srcpkgs/nomacs/template
+++ b/srcpkgs/nomacs/template
@@ -1,7 +1,8 @@
 # Template file for 'nomacs'
 pkgname=nomacs
-version=3.16.224
-revision=5
+version=3.17.2287
+revision=1
+_plugins_ver=3.17.2285
 build_wrksrc=ImageLounge
 build_style=cmake
 configure_args="-DCMAKE_BUILD_TYPE=None -DENABLE_TRANSLATIONS=1
@@ -13,5 +14,13 @@ short_desc="Simple yet powerful Qt imageviewer"
 maintainer="Orphaned <orphan@voidlinux.org>"
 license="GPL-3.0-or-later"
 homepage="https://github.com/nomacs/nomacs"
-distfiles="https://github.com/nomacs/nomacs/archive/${version}.tar.gz"
-checksum=bbc7e9048026ef9e0d2b64902c88050f17a679ef3d3c009de2c3b7de5d1d217c
+distfiles="https://github.com/nomacs/nomacs/archive/${version}.tar.gz
+ https://github.com/novomesk/nomacs-plugins/archive/refs/tags/${_plugins_ver}.tar.gz>plugins.tar.gz"
+checksum="6905ea615358f84a0c83d5b1b7077871dea0526ec667500a1951448cb845a92c
+ 946b2d754be9ecca5cb155f7ecc5dcafb164f6c3dcc7bf5c3c0610d3b47774aa"
+skip_extraction="plugins.tar.gz"
+
+post_extract() {
+ cd ${build_wrksrc}
+ vsrcextract -C plugins "plugins.tar.gz"
+}

From 14ce0831e8fff7ac3c6da91da9e7fa52e1b53d2e Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 17/22] pdf2djvu: revbump for exiv2-0.28.0.

---
 srcpkgs/pdf2djvu/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/pdf2djvu/template b/srcpkgs/pdf2djvu/template
index ef7433c0c98ae..5a6f3ddf4ed35 100644
--- a/srcpkgs/pdf2djvu/template
+++ b/srcpkgs/pdf2djvu/template
@@ -1,7 +1,7 @@
 # Template file for 'pdf2djvu'
 pkgname=pdf2djvu
 version=0.9.19
-revision=4
+revision=5
 build_style=gnu-configure
 hostmakedepends="pkg-config djvulibre gettext"
 makedepends="djvulibre-devel poppler-devel libgraphicsmagick-devel exiv2-devel libuuid-devel"

From 08dc1b1f59ec9cef6c73e3c0743279fdfdbcdfd1 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 18/22] phototonic: revbump for exiv2-0.28.0.

---
 srcpkgs/phototonic/patches/exiv2-0.28.patch | 135 ++++++++++++++++++++
 srcpkgs/phototonic/template                 |   2 +-
 2 files changed, 136 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/phototonic/patches/exiv2-0.28.patch

diff --git a/srcpkgs/phototonic/patches/exiv2-0.28.patch b/srcpkgs/phototonic/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..1c75b628dab33
--- /dev/null
+++ b/srcpkgs/phototonic/patches/exiv2-0.28.patch
@@ -0,0 +1,135 @@
+From 923a3fc14de0b779a45696c5f0aef34c74d84f13 Mon Sep 17 00:00:00 2001
+From: Andreas Sturmlechner <asturm@gentoo.org>
+Date: Sun, 28 May 2023 18:54:10 +0200
+Subject: [PATCH] Fix build with exiv2-0.28
+
+Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>
+---
+ ImageViewer.cpp   | 9 +++++++++
+ MetadataCache.cpp | 8 ++++++++
+ Phototonic.cpp    | 4 ++++
+ Tags.cpp          | 8 ++++++++
+ ThumbsViewer.cpp  | 4 ++++
+ 5 files changed, 33 insertions(+)
+
+diff --git a/ImageViewer.cpp b/ImageViewer.cpp
+index 357d223..df3ac43 100644
+--- a/ImageViewer.cpp
++++ b/ImageViewer.cpp
+@@ -945,7 +945,11 @@ void ImageViewer::keyMoveEvent(int direction) {
+ }
+ 
+ void ImageViewer::saveImage() {
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr image;
++#else
+     Exiv2::Image::AutoPtr image;
++#endif
+     bool exifError = false;
+ 
+     if (newImage) {
+@@ -985,8 +989,13 @@ void ImageViewer::saveImage() {
+ }
+ 
+ void ImageViewer::saveImageAs() {
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++    Exiv2::Image::UniquePtr newExifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
+     Exiv2::Image::AutoPtr newExifImage;
++#endif
+     bool exifError = false;
+ 
+     setCursorHiding(false);
+diff --git a/MetadataCache.cpp b/MetadataCache.cpp
+index 524ae74..5ddd4c8 100644
+--- a/MetadataCache.cpp
++++ b/MetadataCache.cpp
+@@ -64,7 +64,11 @@ void MetadataCache::clear() {
+ }
+ 
+ bool MetadataCache::loadImageMetadata(const QString &imageFullPath) {
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
++#endif
+     QSet<QString> tags;
+     long orientation = 0;
+ 
+@@ -78,7 +82,11 @@ bool MetadataCache::loadImageMetadata(const QString &imageFullPath) {
+     try {
+         Exiv2::ExifData &exifData = exifImage->exifData();
+         if (!exifData.empty()) {
++#if EXIV2_TEST_VERSION(0,28,0)
++            orientation = exifData["Exif.Image.Orientation"].value().toUint32();
++#else
+             orientation = exifData["Exif.Image.Orientation"].value().toLong();
++#endif
+         }
+     } catch (Exiv2::Error &error) {
+         qWarning() << "Failed to read Exif metadata";
+diff --git a/Phototonic.cpp b/Phototonic.cpp
+index 6cc95b3..bd5497d 100644
+--- a/Phototonic.cpp
++++ b/Phototonic.cpp
+@@ -3151,7 +3151,11 @@ void Phototonic::removeMetadata() {
+ 
+     if (ret == MessageBox::Yes) {
+         for (int file = 0; file < fileList.size(); ++file) {
++#if EXIV2_TEST_VERSION(0,28,0)
++            Exiv2::Image::UniquePtr image;
++#else
+             Exiv2::Image::AutoPtr image;
++#endif
+             try {
+                 image = Exiv2::ImageFactory::open(fileList[file].toStdString());
+                 image->clearMetadata();
+diff --git a/Tags.cpp b/Tags.cpp
+index 84eea16..a62da9d 100644
+--- a/Tags.cpp
++++ b/Tags.cpp
+@@ -136,7 +136,11 @@ void ImageTags::addTag(QString tagName, bool tagChecked) {
+ 
+ bool ImageTags::writeTagsToImage(QString &imageFileName, QSet<QString> &newTags) {
+     QSet<QString> imageTags;
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
++#endif
+ 
+     try {
+         exifImage = Exiv2::ImageFactory::open(imageFileName.toStdString());
+@@ -160,7 +164,11 @@ bool ImageTags::writeTagsToImage(QString &imageFileName, QSet<QString> &newTags)
+         QSetIterator<QString> newTagsIt(newTags);
+         while (newTagsIt.hasNext()) {
+             QString tag = newTagsIt.next();
++#if EXIV2_TEST_VERSION(0,28,0)
++            Exiv2::Value::UniquePtr value = Exiv2::Value::create(Exiv2::string);
++#else
+             Exiv2::Value::AutoPtr value = Exiv2::Value::create(Exiv2::string);
++#endif
+             value->read(tag.toStdString());
+             Exiv2::IptcKey key("Iptc.Application2.Keywords");
+             newIptcData.add(key, value.get());
+diff --git a/ThumbsViewer.cpp b/ThumbsViewer.cpp
+index 77a6189..4a11475 100644
+--- a/ThumbsViewer.cpp
++++ b/ThumbsViewer.cpp
+@@ -210,7 +210,11 @@ void ThumbsViewer::updateImageInfoViewer(QString imageFullPath) {
+         infoView->addEntry(key, val);
+     }
+ 
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
++#endif
+     try {
+         exifImage = Exiv2::ImageFactory::open(imageFullPath.toStdString());
+         exifImage->readMetadata();
+-- 
+2.40.1
+
diff --git a/srcpkgs/phototonic/template b/srcpkgs/phototonic/template
index 77ae8bf6a4406..4af006cb7da41 100644
--- a/srcpkgs/phototonic/template
+++ b/srcpkgs/phototonic/template
@@ -1,7 +1,7 @@
 # Template file for 'phototonic'
 pkgname=phototonic
 version=2.1
-revision=3
+revision=4
 build_style=qmake
 hostmakedepends="pkg-config qt5-qmake qt5-host-tools"
 makedepends="qt5-svg-devel exiv2-devel"

From 2919d8d898d812fed7835aae595afb953f3d66b7 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 19/22] qimgv: revbump for exiv2-0.28.0.

---
 srcpkgs/qimgv/patches/exiv2-0.28.patch | 16 ++++++++++++++++
 srcpkgs/qimgv/template                 |  2 +-
 2 files changed, 17 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/qimgv/patches/exiv2-0.28.patch

diff --git a/srcpkgs/qimgv/patches/exiv2-0.28.patch b/srcpkgs/qimgv/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..11f37b5ae2be3
--- /dev/null
+++ b/srcpkgs/qimgv/patches/exiv2-0.28.patch
@@ -0,0 +1,16 @@
+Patch-Source: https://git.alpinelinux.org/aports/tree/community/qimgv/exiv2-0.28.patch
+diff --git a/qimgv/sourcecontainers/documentinfo.cpp b/qimgv/sourcecontainers/documentinfo.cpp
+index 98a68f7..c062474 100644
+--- a/qimgv/sourcecontainers/documentinfo.cpp
++++ b/qimgv/sourcecontainers/documentinfo.cpp
+@@ -271,10 +271,6 @@ void DocumentInfo::loadExifTags() {
+         //std::cout << "Caught Exiv2 exception '" << e.what() << "'\n";
+         return;
+     }
+-    catch (Exiv2::BasicError<CharType> e) {
+-        //std::cout << "Caught BasicError Exiv2 exception '" << e.what() << "'\n";
+-        return;
+-    }
+ #endif
+ }
+ 
diff --git a/srcpkgs/qimgv/template b/srcpkgs/qimgv/template
index 7eb30db33992c..dd341dfe1bfce 100644
--- a/srcpkgs/qimgv/template
+++ b/srcpkgs/qimgv/template
@@ -1,7 +1,7 @@
 # Template file for 'qimgv'
 pkgname=qimgv
 version=1.0.2
-revision=2
+revision=3
 build_style=cmake
 configure_args="$(vopt_if video -DVIDEO_SUPPORT=ON -DVIDEO_SUPPORT=OFF)
  $(vopt_if scale -DOPENCV_SUPPORT=ON -DOPENCV_SUPPORT=OFF)

From 7122d5364e625506748f73e2dc2ea1b4c2cb8acc Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 20/22] SIR: revbump for exiv2-0.28.0.

---
 srcpkgs/SIR/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/SIR/template b/srcpkgs/SIR/template
index 113077acad354..c6da4c26b6c71 100644
--- a/srcpkgs/SIR/template
+++ b/srcpkgs/SIR/template
@@ -1,7 +1,7 @@
 # Template file for 'SIR'
 pkgname=SIR
 version=3.2.2
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="pkg-config"
 makedepends="exiv2-devel qt5-svg-devel qt5-tools-devel"

From b887d8a64a33abf825903b9f730ae35b8b8b26e8 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 21/22] viewnior: revbump for exiv2-0.28.0.

---
 srcpkgs/viewnior/patches/exiv2-0.28.patch | 147 ++++++++++++++++++++++
 srcpkgs/viewnior/template                 |   2 +-
 2 files changed, 148 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/viewnior/patches/exiv2-0.28.patch

diff --git a/srcpkgs/viewnior/patches/exiv2-0.28.patch b/srcpkgs/viewnior/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..71459dee15768
--- /dev/null
+++ b/srcpkgs/viewnior/patches/exiv2-0.28.patch
@@ -0,0 +1,147 @@
+Patch-Source: https://gitlab.archlinux.org/archlinux/packaging/packages/viewnior/-/blob/f206ce6c22a3ec5f1f9ea1bde4077584f80458dd/exiv2-0.28.patch
+--
+From b6bb81a1b46e911d15bbf9a730972523de177705 Mon Sep 17 00:00:00 2001
+From: tastytea <tastytea@tastytea.de>
+Date: Tue, 16 May 2023 10:54:40 +0200
+Subject: [PATCH 1/2] change exiv2 AutoPtr to unique_ptr
+
+exiv2-0.28.0 removed Exiv2::Image::AutoPtr and added
+Exiv2::Image::UniquePtr instead. since it's a typedef for
+std::unique_ptr<Image>, i'm using that directly instead of adding a
+condition on the exiv2 version.
+---
+ src/uni-exiv2.cpp | 21 +++++++++++----------
+ 1 file changed, 11 insertions(+), 10 deletions(-)
+
+diff --git a/src/uni-exiv2.cpp b/src/uni-exiv2.cpp
+index 0d14b9f..77064c2 100644
+--- a/src/uni-exiv2.cpp
++++ b/src/uni-exiv2.cpp
+@@ -22,12 +22,13 @@
+ 
+ #include <exiv2/exiv2.hpp>
+ #include <iostream>
++#include <memory>
+ 
+ #include "uni-exiv2.hpp"
+ 
+ #define ARRAY_SIZE(array) (sizeof array/sizeof(array[0]))
+ 
+-static Exiv2::Image::AutoPtr cached_image;
++static std::unique_ptr<Exiv2::Image> cached_image;
+ 
+ extern "C"
+ void
+@@ -35,8 +36,8 @@ uni_read_exiv2_map(const char *uri, void (*callback)(const char*, const char*, v
+ {
+     Exiv2::LogMsg::setLevel(Exiv2::LogMsg::mute);
+     try {
+-        Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open(uri);
+-        if ( image.get() == 0 ) {
++        std::unique_ptr<Exiv2::Image> image = Exiv2::ImageFactory::open(uri);
++        if (image == nullptr) {
+             return;
+         }
+ 
+@@ -91,14 +92,14 @@ uni_read_exiv2_to_cache(const char *uri)
+ {
+     Exiv2::LogMsg::setLevel(Exiv2::LogMsg::mute);
+ 
+-    if ( cached_image.get() != NULL ) {
++    if (cached_image != nullptr) {
+         cached_image->clearMetadata();
+-        cached_image.reset(NULL);
++        cached_image.reset(nullptr);
+     }
+ 
+     try {
+         cached_image = Exiv2::ImageFactory::open(uri);
+-        if ( cached_image.get() == 0 ) {
++        if (cached_image == nullptr) {
+             return 1;
+         }
+ 
+@@ -116,13 +117,13 @@ uni_write_exiv2_from_cache(const char *uri)
+ {
+     Exiv2::LogMsg::setLevel(Exiv2::LogMsg::mute);
+ 
+-    if ( cached_image.get() == NULL ) {
++    if (cached_image == nullptr) {
+         return 1;
+     }
+ 
+     try {
+-        Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open(uri);
+-        if ( image.get() == 0 ) {
++        std::unique_ptr<Exiv2::Image> image = Exiv2::ImageFactory::open(uri);
++        if (image == nullptr) {
+             return 2;
+         }
+ 
+@@ -130,7 +131,7 @@ uni_write_exiv2_from_cache(const char *uri)
+         image->writeMetadata();
+ 
+         cached_image->clearMetadata();
+-        cached_image.reset(NULL);
++        cached_image.reset(nullptr);
+ 
+         return 0;
+     } catch (Exiv2::AnyError& e) {
+
+From 47d0b98cb46526aa8aa035bebcabc14a11fa57ee Mon Sep 17 00:00:00 2001
+From: tastytea <tastytea@tastytea.de>
+Date: Tue, 16 May 2023 11:17:00 +0200
+Subject: [PATCH 2/2] add support for exiv-0.28.0 errors
+
+exiv2-0.28.0 changed Exiv2::AnyError to Exiv2::Error.
+---
+ src/uni-exiv2.cpp | 15 ++++++++++++---
+ 1 file changed, 12 insertions(+), 3 deletions(-)
+
+diff --git a/src/uni-exiv2.cpp b/src/uni-exiv2.cpp
+index 77064c2..567a50f 100644
+--- a/src/uni-exiv2.cpp
++++ b/src/uni-exiv2.cpp
+@@ -28,6 +28,15 @@
+ 
+ #define ARRAY_SIZE(array) (sizeof array/sizeof(array[0]))
+ 
++#define EXIV_ERROR Exiv2::AnyError
++#ifdef EXIV2_VERSION
++    #ifdef EXIV2_TEST_VERSION
++        #if EXIV2_TEST_VERSION(0,28,0)
++            #define EXIV_ERROR Exiv2::Error
++        #endif
++    #endif
++#endif
++
+ static std::unique_ptr<Exiv2::Image> cached_image;
+ 
+ extern "C"
+@@ -81,7 +90,7 @@ uni_read_exiv2_map(const char *uri, void (*callback)(const char*, const char*, v
+                 }
+             }
+         }
+-    } catch (Exiv2::AnyError& e) {
++    } catch (EXIV_ERROR& e) {
+         std::cerr << "Exiv2: '" << e << "'\n";
+     }
+ }
+@@ -104,7 +113,7 @@ uni_read_exiv2_to_cache(const char *uri)
+         }
+ 
+         cached_image->readMetadata();
+-    } catch (Exiv2::AnyError& e) {
++    } catch (EXIV_ERROR& e) {
+         std::cerr << "Exiv2: '" << e << "'\n";
+     }
+ 
+@@ -134,7 +143,7 @@ uni_write_exiv2_from_cache(const char *uri)
+         cached_image.reset(nullptr);
+ 
+         return 0;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (EXIV_ERROR& e) {
+         std::cerr << "Exiv2: '" << e << "'\n";
+     }
+ 
diff --git a/srcpkgs/viewnior/template b/srcpkgs/viewnior/template
index ea1e528a8651f..4c73226662ca0 100644
--- a/srcpkgs/viewnior/template
+++ b/srcpkgs/viewnior/template
@@ -1,7 +1,7 @@
 # Template file for 'viewnior'
 pkgname=viewnior
 version=1.8
-revision=1
+revision=2
 build_style=meson
 hostmakedepends="pkg-config intltool glib-devel gettext-devel"
 makedepends="gtk+-devel exiv2-devel"

From 94bb73d1ffefc499298aa224d28dd9e122c92683 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Mon, 23 Oct 2023 19:06:34 +0200
Subject: [PATCH 22/22] New package: nufraw-0.43.3

Co-authored-by: Mohammed Anas <triallax@tutanota.com>
---
 srcpkgs/nufraw-gimp                           |  1 +
 .../patches/0001-nufraw-glib-2.70.patch       | 20 +++++++
 srcpkgs/nufraw/patches/exiv-0.28.x.diff       | 59 +++++++++++++++++++
 srcpkgs/nufraw/template                       | 49 +++++++++++++++
 srcpkgs/removed-packages/template             |  8 ++-
 srcpkgs/ufraw                                 |  1 +
 srcpkgs/ufraw-gimp                            |  2 +-
 .../ufraw/patches/001-no-gimp-remote.patch    | 12 ----
 srcpkgs/ufraw/patches/002-fix_abs_int.patch   | 11 ----
 .../ufraw/patches/03_fix-unsigned-char.patch  | 14 -----
 srcpkgs/ufraw/patches/exiv-0.27.patch         | 25 --------
 srcpkgs/ufraw/patches/glib-2.68.patch         | 30 ----------
 srcpkgs/ufraw/patches/iostream.patch          | 13 ----
 srcpkgs/ufraw/template                        | 38 ------------
 14 files changed, 136 insertions(+), 147 deletions(-)
 create mode 120000 srcpkgs/nufraw-gimp
 create mode 100644 srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch
 create mode 100644 srcpkgs/nufraw/patches/exiv-0.28.x.diff
 create mode 100644 srcpkgs/nufraw/template
 create mode 120000 srcpkgs/ufraw
 delete mode 100644 srcpkgs/ufraw/patches/001-no-gimp-remote.patch
 delete mode 100644 srcpkgs/ufraw/patches/002-fix_abs_int.patch
 delete mode 100644 srcpkgs/ufraw/patches/03_fix-unsigned-char.patch
 delete mode 100644 srcpkgs/ufraw/patches/exiv-0.27.patch
 delete mode 100644 srcpkgs/ufraw/patches/glib-2.68.patch
 delete mode 100644 srcpkgs/ufraw/patches/iostream.patch
 delete mode 100644 srcpkgs/ufraw/template

diff --git a/srcpkgs/nufraw-gimp b/srcpkgs/nufraw-gimp
new file mode 120000
index 0000000000000..0bd1459b2a16f
--- /dev/null
+++ b/srcpkgs/nufraw-gimp
@@ -0,0 +1 @@
+nufraw
\ No newline at end of file
diff --git a/srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch b/srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch
new file mode 100644
index 0000000000000..41f10bfbafa1f
--- /dev/null
+++ b/srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch
@@ -0,0 +1,20 @@
+diff -ru nufraw/uf_glib.h nufraw/uf_glib.h
+--- nufraw/uf_glib.h	2022-02-23 09:03:44.700472919 +0100
++++ nufraw/uf_glib.h	2022-02-23 09:04:50.260308805 +0100
+@@ -13,13 +13,13 @@
+ #ifndef _UF_GLIB_H
+ #define _UF_GLIB_H
+ 
++#include <glib.h>
++#include <glib/gstdio.h>
++
+ #ifdef __cplusplus
+ extern "C" {
+ #endif
+ 
+-#include <glib.h>
+-#include <glib/gstdio.h>
+-
+ // g_win32_locale_filename_from_utf8 is needed only on win32
+ #ifdef _WIN32
+ #define uf_win32_locale_filename_from_utf8(__some_string__) \
diff --git a/srcpkgs/nufraw/patches/exiv-0.28.x.diff b/srcpkgs/nufraw/patches/exiv-0.28.x.diff
new file mode 100644
index 0000000000000..6c23359bf706c
--- /dev/null
+++ b/srcpkgs/nufraw/patches/exiv-0.28.x.diff
@@ -0,0 +1,59 @@
+Patch taken from AUR package: https://aur.archlinux.org/cgit/aur.git/tree/exiv2-error.patch?h=nufraw&id=29e467f2c297fcd0f36548642d6d2cab6428d08f
+diff --git a/nufraw_exiv2.cc b/nufraw_exiv2.cc
+index 2de4cc3..45aea87 100644
+--- a/nufraw_exiv2.cc
++++ b/nufraw_exiv2.cc
+@@ -54,7 +54,7 @@ extern "C" int nufraw_exif_read_input(nufraw_data *uf)
+         uf->inputExifBuf = NULL;
+         uf->inputExifBufLen = 0;
+ 
+-        Exiv2::Image::AutoPtr image;
++        Exiv2::Image::UniquePtr image;
+         if (uf->unzippedBuf != NULL) {
+             image = Exiv2::ImageFactory::open(
+                         (const Exiv2::byte*)uf->unzippedBuf, uf->unzippedBufLen);
+@@ -135,7 +135,7 @@ extern "C" int nufraw_exif_read_input(nufraw_data *uf)
+         nufraw_message(NUFRAW_SET_LOG, "%s\n", stderror.str().c_str());
+ 
+         return NUFRAW_SUCCESS;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (Exiv2::Error& e) {
+         std::cerr.rdbuf(savecerr);
+         std::string s(e.what());
+         nufraw_message(NUFRAW_SET_WARNING, "%s\n", s.c_str());
+@@ -156,7 +156,7 @@ static Exiv2::ExifData nufraw_prepare_exifdata(nufraw_data *uf)
+         if ((pos = exifData.findKey(Exiv2::ExifKey("Exif.Image.Orientation")))
+                 != exifData.end()) {
+             nufraw_message(NUFRAW_SET_LOG, "Resetting %s from '%d' to '1'\n",
+-                          pos->key().c_str(), pos->value().toLong());
++                          pos->key().c_str(), pos->value().toInt64());
+             pos->setValue("1"); /* 1 = Normal orientation */
+         }
+     }
+@@ -327,7 +327,7 @@ extern "C" int nufraw_exif_prepare_output(nufraw_data *uf)
+         nufraw_message(NUFRAW_SET_LOG, "%s\n", stderror.str().c_str());
+ 
+         return NUFRAW_SUCCESS;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (Exiv2::Error& e) {
+         std::cerr.rdbuf(savecerr);
+         std::string s(e.what());
+         nufraw_message(NUFRAW_SET_WARNING, "%s\n", s.c_str());
+@@ -347,7 +347,7 @@ extern "C" int nufraw_exif_write(nufraw_data *uf)
+ 
+         char *filename =
+             uf_win32_locale_filename_from_utf8(uf->conf->outputFilename);
+-        Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open(filename);
++        Exiv2::Image::UniquePtr image = Exiv2::ImageFactory::open(filename);
+         uf_win32_locale_filename_free(filename);
+         assert(image.get() != 0);
+ 
+@@ -367,7 +367,7 @@ extern "C" int nufraw_exif_write(nufraw_data *uf)
+         nufraw_message(NUFRAW_SET_LOG, "%s\n", stderror.str().c_str());
+ 
+         return NUFRAW_SUCCESS;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (Exiv2::Error& e) {
+         std::cerr.rdbuf(savecerr);
+         std::string s(e.what());
+         nufraw_message(NUFRAW_SET_WARNING, "%s\n", s.c_str());
diff --git a/srcpkgs/nufraw/template b/srcpkgs/nufraw/template
new file mode 100644
index 0000000000000..0d901565d80fe
--- /dev/null
+++ b/srcpkgs/nufraw/template
@@ -0,0 +1,49 @@
+# Template file for 'nufraw'
+pkgname=nufraw
+version=0.43.3
+revision=1
+_ver="${version%.*}-${version##*.}"
+build_style=gnu-configure
+configure_args="--enable-contrast --enable-mime --enable-openmp --with-gimp
+ --enable-extras"
+hostmakedepends="pkg-config automake libtool glib-devel"
+# libgexiv2-devel is only here to fix build order, remove on next template
+# change
+makedepends="exiv2-devel gimp-devel gtkimageview-devel lcms2-devel
+ lensfun-devel jasper-devel libgexiv2-devel"
+depends="desktop-file-utils"
+short_desc="Utility to read and manipulate raw images from digital cameras"
+maintainer="John <me@johnnynator.dev>"
+license="GPL-2.0-or-later"
+homepage="https://sourceforge.net/projects/nufraw/"
+distfiles="${SOURCEFORGE_SITE}/nufraw/nufraw-${_ver}.tar.gz"
+checksum=2c7dcc1590993ec267b3112562b2433010d6f94f6acc6506c76aa29cf8c6c32c
+
+pre_configure() {
+	autoreconf -fi
+}
+
+pre_build() {
+	mv nufraw.desktop{.desktop,}
+	chmod +x generate_schemas.sh
+}
+
+nufraw-gimp_package() {
+	depends="${sourcepkg}>=${version}_${revision}"
+	short_desc+=" - gimp plugin"
+	pkg_install() {
+		vmove usr/lib/gimp
+	}
+}
+
+ufraw_package() {
+	depends="${sourcepkg}>=${version}_${revision}"
+	build_style=meta
+	short_desc+=" (transitional dummy package)"
+}
+
+ufraw-gimp_package() {
+	depends="nufraw-gimp>=${version}_${revision}"
+	build_style=meta
+	short_desc+=" - gimp plugin (transitional dummy package)"
+}
diff --git a/srcpkgs/removed-packages/template b/srcpkgs/removed-packages/template
index abedf26f739b6..f3d81a8afe04c 100644
--- a/srcpkgs/removed-packages/template
+++ b/srcpkgs/removed-packages/template
@@ -1,6 +1,6 @@
 # Template file for 'removed-packages'
 pkgname=removed-packages
-version=0.1.20231019
+version=0.1.20231101
 revision=1
 build_style=meta
 short_desc="Uninstalls packages removed from repository"
@@ -590,8 +590,8 @@ replaces="
  python3-Flask-Assets<=0.12_9
  python3-Flask-Mail<=0.9.1_5
  python3-Flask-OAuthlib<=0.9.6_4
- python3-Flask-Script<=2.0.6_7
  python3-Flask-SQLAlchemy<=2.5.1_4
+ python3-Flask-Script<=2.0.6_7
  python3-Flask-User<=1.0.2.2_6
  python3-SPARQLWrapper<=1.8.4_4
  python3-aiohttp-cors2<=0.7.0_3
@@ -642,8 +642,8 @@ replaces="
  raul-devel<=0.8.0_6
  raul<=0.8.0_6
  redkite<=1.3.1_1
- rem<=2.10.0_1
  rem-devel<=2.10.0_1
+ rem<=2.10.0_1
  reminiscence<=0.4.6_1
  rkt-stage1-coreos<=1.30.0_3
  rkt-stage1-fly<=1.30.0_3
@@ -675,6 +675,8 @@ replaces="
  traverso<=0.49.6_2
  ttyload-git<=20141117_4
  tuxc<=1.1_3
+ ufraw-gimp<=0.22_5
+ ufraw<=0.22_5
  unicorn-python<=1.0.2_2
  upwork<=5.6.10.0_1
  urlmatch-git<=20141116_2
diff --git a/srcpkgs/ufraw b/srcpkgs/ufraw
new file mode 120000
index 0000000000000..0bd1459b2a16f
--- /dev/null
+++ b/srcpkgs/ufraw
@@ -0,0 +1 @@
+nufraw
\ No newline at end of file
diff --git a/srcpkgs/ufraw-gimp b/srcpkgs/ufraw-gimp
index 967dc902dd02b..0bd1459b2a16f 120000
--- a/srcpkgs/ufraw-gimp
+++ b/srcpkgs/ufraw-gimp
@@ -1 +1 @@
-ufraw
\ No newline at end of file
+nufraw
\ No newline at end of file
diff --git a/srcpkgs/ufraw/patches/001-no-gimp-remote.patch b/srcpkgs/ufraw/patches/001-no-gimp-remote.patch
deleted file mode 100644
index ca4f4beb6240f..0000000000000
--- a/srcpkgs/ufraw/patches/001-no-gimp-remote.patch
+++ /dev/null
@@ -1,12 +0,0 @@
-Don't use gimp-remote since gimp 2.4 already includes gimp-remote functionality
---- a/ufraw_conf.c
-+++ b/ufraw_conf.c
-@@ -137,7 +137,7 @@
- #elif HAVE_GIMP_2_4
-     "gimp", /* remoteGimpCommand */
- #else
--    "gimp-remote", /* remoteGimpCommand */
-+    "gimp", /* remoteGimpCommand */
- #endif
- 
-     /* EXIF data */
diff --git a/srcpkgs/ufraw/patches/002-fix_abs_int.patch b/srcpkgs/ufraw/patches/002-fix_abs_int.patch
deleted file mode 100644
index 6fc552769c9f8..0000000000000
--- a/srcpkgs/ufraw/patches/002-fix_abs_int.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- a/dcraw.cc	2015-06-16 05:58:38.000000000 +0200
-+++ b/dcraw.cc	2018-02-04 14:46:54.489951076 +0100
-@@ -9242,7 +9242,7 @@
-     if (make[0] == 'O') {
-       i = find_green (12, 32, 1188864, 3576832);
-       c = find_green (12, 32, 2383920, 2387016);
--      if (abs(i) < abs(c)) {
-+      if (abs((int)i) < abs((int)c)) {
- 	SWAP(i,c);
- 	load_flags = 24;
-       }
diff --git a/srcpkgs/ufraw/patches/03_fix-unsigned-char.patch b/srcpkgs/ufraw/patches/03_fix-unsigned-char.patch
deleted file mode 100644
index 8690f87ca7d59..0000000000000
--- a/srcpkgs/ufraw/patches/03_fix-unsigned-char.patch
+++ /dev/null
@@ -1,14 +0,0 @@
-Source: written by John Paul Adrian Glaubitz for Debian
-Upstream: https://sourceforge.net/p/ufraw/bugs/417
-Reason: fixes a compilation failure on arm architectures
---- a/dcraw.cc
-+++ b/dcraw.cc
-@@ -2285,7 +2285,7 @@ void CLASS quicktake_100_load_raw()
- 
- void CLASS kodak_radc_load_raw()
- {
--  static const char src[] = {
-+  static const signed char src[] = {
-     1,1, 2,3, 3,4, 4,2, 5,7, 6,5, 7,6, 7,8,
-     1,0, 2,1, 3,3, 4,4, 5,2, 6,7, 7,6, 8,5, 8,8,
-     2,1, 2,3, 3,0, 3,2, 3,4, 4,6, 5,5, 6,7, 6,8,
diff --git a/srcpkgs/ufraw/patches/exiv-0.27.patch b/srcpkgs/ufraw/patches/exiv-0.27.patch
deleted file mode 100644
index b5b4140fff8ed..0000000000000
--- a/srcpkgs/ufraw/patches/exiv-0.27.patch
+++ /dev/null
@@ -1,25 +0,0 @@
---- a/ufraw_exiv2.cc	2015-06-16 05:58:38.000000000 +0200
-+++ b/ufraw_exiv2.cc	2018-12-29 22:51:23.291894430 +0100
-@@ -15,9 +15,7 @@
- #include "ufraw.h"
- 
- #ifdef HAVE_EXIV2
--#include <exiv2/image.hpp>
--#include <exiv2/easyaccess.hpp>
--#include <exiv2/exif.hpp>
-+#include <exiv2/exiv2.hpp>
- #include <sstream>
- #include <cassert>
- 
-@@ -67,7 +65,11 @@
-         if (exifData.empty()) {
-             std::string error(uf->filename);
-             error += ": No Exif data found in the file";
-+#if EXIV2_TEST_VERSION(0,27,0)
-+            throw Exiv2::Error(Exiv2::kerErrorMessage, error);
-+#else
-             throw Exiv2::Error(1, error);
-+#endif
-         }
- 
-         /* List of tag names taken from exiv2's printSummary() in actions.cpp */
diff --git a/srcpkgs/ufraw/patches/glib-2.68.patch b/srcpkgs/ufraw/patches/glib-2.68.patch
deleted file mode 100644
index 5b61468f118aa..0000000000000
--- a/srcpkgs/ufraw/patches/glib-2.68.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-From c56f8be3caf1cf3d9a5c80597bdbaf1325faacc0 Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?S=C3=A9rgio=20M=2E=20Basto?= <sergio@serjux.com>
-Date: Tue, 13 Apr 2021 23:45:39 +0100
-Subject: [PATCH] Fix build against glib-2.68 fixes #10
-
----
- uf_glib.h | 6 +++---
- 1 file changed, 3 insertions(+), 3 deletions(-)
-
-diff --git a/uf_glib.h b/uf_glib.h
-index 21c10b19..56cd6971 100644
---- a/uf_glib.h
-+++ b/uf_glib.h
-@@ -13,13 +13,13 @@
- #ifndef _UF_GLIB_H
- #define _UF_GLIB_H
- 
-+#include <glib.h>
-+#include <glib/gstdio.h>
-+
- #ifdef __cplusplus
- extern "C" {
- #endif
- 
--#include <glib.h>
--#include <glib/gstdio.h>
--
- // g_win32_locale_filename_from_utf8 is needed only on win32
- #ifdef _WIN32
- #define uf_win32_locale_filename_from_utf8(__some_string__) \
diff --git a/srcpkgs/ufraw/patches/iostream.patch b/srcpkgs/ufraw/patches/iostream.patch
deleted file mode 100644
index 6d15869f63db8..0000000000000
--- a/srcpkgs/ufraw/patches/iostream.patch
+++ /dev/null
@@ -1,13 +0,0 @@
-ufraw_exiv2.cc:343:10: note: 'std::cerr' is defined in header '<iostream>'
-ufraw_exiv2.cc:365:14: error: 'cerr' is not a member of 'std'
-
---- a/ufraw_exiv2.cc
-+++ b/ufraw_exiv2.cc
-@@ -17,6 +17,7 @@
- #ifdef HAVE_EXIV2
- #include <exiv2/exiv2.hpp>
- #include <sstream>
-+#include <iostream>
- #include <cassert>
- 
- /*
diff --git a/srcpkgs/ufraw/template b/srcpkgs/ufraw/template
deleted file mode 100644
index ceddcacacefb2..0000000000000
--- a/srcpkgs/ufraw/template
+++ /dev/null
@@ -1,38 +0,0 @@
-# Template file for 'ufraw'
-pkgname=ufraw
-version=0.22
-revision=5
-build_style=gnu-configure
-configure_args="--enable-contrast --enable-mime --enable-openmp --with-gimp
- $(vopt_enable extras)"
-hostmakedepends="pkg-config dcraw gettext"
-makedepends="exiv2-devel gimp-devel glib-devel gtkimageview-devel lcms2-devel lensfun-devel
- jasper-devel"
-depends="desktop-file-utils"
-short_desc="Utility to read and manipulate raw images from digital cameras"
-maintainer="John <me@johnnynator.dev>"
-license="GPL-2.0-or-later"
-homepage="http://ufraw.sourceforge.net/"
-distfiles="${SOURCEFORGE_SITE}/ufraw/ufraw/ufraw-${version}/ufraw-${version}.tar.gz"
-checksum=f7abd28ce587db2a74b4c54149bd8a2523a7ddc09bedf4f923246ff0ae09a25e
-
-build_options="extras"
-
-post_patch() {
-	vsed -e 's/default(none)//g' \
-		-i dcraw_indi.c \
-		-i dcraw_api.cc \
-		-i ufraw_ufraw.c \
-		-i ufraw_developer.c
-	vsed -i -e '/DATADIRNAME=/s/=.*/=share/' configure
-	vsed -i -e "s,^localedir =.*,localedir = /usr/share/locale," \
-		po/Makefile.in.in
-}
-
-ufraw-gimp_package() {
-	depends="${sourcepkg}>=${version}_${revision}"
-	short_desc+=" - gimp plugin"
-	pkg_install() {
-		vmove usr/lib/gimp
-	}
-}

^ permalink raw reply	[flat|nested] 27+ messages in thread

* Re: [PR PATCH] [Updated] exiv2: update to 0.28.0.
  2023-10-23  0:10 [PR PATCH] exiv2: update to 0.28.0 mhmdanas
                   ` (8 preceding siblings ...)
  2023-11-06 20:17 ` mhmdanas
@ 2023-11-06 20:18 ` mhmdanas
  2023-11-06 20:19 ` mhmdanas
                   ` (15 subsequent siblings)
  25 siblings, 0 replies; 27+ messages in thread
From: mhmdanas @ 2023-11-06 20:18 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 2054 bytes --]

There is an updated pull request by mhmdanas against master on the void-packages repository

https://github.com/mhmdanas/void-packages exiv2-0.28.0
https://github.com/void-linux/void-packages/pull/46838

exiv2: update to 0.28.0.
<!-- Uncomment relevant sections and delete options which are not applicable -->

#### Testing the changes
- I tested the changes in this PR: **briefly**

TODO:
- [x] Fix `gwenview`'s failed checks (not really fixed but the exact same tests fail on master as well)
- [x] `test_exiv2` fails for `libextractor`
- [x] `kfilemetadata5` tests fail (same tests fail on master)
- [ ] Fix `nufraw` cross-build

@Johnnynator ufraw has been [unmaintained since December 2016](https://sourceforge.net/p/ufraw/discussion/434060/thread/30b4249b/), and it doesn't build with this PR; here are the options:
- remove the package entirely
- replace it with the newer [nufraw](https://sourceforge.net/projects/nufraw/), which already has [an exiv 0.28.x patch floating around](https://aur.archlinux.org/cgit/aur.git/tree/exiv2-error.patch?h=nufraw)
- patch it to build with this PR

What do you think? (edit: `nufraw` now replaces `ufraw` in this PR)

<!--
#### New package
- This new package conforms to the [package requirements](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTItest_exiv2NG.md#package-requirements): **YES**|**NO**
-->

<!-- Note: If the build is likely to take more than 2 hours, please add ci skip tag as described in
https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration
and test at least one native build and, if supported, at least one cross build.
Ignore this section if this PR is not skipping CI.
-->
<!--
#### Local build testing
- I built this PR locally for my native architecture, (ARCH-LIBC)
- I built this PR locally for these architectures (if supported. mark crossbuilds):
  - aarch64-musl
  - armv7l
  - armv6l-musl
-->


A patch file from https://github.com/void-linux/void-packages/pull/46838.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-exiv2-0.28.0-46838.patch --]
[-- Type: text/x-diff, Size: 60907 bytes --]

From c287c36c4507d4589e2b8e658c67f286f3e63f96 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Mon, 23 Oct 2023 01:20:09 +0100
Subject: [PATCH 01/22] inih: add `libINIReader.so.0` common/shlibs entry.

---
 common/shlibs | 1 +
 1 file changed, 1 insertion(+)

diff --git a/common/shlibs b/common/shlibs
index 9036a675c1ae5..8f03a38a16789 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -3905,6 +3905,7 @@ libnotcurses++.so.3 notcurses-3.0.5_1
 libnotcurses-ffi.so.3 notcurses-3.0.5_1
 libevemu.so.3 evemu-2.7.0_1
 libinih.so.0 inih-52_1
+libINIReader.so.0 inih-57_1
 libpcaudio.so.0 pcaudiolib-1.1_1
 libdcerpc-samr.so.0 samba-4.13.2_1
 libdcerpc-server-core.so.0 samba-4.13.2_1

From 06a890abedb74bb755f00830e661c649ae7a3464 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:12 +0100
Subject: [PATCH 02/22] exiv2: update to 0.28.0.

---
 common/shlibs          |  2 +-
 srcpkgs/exiv2/template | 18 +++++++++++-------
 2 files changed, 12 insertions(+), 8 deletions(-)

diff --git a/common/shlibs b/common/shlibs
index 8f03a38a16789..0b1d0c89d3e51 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -555,7 +555,7 @@ libgimpcolor-2.0.so.0 libgimp-2.10.0_1
 libgimpmodule-2.0.so.0 libgimp-2.10.0_1
 libgmic.so.3 gmic-3.1.6_1
 libcgmic.so.3 gmic-3.1.6_1
-libexiv2.so.27 exiv2-0.27_1
+libexiv2.so.28 exiv2-0.28.0_1
 libKF5Holidays.so.5 kholidays-5.47.0_1
 libPhabricatorHelpers.so.5 purpose-5.48.0_1
 libKF5PurposeWidgets.so.5 purpose-5.48.0_1
diff --git a/srcpkgs/exiv2/template b/srcpkgs/exiv2/template
index 49985fe82cc14..4517906521b4e 100644
--- a/srcpkgs/exiv2/template
+++ b/srcpkgs/exiv2/template
@@ -1,17 +1,17 @@
 # Template file for 'exiv2'
 pkgname=exiv2
-version=0.27.6
+version=0.28.1
 revision=1
 build_style=cmake
 configure_args="-DEXIV2_BUILD_SAMPLES=OFF -DEXIV2_ENABLE_BMFF=ON"
-makedepends="zlib-devel expat-devel"
-checkdepends="gtest-devel"
+makedepends="zlib-devel brotli-devel expat-devel inih-devel"
+checkdepends="gtest-devel python3"
 short_desc="Image metadata manipulation"
 maintainer="Enno Boland <gottox@voidlinux.org>"
 license="GPL-2.0-or-later"
 homepage="https://www.exiv2.org"
-distfiles="https://github.com/Exiv2/exiv2/releases/download/v${version}/exiv2-${version}-Source.tar.gz"
-checksum=4c192483a1125dc59a3d70b30d30d32edace9e14adf52802d2f853abf72db8a6
+distfiles="https://github.com/Exiv2/exiv2/archive/refs/tags/v${version}.zip"
+checksum=eab4c4b919930905e2128c56cb15919cb8105d431ccef8712f98fd4871f3d09a
 
 if [ -n "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DEXIV2_BUILD_UNIT_TESTS=ON"
@@ -21,14 +21,18 @@ if [ -n "$XBPS_CCACHE" ]; then
 	configure_args+=" -DBUILD_WITH_CCACHE=ON"
 fi
 
+pre_check() {
+	# https://github.com/Exiv2/exiv2/issues/2762
+	rm -f tests/bugfixes/github/test_issue_2427.py
+}
+
 exiv2-devel_package() {
 	depends="${makedepends} ${sourcepkg}-${version}_${revision}"
 	short_desc+=" - development files"
 	pkg_install() {
 		vmove usr/include
-		vmove usr/lib/cmake
 		vmove usr/lib/pkgconfig
-		vmove "usr/lib/*.a"
+		vmove usr/share/cmake
 		vmove "usr/lib/*.so"
 	}
 }

From 2574aad4337ccce013880a910191d6ac4263f2b1 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:37 +0100
Subject: [PATCH 03/22] ART: revbump for exiv2-0.28.0.

---
 srcpkgs/ART/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/ART/template b/srcpkgs/ART/template
index b6c47fc6c4cdf..94c7aa0378061 100644
--- a/srcpkgs/ART/template
+++ b/srcpkgs/ART/template
@@ -1,7 +1,7 @@
 # Template file for 'ART'
 pkgname=ART
 version=1.20.2
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="pkg-config"
 makedepends="fftw-devel gtkmm-devel lensfun-devel

From e656a49ca7874e6b2c9a038bb3c9d6d92f66b805 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 04/22] darktable: revbump for exiv2-0.28.0.

---
 srcpkgs/darktable/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/darktable/template b/srcpkgs/darktable/template
index 60415a34dc018..3d35571239a93 100644
--- a/srcpkgs/darktable/template
+++ b/srcpkgs/darktable/template
@@ -1,7 +1,7 @@
 # Template file for 'darktable'
 pkgname=darktable
 version=4.4.2
-revision=2
+revision=3
 # upstream only supports these archs:
 archs="x86_64* aarch64* ppc64le*"
 build_style=cmake

From c2d7e52bf364c39b07fa240e07e3100f3e7ae180 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 05/22] digikam: revbump for exiv2-0.28.0.

---
 srcpkgs/digikam/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/digikam/template b/srcpkgs/digikam/template
index 206185f565488..4784bf7d62a8e 100644
--- a/srcpkgs/digikam/template
+++ b/srcpkgs/digikam/template
@@ -1,7 +1,7 @@
 # Template file for 'digikam'
 pkgname=digikam
 version=8.1.0
-revision=1
+revision=2
 build_style=cmake
 configure_args="-DBUILD_TESTING=OFF"
 hostmakedepends="extra-cmake-modules gettext pkg-config bison flex qt5-qmake

From 9d5bff3c61d77a12024d5b0005613380785dae77 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 06/22] geeqie: revbump for exiv2-0.28.0.

---
 srcpkgs/geeqie/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/geeqie/template b/srcpkgs/geeqie/template
index b5f958f854c1b..b494bc149e957 100644
--- a/srcpkgs/geeqie/template
+++ b/srcpkgs/geeqie/template
@@ -1,7 +1,7 @@
 # Template file for 'geeqie'
 pkgname=geeqie
 version=2.1
-revision=1
+revision=2
 build_style=meson
 hostmakedepends="pkg-config gettext xxd gdk-pixbuf-devel glib-devel"
 makedepends="gtk+3-devel glib-devel lcms2-devel exiv2-devel libheif-devel

From db6cd54e098cf0025294e72a8bf743db22732101 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 07/22] gthumb: revbump for exiv2-0.28.0.

---
 srcpkgs/gthumb/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/gthumb/template b/srcpkgs/gthumb/template
index c8e19f0dedb61..732d5e1c6089f 100644
--- a/srcpkgs/gthumb/template
+++ b/srcpkgs/gthumb/template
@@ -1,7 +1,7 @@
 # Template file for 'gthumb'
 pkgname=gthumb
 version=3.12.3
-revision=1
+revision=2
 build_style=meson
 hostmakedepends="gettext pkg-config itstool glib-devel"
 makedepends="webkit2gtk-devel json-glib-devel libsecret-devel librsvg-devel

From a852724d381fbcf4629d70a75bccbf49e84e99c2 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 08/22] gwenview: revbump for exiv2-0.28.0.

---
 srcpkgs/gwenview/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/gwenview/template b/srcpkgs/gwenview/template
index 73d450a458c4d..eb876cfadcfe8 100644
--- a/srcpkgs/gwenview/template
+++ b/srcpkgs/gwenview/template
@@ -1,7 +1,7 @@
 # Template file for 'gwenview'
 pkgname=gwenview
 version=23.08.2
-revision=1
+revision=2
 build_style=cmake
 build_helper=qemu
 hostmakedepends="extra-cmake-modules pkg-config qt5-qmake qt5-host-tools

From 722d30ff0af1b1422274563b50d6d0414aec4b3c Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 09/22] hugin: revbump for exiv2-0.28.0.

---
 srcpkgs/hugin/patches/exiv2-0.28.patch | 77 ++++++++++++++++++++++++++
 srcpkgs/hugin/template                 |  2 +-
 2 files changed, 78 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/hugin/patches/exiv2-0.28.patch

diff --git a/srcpkgs/hugin/patches/exiv2-0.28.patch b/srcpkgs/hugin/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..49f0518117020
--- /dev/null
+++ b/srcpkgs/hugin/patches/exiv2-0.28.patch
@@ -0,0 +1,77 @@
+Patch-Source: https://gitlab.archlinux.org/archlinux/packaging/packages/hugin/-/blob/main/exiv2-0.28.patch
+diff -r 79cd11a7a66f src/hugin_base/panodata/Exiv2Helper.cpp
+--- a/src/hugin_base/panodata/Exiv2Helper.cpp	Wed May 24 19:13:20 2023 +0200
++++ b/src/hugin_base/panodata/Exiv2Helper.cpp	Mon Jun 05 00:31:19 2023 +0200
+@@ -40,7 +40,7 @@
+             Exiv2::ExifData::iterator itr = exifData.findKey(Exiv2::ExifKey(keyName));
+             if (itr != exifData.end() && itr->count())
+             {
+-                value = itr->toLong();
++                value = itr->toUint32();
+                 return true;
+             }
+             else
+@@ -165,7 +165,7 @@
+         {
+             if(it!=exifData.end() && it->count())
+             {
+-                return it->toLong();
++                return it->toUint32();
+             }
+             return 0;
+         };
+@@ -600,4 +600,4 @@
+         };
+ 
+     }; //namespace Exiv2Helper
+-}; //namespace HuginBase
+\ No newline at end of file
++}; //namespace HuginBase
+diff -r 79cd11a7a66f src/hugin_base/panodata/SrcPanoImage.cpp
+--- a/src/hugin_base/panodata/SrcPanoImage.cpp	Wed May 24 19:13:20 2023 +0200
++++ b/src/hugin_base/panodata/SrcPanoImage.cpp	Mon Jun 05 00:31:19 2023 +0200
+@@ -384,7 +384,7 @@
+                     pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaImageWidthPixels"));
+                     if (pos != xmpData.end())
+                     {
+-                        croppedWidth = pos->toLong();
++                        croppedWidth = pos->toUint32();
+                     }
+                     else
+                     {
+@@ -394,7 +394,7 @@
+                     pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaImageHeightPixels"));
+                     if (pos != xmpData.end())
+                     {
+-                        croppedHeight = pos->toLong();
++                        croppedHeight = pos->toUint32();
+                     }
+                     else
+                     {
+@@ -408,7 +408,7 @@
+                         double hfov = 0;
+                         if (pos != xmpData.end())
+                         {
+-                            hfov = 360 * croppedWidth / (double)pos->toLong();
++                            hfov = 360 * croppedWidth / (double)pos->toUint32();
+                         }
+                         else
+                         {
+@@ -419,7 +419,7 @@
+                         pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.FullPanoHeightPixels"));
+                         if (pos != xmpData.end())
+                         {
+-                            fullHeight = pos->toLong();
++                            fullHeight = pos->toUint32();
+                         }
+                         else
+                         {
+@@ -430,7 +430,7 @@
+                         pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaTopPixels"));
+                         if (pos != xmpData.end())
+                         {
+-                            cropTop = pos->toLong();
++                            cropTop = pos->toUint32();
+                         }
+                         else
+                         {
diff --git a/srcpkgs/hugin/template b/srcpkgs/hugin/template
index f96d2f6e27d42..ce71f6e4cbb2d 100644
--- a/srcpkgs/hugin/template
+++ b/srcpkgs/hugin/template
@@ -1,7 +1,7 @@
 # Template file for 'hugin'
 pkgname=hugin
 version=2022.0.0
-revision=10
+revision=11
 build_style=cmake
 build_helper=cmake-wxWidgets-gtk3
 pycompile_dirs="usr/share/hugin/data/plugins usr/share/hugin/data/plugins-templates"

From b09d091225cbb038ba79656add101a7f7ee56845 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 10/22] kfilemetadata5: revbump for exiv2-0.28.0.

---
 srcpkgs/kfilemetadata5/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/kfilemetadata5/template b/srcpkgs/kfilemetadata5/template
index 00f7a98cf6399..e294ae5af947c 100644
--- a/srcpkgs/kfilemetadata5/template
+++ b/srcpkgs/kfilemetadata5/template
@@ -1,7 +1,7 @@
 # Template file for 'kfilemetadata5'
 pkgname=kfilemetadata5
 version=5.111.0
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="kcoreaddons extra-cmake-modules pkg-config qt5-host-tools qt5-qmake
  gettext kcoreaddons python3"

From 25752cf46b25c1a4fe59f790d9f7f2929b5c5e9c Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 11/22] krename: revbump for exiv2-0.28.0.

---
 srcpkgs/krename/patches/e7dd767a.patch | 90 ++++++++++++++++++++++++++
 srcpkgs/krename/template               |  2 +-
 2 files changed, 91 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/krename/patches/e7dd767a.patch

diff --git a/srcpkgs/krename/patches/e7dd767a.patch b/srcpkgs/krename/patches/e7dd767a.patch
new file mode 100644
index 0000000000000..a0ef428ce46b1
--- /dev/null
+++ b/srcpkgs/krename/patches/e7dd767a.patch
@@ -0,0 +1,90 @@
+Patch-Source: https://invent.kde.org/utilities/krename/-/commit/e7dd767a
+From e7dd767a9a1068ee1fe1502c4d619b57d3b12add Mon Sep 17 00:00:00 2001
+From: Andreas Sturmlechner <asturm@gentoo.org>
+Date: Fri, 26 May 2023 23:23:10 +0200
+Subject: [PATCH] Fix build with >=exiv2-0.28, raise minimum to 0.27
+
+- enables use of EXIV2_TEST_VERSION macro
+- exiv2 headers cleanup
+
+Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>
+---
+ CMakeLists.txt         |  6 +-----
+ config-krename.h.cmake |  3 ---
+ src/exiv2plugin.cpp    | 17 +++++------------
+ 3 files changed, 6 insertions(+), 20 deletions(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 0bda8ac..72e7297 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -56,13 +56,9 @@ set_package_properties(Taglib PROPERTIES
+     TYPE OPTIONAL)
+ 
+ # Find exiv2
+-find_package(LibExiv2 0.13) # AccessMode was added in 0.13
++find_package(LibExiv2 0.27) # EXIV2_TEST_VERSION was added in 0.27
+ set_package_properties(LibExiv2 PROPERTIES TYPE OPTIONAL)
+ 
+-if (LibExiv2_VERSION VERSION_GREATER_EQUAL "0.27")
+-    set(HAVE_LIBEXIV2_0_27 TRUE)
+-endif()
+-
+ # Find podofo
+ find_package(PoDoFo)
+ set_package_properties(PoDoFo PROPERTIES
+diff --git a/config-krename.h.cmake b/config-krename.h.cmake
+index 76c3d30..862e40b 100644
+--- a/config-krename.h.cmake
++++ b/config-krename.h.cmake
+@@ -6,9 +6,6 @@
+ /* have Exiv2 */
+ #cmakedefine01 HAVE_EXIV2
+ 
+-/* Defined if we have libexiv2 >= 0.27 */
+-#cmakedefine HAVE_LIBEXIV2_0_27
+-
+ /* have PoDoFo */
+ #cmakedefine01 HAVE_PODOFO
+ 
+diff --git a/src/exiv2plugin.cpp b/src/exiv2plugin.cpp
+index 5694d8c..25e8869 100644
+--- a/src/exiv2plugin.cpp
++++ b/src/exiv2plugin.cpp
+@@ -3,20 +3,9 @@
+ 
+ #include "exiv2plugin.h"
+ 
+-#include "../config-krename.h"
+-
+ #include <KLocalizedString>
+ 
+-#include <exiv2/error.hpp>
+-#include <exiv2/exif.hpp>
+-#include <exiv2/image.hpp>
+-#include <exiv2/iptc.hpp>
+-#ifdef HAVE_LIBEXIV2_0_27
+-    #include <exiv2/xmp_exiv2.hpp>
+-#else
+-    #include <exiv2/xmp.hpp>
+-#endif
+-#include <exiv2/tags.hpp>
++#include <exiv2/exiv2.hpp>
+ 
+ #include "batchrenamer.h"
+ #include "tokenhelpdialog.h"
+@@ -381,7 +370,11 @@ QString Exiv2Plugin::processFile(BatchRenamer *b, int index, const QString &file
+     std::string strFilename(asc.constData(), asc.length());
+ 
+     try {
++#if EXIV2_TEST_VERSION(0,28,0)
++        Image::UniquePtr image = Exiv2::ImageFactory::open(strFilename);
++#else
+         Image::AutoPtr image = Exiv2::ImageFactory::open(strFilename);
++#endif
+         if (image.get() != nullptr && image->good()) {
+             image->readMetadata();
+ 
+-- 
+GitLab
+
diff --git a/srcpkgs/krename/template b/srcpkgs/krename/template
index 66023163e3293..df5535007714a 100644
--- a/srcpkgs/krename/template
+++ b/srcpkgs/krename/template
@@ -1,7 +1,7 @@
 # Template file for 'krename'
 pkgname=krename
 version=5.0.2
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="extra-cmake-modules gettext kcoreaddons pkg-config qt5-host-tools qt5-qmake"
 makedepends="exiv2-devel freetype-devel kjs-devel kparts-devel libpodofo-devel

From 2c4216297307d1ae5e8ede1ec8300ebc00e1dd4c Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 12/22] krita: revbump for exiv2-0.28.0.

---
 srcpkgs/krita/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/krita/template b/srcpkgs/krita/template
index 63ee0fbe9bceb..f4d665daf7c31 100644
--- a/srcpkgs/krita/template
+++ b/srcpkgs/krita/template
@@ -1,7 +1,7 @@
 # Template file for 'krita'
 pkgname=krita
 version=5.2.1
-revision=1
+revision=2
 build_style=cmake
 configure_args="-Wno-dev -DBUILD_TESTING=OFF"
 hostmakedepends="extra-cmake-modules gettext pkg-config python3

From 4cd3a85eaef05dad5127a4e0fe33ea7f2c1675e4 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 13/22] libextractor: revbump for exiv2-0.28.0.

---
 srcpkgs/libextractor/patches/exiv2-0.28.patch | 286 ++++++++++++++++++
 srcpkgs/libextractor/patches/fix-tests.diff   |  24 ++
 srcpkgs/libextractor/template                 |   2 +-
 3 files changed, 311 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/libextractor/patches/exiv2-0.28.patch
 create mode 100644 srcpkgs/libextractor/patches/fix-tests.diff

diff --git a/srcpkgs/libextractor/patches/exiv2-0.28.patch b/srcpkgs/libextractor/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..270a626d8ab06
--- /dev/null
+++ b/srcpkgs/libextractor/patches/exiv2-0.28.patch
@@ -0,0 +1,286 @@
+Patch-Source: https://gitlab.archlinux.org/archlinux/packaging/packages/libextractor/-/blob/main/exiv2-0.28.patch
+diff --git a/src/plugins/exiv2_extractor.cc b/src/plugins/exiv2_extractor.cc
+index 78f9bda..d32ed6a 100644
+--- a/src/plugins/exiv2_extractor.cc
++++ b/src/plugins/exiv2_extractor.cc
+@@ -90,7 +90,11 @@ virtual int close ();
+  * @param rcount number of bytes to read
+  * @return buffer with data read, empty buffer (!) on failure (!)
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++virtual Exiv2::DataBuf read (size_t rcount);
++#else
+ virtual Exiv2::DataBuf read (long rcount);
++#endif
+ 
+ /**
+  * Read up to 'rcount' bytes into 'buf'.
+@@ -99,8 +103,17 @@ virtual Exiv2::DataBuf read (long rcount);
+  * @param rcount size of 'buf'
+  * @return number of bytes read successfully, 0 on failure (!)
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++virtual size_t read (Exiv2::byte *buf,
++                   size_t rcount);
++#else
+ virtual long read (Exiv2::byte *buf,
+                    long rcount);
++#endif
++
++#if EXIV2_TEST_VERSION (0,28,0)
++virtual void populateFakeData();
++#endif
+ 
+ /**
+  * Read a single character.
+@@ -117,8 +130,13 @@ virtual int getb ();
+  * @param wcount how many bytes to write
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual size_t write (const Exiv2::byte *data,
++                    size_t wcount);
++#else
+ virtual long write (const Exiv2::byte *data,
+                     long wcount);
++#endif
+ 
+ /**
+  * Write to stream.
+@@ -126,7 +144,11 @@ virtual long write (const Exiv2::byte *data,
+  * @param src stream to copy
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual size_t write (Exiv2::BasicIo &src);
++#else
+ virtual long write (Exiv2::BasicIo &src);
++#endif
+ 
+ /**
+  * Write a single byte.
+@@ -172,7 +194,11 @@ virtual int munmap ();
+  *
+  * @return -1 on error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual size_t tell (void) const;
++#else
+ virtual long int tell (void) const;
++#endif
+ 
+ /**
+  * Return overall size of the file.
+@@ -213,7 +239,11 @@ virtual bool eof () const;
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual const std::string& path () const noexcept;
++#else
+ virtual std::string path () const;
++#endif
+ 
+ #ifdef EXV_UNICODE_PATH
+ /**
+@@ -230,7 +260,11 @@ virtual std::wstring wpath () const;
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual Exiv2::BasicIo::UniquePtr temporary () const;
++#else
+ virtual Exiv2::BasicIo::AutoPtr temporary () const;
++#endif
+ 
+ };
+ 
+@@ -266,7 +300,11 @@ ExtractorIO::close ()
+  * @return buffer with data read, empty buffer (!) on failure (!)
+  */
+ Exiv2::DataBuf
++#if EXIV2_TEST_VERSION (0,28,0)
++ExtractorIO::read (size_t rcount)
++#else
+ ExtractorIO::read (long rcount)
++#endif
+ {
+   void *data;
+   ssize_t ret;
+@@ -284,9 +322,15 @@ ExtractorIO::read (long rcount)
+  * @param rcount size of 'buf'
+  * @return number of bytes read successfully, 0 on failure (!)
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++size_t
++ExtractorIO::read (Exiv2::byte *buf,
++                   size_t rcount)
++#else
+ long
+ ExtractorIO::read (Exiv2::byte *buf,
+                    long rcount)
++#endif
+ {
+   void *data;
+   ssize_t ret;
+@@ -305,6 +349,12 @@ ExtractorIO::read (Exiv2::byte *buf,
+   return got;
+ }
+ 
++#if EXIV2_TEST_VERSION (0,28,0)
++void ExtractorIO::populateFakeData()
++{
++  return;
++}
++#endif
+ 
+ /**
+  * Read a single character.
+@@ -319,7 +369,9 @@ ExtractorIO::getb ()
+   const unsigned char *r;
+ 
+   if (1 != ec->read (ec->cls, &data, 1))
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION(0,28,0)
++    throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+     throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+     throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -336,9 +388,15 @@ ExtractorIO::getb ()
+  * @param wcount how many bytes to write
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++size_t
++ExtractorIO::write (const Exiv2::byte *data,
++                    size_t wcount)
++#else
+ long
+ ExtractorIO::write (const Exiv2::byte *data,
+                     long wcount)
++#endif
+ {
+   return -1;
+ }
+@@ -350,7 +408,11 @@ ExtractorIO::write (const Exiv2::byte *data,
+  * @param src stream to copy
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++size_t
++#else
+ long
++#endif
+ ExtractorIO::write (Exiv2::BasicIo &src)
+ {
+   return -1;
+@@ -378,7 +440,9 @@ ExtractorIO::putb (Exiv2::byte data)
+ void
+ ExtractorIO::transfer (Exiv2::BasicIo& src)
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION(0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -427,7 +491,9 @@ ExtractorIO::seek (long offset,
+ Exiv2::byte *
+ ExtractorIO::mmap (bool isWritable)
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION (0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -452,7 +518,11 @@ ExtractorIO::munmap ()
+  *
+  * @return -1 on error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++size_t
++#else
+ long int
++#endif
+ ExtractorIO::tell (void) const
+ {
+   return (long) ec->seek (ec->cls, 0, SEEK_CUR);
+@@ -516,10 +586,17 @@ ExtractorIO::eof () const
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++const std::string&
++ExtractorIO::path () const noexcept
++#else
+ std::string
+ ExtractorIO::path () const
++#endif
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION (0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -536,7 +613,9 @@ ExtractorIO::path () const
+ std::wstring
+ ExtractorIO::wpath () const
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION (0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -552,11 +631,17 @@ ExtractorIO::wpath () const
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++Exiv2::BasicIo::UniquePtr
++#else
+ Exiv2::BasicIo::AutoPtr
++#endif
+ ExtractorIO::temporary () const
+ {
+   fprintf (stderr, "throwing temporary error\n");
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION(0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -737,8 +822,13 @@ EXTRACTOR_exiv2_extract_method (struct EXTRACTOR_ExtractContext *ec)
+ #if ! EXIV2_TEST_VERSION (0,24,0)
+     Exiv2::LogMsg::setLevel (Exiv2::LogMsg::mute);
+ #endif
++#if EXIV2_TEST_VERSION(0,28,0)
++    std::unique_ptr<Exiv2::BasicIo> eio (new ExtractorIO (ec));
++    Exiv2::Image::UniquePtr image = Exiv2::ImageFactory::open (std::move(eio));
++#else
+     std::auto_ptr<Exiv2::BasicIo> eio (new ExtractorIO (ec));
+     Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open (eio);
++#endif
+     if (0 == image.get ())
+       return;
+     image->readMetadata ();
+@@ -822,7 +912,11 @@ EXTRACTOR_exiv2_extract_method (struct EXTRACTOR_ExtractContext *ec)
+       ADDXMP ("Xmp.lr.hierarchicalSubject", EXTRACTOR_METATYPE_SUBJECT);
+     }
+   }
++#if EXIV2_TEST_VERSION (0,28,0)
++  catch (const Exiv2::Error& e)
++#else
+   catch (const Exiv2::AnyError& e)
++#endif
+   {
+ #if DEBUG
+     std::cerr << "Caught Exiv2 exception '" << e << "'\n";
diff --git a/srcpkgs/libextractor/patches/fix-tests.diff b/srcpkgs/libextractor/patches/fix-tests.diff
new file mode 100644
index 0000000000000..3b4ee7cbeea33
--- /dev/null
+++ b/srcpkgs/libextractor/patches/fix-tests.diff
@@ -0,0 +1,24 @@
+--- a/src/plugins/test_exiv2.c	2021-01-30 13:20:23.000000000 +0000
++++ b/src/plugins/test_exiv2.c	2023-11-03 19:39:43.115274492 +0000
+@@ -49,8 +49,8 @@
+       EXTRACTOR_METATYPE_GPS_LATITUDE,
+       EXTRACTOR_METAFORMAT_UTF8,
+       "text/plain",
+-      "28deg 8' (18|17.585)\" ?",
+-      strlen ("28deg 8' (18|17.585)\" ?") + 1,
++      "28 deg 8' (18|17.58)\" ?",
++      strlen ("28 deg 8' (18|17.58)\" ?") + 1,
+       0,
+       .regex = 1
+     },
+@@ -66,8 +66,8 @@
+       EXTRACTOR_METATYPE_GPS_LONGITUDE,
+       EXTRACTOR_METAFORMAT_UTF8,
+       "text/plain",
+-      "14deg 14' (22|21.713)\" ?",
+-      strlen ("14deg 14' (22|21.713)\" ?"),
++      "14 deg 14' (22|21.71)\" ?",
++      strlen ("14 deg 14' (22|21.71)\" ?"),
+       0,
+       .regex = 1
+     },
diff --git a/srcpkgs/libextractor/template b/srcpkgs/libextractor/template
index ddd4790f93e88..bfcea979a308c 100644
--- a/srcpkgs/libextractor/template
+++ b/srcpkgs/libextractor/template
@@ -1,7 +1,7 @@
 # Template file for 'libextractor'
 pkgname=libextractor
 version=1.11
-revision=2
+revision=3
 build_style=gnu-configure
 configure_args="--disable-static"
 hostmakedepends="pkg-config"

From 3b6d90ee4bc1340cf2e960b3bde16d7dfce72a35 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 14/22] libgexiv2: update to 0.14.2.

---
 srcpkgs/libgexiv2/template | 14 +++++++-------
 1 file changed, 7 insertions(+), 7 deletions(-)

diff --git a/srcpkgs/libgexiv2/template b/srcpkgs/libgexiv2/template
index 23780e5397dc4..91dbcaa9aca52 100644
--- a/srcpkgs/libgexiv2/template
+++ b/srcpkgs/libgexiv2/template
@@ -1,19 +1,19 @@
 # Template file for 'libgexiv2'
 pkgname=libgexiv2
-version=0.14.0
-revision=3
+version=0.14.2
+revision=1
 build_style=meson
 build_helper="gir"
-configure_args="-Dintrospection=$(vopt_if gir true false)
- -Dvapi=$(vopt_if vala true false)"
+configure_args="$(vopt_bool gir introspection) $(vopt_bool vala vapi)"
 hostmakedepends="pkg-config glib-devel $(vopt_if vala 'vala') python3-gobject"
 makedepends="libglib-devel exiv2-devel"
 short_desc="GObject-based wrapper around the Exiv2 library"
 maintainer="Enno Boland <gottox@voidlinux.org>"
 license="GPL-2.0-or-later"
 homepage="https://wiki.gnome.org/Projects/gexiv2"
-distfiles="${GNOME_SITE}/gexiv2/${version%.*}/${pkgname/lib/}-${version}.tar.xz"
-checksum=e58279a6ff20b6f64fa499615da5e9b57cf65ba7850b72fafdf17221a9d6d69e
+changelog="https://gitlab.gnome.org/GNOME/gexiv2/-/raw/master/NEWS"
+distfiles="${GNOME_SITE}/gexiv2/${version%.*}/gexiv2-${version}.tar.xz"
+checksum=2a0c9cf48fbe8b3435008866ffd40b8eddb0667d2212b42396fdf688e93ce0be
 
 build_options="gir vala"
 build_options_default="gir vala"
@@ -23,7 +23,7 @@ libgexiv2-devel_package() {
 	short_desc+=" - development files"
 	pkg_install() {
 		vmove usr/include
-		vmove usr/lib/*.so
+		vmove "usr/lib/*.so"
 		vmove usr/lib/pkgconfig
 		if [ "$build_option_vala" ]; then
 			vmove usr/share/vala

From de998029b9d172f155bc8390fdd6fe8b990f2b99 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 15/22] libkexiv25: update to 23.08.2.

---
 srcpkgs/libkexiv25/template | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/srcpkgs/libkexiv25/template b/srcpkgs/libkexiv25/template
index b439a42ef2b97..4d7f9600572ea 100644
--- a/srcpkgs/libkexiv25/template
+++ b/srcpkgs/libkexiv25/template
@@ -1,6 +1,6 @@
 # Template file for 'libkexiv25'
 pkgname=libkexiv25
-version=23.04.0
+version=23.08.2
 revision=1
 build_style=cmake
 configure_args="-DBUILD_TESTING=OFF"
@@ -11,7 +11,7 @@ maintainer="Orphaned <orphan@voidlinux.org>"
 license="GPL-2.0-or-later"
 homepage="https://invent.kde.org/graphics/libkexiv2"
 distfiles="${KDE_SITE}/release-service/${version}/src/libkexiv2-${version}.tar.xz"
-checksum=18d3eed06df9d1e31d8434ed9887e305aba176d0856e19a8cd3bdb555b80d391
+checksum=d06e36a408bf2e846a18056a1f15e61d981fa2a1fceb81f7c15136604319d033
 
 libkexiv25-devel_package() {
 	short_desc+=" - development files"

From bc2bcc624924aaa841ece4293875eef642d7be5c Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 16/22] nomacs: update to 3.17.2287.

---
 srcpkgs/nomacs/template | 17 +++++++++++++----
 1 file changed, 13 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/nomacs/template b/srcpkgs/nomacs/template
index c52cd54e294db..956bd21ebb129 100644
--- a/srcpkgs/nomacs/template
+++ b/srcpkgs/nomacs/template
@@ -1,7 +1,8 @@
 # Template file for 'nomacs'
 pkgname=nomacs
-version=3.16.224
-revision=5
+version=3.17.2287
+revision=1
+_plugins_ver=3.17.2285
 build_wrksrc=ImageLounge
 build_style=cmake
 configure_args="-DCMAKE_BUILD_TYPE=None -DENABLE_TRANSLATIONS=1
@@ -13,5 +14,13 @@ short_desc="Simple yet powerful Qt imageviewer"
 maintainer="Orphaned <orphan@voidlinux.org>"
 license="GPL-3.0-or-later"
 homepage="https://github.com/nomacs/nomacs"
-distfiles="https://github.com/nomacs/nomacs/archive/${version}.tar.gz"
-checksum=bbc7e9048026ef9e0d2b64902c88050f17a679ef3d3c009de2c3b7de5d1d217c
+distfiles="https://github.com/nomacs/nomacs/archive/${version}.tar.gz
+ https://github.com/novomesk/nomacs-plugins/archive/refs/tags/${_plugins_ver}.tar.gz>plugins.tar.gz"
+checksum="6905ea615358f84a0c83d5b1b7077871dea0526ec667500a1951448cb845a92c
+ 946b2d754be9ecca5cb155f7ecc5dcafb164f6c3dcc7bf5c3c0610d3b47774aa"
+skip_extraction="plugins.tar.gz"
+
+post_extract() {
+ cd ${build_wrksrc}
+ vsrcextract -C plugins "plugins.tar.gz"
+}

From 14ce0831e8fff7ac3c6da91da9e7fa52e1b53d2e Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 17/22] pdf2djvu: revbump for exiv2-0.28.0.

---
 srcpkgs/pdf2djvu/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/pdf2djvu/template b/srcpkgs/pdf2djvu/template
index ef7433c0c98ae..5a6f3ddf4ed35 100644
--- a/srcpkgs/pdf2djvu/template
+++ b/srcpkgs/pdf2djvu/template
@@ -1,7 +1,7 @@
 # Template file for 'pdf2djvu'
 pkgname=pdf2djvu
 version=0.9.19
-revision=4
+revision=5
 build_style=gnu-configure
 hostmakedepends="pkg-config djvulibre gettext"
 makedepends="djvulibre-devel poppler-devel libgraphicsmagick-devel exiv2-devel libuuid-devel"

From 08dc1b1f59ec9cef6c73e3c0743279fdfdbcdfd1 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 18/22] phototonic: revbump for exiv2-0.28.0.

---
 srcpkgs/phototonic/patches/exiv2-0.28.patch | 135 ++++++++++++++++++++
 srcpkgs/phototonic/template                 |   2 +-
 2 files changed, 136 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/phototonic/patches/exiv2-0.28.patch

diff --git a/srcpkgs/phototonic/patches/exiv2-0.28.patch b/srcpkgs/phototonic/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..1c75b628dab33
--- /dev/null
+++ b/srcpkgs/phototonic/patches/exiv2-0.28.patch
@@ -0,0 +1,135 @@
+From 923a3fc14de0b779a45696c5f0aef34c74d84f13 Mon Sep 17 00:00:00 2001
+From: Andreas Sturmlechner <asturm@gentoo.org>
+Date: Sun, 28 May 2023 18:54:10 +0200
+Subject: [PATCH] Fix build with exiv2-0.28
+
+Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>
+---
+ ImageViewer.cpp   | 9 +++++++++
+ MetadataCache.cpp | 8 ++++++++
+ Phototonic.cpp    | 4 ++++
+ Tags.cpp          | 8 ++++++++
+ ThumbsViewer.cpp  | 4 ++++
+ 5 files changed, 33 insertions(+)
+
+diff --git a/ImageViewer.cpp b/ImageViewer.cpp
+index 357d223..df3ac43 100644
+--- a/ImageViewer.cpp
++++ b/ImageViewer.cpp
+@@ -945,7 +945,11 @@ void ImageViewer::keyMoveEvent(int direction) {
+ }
+ 
+ void ImageViewer::saveImage() {
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr image;
++#else
+     Exiv2::Image::AutoPtr image;
++#endif
+     bool exifError = false;
+ 
+     if (newImage) {
+@@ -985,8 +989,13 @@ void ImageViewer::saveImage() {
+ }
+ 
+ void ImageViewer::saveImageAs() {
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++    Exiv2::Image::UniquePtr newExifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
+     Exiv2::Image::AutoPtr newExifImage;
++#endif
+     bool exifError = false;
+ 
+     setCursorHiding(false);
+diff --git a/MetadataCache.cpp b/MetadataCache.cpp
+index 524ae74..5ddd4c8 100644
+--- a/MetadataCache.cpp
++++ b/MetadataCache.cpp
+@@ -64,7 +64,11 @@ void MetadataCache::clear() {
+ }
+ 
+ bool MetadataCache::loadImageMetadata(const QString &imageFullPath) {
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
++#endif
+     QSet<QString> tags;
+     long orientation = 0;
+ 
+@@ -78,7 +82,11 @@ bool MetadataCache::loadImageMetadata(const QString &imageFullPath) {
+     try {
+         Exiv2::ExifData &exifData = exifImage->exifData();
+         if (!exifData.empty()) {
++#if EXIV2_TEST_VERSION(0,28,0)
++            orientation = exifData["Exif.Image.Orientation"].value().toUint32();
++#else
+             orientation = exifData["Exif.Image.Orientation"].value().toLong();
++#endif
+         }
+     } catch (Exiv2::Error &error) {
+         qWarning() << "Failed to read Exif metadata";
+diff --git a/Phototonic.cpp b/Phototonic.cpp
+index 6cc95b3..bd5497d 100644
+--- a/Phototonic.cpp
++++ b/Phototonic.cpp
+@@ -3151,7 +3151,11 @@ void Phototonic::removeMetadata() {
+ 
+     if (ret == MessageBox::Yes) {
+         for (int file = 0; file < fileList.size(); ++file) {
++#if EXIV2_TEST_VERSION(0,28,0)
++            Exiv2::Image::UniquePtr image;
++#else
+             Exiv2::Image::AutoPtr image;
++#endif
+             try {
+                 image = Exiv2::ImageFactory::open(fileList[file].toStdString());
+                 image->clearMetadata();
+diff --git a/Tags.cpp b/Tags.cpp
+index 84eea16..a62da9d 100644
+--- a/Tags.cpp
++++ b/Tags.cpp
+@@ -136,7 +136,11 @@ void ImageTags::addTag(QString tagName, bool tagChecked) {
+ 
+ bool ImageTags::writeTagsToImage(QString &imageFileName, QSet<QString> &newTags) {
+     QSet<QString> imageTags;
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
++#endif
+ 
+     try {
+         exifImage = Exiv2::ImageFactory::open(imageFileName.toStdString());
+@@ -160,7 +164,11 @@ bool ImageTags::writeTagsToImage(QString &imageFileName, QSet<QString> &newTags)
+         QSetIterator<QString> newTagsIt(newTags);
+         while (newTagsIt.hasNext()) {
+             QString tag = newTagsIt.next();
++#if EXIV2_TEST_VERSION(0,28,0)
++            Exiv2::Value::UniquePtr value = Exiv2::Value::create(Exiv2::string);
++#else
+             Exiv2::Value::AutoPtr value = Exiv2::Value::create(Exiv2::string);
++#endif
+             value->read(tag.toStdString());
+             Exiv2::IptcKey key("Iptc.Application2.Keywords");
+             newIptcData.add(key, value.get());
+diff --git a/ThumbsViewer.cpp b/ThumbsViewer.cpp
+index 77a6189..4a11475 100644
+--- a/ThumbsViewer.cpp
++++ b/ThumbsViewer.cpp
+@@ -210,7 +210,11 @@ void ThumbsViewer::updateImageInfoViewer(QString imageFullPath) {
+         infoView->addEntry(key, val);
+     }
+ 
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
++#endif
+     try {
+         exifImage = Exiv2::ImageFactory::open(imageFullPath.toStdString());
+         exifImage->readMetadata();
+-- 
+2.40.1
+
diff --git a/srcpkgs/phototonic/template b/srcpkgs/phototonic/template
index 77ae8bf6a4406..4af006cb7da41 100644
--- a/srcpkgs/phototonic/template
+++ b/srcpkgs/phototonic/template
@@ -1,7 +1,7 @@
 # Template file for 'phototonic'
 pkgname=phototonic
 version=2.1
-revision=3
+revision=4
 build_style=qmake
 hostmakedepends="pkg-config qt5-qmake qt5-host-tools"
 makedepends="qt5-svg-devel exiv2-devel"

From 2919d8d898d812fed7835aae595afb953f3d66b7 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 19/22] qimgv: revbump for exiv2-0.28.0.

---
 srcpkgs/qimgv/patches/exiv2-0.28.patch | 16 ++++++++++++++++
 srcpkgs/qimgv/template                 |  2 +-
 2 files changed, 17 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/qimgv/patches/exiv2-0.28.patch

diff --git a/srcpkgs/qimgv/patches/exiv2-0.28.patch b/srcpkgs/qimgv/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..11f37b5ae2be3
--- /dev/null
+++ b/srcpkgs/qimgv/patches/exiv2-0.28.patch
@@ -0,0 +1,16 @@
+Patch-Source: https://git.alpinelinux.org/aports/tree/community/qimgv/exiv2-0.28.patch
+diff --git a/qimgv/sourcecontainers/documentinfo.cpp b/qimgv/sourcecontainers/documentinfo.cpp
+index 98a68f7..c062474 100644
+--- a/qimgv/sourcecontainers/documentinfo.cpp
++++ b/qimgv/sourcecontainers/documentinfo.cpp
+@@ -271,10 +271,6 @@ void DocumentInfo::loadExifTags() {
+         //std::cout << "Caught Exiv2 exception '" << e.what() << "'\n";
+         return;
+     }
+-    catch (Exiv2::BasicError<CharType> e) {
+-        //std::cout << "Caught BasicError Exiv2 exception '" << e.what() << "'\n";
+-        return;
+-    }
+ #endif
+ }
+ 
diff --git a/srcpkgs/qimgv/template b/srcpkgs/qimgv/template
index 7eb30db33992c..dd341dfe1bfce 100644
--- a/srcpkgs/qimgv/template
+++ b/srcpkgs/qimgv/template
@@ -1,7 +1,7 @@
 # Template file for 'qimgv'
 pkgname=qimgv
 version=1.0.2
-revision=2
+revision=3
 build_style=cmake
 configure_args="$(vopt_if video -DVIDEO_SUPPORT=ON -DVIDEO_SUPPORT=OFF)
  $(vopt_if scale -DOPENCV_SUPPORT=ON -DOPENCV_SUPPORT=OFF)

From 7122d5364e625506748f73e2dc2ea1b4c2cb8acc Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 20/22] SIR: revbump for exiv2-0.28.0.

---
 srcpkgs/SIR/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/SIR/template b/srcpkgs/SIR/template
index 113077acad354..c6da4c26b6c71 100644
--- a/srcpkgs/SIR/template
+++ b/srcpkgs/SIR/template
@@ -1,7 +1,7 @@
 # Template file for 'SIR'
 pkgname=SIR
 version=3.2.2
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="pkg-config"
 makedepends="exiv2-devel qt5-svg-devel qt5-tools-devel"

From b887d8a64a33abf825903b9f730ae35b8b8b26e8 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 21/22] viewnior: revbump for exiv2-0.28.0.

---
 srcpkgs/viewnior/patches/exiv2-0.28.patch | 147 ++++++++++++++++++++++
 srcpkgs/viewnior/template                 |   2 +-
 2 files changed, 148 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/viewnior/patches/exiv2-0.28.patch

diff --git a/srcpkgs/viewnior/patches/exiv2-0.28.patch b/srcpkgs/viewnior/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..71459dee15768
--- /dev/null
+++ b/srcpkgs/viewnior/patches/exiv2-0.28.patch
@@ -0,0 +1,147 @@
+Patch-Source: https://gitlab.archlinux.org/archlinux/packaging/packages/viewnior/-/blob/f206ce6c22a3ec5f1f9ea1bde4077584f80458dd/exiv2-0.28.patch
+--
+From b6bb81a1b46e911d15bbf9a730972523de177705 Mon Sep 17 00:00:00 2001
+From: tastytea <tastytea@tastytea.de>
+Date: Tue, 16 May 2023 10:54:40 +0200
+Subject: [PATCH 1/2] change exiv2 AutoPtr to unique_ptr
+
+exiv2-0.28.0 removed Exiv2::Image::AutoPtr and added
+Exiv2::Image::UniquePtr instead. since it's a typedef for
+std::unique_ptr<Image>, i'm using that directly instead of adding a
+condition on the exiv2 version.
+---
+ src/uni-exiv2.cpp | 21 +++++++++++----------
+ 1 file changed, 11 insertions(+), 10 deletions(-)
+
+diff --git a/src/uni-exiv2.cpp b/src/uni-exiv2.cpp
+index 0d14b9f..77064c2 100644
+--- a/src/uni-exiv2.cpp
++++ b/src/uni-exiv2.cpp
+@@ -22,12 +22,13 @@
+ 
+ #include <exiv2/exiv2.hpp>
+ #include <iostream>
++#include <memory>
+ 
+ #include "uni-exiv2.hpp"
+ 
+ #define ARRAY_SIZE(array) (sizeof array/sizeof(array[0]))
+ 
+-static Exiv2::Image::AutoPtr cached_image;
++static std::unique_ptr<Exiv2::Image> cached_image;
+ 
+ extern "C"
+ void
+@@ -35,8 +36,8 @@ uni_read_exiv2_map(const char *uri, void (*callback)(const char*, const char*, v
+ {
+     Exiv2::LogMsg::setLevel(Exiv2::LogMsg::mute);
+     try {
+-        Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open(uri);
+-        if ( image.get() == 0 ) {
++        std::unique_ptr<Exiv2::Image> image = Exiv2::ImageFactory::open(uri);
++        if (image == nullptr) {
+             return;
+         }
+ 
+@@ -91,14 +92,14 @@ uni_read_exiv2_to_cache(const char *uri)
+ {
+     Exiv2::LogMsg::setLevel(Exiv2::LogMsg::mute);
+ 
+-    if ( cached_image.get() != NULL ) {
++    if (cached_image != nullptr) {
+         cached_image->clearMetadata();
+-        cached_image.reset(NULL);
++        cached_image.reset(nullptr);
+     }
+ 
+     try {
+         cached_image = Exiv2::ImageFactory::open(uri);
+-        if ( cached_image.get() == 0 ) {
++        if (cached_image == nullptr) {
+             return 1;
+         }
+ 
+@@ -116,13 +117,13 @@ uni_write_exiv2_from_cache(const char *uri)
+ {
+     Exiv2::LogMsg::setLevel(Exiv2::LogMsg::mute);
+ 
+-    if ( cached_image.get() == NULL ) {
++    if (cached_image == nullptr) {
+         return 1;
+     }
+ 
+     try {
+-        Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open(uri);
+-        if ( image.get() == 0 ) {
++        std::unique_ptr<Exiv2::Image> image = Exiv2::ImageFactory::open(uri);
++        if (image == nullptr) {
+             return 2;
+         }
+ 
+@@ -130,7 +131,7 @@ uni_write_exiv2_from_cache(const char *uri)
+         image->writeMetadata();
+ 
+         cached_image->clearMetadata();
+-        cached_image.reset(NULL);
++        cached_image.reset(nullptr);
+ 
+         return 0;
+     } catch (Exiv2::AnyError& e) {
+
+From 47d0b98cb46526aa8aa035bebcabc14a11fa57ee Mon Sep 17 00:00:00 2001
+From: tastytea <tastytea@tastytea.de>
+Date: Tue, 16 May 2023 11:17:00 +0200
+Subject: [PATCH 2/2] add support for exiv-0.28.0 errors
+
+exiv2-0.28.0 changed Exiv2::AnyError to Exiv2::Error.
+---
+ src/uni-exiv2.cpp | 15 ++++++++++++---
+ 1 file changed, 12 insertions(+), 3 deletions(-)
+
+diff --git a/src/uni-exiv2.cpp b/src/uni-exiv2.cpp
+index 77064c2..567a50f 100644
+--- a/src/uni-exiv2.cpp
++++ b/src/uni-exiv2.cpp
+@@ -28,6 +28,15 @@
+ 
+ #define ARRAY_SIZE(array) (sizeof array/sizeof(array[0]))
+ 
++#define EXIV_ERROR Exiv2::AnyError
++#ifdef EXIV2_VERSION
++    #ifdef EXIV2_TEST_VERSION
++        #if EXIV2_TEST_VERSION(0,28,0)
++            #define EXIV_ERROR Exiv2::Error
++        #endif
++    #endif
++#endif
++
+ static std::unique_ptr<Exiv2::Image> cached_image;
+ 
+ extern "C"
+@@ -81,7 +90,7 @@ uni_read_exiv2_map(const char *uri, void (*callback)(const char*, const char*, v
+                 }
+             }
+         }
+-    } catch (Exiv2::AnyError& e) {
++    } catch (EXIV_ERROR& e) {
+         std::cerr << "Exiv2: '" << e << "'\n";
+     }
+ }
+@@ -104,7 +113,7 @@ uni_read_exiv2_to_cache(const char *uri)
+         }
+ 
+         cached_image->readMetadata();
+-    } catch (Exiv2::AnyError& e) {
++    } catch (EXIV_ERROR& e) {
+         std::cerr << "Exiv2: '" << e << "'\n";
+     }
+ 
+@@ -134,7 +143,7 @@ uni_write_exiv2_from_cache(const char *uri)
+         cached_image.reset(nullptr);
+ 
+         return 0;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (EXIV_ERROR& e) {
+         std::cerr << "Exiv2: '" << e << "'\n";
+     }
+ 
diff --git a/srcpkgs/viewnior/template b/srcpkgs/viewnior/template
index ea1e528a8651f..4c73226662ca0 100644
--- a/srcpkgs/viewnior/template
+++ b/srcpkgs/viewnior/template
@@ -1,7 +1,7 @@
 # Template file for 'viewnior'
 pkgname=viewnior
 version=1.8
-revision=1
+revision=2
 build_style=meson
 hostmakedepends="pkg-config intltool glib-devel gettext-devel"
 makedepends="gtk+-devel exiv2-devel"

From 98b24eaef09334126a6f40abaa7f46a03c66f46c Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Mon, 23 Oct 2023 19:06:34 +0200
Subject: [PATCH 22/22] New package: nufraw-0.43.3

Co-authored-by: triallax <triallax@tutanota.com>
---
 srcpkgs/nufraw-gimp                           |  1 +
 .../patches/0001-nufraw-glib-2.70.patch       | 20 +++++++
 srcpkgs/nufraw/patches/exiv-0.28.x.diff       | 59 +++++++++++++++++++
 srcpkgs/nufraw/template                       | 49 +++++++++++++++
 srcpkgs/removed-packages/template             |  8 ++-
 srcpkgs/ufraw                                 |  1 +
 srcpkgs/ufraw-gimp                            |  2 +-
 .../ufraw/patches/001-no-gimp-remote.patch    | 12 ----
 srcpkgs/ufraw/patches/002-fix_abs_int.patch   | 11 ----
 .../ufraw/patches/03_fix-unsigned-char.patch  | 14 -----
 srcpkgs/ufraw/patches/exiv-0.27.patch         | 25 --------
 srcpkgs/ufraw/patches/glib-2.68.patch         | 30 ----------
 srcpkgs/ufraw/patches/iostream.patch          | 13 ----
 srcpkgs/ufraw/template                        | 38 ------------
 14 files changed, 136 insertions(+), 147 deletions(-)
 create mode 120000 srcpkgs/nufraw-gimp
 create mode 100644 srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch
 create mode 100644 srcpkgs/nufraw/patches/exiv-0.28.x.diff
 create mode 100644 srcpkgs/nufraw/template
 create mode 120000 srcpkgs/ufraw
 delete mode 100644 srcpkgs/ufraw/patches/001-no-gimp-remote.patch
 delete mode 100644 srcpkgs/ufraw/patches/002-fix_abs_int.patch
 delete mode 100644 srcpkgs/ufraw/patches/03_fix-unsigned-char.patch
 delete mode 100644 srcpkgs/ufraw/patches/exiv-0.27.patch
 delete mode 100644 srcpkgs/ufraw/patches/glib-2.68.patch
 delete mode 100644 srcpkgs/ufraw/patches/iostream.patch
 delete mode 100644 srcpkgs/ufraw/template

diff --git a/srcpkgs/nufraw-gimp b/srcpkgs/nufraw-gimp
new file mode 120000
index 0000000000000..0bd1459b2a16f
--- /dev/null
+++ b/srcpkgs/nufraw-gimp
@@ -0,0 +1 @@
+nufraw
\ No newline at end of file
diff --git a/srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch b/srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch
new file mode 100644
index 0000000000000..41f10bfbafa1f
--- /dev/null
+++ b/srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch
@@ -0,0 +1,20 @@
+diff -ru nufraw/uf_glib.h nufraw/uf_glib.h
+--- nufraw/uf_glib.h	2022-02-23 09:03:44.700472919 +0100
++++ nufraw/uf_glib.h	2022-02-23 09:04:50.260308805 +0100
+@@ -13,13 +13,13 @@
+ #ifndef _UF_GLIB_H
+ #define _UF_GLIB_H
+ 
++#include <glib.h>
++#include <glib/gstdio.h>
++
+ #ifdef __cplusplus
+ extern "C" {
+ #endif
+ 
+-#include <glib.h>
+-#include <glib/gstdio.h>
+-
+ // g_win32_locale_filename_from_utf8 is needed only on win32
+ #ifdef _WIN32
+ #define uf_win32_locale_filename_from_utf8(__some_string__) \
diff --git a/srcpkgs/nufraw/patches/exiv-0.28.x.diff b/srcpkgs/nufraw/patches/exiv-0.28.x.diff
new file mode 100644
index 0000000000000..6c23359bf706c
--- /dev/null
+++ b/srcpkgs/nufraw/patches/exiv-0.28.x.diff
@@ -0,0 +1,59 @@
+Patch taken from AUR package: https://aur.archlinux.org/cgit/aur.git/tree/exiv2-error.patch?h=nufraw&id=29e467f2c297fcd0f36548642d6d2cab6428d08f
+diff --git a/nufraw_exiv2.cc b/nufraw_exiv2.cc
+index 2de4cc3..45aea87 100644
+--- a/nufraw_exiv2.cc
++++ b/nufraw_exiv2.cc
+@@ -54,7 +54,7 @@ extern "C" int nufraw_exif_read_input(nufraw_data *uf)
+         uf->inputExifBuf = NULL;
+         uf->inputExifBufLen = 0;
+ 
+-        Exiv2::Image::AutoPtr image;
++        Exiv2::Image::UniquePtr image;
+         if (uf->unzippedBuf != NULL) {
+             image = Exiv2::ImageFactory::open(
+                         (const Exiv2::byte*)uf->unzippedBuf, uf->unzippedBufLen);
+@@ -135,7 +135,7 @@ extern "C" int nufraw_exif_read_input(nufraw_data *uf)
+         nufraw_message(NUFRAW_SET_LOG, "%s\n", stderror.str().c_str());
+ 
+         return NUFRAW_SUCCESS;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (Exiv2::Error& e) {
+         std::cerr.rdbuf(savecerr);
+         std::string s(e.what());
+         nufraw_message(NUFRAW_SET_WARNING, "%s\n", s.c_str());
+@@ -156,7 +156,7 @@ static Exiv2::ExifData nufraw_prepare_exifdata(nufraw_data *uf)
+         if ((pos = exifData.findKey(Exiv2::ExifKey("Exif.Image.Orientation")))
+                 != exifData.end()) {
+             nufraw_message(NUFRAW_SET_LOG, "Resetting %s from '%d' to '1'\n",
+-                          pos->key().c_str(), pos->value().toLong());
++                          pos->key().c_str(), pos->value().toInt64());
+             pos->setValue("1"); /* 1 = Normal orientation */
+         }
+     }
+@@ -327,7 +327,7 @@ extern "C" int nufraw_exif_prepare_output(nufraw_data *uf)
+         nufraw_message(NUFRAW_SET_LOG, "%s\n", stderror.str().c_str());
+ 
+         return NUFRAW_SUCCESS;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (Exiv2::Error& e) {
+         std::cerr.rdbuf(savecerr);
+         std::string s(e.what());
+         nufraw_message(NUFRAW_SET_WARNING, "%s\n", s.c_str());
+@@ -347,7 +347,7 @@ extern "C" int nufraw_exif_write(nufraw_data *uf)
+ 
+         char *filename =
+             uf_win32_locale_filename_from_utf8(uf->conf->outputFilename);
+-        Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open(filename);
++        Exiv2::Image::UniquePtr image = Exiv2::ImageFactory::open(filename);
+         uf_win32_locale_filename_free(filename);
+         assert(image.get() != 0);
+ 
+@@ -367,7 +367,7 @@ extern "C" int nufraw_exif_write(nufraw_data *uf)
+         nufraw_message(NUFRAW_SET_LOG, "%s\n", stderror.str().c_str());
+ 
+         return NUFRAW_SUCCESS;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (Exiv2::Error& e) {
+         std::cerr.rdbuf(savecerr);
+         std::string s(e.what());
+         nufraw_message(NUFRAW_SET_WARNING, "%s\n", s.c_str());
diff --git a/srcpkgs/nufraw/template b/srcpkgs/nufraw/template
new file mode 100644
index 0000000000000..b65964cce61d0
--- /dev/null
+++ b/srcpkgs/nufraw/template
@@ -0,0 +1,49 @@
+# Template file for 'nufraw'
+pkgname=nufraw
+version=0.43.3
+revision=1
+_ver="${version%.*}-${version##*.}"
+build_style=gnu-configure
+configure_args="--enable-contrast --enable-mime --enable-openmp --with-gimp
+ --enable-extras"
+hostmakedepends="pkg-config automake libtool glib-devel"
+# libgexiv2-devel is only here to fix build order, remove on next template
+# change
+makedepends="exiv2-devel gimp-devel gilb-devel gtkimageview-devel lcms2-devel
+ lensfun-devel jasper-devel libgexiv2-devel"
+depends="desktop-file-utils"
+short_desc="Utility to read and manipulate raw images from digital cameras"
+maintainer="John <me@johnnynator.dev>"
+license="GPL-2.0-or-later"
+homepage="https://sourceforge.net/projects/nufraw/"
+distfiles="${SOURCEFORGE_SITE}/nufraw/nufraw-${_ver}.tar.gz"
+checksum=2c7dcc1590993ec267b3112562b2433010d6f94f6acc6506c76aa29cf8c6c32c
+
+pre_configure() {
+	autoreconf -fi
+}
+
+pre_build() {
+	mv nufraw.desktop{.desktop,}
+	chmod +x generate_schemas.sh
+}
+
+nufraw-gimp_package() {
+	depends="${sourcepkg}>=${version}_${revision}"
+	short_desc+=" - gimp plugin"
+	pkg_install() {
+		vmove usr/lib/gimp
+	}
+}
+
+ufraw_package() {
+	depends="${sourcepkg}>=${version}_${revision}"
+	build_style=meta
+	short_desc+=" (transitional dummy package)"
+}
+
+ufraw-gimp_package() {
+	depends="nufraw-gimp>=${version}_${revision}"
+	build_style=meta
+	short_desc+=" - gimp plugin (transitional dummy package)"
+}
diff --git a/srcpkgs/removed-packages/template b/srcpkgs/removed-packages/template
index abedf26f739b6..f3d81a8afe04c 100644
--- a/srcpkgs/removed-packages/template
+++ b/srcpkgs/removed-packages/template
@@ -1,6 +1,6 @@
 # Template file for 'removed-packages'
 pkgname=removed-packages
-version=0.1.20231019
+version=0.1.20231101
 revision=1
 build_style=meta
 short_desc="Uninstalls packages removed from repository"
@@ -590,8 +590,8 @@ replaces="
  python3-Flask-Assets<=0.12_9
  python3-Flask-Mail<=0.9.1_5
  python3-Flask-OAuthlib<=0.9.6_4
- python3-Flask-Script<=2.0.6_7
  python3-Flask-SQLAlchemy<=2.5.1_4
+ python3-Flask-Script<=2.0.6_7
  python3-Flask-User<=1.0.2.2_6
  python3-SPARQLWrapper<=1.8.4_4
  python3-aiohttp-cors2<=0.7.0_3
@@ -642,8 +642,8 @@ replaces="
  raul-devel<=0.8.0_6
  raul<=0.8.0_6
  redkite<=1.3.1_1
- rem<=2.10.0_1
  rem-devel<=2.10.0_1
+ rem<=2.10.0_1
  reminiscence<=0.4.6_1
  rkt-stage1-coreos<=1.30.0_3
  rkt-stage1-fly<=1.30.0_3
@@ -675,6 +675,8 @@ replaces="
  traverso<=0.49.6_2
  ttyload-git<=20141117_4
  tuxc<=1.1_3
+ ufraw-gimp<=0.22_5
+ ufraw<=0.22_5
  unicorn-python<=1.0.2_2
  upwork<=5.6.10.0_1
  urlmatch-git<=20141116_2
diff --git a/srcpkgs/ufraw b/srcpkgs/ufraw
new file mode 120000
index 0000000000000..0bd1459b2a16f
--- /dev/null
+++ b/srcpkgs/ufraw
@@ -0,0 +1 @@
+nufraw
\ No newline at end of file
diff --git a/srcpkgs/ufraw-gimp b/srcpkgs/ufraw-gimp
index 967dc902dd02b..0bd1459b2a16f 120000
--- a/srcpkgs/ufraw-gimp
+++ b/srcpkgs/ufraw-gimp
@@ -1 +1 @@
-ufraw
\ No newline at end of file
+nufraw
\ No newline at end of file
diff --git a/srcpkgs/ufraw/patches/001-no-gimp-remote.patch b/srcpkgs/ufraw/patches/001-no-gimp-remote.patch
deleted file mode 100644
index ca4f4beb6240f..0000000000000
--- a/srcpkgs/ufraw/patches/001-no-gimp-remote.patch
+++ /dev/null
@@ -1,12 +0,0 @@
-Don't use gimp-remote since gimp 2.4 already includes gimp-remote functionality
---- a/ufraw_conf.c
-+++ b/ufraw_conf.c
-@@ -137,7 +137,7 @@
- #elif HAVE_GIMP_2_4
-     "gimp", /* remoteGimpCommand */
- #else
--    "gimp-remote", /* remoteGimpCommand */
-+    "gimp", /* remoteGimpCommand */
- #endif
- 
-     /* EXIF data */
diff --git a/srcpkgs/ufraw/patches/002-fix_abs_int.patch b/srcpkgs/ufraw/patches/002-fix_abs_int.patch
deleted file mode 100644
index 6fc552769c9f8..0000000000000
--- a/srcpkgs/ufraw/patches/002-fix_abs_int.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- a/dcraw.cc	2015-06-16 05:58:38.000000000 +0200
-+++ b/dcraw.cc	2018-02-04 14:46:54.489951076 +0100
-@@ -9242,7 +9242,7 @@
-     if (make[0] == 'O') {
-       i = find_green (12, 32, 1188864, 3576832);
-       c = find_green (12, 32, 2383920, 2387016);
--      if (abs(i) < abs(c)) {
-+      if (abs((int)i) < abs((int)c)) {
- 	SWAP(i,c);
- 	load_flags = 24;
-       }
diff --git a/srcpkgs/ufraw/patches/03_fix-unsigned-char.patch b/srcpkgs/ufraw/patches/03_fix-unsigned-char.patch
deleted file mode 100644
index 8690f87ca7d59..0000000000000
--- a/srcpkgs/ufraw/patches/03_fix-unsigned-char.patch
+++ /dev/null
@@ -1,14 +0,0 @@
-Source: written by John Paul Adrian Glaubitz for Debian
-Upstream: https://sourceforge.net/p/ufraw/bugs/417
-Reason: fixes a compilation failure on arm architectures
---- a/dcraw.cc
-+++ b/dcraw.cc
-@@ -2285,7 +2285,7 @@ void CLASS quicktake_100_load_raw()
- 
- void CLASS kodak_radc_load_raw()
- {
--  static const char src[] = {
-+  static const signed char src[] = {
-     1,1, 2,3, 3,4, 4,2, 5,7, 6,5, 7,6, 7,8,
-     1,0, 2,1, 3,3, 4,4, 5,2, 6,7, 7,6, 8,5, 8,8,
-     2,1, 2,3, 3,0, 3,2, 3,4, 4,6, 5,5, 6,7, 6,8,
diff --git a/srcpkgs/ufraw/patches/exiv-0.27.patch b/srcpkgs/ufraw/patches/exiv-0.27.patch
deleted file mode 100644
index b5b4140fff8ed..0000000000000
--- a/srcpkgs/ufraw/patches/exiv-0.27.patch
+++ /dev/null
@@ -1,25 +0,0 @@
---- a/ufraw_exiv2.cc	2015-06-16 05:58:38.000000000 +0200
-+++ b/ufraw_exiv2.cc	2018-12-29 22:51:23.291894430 +0100
-@@ -15,9 +15,7 @@
- #include "ufraw.h"
- 
- #ifdef HAVE_EXIV2
--#include <exiv2/image.hpp>
--#include <exiv2/easyaccess.hpp>
--#include <exiv2/exif.hpp>
-+#include <exiv2/exiv2.hpp>
- #include <sstream>
- #include <cassert>
- 
-@@ -67,7 +65,11 @@
-         if (exifData.empty()) {
-             std::string error(uf->filename);
-             error += ": No Exif data found in the file";
-+#if EXIV2_TEST_VERSION(0,27,0)
-+            throw Exiv2::Error(Exiv2::kerErrorMessage, error);
-+#else
-             throw Exiv2::Error(1, error);
-+#endif
-         }
- 
-         /* List of tag names taken from exiv2's printSummary() in actions.cpp */
diff --git a/srcpkgs/ufraw/patches/glib-2.68.patch b/srcpkgs/ufraw/patches/glib-2.68.patch
deleted file mode 100644
index 5b61468f118aa..0000000000000
--- a/srcpkgs/ufraw/patches/glib-2.68.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-From c56f8be3caf1cf3d9a5c80597bdbaf1325faacc0 Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?S=C3=A9rgio=20M=2E=20Basto?= <sergio@serjux.com>
-Date: Tue, 13 Apr 2021 23:45:39 +0100
-Subject: [PATCH] Fix build against glib-2.68 fixes #10
-
----
- uf_glib.h | 6 +++---
- 1 file changed, 3 insertions(+), 3 deletions(-)
-
-diff --git a/uf_glib.h b/uf_glib.h
-index 21c10b19..56cd6971 100644
---- a/uf_glib.h
-+++ b/uf_glib.h
-@@ -13,13 +13,13 @@
- #ifndef _UF_GLIB_H
- #define _UF_GLIB_H
- 
-+#include <glib.h>
-+#include <glib/gstdio.h>
-+
- #ifdef __cplusplus
- extern "C" {
- #endif
- 
--#include <glib.h>
--#include <glib/gstdio.h>
--
- // g_win32_locale_filename_from_utf8 is needed only on win32
- #ifdef _WIN32
- #define uf_win32_locale_filename_from_utf8(__some_string__) \
diff --git a/srcpkgs/ufraw/patches/iostream.patch b/srcpkgs/ufraw/patches/iostream.patch
deleted file mode 100644
index 6d15869f63db8..0000000000000
--- a/srcpkgs/ufraw/patches/iostream.patch
+++ /dev/null
@@ -1,13 +0,0 @@
-ufraw_exiv2.cc:343:10: note: 'std::cerr' is defined in header '<iostream>'
-ufraw_exiv2.cc:365:14: error: 'cerr' is not a member of 'std'
-
---- a/ufraw_exiv2.cc
-+++ b/ufraw_exiv2.cc
-@@ -17,6 +17,7 @@
- #ifdef HAVE_EXIV2
- #include <exiv2/exiv2.hpp>
- #include <sstream>
-+#include <iostream>
- #include <cassert>
- 
- /*
diff --git a/srcpkgs/ufraw/template b/srcpkgs/ufraw/template
deleted file mode 100644
index ceddcacacefb2..0000000000000
--- a/srcpkgs/ufraw/template
+++ /dev/null
@@ -1,38 +0,0 @@
-# Template file for 'ufraw'
-pkgname=ufraw
-version=0.22
-revision=5
-build_style=gnu-configure
-configure_args="--enable-contrast --enable-mime --enable-openmp --with-gimp
- $(vopt_enable extras)"
-hostmakedepends="pkg-config dcraw gettext"
-makedepends="exiv2-devel gimp-devel glib-devel gtkimageview-devel lcms2-devel lensfun-devel
- jasper-devel"
-depends="desktop-file-utils"
-short_desc="Utility to read and manipulate raw images from digital cameras"
-maintainer="John <me@johnnynator.dev>"
-license="GPL-2.0-or-later"
-homepage="http://ufraw.sourceforge.net/"
-distfiles="${SOURCEFORGE_SITE}/ufraw/ufraw/ufraw-${version}/ufraw-${version}.tar.gz"
-checksum=f7abd28ce587db2a74b4c54149bd8a2523a7ddc09bedf4f923246ff0ae09a25e
-
-build_options="extras"
-
-post_patch() {
-	vsed -e 's/default(none)//g' \
-		-i dcraw_indi.c \
-		-i dcraw_api.cc \
-		-i ufraw_ufraw.c \
-		-i ufraw_developer.c
-	vsed -i -e '/DATADIRNAME=/s/=.*/=share/' configure
-	vsed -i -e "s,^localedir =.*,localedir = /usr/share/locale," \
-		po/Makefile.in.in
-}
-
-ufraw-gimp_package() {
-	depends="${sourcepkg}>=${version}_${revision}"
-	short_desc+=" - gimp plugin"
-	pkg_install() {
-		vmove usr/lib/gimp
-	}
-}

^ permalink raw reply	[flat|nested] 27+ messages in thread

* Re: [PR PATCH] [Updated] exiv2: update to 0.28.0.
  2023-10-23  0:10 [PR PATCH] exiv2: update to 0.28.0 mhmdanas
                   ` (9 preceding siblings ...)
  2023-11-06 20:18 ` mhmdanas
@ 2023-11-06 20:19 ` mhmdanas
  2023-11-06 20:20 ` mhmdanas
                   ` (14 subsequent siblings)
  25 siblings, 0 replies; 27+ messages in thread
From: mhmdanas @ 2023-11-06 20:19 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 2054 bytes --]

There is an updated pull request by mhmdanas against master on the void-packages repository

https://github.com/mhmdanas/void-packages exiv2-0.28.0
https://github.com/void-linux/void-packages/pull/46838

exiv2: update to 0.28.0.
<!-- Uncomment relevant sections and delete options which are not applicable -->

#### Testing the changes
- I tested the changes in this PR: **briefly**

TODO:
- [x] Fix `gwenview`'s failed checks (not really fixed but the exact same tests fail on master as well)
- [x] `test_exiv2` fails for `libextractor`
- [x] `kfilemetadata5` tests fail (same tests fail on master)
- [ ] Fix `nufraw` cross-build

@Johnnynator ufraw has been [unmaintained since December 2016](https://sourceforge.net/p/ufraw/discussion/434060/thread/30b4249b/), and it doesn't build with this PR; here are the options:
- remove the package entirely
- replace it with the newer [nufraw](https://sourceforge.net/projects/nufraw/), which already has [an exiv 0.28.x patch floating around](https://aur.archlinux.org/cgit/aur.git/tree/exiv2-error.patch?h=nufraw)
- patch it to build with this PR

What do you think? (edit: `nufraw` now replaces `ufraw` in this PR)

<!--
#### New package
- This new package conforms to the [package requirements](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTItest_exiv2NG.md#package-requirements): **YES**|**NO**
-->

<!-- Note: If the build is likely to take more than 2 hours, please add ci skip tag as described in
https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration
and test at least one native build and, if supported, at least one cross build.
Ignore this section if this PR is not skipping CI.
-->
<!--
#### Local build testing
- I built this PR locally for my native architecture, (ARCH-LIBC)
- I built this PR locally for these architectures (if supported. mark crossbuilds):
  - aarch64-musl
  - armv7l
  - armv6l-musl
-->


A patch file from https://github.com/void-linux/void-packages/pull/46838.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-exiv2-0.28.0-46838.patch --]
[-- Type: text/x-diff, Size: 60907 bytes --]

From c287c36c4507d4589e2b8e658c67f286f3e63f96 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Mon, 23 Oct 2023 01:20:09 +0100
Subject: [PATCH 01/22] inih: add `libINIReader.so.0` common/shlibs entry.

---
 common/shlibs | 1 +
 1 file changed, 1 insertion(+)

diff --git a/common/shlibs b/common/shlibs
index 9036a675c1ae5..8f03a38a16789 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -3905,6 +3905,7 @@ libnotcurses++.so.3 notcurses-3.0.5_1
 libnotcurses-ffi.so.3 notcurses-3.0.5_1
 libevemu.so.3 evemu-2.7.0_1
 libinih.so.0 inih-52_1
+libINIReader.so.0 inih-57_1
 libpcaudio.so.0 pcaudiolib-1.1_1
 libdcerpc-samr.so.0 samba-4.13.2_1
 libdcerpc-server-core.so.0 samba-4.13.2_1

From 06a890abedb74bb755f00830e661c649ae7a3464 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:12 +0100
Subject: [PATCH 02/22] exiv2: update to 0.28.0.

---
 common/shlibs          |  2 +-
 srcpkgs/exiv2/template | 18 +++++++++++-------
 2 files changed, 12 insertions(+), 8 deletions(-)

diff --git a/common/shlibs b/common/shlibs
index 8f03a38a16789..0b1d0c89d3e51 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -555,7 +555,7 @@ libgimpcolor-2.0.so.0 libgimp-2.10.0_1
 libgimpmodule-2.0.so.0 libgimp-2.10.0_1
 libgmic.so.3 gmic-3.1.6_1
 libcgmic.so.3 gmic-3.1.6_1
-libexiv2.so.27 exiv2-0.27_1
+libexiv2.so.28 exiv2-0.28.0_1
 libKF5Holidays.so.5 kholidays-5.47.0_1
 libPhabricatorHelpers.so.5 purpose-5.48.0_1
 libKF5PurposeWidgets.so.5 purpose-5.48.0_1
diff --git a/srcpkgs/exiv2/template b/srcpkgs/exiv2/template
index 49985fe82cc14..4517906521b4e 100644
--- a/srcpkgs/exiv2/template
+++ b/srcpkgs/exiv2/template
@@ -1,17 +1,17 @@
 # Template file for 'exiv2'
 pkgname=exiv2
-version=0.27.6
+version=0.28.1
 revision=1
 build_style=cmake
 configure_args="-DEXIV2_BUILD_SAMPLES=OFF -DEXIV2_ENABLE_BMFF=ON"
-makedepends="zlib-devel expat-devel"
-checkdepends="gtest-devel"
+makedepends="zlib-devel brotli-devel expat-devel inih-devel"
+checkdepends="gtest-devel python3"
 short_desc="Image metadata manipulation"
 maintainer="Enno Boland <gottox@voidlinux.org>"
 license="GPL-2.0-or-later"
 homepage="https://www.exiv2.org"
-distfiles="https://github.com/Exiv2/exiv2/releases/download/v${version}/exiv2-${version}-Source.tar.gz"
-checksum=4c192483a1125dc59a3d70b30d30d32edace9e14adf52802d2f853abf72db8a6
+distfiles="https://github.com/Exiv2/exiv2/archive/refs/tags/v${version}.zip"
+checksum=eab4c4b919930905e2128c56cb15919cb8105d431ccef8712f98fd4871f3d09a
 
 if [ -n "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DEXIV2_BUILD_UNIT_TESTS=ON"
@@ -21,14 +21,18 @@ if [ -n "$XBPS_CCACHE" ]; then
 	configure_args+=" -DBUILD_WITH_CCACHE=ON"
 fi
 
+pre_check() {
+	# https://github.com/Exiv2/exiv2/issues/2762
+	rm -f tests/bugfixes/github/test_issue_2427.py
+}
+
 exiv2-devel_package() {
 	depends="${makedepends} ${sourcepkg}-${version}_${revision}"
 	short_desc+=" - development files"
 	pkg_install() {
 		vmove usr/include
-		vmove usr/lib/cmake
 		vmove usr/lib/pkgconfig
-		vmove "usr/lib/*.a"
+		vmove usr/share/cmake
 		vmove "usr/lib/*.so"
 	}
 }

From 2574aad4337ccce013880a910191d6ac4263f2b1 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:37 +0100
Subject: [PATCH 03/22] ART: revbump for exiv2-0.28.0.

---
 srcpkgs/ART/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/ART/template b/srcpkgs/ART/template
index b6c47fc6c4cdf..94c7aa0378061 100644
--- a/srcpkgs/ART/template
+++ b/srcpkgs/ART/template
@@ -1,7 +1,7 @@
 # Template file for 'ART'
 pkgname=ART
 version=1.20.2
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="pkg-config"
 makedepends="fftw-devel gtkmm-devel lensfun-devel

From e656a49ca7874e6b2c9a038bb3c9d6d92f66b805 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 04/22] darktable: revbump for exiv2-0.28.0.

---
 srcpkgs/darktable/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/darktable/template b/srcpkgs/darktable/template
index 60415a34dc018..3d35571239a93 100644
--- a/srcpkgs/darktable/template
+++ b/srcpkgs/darktable/template
@@ -1,7 +1,7 @@
 # Template file for 'darktable'
 pkgname=darktable
 version=4.4.2
-revision=2
+revision=3
 # upstream only supports these archs:
 archs="x86_64* aarch64* ppc64le*"
 build_style=cmake

From c2d7e52bf364c39b07fa240e07e3100f3e7ae180 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 05/22] digikam: revbump for exiv2-0.28.0.

---
 srcpkgs/digikam/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/digikam/template b/srcpkgs/digikam/template
index 206185f565488..4784bf7d62a8e 100644
--- a/srcpkgs/digikam/template
+++ b/srcpkgs/digikam/template
@@ -1,7 +1,7 @@
 # Template file for 'digikam'
 pkgname=digikam
 version=8.1.0
-revision=1
+revision=2
 build_style=cmake
 configure_args="-DBUILD_TESTING=OFF"
 hostmakedepends="extra-cmake-modules gettext pkg-config bison flex qt5-qmake

From 9d5bff3c61d77a12024d5b0005613380785dae77 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 06/22] geeqie: revbump for exiv2-0.28.0.

---
 srcpkgs/geeqie/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/geeqie/template b/srcpkgs/geeqie/template
index b5f958f854c1b..b494bc149e957 100644
--- a/srcpkgs/geeqie/template
+++ b/srcpkgs/geeqie/template
@@ -1,7 +1,7 @@
 # Template file for 'geeqie'
 pkgname=geeqie
 version=2.1
-revision=1
+revision=2
 build_style=meson
 hostmakedepends="pkg-config gettext xxd gdk-pixbuf-devel glib-devel"
 makedepends="gtk+3-devel glib-devel lcms2-devel exiv2-devel libheif-devel

From db6cd54e098cf0025294e72a8bf743db22732101 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 07/22] gthumb: revbump for exiv2-0.28.0.

---
 srcpkgs/gthumb/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/gthumb/template b/srcpkgs/gthumb/template
index c8e19f0dedb61..732d5e1c6089f 100644
--- a/srcpkgs/gthumb/template
+++ b/srcpkgs/gthumb/template
@@ -1,7 +1,7 @@
 # Template file for 'gthumb'
 pkgname=gthumb
 version=3.12.3
-revision=1
+revision=2
 build_style=meson
 hostmakedepends="gettext pkg-config itstool glib-devel"
 makedepends="webkit2gtk-devel json-glib-devel libsecret-devel librsvg-devel

From a852724d381fbcf4629d70a75bccbf49e84e99c2 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 08/22] gwenview: revbump for exiv2-0.28.0.

---
 srcpkgs/gwenview/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/gwenview/template b/srcpkgs/gwenview/template
index 73d450a458c4d..eb876cfadcfe8 100644
--- a/srcpkgs/gwenview/template
+++ b/srcpkgs/gwenview/template
@@ -1,7 +1,7 @@
 # Template file for 'gwenview'
 pkgname=gwenview
 version=23.08.2
-revision=1
+revision=2
 build_style=cmake
 build_helper=qemu
 hostmakedepends="extra-cmake-modules pkg-config qt5-qmake qt5-host-tools

From 722d30ff0af1b1422274563b50d6d0414aec4b3c Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 09/22] hugin: revbump for exiv2-0.28.0.

---
 srcpkgs/hugin/patches/exiv2-0.28.patch | 77 ++++++++++++++++++++++++++
 srcpkgs/hugin/template                 |  2 +-
 2 files changed, 78 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/hugin/patches/exiv2-0.28.patch

diff --git a/srcpkgs/hugin/patches/exiv2-0.28.patch b/srcpkgs/hugin/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..49f0518117020
--- /dev/null
+++ b/srcpkgs/hugin/patches/exiv2-0.28.patch
@@ -0,0 +1,77 @@
+Patch-Source: https://gitlab.archlinux.org/archlinux/packaging/packages/hugin/-/blob/main/exiv2-0.28.patch
+diff -r 79cd11a7a66f src/hugin_base/panodata/Exiv2Helper.cpp
+--- a/src/hugin_base/panodata/Exiv2Helper.cpp	Wed May 24 19:13:20 2023 +0200
++++ b/src/hugin_base/panodata/Exiv2Helper.cpp	Mon Jun 05 00:31:19 2023 +0200
+@@ -40,7 +40,7 @@
+             Exiv2::ExifData::iterator itr = exifData.findKey(Exiv2::ExifKey(keyName));
+             if (itr != exifData.end() && itr->count())
+             {
+-                value = itr->toLong();
++                value = itr->toUint32();
+                 return true;
+             }
+             else
+@@ -165,7 +165,7 @@
+         {
+             if(it!=exifData.end() && it->count())
+             {
+-                return it->toLong();
++                return it->toUint32();
+             }
+             return 0;
+         };
+@@ -600,4 +600,4 @@
+         };
+ 
+     }; //namespace Exiv2Helper
+-}; //namespace HuginBase
+\ No newline at end of file
++}; //namespace HuginBase
+diff -r 79cd11a7a66f src/hugin_base/panodata/SrcPanoImage.cpp
+--- a/src/hugin_base/panodata/SrcPanoImage.cpp	Wed May 24 19:13:20 2023 +0200
++++ b/src/hugin_base/panodata/SrcPanoImage.cpp	Mon Jun 05 00:31:19 2023 +0200
+@@ -384,7 +384,7 @@
+                     pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaImageWidthPixels"));
+                     if (pos != xmpData.end())
+                     {
+-                        croppedWidth = pos->toLong();
++                        croppedWidth = pos->toUint32();
+                     }
+                     else
+                     {
+@@ -394,7 +394,7 @@
+                     pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaImageHeightPixels"));
+                     if (pos != xmpData.end())
+                     {
+-                        croppedHeight = pos->toLong();
++                        croppedHeight = pos->toUint32();
+                     }
+                     else
+                     {
+@@ -408,7 +408,7 @@
+                         double hfov = 0;
+                         if (pos != xmpData.end())
+                         {
+-                            hfov = 360 * croppedWidth / (double)pos->toLong();
++                            hfov = 360 * croppedWidth / (double)pos->toUint32();
+                         }
+                         else
+                         {
+@@ -419,7 +419,7 @@
+                         pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.FullPanoHeightPixels"));
+                         if (pos != xmpData.end())
+                         {
+-                            fullHeight = pos->toLong();
++                            fullHeight = pos->toUint32();
+                         }
+                         else
+                         {
+@@ -430,7 +430,7 @@
+                         pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaTopPixels"));
+                         if (pos != xmpData.end())
+                         {
+-                            cropTop = pos->toLong();
++                            cropTop = pos->toUint32();
+                         }
+                         else
+                         {
diff --git a/srcpkgs/hugin/template b/srcpkgs/hugin/template
index f96d2f6e27d42..ce71f6e4cbb2d 100644
--- a/srcpkgs/hugin/template
+++ b/srcpkgs/hugin/template
@@ -1,7 +1,7 @@
 # Template file for 'hugin'
 pkgname=hugin
 version=2022.0.0
-revision=10
+revision=11
 build_style=cmake
 build_helper=cmake-wxWidgets-gtk3
 pycompile_dirs="usr/share/hugin/data/plugins usr/share/hugin/data/plugins-templates"

From b09d091225cbb038ba79656add101a7f7ee56845 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 10/22] kfilemetadata5: revbump for exiv2-0.28.0.

---
 srcpkgs/kfilemetadata5/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/kfilemetadata5/template b/srcpkgs/kfilemetadata5/template
index 00f7a98cf6399..e294ae5af947c 100644
--- a/srcpkgs/kfilemetadata5/template
+++ b/srcpkgs/kfilemetadata5/template
@@ -1,7 +1,7 @@
 # Template file for 'kfilemetadata5'
 pkgname=kfilemetadata5
 version=5.111.0
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="kcoreaddons extra-cmake-modules pkg-config qt5-host-tools qt5-qmake
  gettext kcoreaddons python3"

From 25752cf46b25c1a4fe59f790d9f7f2929b5c5e9c Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 11/22] krename: revbump for exiv2-0.28.0.

---
 srcpkgs/krename/patches/e7dd767a.patch | 90 ++++++++++++++++++++++++++
 srcpkgs/krename/template               |  2 +-
 2 files changed, 91 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/krename/patches/e7dd767a.patch

diff --git a/srcpkgs/krename/patches/e7dd767a.patch b/srcpkgs/krename/patches/e7dd767a.patch
new file mode 100644
index 0000000000000..a0ef428ce46b1
--- /dev/null
+++ b/srcpkgs/krename/patches/e7dd767a.patch
@@ -0,0 +1,90 @@
+Patch-Source: https://invent.kde.org/utilities/krename/-/commit/e7dd767a
+From e7dd767a9a1068ee1fe1502c4d619b57d3b12add Mon Sep 17 00:00:00 2001
+From: Andreas Sturmlechner <asturm@gentoo.org>
+Date: Fri, 26 May 2023 23:23:10 +0200
+Subject: [PATCH] Fix build with >=exiv2-0.28, raise minimum to 0.27
+
+- enables use of EXIV2_TEST_VERSION macro
+- exiv2 headers cleanup
+
+Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>
+---
+ CMakeLists.txt         |  6 +-----
+ config-krename.h.cmake |  3 ---
+ src/exiv2plugin.cpp    | 17 +++++------------
+ 3 files changed, 6 insertions(+), 20 deletions(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 0bda8ac..72e7297 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -56,13 +56,9 @@ set_package_properties(Taglib PROPERTIES
+     TYPE OPTIONAL)
+ 
+ # Find exiv2
+-find_package(LibExiv2 0.13) # AccessMode was added in 0.13
++find_package(LibExiv2 0.27) # EXIV2_TEST_VERSION was added in 0.27
+ set_package_properties(LibExiv2 PROPERTIES TYPE OPTIONAL)
+ 
+-if (LibExiv2_VERSION VERSION_GREATER_EQUAL "0.27")
+-    set(HAVE_LIBEXIV2_0_27 TRUE)
+-endif()
+-
+ # Find podofo
+ find_package(PoDoFo)
+ set_package_properties(PoDoFo PROPERTIES
+diff --git a/config-krename.h.cmake b/config-krename.h.cmake
+index 76c3d30..862e40b 100644
+--- a/config-krename.h.cmake
++++ b/config-krename.h.cmake
+@@ -6,9 +6,6 @@
+ /* have Exiv2 */
+ #cmakedefine01 HAVE_EXIV2
+ 
+-/* Defined if we have libexiv2 >= 0.27 */
+-#cmakedefine HAVE_LIBEXIV2_0_27
+-
+ /* have PoDoFo */
+ #cmakedefine01 HAVE_PODOFO
+ 
+diff --git a/src/exiv2plugin.cpp b/src/exiv2plugin.cpp
+index 5694d8c..25e8869 100644
+--- a/src/exiv2plugin.cpp
++++ b/src/exiv2plugin.cpp
+@@ -3,20 +3,9 @@
+ 
+ #include "exiv2plugin.h"
+ 
+-#include "../config-krename.h"
+-
+ #include <KLocalizedString>
+ 
+-#include <exiv2/error.hpp>
+-#include <exiv2/exif.hpp>
+-#include <exiv2/image.hpp>
+-#include <exiv2/iptc.hpp>
+-#ifdef HAVE_LIBEXIV2_0_27
+-    #include <exiv2/xmp_exiv2.hpp>
+-#else
+-    #include <exiv2/xmp.hpp>
+-#endif
+-#include <exiv2/tags.hpp>
++#include <exiv2/exiv2.hpp>
+ 
+ #include "batchrenamer.h"
+ #include "tokenhelpdialog.h"
+@@ -381,7 +370,11 @@ QString Exiv2Plugin::processFile(BatchRenamer *b, int index, const QString &file
+     std::string strFilename(asc.constData(), asc.length());
+ 
+     try {
++#if EXIV2_TEST_VERSION(0,28,0)
++        Image::UniquePtr image = Exiv2::ImageFactory::open(strFilename);
++#else
+         Image::AutoPtr image = Exiv2::ImageFactory::open(strFilename);
++#endif
+         if (image.get() != nullptr && image->good()) {
+             image->readMetadata();
+ 
+-- 
+GitLab
+
diff --git a/srcpkgs/krename/template b/srcpkgs/krename/template
index 66023163e3293..df5535007714a 100644
--- a/srcpkgs/krename/template
+++ b/srcpkgs/krename/template
@@ -1,7 +1,7 @@
 # Template file for 'krename'
 pkgname=krename
 version=5.0.2
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="extra-cmake-modules gettext kcoreaddons pkg-config qt5-host-tools qt5-qmake"
 makedepends="exiv2-devel freetype-devel kjs-devel kparts-devel libpodofo-devel

From 2c4216297307d1ae5e8ede1ec8300ebc00e1dd4c Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 12/22] krita: revbump for exiv2-0.28.0.

---
 srcpkgs/krita/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/krita/template b/srcpkgs/krita/template
index 63ee0fbe9bceb..f4d665daf7c31 100644
--- a/srcpkgs/krita/template
+++ b/srcpkgs/krita/template
@@ -1,7 +1,7 @@
 # Template file for 'krita'
 pkgname=krita
 version=5.2.1
-revision=1
+revision=2
 build_style=cmake
 configure_args="-Wno-dev -DBUILD_TESTING=OFF"
 hostmakedepends="extra-cmake-modules gettext pkg-config python3

From 4cd3a85eaef05dad5127a4e0fe33ea7f2c1675e4 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 13/22] libextractor: revbump for exiv2-0.28.0.

---
 srcpkgs/libextractor/patches/exiv2-0.28.patch | 286 ++++++++++++++++++
 srcpkgs/libextractor/patches/fix-tests.diff   |  24 ++
 srcpkgs/libextractor/template                 |   2 +-
 3 files changed, 311 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/libextractor/patches/exiv2-0.28.patch
 create mode 100644 srcpkgs/libextractor/patches/fix-tests.diff

diff --git a/srcpkgs/libextractor/patches/exiv2-0.28.patch b/srcpkgs/libextractor/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..270a626d8ab06
--- /dev/null
+++ b/srcpkgs/libextractor/patches/exiv2-0.28.patch
@@ -0,0 +1,286 @@
+Patch-Source: https://gitlab.archlinux.org/archlinux/packaging/packages/libextractor/-/blob/main/exiv2-0.28.patch
+diff --git a/src/plugins/exiv2_extractor.cc b/src/plugins/exiv2_extractor.cc
+index 78f9bda..d32ed6a 100644
+--- a/src/plugins/exiv2_extractor.cc
++++ b/src/plugins/exiv2_extractor.cc
+@@ -90,7 +90,11 @@ virtual int close ();
+  * @param rcount number of bytes to read
+  * @return buffer with data read, empty buffer (!) on failure (!)
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++virtual Exiv2::DataBuf read (size_t rcount);
++#else
+ virtual Exiv2::DataBuf read (long rcount);
++#endif
+ 
+ /**
+  * Read up to 'rcount' bytes into 'buf'.
+@@ -99,8 +103,17 @@ virtual Exiv2::DataBuf read (long rcount);
+  * @param rcount size of 'buf'
+  * @return number of bytes read successfully, 0 on failure (!)
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++virtual size_t read (Exiv2::byte *buf,
++                   size_t rcount);
++#else
+ virtual long read (Exiv2::byte *buf,
+                    long rcount);
++#endif
++
++#if EXIV2_TEST_VERSION (0,28,0)
++virtual void populateFakeData();
++#endif
+ 
+ /**
+  * Read a single character.
+@@ -117,8 +130,13 @@ virtual int getb ();
+  * @param wcount how many bytes to write
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual size_t write (const Exiv2::byte *data,
++                    size_t wcount);
++#else
+ virtual long write (const Exiv2::byte *data,
+                     long wcount);
++#endif
+ 
+ /**
+  * Write to stream.
+@@ -126,7 +144,11 @@ virtual long write (const Exiv2::byte *data,
+  * @param src stream to copy
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual size_t write (Exiv2::BasicIo &src);
++#else
+ virtual long write (Exiv2::BasicIo &src);
++#endif
+ 
+ /**
+  * Write a single byte.
+@@ -172,7 +194,11 @@ virtual int munmap ();
+  *
+  * @return -1 on error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual size_t tell (void) const;
++#else
+ virtual long int tell (void) const;
++#endif
+ 
+ /**
+  * Return overall size of the file.
+@@ -213,7 +239,11 @@ virtual bool eof () const;
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual const std::string& path () const noexcept;
++#else
+ virtual std::string path () const;
++#endif
+ 
+ #ifdef EXV_UNICODE_PATH
+ /**
+@@ -230,7 +260,11 @@ virtual std::wstring wpath () const;
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual Exiv2::BasicIo::UniquePtr temporary () const;
++#else
+ virtual Exiv2::BasicIo::AutoPtr temporary () const;
++#endif
+ 
+ };
+ 
+@@ -266,7 +300,11 @@ ExtractorIO::close ()
+  * @return buffer with data read, empty buffer (!) on failure (!)
+  */
+ Exiv2::DataBuf
++#if EXIV2_TEST_VERSION (0,28,0)
++ExtractorIO::read (size_t rcount)
++#else
+ ExtractorIO::read (long rcount)
++#endif
+ {
+   void *data;
+   ssize_t ret;
+@@ -284,9 +322,15 @@ ExtractorIO::read (long rcount)
+  * @param rcount size of 'buf'
+  * @return number of bytes read successfully, 0 on failure (!)
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++size_t
++ExtractorIO::read (Exiv2::byte *buf,
++                   size_t rcount)
++#else
+ long
+ ExtractorIO::read (Exiv2::byte *buf,
+                    long rcount)
++#endif
+ {
+   void *data;
+   ssize_t ret;
+@@ -305,6 +349,12 @@ ExtractorIO::read (Exiv2::byte *buf,
+   return got;
+ }
+ 
++#if EXIV2_TEST_VERSION (0,28,0)
++void ExtractorIO::populateFakeData()
++{
++  return;
++}
++#endif
+ 
+ /**
+  * Read a single character.
+@@ -319,7 +369,9 @@ ExtractorIO::getb ()
+   const unsigned char *r;
+ 
+   if (1 != ec->read (ec->cls, &data, 1))
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION(0,28,0)
++    throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+     throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+     throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -336,9 +388,15 @@ ExtractorIO::getb ()
+  * @param wcount how many bytes to write
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++size_t
++ExtractorIO::write (const Exiv2::byte *data,
++                    size_t wcount)
++#else
+ long
+ ExtractorIO::write (const Exiv2::byte *data,
+                     long wcount)
++#endif
+ {
+   return -1;
+ }
+@@ -350,7 +408,11 @@ ExtractorIO::write (const Exiv2::byte *data,
+  * @param src stream to copy
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++size_t
++#else
+ long
++#endif
+ ExtractorIO::write (Exiv2::BasicIo &src)
+ {
+   return -1;
+@@ -378,7 +440,9 @@ ExtractorIO::putb (Exiv2::byte data)
+ void
+ ExtractorIO::transfer (Exiv2::BasicIo& src)
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION(0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -427,7 +491,9 @@ ExtractorIO::seek (long offset,
+ Exiv2::byte *
+ ExtractorIO::mmap (bool isWritable)
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION (0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -452,7 +518,11 @@ ExtractorIO::munmap ()
+  *
+  * @return -1 on error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++size_t
++#else
+ long int
++#endif
+ ExtractorIO::tell (void) const
+ {
+   return (long) ec->seek (ec->cls, 0, SEEK_CUR);
+@@ -516,10 +586,17 @@ ExtractorIO::eof () const
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++const std::string&
++ExtractorIO::path () const noexcept
++#else
+ std::string
+ ExtractorIO::path () const
++#endif
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION (0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -536,7 +613,9 @@ ExtractorIO::path () const
+ std::wstring
+ ExtractorIO::wpath () const
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION (0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -552,11 +631,17 @@ ExtractorIO::wpath () const
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++Exiv2::BasicIo::UniquePtr
++#else
+ Exiv2::BasicIo::AutoPtr
++#endif
+ ExtractorIO::temporary () const
+ {
+   fprintf (stderr, "throwing temporary error\n");
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION(0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -737,8 +822,13 @@ EXTRACTOR_exiv2_extract_method (struct EXTRACTOR_ExtractContext *ec)
+ #if ! EXIV2_TEST_VERSION (0,24,0)
+     Exiv2::LogMsg::setLevel (Exiv2::LogMsg::mute);
+ #endif
++#if EXIV2_TEST_VERSION(0,28,0)
++    std::unique_ptr<Exiv2::BasicIo> eio (new ExtractorIO (ec));
++    Exiv2::Image::UniquePtr image = Exiv2::ImageFactory::open (std::move(eio));
++#else
+     std::auto_ptr<Exiv2::BasicIo> eio (new ExtractorIO (ec));
+     Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open (eio);
++#endif
+     if (0 == image.get ())
+       return;
+     image->readMetadata ();
+@@ -822,7 +912,11 @@ EXTRACTOR_exiv2_extract_method (struct EXTRACTOR_ExtractContext *ec)
+       ADDXMP ("Xmp.lr.hierarchicalSubject", EXTRACTOR_METATYPE_SUBJECT);
+     }
+   }
++#if EXIV2_TEST_VERSION (0,28,0)
++  catch (const Exiv2::Error& e)
++#else
+   catch (const Exiv2::AnyError& e)
++#endif
+   {
+ #if DEBUG
+     std::cerr << "Caught Exiv2 exception '" << e << "'\n";
diff --git a/srcpkgs/libextractor/patches/fix-tests.diff b/srcpkgs/libextractor/patches/fix-tests.diff
new file mode 100644
index 0000000000000..3b4ee7cbeea33
--- /dev/null
+++ b/srcpkgs/libextractor/patches/fix-tests.diff
@@ -0,0 +1,24 @@
+--- a/src/plugins/test_exiv2.c	2021-01-30 13:20:23.000000000 +0000
++++ b/src/plugins/test_exiv2.c	2023-11-03 19:39:43.115274492 +0000
+@@ -49,8 +49,8 @@
+       EXTRACTOR_METATYPE_GPS_LATITUDE,
+       EXTRACTOR_METAFORMAT_UTF8,
+       "text/plain",
+-      "28deg 8' (18|17.585)\" ?",
+-      strlen ("28deg 8' (18|17.585)\" ?") + 1,
++      "28 deg 8' (18|17.58)\" ?",
++      strlen ("28 deg 8' (18|17.58)\" ?") + 1,
+       0,
+       .regex = 1
+     },
+@@ -66,8 +66,8 @@
+       EXTRACTOR_METATYPE_GPS_LONGITUDE,
+       EXTRACTOR_METAFORMAT_UTF8,
+       "text/plain",
+-      "14deg 14' (22|21.713)\" ?",
+-      strlen ("14deg 14' (22|21.713)\" ?"),
++      "14 deg 14' (22|21.71)\" ?",
++      strlen ("14 deg 14' (22|21.71)\" ?"),
+       0,
+       .regex = 1
+     },
diff --git a/srcpkgs/libextractor/template b/srcpkgs/libextractor/template
index ddd4790f93e88..bfcea979a308c 100644
--- a/srcpkgs/libextractor/template
+++ b/srcpkgs/libextractor/template
@@ -1,7 +1,7 @@
 # Template file for 'libextractor'
 pkgname=libextractor
 version=1.11
-revision=2
+revision=3
 build_style=gnu-configure
 configure_args="--disable-static"
 hostmakedepends="pkg-config"

From 3b6d90ee4bc1340cf2e960b3bde16d7dfce72a35 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 14/22] libgexiv2: update to 0.14.2.

---
 srcpkgs/libgexiv2/template | 14 +++++++-------
 1 file changed, 7 insertions(+), 7 deletions(-)

diff --git a/srcpkgs/libgexiv2/template b/srcpkgs/libgexiv2/template
index 23780e5397dc4..91dbcaa9aca52 100644
--- a/srcpkgs/libgexiv2/template
+++ b/srcpkgs/libgexiv2/template
@@ -1,19 +1,19 @@
 # Template file for 'libgexiv2'
 pkgname=libgexiv2
-version=0.14.0
-revision=3
+version=0.14.2
+revision=1
 build_style=meson
 build_helper="gir"
-configure_args="-Dintrospection=$(vopt_if gir true false)
- -Dvapi=$(vopt_if vala true false)"
+configure_args="$(vopt_bool gir introspection) $(vopt_bool vala vapi)"
 hostmakedepends="pkg-config glib-devel $(vopt_if vala 'vala') python3-gobject"
 makedepends="libglib-devel exiv2-devel"
 short_desc="GObject-based wrapper around the Exiv2 library"
 maintainer="Enno Boland <gottox@voidlinux.org>"
 license="GPL-2.0-or-later"
 homepage="https://wiki.gnome.org/Projects/gexiv2"
-distfiles="${GNOME_SITE}/gexiv2/${version%.*}/${pkgname/lib/}-${version}.tar.xz"
-checksum=e58279a6ff20b6f64fa499615da5e9b57cf65ba7850b72fafdf17221a9d6d69e
+changelog="https://gitlab.gnome.org/GNOME/gexiv2/-/raw/master/NEWS"
+distfiles="${GNOME_SITE}/gexiv2/${version%.*}/gexiv2-${version}.tar.xz"
+checksum=2a0c9cf48fbe8b3435008866ffd40b8eddb0667d2212b42396fdf688e93ce0be
 
 build_options="gir vala"
 build_options_default="gir vala"
@@ -23,7 +23,7 @@ libgexiv2-devel_package() {
 	short_desc+=" - development files"
 	pkg_install() {
 		vmove usr/include
-		vmove usr/lib/*.so
+		vmove "usr/lib/*.so"
 		vmove usr/lib/pkgconfig
 		if [ "$build_option_vala" ]; then
 			vmove usr/share/vala

From de998029b9d172f155bc8390fdd6fe8b990f2b99 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 15/22] libkexiv25: update to 23.08.2.

---
 srcpkgs/libkexiv25/template | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/srcpkgs/libkexiv25/template b/srcpkgs/libkexiv25/template
index b439a42ef2b97..4d7f9600572ea 100644
--- a/srcpkgs/libkexiv25/template
+++ b/srcpkgs/libkexiv25/template
@@ -1,6 +1,6 @@
 # Template file for 'libkexiv25'
 pkgname=libkexiv25
-version=23.04.0
+version=23.08.2
 revision=1
 build_style=cmake
 configure_args="-DBUILD_TESTING=OFF"
@@ -11,7 +11,7 @@ maintainer="Orphaned <orphan@voidlinux.org>"
 license="GPL-2.0-or-later"
 homepage="https://invent.kde.org/graphics/libkexiv2"
 distfiles="${KDE_SITE}/release-service/${version}/src/libkexiv2-${version}.tar.xz"
-checksum=18d3eed06df9d1e31d8434ed9887e305aba176d0856e19a8cd3bdb555b80d391
+checksum=d06e36a408bf2e846a18056a1f15e61d981fa2a1fceb81f7c15136604319d033
 
 libkexiv25-devel_package() {
 	short_desc+=" - development files"

From bc2bcc624924aaa841ece4293875eef642d7be5c Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 16/22] nomacs: update to 3.17.2287.

---
 srcpkgs/nomacs/template | 17 +++++++++++++----
 1 file changed, 13 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/nomacs/template b/srcpkgs/nomacs/template
index c52cd54e294db..956bd21ebb129 100644
--- a/srcpkgs/nomacs/template
+++ b/srcpkgs/nomacs/template
@@ -1,7 +1,8 @@
 # Template file for 'nomacs'
 pkgname=nomacs
-version=3.16.224
-revision=5
+version=3.17.2287
+revision=1
+_plugins_ver=3.17.2285
 build_wrksrc=ImageLounge
 build_style=cmake
 configure_args="-DCMAKE_BUILD_TYPE=None -DENABLE_TRANSLATIONS=1
@@ -13,5 +14,13 @@ short_desc="Simple yet powerful Qt imageviewer"
 maintainer="Orphaned <orphan@voidlinux.org>"
 license="GPL-3.0-or-later"
 homepage="https://github.com/nomacs/nomacs"
-distfiles="https://github.com/nomacs/nomacs/archive/${version}.tar.gz"
-checksum=bbc7e9048026ef9e0d2b64902c88050f17a679ef3d3c009de2c3b7de5d1d217c
+distfiles="https://github.com/nomacs/nomacs/archive/${version}.tar.gz
+ https://github.com/novomesk/nomacs-plugins/archive/refs/tags/${_plugins_ver}.tar.gz>plugins.tar.gz"
+checksum="6905ea615358f84a0c83d5b1b7077871dea0526ec667500a1951448cb845a92c
+ 946b2d754be9ecca5cb155f7ecc5dcafb164f6c3dcc7bf5c3c0610d3b47774aa"
+skip_extraction="plugins.tar.gz"
+
+post_extract() {
+ cd ${build_wrksrc}
+ vsrcextract -C plugins "plugins.tar.gz"
+}

From 14ce0831e8fff7ac3c6da91da9e7fa52e1b53d2e Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 17/22] pdf2djvu: revbump for exiv2-0.28.0.

---
 srcpkgs/pdf2djvu/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/pdf2djvu/template b/srcpkgs/pdf2djvu/template
index ef7433c0c98ae..5a6f3ddf4ed35 100644
--- a/srcpkgs/pdf2djvu/template
+++ b/srcpkgs/pdf2djvu/template
@@ -1,7 +1,7 @@
 # Template file for 'pdf2djvu'
 pkgname=pdf2djvu
 version=0.9.19
-revision=4
+revision=5
 build_style=gnu-configure
 hostmakedepends="pkg-config djvulibre gettext"
 makedepends="djvulibre-devel poppler-devel libgraphicsmagick-devel exiv2-devel libuuid-devel"

From 08dc1b1f59ec9cef6c73e3c0743279fdfdbcdfd1 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 18/22] phototonic: revbump for exiv2-0.28.0.

---
 srcpkgs/phototonic/patches/exiv2-0.28.patch | 135 ++++++++++++++++++++
 srcpkgs/phototonic/template                 |   2 +-
 2 files changed, 136 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/phototonic/patches/exiv2-0.28.patch

diff --git a/srcpkgs/phototonic/patches/exiv2-0.28.patch b/srcpkgs/phototonic/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..1c75b628dab33
--- /dev/null
+++ b/srcpkgs/phototonic/patches/exiv2-0.28.patch
@@ -0,0 +1,135 @@
+From 923a3fc14de0b779a45696c5f0aef34c74d84f13 Mon Sep 17 00:00:00 2001
+From: Andreas Sturmlechner <asturm@gentoo.org>
+Date: Sun, 28 May 2023 18:54:10 +0200
+Subject: [PATCH] Fix build with exiv2-0.28
+
+Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>
+---
+ ImageViewer.cpp   | 9 +++++++++
+ MetadataCache.cpp | 8 ++++++++
+ Phototonic.cpp    | 4 ++++
+ Tags.cpp          | 8 ++++++++
+ ThumbsViewer.cpp  | 4 ++++
+ 5 files changed, 33 insertions(+)
+
+diff --git a/ImageViewer.cpp b/ImageViewer.cpp
+index 357d223..df3ac43 100644
+--- a/ImageViewer.cpp
++++ b/ImageViewer.cpp
+@@ -945,7 +945,11 @@ void ImageViewer::keyMoveEvent(int direction) {
+ }
+ 
+ void ImageViewer::saveImage() {
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr image;
++#else
+     Exiv2::Image::AutoPtr image;
++#endif
+     bool exifError = false;
+ 
+     if (newImage) {
+@@ -985,8 +989,13 @@ void ImageViewer::saveImage() {
+ }
+ 
+ void ImageViewer::saveImageAs() {
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++    Exiv2::Image::UniquePtr newExifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
+     Exiv2::Image::AutoPtr newExifImage;
++#endif
+     bool exifError = false;
+ 
+     setCursorHiding(false);
+diff --git a/MetadataCache.cpp b/MetadataCache.cpp
+index 524ae74..5ddd4c8 100644
+--- a/MetadataCache.cpp
++++ b/MetadataCache.cpp
+@@ -64,7 +64,11 @@ void MetadataCache::clear() {
+ }
+ 
+ bool MetadataCache::loadImageMetadata(const QString &imageFullPath) {
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
++#endif
+     QSet<QString> tags;
+     long orientation = 0;
+ 
+@@ -78,7 +82,11 @@ bool MetadataCache::loadImageMetadata(const QString &imageFullPath) {
+     try {
+         Exiv2::ExifData &exifData = exifImage->exifData();
+         if (!exifData.empty()) {
++#if EXIV2_TEST_VERSION(0,28,0)
++            orientation = exifData["Exif.Image.Orientation"].value().toUint32();
++#else
+             orientation = exifData["Exif.Image.Orientation"].value().toLong();
++#endif
+         }
+     } catch (Exiv2::Error &error) {
+         qWarning() << "Failed to read Exif metadata";
+diff --git a/Phototonic.cpp b/Phototonic.cpp
+index 6cc95b3..bd5497d 100644
+--- a/Phototonic.cpp
++++ b/Phototonic.cpp
+@@ -3151,7 +3151,11 @@ void Phototonic::removeMetadata() {
+ 
+     if (ret == MessageBox::Yes) {
+         for (int file = 0; file < fileList.size(); ++file) {
++#if EXIV2_TEST_VERSION(0,28,0)
++            Exiv2::Image::UniquePtr image;
++#else
+             Exiv2::Image::AutoPtr image;
++#endif
+             try {
+                 image = Exiv2::ImageFactory::open(fileList[file].toStdString());
+                 image->clearMetadata();
+diff --git a/Tags.cpp b/Tags.cpp
+index 84eea16..a62da9d 100644
+--- a/Tags.cpp
++++ b/Tags.cpp
+@@ -136,7 +136,11 @@ void ImageTags::addTag(QString tagName, bool tagChecked) {
+ 
+ bool ImageTags::writeTagsToImage(QString &imageFileName, QSet<QString> &newTags) {
+     QSet<QString> imageTags;
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
++#endif
+ 
+     try {
+         exifImage = Exiv2::ImageFactory::open(imageFileName.toStdString());
+@@ -160,7 +164,11 @@ bool ImageTags::writeTagsToImage(QString &imageFileName, QSet<QString> &newTags)
+         QSetIterator<QString> newTagsIt(newTags);
+         while (newTagsIt.hasNext()) {
+             QString tag = newTagsIt.next();
++#if EXIV2_TEST_VERSION(0,28,0)
++            Exiv2::Value::UniquePtr value = Exiv2::Value::create(Exiv2::string);
++#else
+             Exiv2::Value::AutoPtr value = Exiv2::Value::create(Exiv2::string);
++#endif
+             value->read(tag.toStdString());
+             Exiv2::IptcKey key("Iptc.Application2.Keywords");
+             newIptcData.add(key, value.get());
+diff --git a/ThumbsViewer.cpp b/ThumbsViewer.cpp
+index 77a6189..4a11475 100644
+--- a/ThumbsViewer.cpp
++++ b/ThumbsViewer.cpp
+@@ -210,7 +210,11 @@ void ThumbsViewer::updateImageInfoViewer(QString imageFullPath) {
+         infoView->addEntry(key, val);
+     }
+ 
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
++#endif
+     try {
+         exifImage = Exiv2::ImageFactory::open(imageFullPath.toStdString());
+         exifImage->readMetadata();
+-- 
+2.40.1
+
diff --git a/srcpkgs/phototonic/template b/srcpkgs/phototonic/template
index 77ae8bf6a4406..4af006cb7da41 100644
--- a/srcpkgs/phototonic/template
+++ b/srcpkgs/phototonic/template
@@ -1,7 +1,7 @@
 # Template file for 'phototonic'
 pkgname=phototonic
 version=2.1
-revision=3
+revision=4
 build_style=qmake
 hostmakedepends="pkg-config qt5-qmake qt5-host-tools"
 makedepends="qt5-svg-devel exiv2-devel"

From 2919d8d898d812fed7835aae595afb953f3d66b7 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 19/22] qimgv: revbump for exiv2-0.28.0.

---
 srcpkgs/qimgv/patches/exiv2-0.28.patch | 16 ++++++++++++++++
 srcpkgs/qimgv/template                 |  2 +-
 2 files changed, 17 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/qimgv/patches/exiv2-0.28.patch

diff --git a/srcpkgs/qimgv/patches/exiv2-0.28.patch b/srcpkgs/qimgv/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..11f37b5ae2be3
--- /dev/null
+++ b/srcpkgs/qimgv/patches/exiv2-0.28.patch
@@ -0,0 +1,16 @@
+Patch-Source: https://git.alpinelinux.org/aports/tree/community/qimgv/exiv2-0.28.patch
+diff --git a/qimgv/sourcecontainers/documentinfo.cpp b/qimgv/sourcecontainers/documentinfo.cpp
+index 98a68f7..c062474 100644
+--- a/qimgv/sourcecontainers/documentinfo.cpp
++++ b/qimgv/sourcecontainers/documentinfo.cpp
+@@ -271,10 +271,6 @@ void DocumentInfo::loadExifTags() {
+         //std::cout << "Caught Exiv2 exception '" << e.what() << "'\n";
+         return;
+     }
+-    catch (Exiv2::BasicError<CharType> e) {
+-        //std::cout << "Caught BasicError Exiv2 exception '" << e.what() << "'\n";
+-        return;
+-    }
+ #endif
+ }
+ 
diff --git a/srcpkgs/qimgv/template b/srcpkgs/qimgv/template
index 7eb30db33992c..dd341dfe1bfce 100644
--- a/srcpkgs/qimgv/template
+++ b/srcpkgs/qimgv/template
@@ -1,7 +1,7 @@
 # Template file for 'qimgv'
 pkgname=qimgv
 version=1.0.2
-revision=2
+revision=3
 build_style=cmake
 configure_args="$(vopt_if video -DVIDEO_SUPPORT=ON -DVIDEO_SUPPORT=OFF)
  $(vopt_if scale -DOPENCV_SUPPORT=ON -DOPENCV_SUPPORT=OFF)

From 7122d5364e625506748f73e2dc2ea1b4c2cb8acc Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 20/22] SIR: revbump for exiv2-0.28.0.

---
 srcpkgs/SIR/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/SIR/template b/srcpkgs/SIR/template
index 113077acad354..c6da4c26b6c71 100644
--- a/srcpkgs/SIR/template
+++ b/srcpkgs/SIR/template
@@ -1,7 +1,7 @@
 # Template file for 'SIR'
 pkgname=SIR
 version=3.2.2
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="pkg-config"
 makedepends="exiv2-devel qt5-svg-devel qt5-tools-devel"

From b887d8a64a33abf825903b9f730ae35b8b8b26e8 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 21/22] viewnior: revbump for exiv2-0.28.0.

---
 srcpkgs/viewnior/patches/exiv2-0.28.patch | 147 ++++++++++++++++++++++
 srcpkgs/viewnior/template                 |   2 +-
 2 files changed, 148 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/viewnior/patches/exiv2-0.28.patch

diff --git a/srcpkgs/viewnior/patches/exiv2-0.28.patch b/srcpkgs/viewnior/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..71459dee15768
--- /dev/null
+++ b/srcpkgs/viewnior/patches/exiv2-0.28.patch
@@ -0,0 +1,147 @@
+Patch-Source: https://gitlab.archlinux.org/archlinux/packaging/packages/viewnior/-/blob/f206ce6c22a3ec5f1f9ea1bde4077584f80458dd/exiv2-0.28.patch
+--
+From b6bb81a1b46e911d15bbf9a730972523de177705 Mon Sep 17 00:00:00 2001
+From: tastytea <tastytea@tastytea.de>
+Date: Tue, 16 May 2023 10:54:40 +0200
+Subject: [PATCH 1/2] change exiv2 AutoPtr to unique_ptr
+
+exiv2-0.28.0 removed Exiv2::Image::AutoPtr and added
+Exiv2::Image::UniquePtr instead. since it's a typedef for
+std::unique_ptr<Image>, i'm using that directly instead of adding a
+condition on the exiv2 version.
+---
+ src/uni-exiv2.cpp | 21 +++++++++++----------
+ 1 file changed, 11 insertions(+), 10 deletions(-)
+
+diff --git a/src/uni-exiv2.cpp b/src/uni-exiv2.cpp
+index 0d14b9f..77064c2 100644
+--- a/src/uni-exiv2.cpp
++++ b/src/uni-exiv2.cpp
+@@ -22,12 +22,13 @@
+ 
+ #include <exiv2/exiv2.hpp>
+ #include <iostream>
++#include <memory>
+ 
+ #include "uni-exiv2.hpp"
+ 
+ #define ARRAY_SIZE(array) (sizeof array/sizeof(array[0]))
+ 
+-static Exiv2::Image::AutoPtr cached_image;
++static std::unique_ptr<Exiv2::Image> cached_image;
+ 
+ extern "C"
+ void
+@@ -35,8 +36,8 @@ uni_read_exiv2_map(const char *uri, void (*callback)(const char*, const char*, v
+ {
+     Exiv2::LogMsg::setLevel(Exiv2::LogMsg::mute);
+     try {
+-        Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open(uri);
+-        if ( image.get() == 0 ) {
++        std::unique_ptr<Exiv2::Image> image = Exiv2::ImageFactory::open(uri);
++        if (image == nullptr) {
+             return;
+         }
+ 
+@@ -91,14 +92,14 @@ uni_read_exiv2_to_cache(const char *uri)
+ {
+     Exiv2::LogMsg::setLevel(Exiv2::LogMsg::mute);
+ 
+-    if ( cached_image.get() != NULL ) {
++    if (cached_image != nullptr) {
+         cached_image->clearMetadata();
+-        cached_image.reset(NULL);
++        cached_image.reset(nullptr);
+     }
+ 
+     try {
+         cached_image = Exiv2::ImageFactory::open(uri);
+-        if ( cached_image.get() == 0 ) {
++        if (cached_image == nullptr) {
+             return 1;
+         }
+ 
+@@ -116,13 +117,13 @@ uni_write_exiv2_from_cache(const char *uri)
+ {
+     Exiv2::LogMsg::setLevel(Exiv2::LogMsg::mute);
+ 
+-    if ( cached_image.get() == NULL ) {
++    if (cached_image == nullptr) {
+         return 1;
+     }
+ 
+     try {
+-        Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open(uri);
+-        if ( image.get() == 0 ) {
++        std::unique_ptr<Exiv2::Image> image = Exiv2::ImageFactory::open(uri);
++        if (image == nullptr) {
+             return 2;
+         }
+ 
+@@ -130,7 +131,7 @@ uni_write_exiv2_from_cache(const char *uri)
+         image->writeMetadata();
+ 
+         cached_image->clearMetadata();
+-        cached_image.reset(NULL);
++        cached_image.reset(nullptr);
+ 
+         return 0;
+     } catch (Exiv2::AnyError& e) {
+
+From 47d0b98cb46526aa8aa035bebcabc14a11fa57ee Mon Sep 17 00:00:00 2001
+From: tastytea <tastytea@tastytea.de>
+Date: Tue, 16 May 2023 11:17:00 +0200
+Subject: [PATCH 2/2] add support for exiv-0.28.0 errors
+
+exiv2-0.28.0 changed Exiv2::AnyError to Exiv2::Error.
+---
+ src/uni-exiv2.cpp | 15 ++++++++++++---
+ 1 file changed, 12 insertions(+), 3 deletions(-)
+
+diff --git a/src/uni-exiv2.cpp b/src/uni-exiv2.cpp
+index 77064c2..567a50f 100644
+--- a/src/uni-exiv2.cpp
++++ b/src/uni-exiv2.cpp
+@@ -28,6 +28,15 @@
+ 
+ #define ARRAY_SIZE(array) (sizeof array/sizeof(array[0]))
+ 
++#define EXIV_ERROR Exiv2::AnyError
++#ifdef EXIV2_VERSION
++    #ifdef EXIV2_TEST_VERSION
++        #if EXIV2_TEST_VERSION(0,28,0)
++            #define EXIV_ERROR Exiv2::Error
++        #endif
++    #endif
++#endif
++
+ static std::unique_ptr<Exiv2::Image> cached_image;
+ 
+ extern "C"
+@@ -81,7 +90,7 @@ uni_read_exiv2_map(const char *uri, void (*callback)(const char*, const char*, v
+                 }
+             }
+         }
+-    } catch (Exiv2::AnyError& e) {
++    } catch (EXIV_ERROR& e) {
+         std::cerr << "Exiv2: '" << e << "'\n";
+     }
+ }
+@@ -104,7 +113,7 @@ uni_read_exiv2_to_cache(const char *uri)
+         }
+ 
+         cached_image->readMetadata();
+-    } catch (Exiv2::AnyError& e) {
++    } catch (EXIV_ERROR& e) {
+         std::cerr << "Exiv2: '" << e << "'\n";
+     }
+ 
+@@ -134,7 +143,7 @@ uni_write_exiv2_from_cache(const char *uri)
+         cached_image.reset(nullptr);
+ 
+         return 0;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (EXIV_ERROR& e) {
+         std::cerr << "Exiv2: '" << e << "'\n";
+     }
+ 
diff --git a/srcpkgs/viewnior/template b/srcpkgs/viewnior/template
index ea1e528a8651f..4c73226662ca0 100644
--- a/srcpkgs/viewnior/template
+++ b/srcpkgs/viewnior/template
@@ -1,7 +1,7 @@
 # Template file for 'viewnior'
 pkgname=viewnior
 version=1.8
-revision=1
+revision=2
 build_style=meson
 hostmakedepends="pkg-config intltool glib-devel gettext-devel"
 makedepends="gtk+-devel exiv2-devel"

From 7ae8861e6109dce9a0ed1c94952c637c0c9c5d64 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Mon, 23 Oct 2023 19:06:34 +0200
Subject: [PATCH 22/22] New package: nufraw-0.43.3

Co-authored-by: triallax <triallax@tutanota.com>
---
 srcpkgs/nufraw-gimp                           |  1 +
 .../patches/0001-nufraw-glib-2.70.patch       | 20 +++++++
 srcpkgs/nufraw/patches/exiv-0.28.x.diff       | 59 +++++++++++++++++++
 srcpkgs/nufraw/template                       | 49 +++++++++++++++
 srcpkgs/removed-packages/template             |  8 ++-
 srcpkgs/ufraw                                 |  1 +
 srcpkgs/ufraw-gimp                            |  2 +-
 .../ufraw/patches/001-no-gimp-remote.patch    | 12 ----
 srcpkgs/ufraw/patches/002-fix_abs_int.patch   | 11 ----
 .../ufraw/patches/03_fix-unsigned-char.patch  | 14 -----
 srcpkgs/ufraw/patches/exiv-0.27.patch         | 25 --------
 srcpkgs/ufraw/patches/glib-2.68.patch         | 30 ----------
 srcpkgs/ufraw/patches/iostream.patch          | 13 ----
 srcpkgs/ufraw/template                        | 38 ------------
 14 files changed, 136 insertions(+), 147 deletions(-)
 create mode 120000 srcpkgs/nufraw-gimp
 create mode 100644 srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch
 create mode 100644 srcpkgs/nufraw/patches/exiv-0.28.x.diff
 create mode 100644 srcpkgs/nufraw/template
 create mode 120000 srcpkgs/ufraw
 delete mode 100644 srcpkgs/ufraw/patches/001-no-gimp-remote.patch
 delete mode 100644 srcpkgs/ufraw/patches/002-fix_abs_int.patch
 delete mode 100644 srcpkgs/ufraw/patches/03_fix-unsigned-char.patch
 delete mode 100644 srcpkgs/ufraw/patches/exiv-0.27.patch
 delete mode 100644 srcpkgs/ufraw/patches/glib-2.68.patch
 delete mode 100644 srcpkgs/ufraw/patches/iostream.patch
 delete mode 100644 srcpkgs/ufraw/template

diff --git a/srcpkgs/nufraw-gimp b/srcpkgs/nufraw-gimp
new file mode 120000
index 0000000000000..0bd1459b2a16f
--- /dev/null
+++ b/srcpkgs/nufraw-gimp
@@ -0,0 +1 @@
+nufraw
\ No newline at end of file
diff --git a/srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch b/srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch
new file mode 100644
index 0000000000000..41f10bfbafa1f
--- /dev/null
+++ b/srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch
@@ -0,0 +1,20 @@
+diff -ru nufraw/uf_glib.h nufraw/uf_glib.h
+--- nufraw/uf_glib.h	2022-02-23 09:03:44.700472919 +0100
++++ nufraw/uf_glib.h	2022-02-23 09:04:50.260308805 +0100
+@@ -13,13 +13,13 @@
+ #ifndef _UF_GLIB_H
+ #define _UF_GLIB_H
+ 
++#include <glib.h>
++#include <glib/gstdio.h>
++
+ #ifdef __cplusplus
+ extern "C" {
+ #endif
+ 
+-#include <glib.h>
+-#include <glib/gstdio.h>
+-
+ // g_win32_locale_filename_from_utf8 is needed only on win32
+ #ifdef _WIN32
+ #define uf_win32_locale_filename_from_utf8(__some_string__) \
diff --git a/srcpkgs/nufraw/patches/exiv-0.28.x.diff b/srcpkgs/nufraw/patches/exiv-0.28.x.diff
new file mode 100644
index 0000000000000..6c23359bf706c
--- /dev/null
+++ b/srcpkgs/nufraw/patches/exiv-0.28.x.diff
@@ -0,0 +1,59 @@
+Patch taken from AUR package: https://aur.archlinux.org/cgit/aur.git/tree/exiv2-error.patch?h=nufraw&id=29e467f2c297fcd0f36548642d6d2cab6428d08f
+diff --git a/nufraw_exiv2.cc b/nufraw_exiv2.cc
+index 2de4cc3..45aea87 100644
+--- a/nufraw_exiv2.cc
++++ b/nufraw_exiv2.cc
+@@ -54,7 +54,7 @@ extern "C" int nufraw_exif_read_input(nufraw_data *uf)
+         uf->inputExifBuf = NULL;
+         uf->inputExifBufLen = 0;
+ 
+-        Exiv2::Image::AutoPtr image;
++        Exiv2::Image::UniquePtr image;
+         if (uf->unzippedBuf != NULL) {
+             image = Exiv2::ImageFactory::open(
+                         (const Exiv2::byte*)uf->unzippedBuf, uf->unzippedBufLen);
+@@ -135,7 +135,7 @@ extern "C" int nufraw_exif_read_input(nufraw_data *uf)
+         nufraw_message(NUFRAW_SET_LOG, "%s\n", stderror.str().c_str());
+ 
+         return NUFRAW_SUCCESS;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (Exiv2::Error& e) {
+         std::cerr.rdbuf(savecerr);
+         std::string s(e.what());
+         nufraw_message(NUFRAW_SET_WARNING, "%s\n", s.c_str());
+@@ -156,7 +156,7 @@ static Exiv2::ExifData nufraw_prepare_exifdata(nufraw_data *uf)
+         if ((pos = exifData.findKey(Exiv2::ExifKey("Exif.Image.Orientation")))
+                 != exifData.end()) {
+             nufraw_message(NUFRAW_SET_LOG, "Resetting %s from '%d' to '1'\n",
+-                          pos->key().c_str(), pos->value().toLong());
++                          pos->key().c_str(), pos->value().toInt64());
+             pos->setValue("1"); /* 1 = Normal orientation */
+         }
+     }
+@@ -327,7 +327,7 @@ extern "C" int nufraw_exif_prepare_output(nufraw_data *uf)
+         nufraw_message(NUFRAW_SET_LOG, "%s\n", stderror.str().c_str());
+ 
+         return NUFRAW_SUCCESS;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (Exiv2::Error& e) {
+         std::cerr.rdbuf(savecerr);
+         std::string s(e.what());
+         nufraw_message(NUFRAW_SET_WARNING, "%s\n", s.c_str());
+@@ -347,7 +347,7 @@ extern "C" int nufraw_exif_write(nufraw_data *uf)
+ 
+         char *filename =
+             uf_win32_locale_filename_from_utf8(uf->conf->outputFilename);
+-        Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open(filename);
++        Exiv2::Image::UniquePtr image = Exiv2::ImageFactory::open(filename);
+         uf_win32_locale_filename_free(filename);
+         assert(image.get() != 0);
+ 
+@@ -367,7 +367,7 @@ extern "C" int nufraw_exif_write(nufraw_data *uf)
+         nufraw_message(NUFRAW_SET_LOG, "%s\n", stderror.str().c_str());
+ 
+         return NUFRAW_SUCCESS;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (Exiv2::Error& e) {
+         std::cerr.rdbuf(savecerr);
+         std::string s(e.what());
+         nufraw_message(NUFRAW_SET_WARNING, "%s\n", s.c_str());
diff --git a/srcpkgs/nufraw/template b/srcpkgs/nufraw/template
new file mode 100644
index 0000000000000..e9b2b9aed0448
--- /dev/null
+++ b/srcpkgs/nufraw/template
@@ -0,0 +1,49 @@
+# Template file for 'nufraw'
+pkgname=nufraw
+version=0.43.3
+revision=1
+_ver="${version%.*}-${version##*.}"
+build_style=gnu-configure
+configure_args="--enable-contrast --enable-mime --enable-openmp --with-gimp
+ --enable-extras"
+hostmakedepends="pkg-config automake libtool glib-devel"
+# libgexiv2-devel is only here to fix build order, remove on next template
+# change
+makedepends="exiv2-devel gimp-devel glib-devel gtkimageview-devel lcms2-devel
+ lensfun-devel jasper-devel libgexiv2-devel"
+depends="desktop-file-utils"
+short_desc="Utility to read and manipulate raw images from digital cameras"
+maintainer="John <me@johnnynator.dev>"
+license="GPL-2.0-or-later"
+homepage="https://sourceforge.net/projects/nufraw/"
+distfiles="${SOURCEFORGE_SITE}/nufraw/nufraw-${_ver}.tar.gz"
+checksum=2c7dcc1590993ec267b3112562b2433010d6f94f6acc6506c76aa29cf8c6c32c
+
+pre_configure() {
+	autoreconf -fi
+}
+
+pre_build() {
+	mv nufraw.desktop{.desktop,}
+	chmod +x generate_schemas.sh
+}
+
+nufraw-gimp_package() {
+	depends="${sourcepkg}>=${version}_${revision}"
+	short_desc+=" - gimp plugin"
+	pkg_install() {
+		vmove usr/lib/gimp
+	}
+}
+
+ufraw_package() {
+	depends="${sourcepkg}>=${version}_${revision}"
+	build_style=meta
+	short_desc+=" (transitional dummy package)"
+}
+
+ufraw-gimp_package() {
+	depends="nufraw-gimp>=${version}_${revision}"
+	build_style=meta
+	short_desc+=" - gimp plugin (transitional dummy package)"
+}
diff --git a/srcpkgs/removed-packages/template b/srcpkgs/removed-packages/template
index abedf26f739b6..f3d81a8afe04c 100644
--- a/srcpkgs/removed-packages/template
+++ b/srcpkgs/removed-packages/template
@@ -1,6 +1,6 @@
 # Template file for 'removed-packages'
 pkgname=removed-packages
-version=0.1.20231019
+version=0.1.20231101
 revision=1
 build_style=meta
 short_desc="Uninstalls packages removed from repository"
@@ -590,8 +590,8 @@ replaces="
  python3-Flask-Assets<=0.12_9
  python3-Flask-Mail<=0.9.1_5
  python3-Flask-OAuthlib<=0.9.6_4
- python3-Flask-Script<=2.0.6_7
  python3-Flask-SQLAlchemy<=2.5.1_4
+ python3-Flask-Script<=2.0.6_7
  python3-Flask-User<=1.0.2.2_6
  python3-SPARQLWrapper<=1.8.4_4
  python3-aiohttp-cors2<=0.7.0_3
@@ -642,8 +642,8 @@ replaces="
  raul-devel<=0.8.0_6
  raul<=0.8.0_6
  redkite<=1.3.1_1
- rem<=2.10.0_1
  rem-devel<=2.10.0_1
+ rem<=2.10.0_1
  reminiscence<=0.4.6_1
  rkt-stage1-coreos<=1.30.0_3
  rkt-stage1-fly<=1.30.0_3
@@ -675,6 +675,8 @@ replaces="
  traverso<=0.49.6_2
  ttyload-git<=20141117_4
  tuxc<=1.1_3
+ ufraw-gimp<=0.22_5
+ ufraw<=0.22_5
  unicorn-python<=1.0.2_2
  upwork<=5.6.10.0_1
  urlmatch-git<=20141116_2
diff --git a/srcpkgs/ufraw b/srcpkgs/ufraw
new file mode 120000
index 0000000000000..0bd1459b2a16f
--- /dev/null
+++ b/srcpkgs/ufraw
@@ -0,0 +1 @@
+nufraw
\ No newline at end of file
diff --git a/srcpkgs/ufraw-gimp b/srcpkgs/ufraw-gimp
index 967dc902dd02b..0bd1459b2a16f 120000
--- a/srcpkgs/ufraw-gimp
+++ b/srcpkgs/ufraw-gimp
@@ -1 +1 @@
-ufraw
\ No newline at end of file
+nufraw
\ No newline at end of file
diff --git a/srcpkgs/ufraw/patches/001-no-gimp-remote.patch b/srcpkgs/ufraw/patches/001-no-gimp-remote.patch
deleted file mode 100644
index ca4f4beb6240f..0000000000000
--- a/srcpkgs/ufraw/patches/001-no-gimp-remote.patch
+++ /dev/null
@@ -1,12 +0,0 @@
-Don't use gimp-remote since gimp 2.4 already includes gimp-remote functionality
---- a/ufraw_conf.c
-+++ b/ufraw_conf.c
-@@ -137,7 +137,7 @@
- #elif HAVE_GIMP_2_4
-     "gimp", /* remoteGimpCommand */
- #else
--    "gimp-remote", /* remoteGimpCommand */
-+    "gimp", /* remoteGimpCommand */
- #endif
- 
-     /* EXIF data */
diff --git a/srcpkgs/ufraw/patches/002-fix_abs_int.patch b/srcpkgs/ufraw/patches/002-fix_abs_int.patch
deleted file mode 100644
index 6fc552769c9f8..0000000000000
--- a/srcpkgs/ufraw/patches/002-fix_abs_int.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- a/dcraw.cc	2015-06-16 05:58:38.000000000 +0200
-+++ b/dcraw.cc	2018-02-04 14:46:54.489951076 +0100
-@@ -9242,7 +9242,7 @@
-     if (make[0] == 'O') {
-       i = find_green (12, 32, 1188864, 3576832);
-       c = find_green (12, 32, 2383920, 2387016);
--      if (abs(i) < abs(c)) {
-+      if (abs((int)i) < abs((int)c)) {
- 	SWAP(i,c);
- 	load_flags = 24;
-       }
diff --git a/srcpkgs/ufraw/patches/03_fix-unsigned-char.patch b/srcpkgs/ufraw/patches/03_fix-unsigned-char.patch
deleted file mode 100644
index 8690f87ca7d59..0000000000000
--- a/srcpkgs/ufraw/patches/03_fix-unsigned-char.patch
+++ /dev/null
@@ -1,14 +0,0 @@
-Source: written by John Paul Adrian Glaubitz for Debian
-Upstream: https://sourceforge.net/p/ufraw/bugs/417
-Reason: fixes a compilation failure on arm architectures
---- a/dcraw.cc
-+++ b/dcraw.cc
-@@ -2285,7 +2285,7 @@ void CLASS quicktake_100_load_raw()
- 
- void CLASS kodak_radc_load_raw()
- {
--  static const char src[] = {
-+  static const signed char src[] = {
-     1,1, 2,3, 3,4, 4,2, 5,7, 6,5, 7,6, 7,8,
-     1,0, 2,1, 3,3, 4,4, 5,2, 6,7, 7,6, 8,5, 8,8,
-     2,1, 2,3, 3,0, 3,2, 3,4, 4,6, 5,5, 6,7, 6,8,
diff --git a/srcpkgs/ufraw/patches/exiv-0.27.patch b/srcpkgs/ufraw/patches/exiv-0.27.patch
deleted file mode 100644
index b5b4140fff8ed..0000000000000
--- a/srcpkgs/ufraw/patches/exiv-0.27.patch
+++ /dev/null
@@ -1,25 +0,0 @@
---- a/ufraw_exiv2.cc	2015-06-16 05:58:38.000000000 +0200
-+++ b/ufraw_exiv2.cc	2018-12-29 22:51:23.291894430 +0100
-@@ -15,9 +15,7 @@
- #include "ufraw.h"
- 
- #ifdef HAVE_EXIV2
--#include <exiv2/image.hpp>
--#include <exiv2/easyaccess.hpp>
--#include <exiv2/exif.hpp>
-+#include <exiv2/exiv2.hpp>
- #include <sstream>
- #include <cassert>
- 
-@@ -67,7 +65,11 @@
-         if (exifData.empty()) {
-             std::string error(uf->filename);
-             error += ": No Exif data found in the file";
-+#if EXIV2_TEST_VERSION(0,27,0)
-+            throw Exiv2::Error(Exiv2::kerErrorMessage, error);
-+#else
-             throw Exiv2::Error(1, error);
-+#endif
-         }
- 
-         /* List of tag names taken from exiv2's printSummary() in actions.cpp */
diff --git a/srcpkgs/ufraw/patches/glib-2.68.patch b/srcpkgs/ufraw/patches/glib-2.68.patch
deleted file mode 100644
index 5b61468f118aa..0000000000000
--- a/srcpkgs/ufraw/patches/glib-2.68.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-From c56f8be3caf1cf3d9a5c80597bdbaf1325faacc0 Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?S=C3=A9rgio=20M=2E=20Basto?= <sergio@serjux.com>
-Date: Tue, 13 Apr 2021 23:45:39 +0100
-Subject: [PATCH] Fix build against glib-2.68 fixes #10
-
----
- uf_glib.h | 6 +++---
- 1 file changed, 3 insertions(+), 3 deletions(-)
-
-diff --git a/uf_glib.h b/uf_glib.h
-index 21c10b19..56cd6971 100644
---- a/uf_glib.h
-+++ b/uf_glib.h
-@@ -13,13 +13,13 @@
- #ifndef _UF_GLIB_H
- #define _UF_GLIB_H
- 
-+#include <glib.h>
-+#include <glib/gstdio.h>
-+
- #ifdef __cplusplus
- extern "C" {
- #endif
- 
--#include <glib.h>
--#include <glib/gstdio.h>
--
- // g_win32_locale_filename_from_utf8 is needed only on win32
- #ifdef _WIN32
- #define uf_win32_locale_filename_from_utf8(__some_string__) \
diff --git a/srcpkgs/ufraw/patches/iostream.patch b/srcpkgs/ufraw/patches/iostream.patch
deleted file mode 100644
index 6d15869f63db8..0000000000000
--- a/srcpkgs/ufraw/patches/iostream.patch
+++ /dev/null
@@ -1,13 +0,0 @@
-ufraw_exiv2.cc:343:10: note: 'std::cerr' is defined in header '<iostream>'
-ufraw_exiv2.cc:365:14: error: 'cerr' is not a member of 'std'
-
---- a/ufraw_exiv2.cc
-+++ b/ufraw_exiv2.cc
-@@ -17,6 +17,7 @@
- #ifdef HAVE_EXIV2
- #include <exiv2/exiv2.hpp>
- #include <sstream>
-+#include <iostream>
- #include <cassert>
- 
- /*
diff --git a/srcpkgs/ufraw/template b/srcpkgs/ufraw/template
deleted file mode 100644
index ceddcacacefb2..0000000000000
--- a/srcpkgs/ufraw/template
+++ /dev/null
@@ -1,38 +0,0 @@
-# Template file for 'ufraw'
-pkgname=ufraw
-version=0.22
-revision=5
-build_style=gnu-configure
-configure_args="--enable-contrast --enable-mime --enable-openmp --with-gimp
- $(vopt_enable extras)"
-hostmakedepends="pkg-config dcraw gettext"
-makedepends="exiv2-devel gimp-devel glib-devel gtkimageview-devel lcms2-devel lensfun-devel
- jasper-devel"
-depends="desktop-file-utils"
-short_desc="Utility to read and manipulate raw images from digital cameras"
-maintainer="John <me@johnnynator.dev>"
-license="GPL-2.0-or-later"
-homepage="http://ufraw.sourceforge.net/"
-distfiles="${SOURCEFORGE_SITE}/ufraw/ufraw/ufraw-${version}/ufraw-${version}.tar.gz"
-checksum=f7abd28ce587db2a74b4c54149bd8a2523a7ddc09bedf4f923246ff0ae09a25e
-
-build_options="extras"
-
-post_patch() {
-	vsed -e 's/default(none)//g' \
-		-i dcraw_indi.c \
-		-i dcraw_api.cc \
-		-i ufraw_ufraw.c \
-		-i ufraw_developer.c
-	vsed -i -e '/DATADIRNAME=/s/=.*/=share/' configure
-	vsed -i -e "s,^localedir =.*,localedir = /usr/share/locale," \
-		po/Makefile.in.in
-}
-
-ufraw-gimp_package() {
-	depends="${sourcepkg}>=${version}_${revision}"
-	short_desc+=" - gimp plugin"
-	pkg_install() {
-		vmove usr/lib/gimp
-	}
-}

^ permalink raw reply	[flat|nested] 27+ messages in thread

* Re: exiv2: update to 0.28.0.
  2023-10-23  0:10 [PR PATCH] exiv2: update to 0.28.0 mhmdanas
                   ` (10 preceding siblings ...)
  2023-11-06 20:19 ` mhmdanas
@ 2023-11-06 20:20 ` mhmdanas
  2023-11-12 13:04 ` biopsin
                   ` (13 subsequent siblings)
  25 siblings, 0 replies; 27+ messages in thread
From: mhmdanas @ 2023-11-06 20:20 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 501 bytes --]

New comment by mhmdanas on void-packages repository

https://github.com/void-linux/void-packages/pull/46838#issuecomment-1796369606

Comment:
`nufraw` cross builds fail with a bunch of errors of this form:

```
dcraw.cc:2318:26: error: narrowing conversion of '-39' from 'int' to 'char' [-Wnarrowing]                                    
 2318 |     2,-26, 2,-13, 2,1, 3,-39, 4,16, 5,-55, 6,-76, 6,37                                                               
```

Not sure how to fix them.

^ permalink raw reply	[flat|nested] 27+ messages in thread

* Re: exiv2: update to 0.28.0.
  2023-10-23  0:10 [PR PATCH] exiv2: update to 0.28.0 mhmdanas
                   ` (11 preceding siblings ...)
  2023-11-06 20:20 ` mhmdanas
@ 2023-11-12 13:04 ` biopsin
  2023-11-12 15:01 ` mhmdanas
                   ` (12 subsequent siblings)
  25 siblings, 0 replies; 27+ messages in thread
From: biopsin @ 2023-11-12 13:04 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 1952 bytes --]

New comment by biopsin on void-packages repository

https://github.com/void-linux/void-packages/pull/46838#issuecomment-1807122014

Comment:
@mhmdanas
With nufraw Im hitting a different local issue in regards to the exiv-0.28.x.diff patch, I'll see what I can dig up here

```
nufraw_exiv2.cc: In function 'int nufraw_exif_read_input(nufraw_data*)':
nufraw_exiv2.cc:57:23: error: 'UniquePtr' is not a member of 'Exiv2::Image'
   57 |         Exiv2::Image::UniquePtr image;
      |                       ^~~~~~~~~
nufraw_exiv2.cc:59:13: error: 'image' was not declared in this scope
   59 |             image = Exiv2::ImageFactory::open(
      |             ^~~~~
nufraw_exiv2.cc:63:13: error: 'image' was not declared in this scope
   63 |             image = Exiv2::ImageFactory::open(filename);
      |             ^~~~~
In file included from /usr/include/c++/12.2/cassert:44,
                 from nufraw_exiv2.cc:22:
nufraw_exiv2.cc:66:16: error: 'image' was not declared in this scope
   66 |         assert(image.get() != 0);
      |                ^~~~~
nufraw_exiv2.cc: In function 'Exiv2::ExifData nufraw_prepare_exifdata(nufraw_data*)':
nufraw_exiv2.cc:159:60: error: 'const class Exiv2::Value' has no member named 'toInt64'
  159 |                           pos->key().c_str(), pos->value().toInt64());
      |                                                            ^~~~~~~
nufraw_exiv2.cc: In function 'int nufraw_exif_write(nufraw_data*)':
nufraw_exiv2.cc:350:23: error: 'UniquePtr' is not a member of 'Exiv2::Image'
  350 |         Exiv2::Image::UniquePtr image = Exiv2::ImageFactory::open(filename);
      |                       ^~~~~~~~~
nufraw_exiv2.cc:352:16: error: 'image' was not declared in this scope
  352 |         assert(image.get() != 0);
      |                ^~~~~
make[2]: *** [Makefile:929: nufraw_exiv2.o] Error 1

```

other : Ive succesfully tested exiv2 libgexiv2 gimp-2-10.36

^ permalink raw reply	[flat|nested] 27+ messages in thread

* Re: exiv2: update to 0.28.0.
  2023-10-23  0:10 [PR PATCH] exiv2: update to 0.28.0 mhmdanas
                   ` (12 preceding siblings ...)
  2023-11-12 13:04 ` biopsin
@ 2023-11-12 15:01 ` mhmdanas
  2023-11-12 22:54 ` [PR PATCH] [Updated] " mhmdanas
                   ` (11 subsequent siblings)
  25 siblings, 0 replies; 27+ messages in thread
From: mhmdanas @ 2023-11-12 15:01 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 226 bytes --]

New comment by mhmdanas on void-packages repository

https://github.com/void-linux/void-packages/pull/46838#issuecomment-1807152041

Comment:
@biopsin I already have a fix for that locally, I'll get around to pushing it soon.

^ permalink raw reply	[flat|nested] 27+ messages in thread

* Re: [PR PATCH] [Updated] exiv2: update to 0.28.0.
  2023-10-23  0:10 [PR PATCH] exiv2: update to 0.28.0 mhmdanas
                   ` (13 preceding siblings ...)
  2023-11-12 15:01 ` mhmdanas
@ 2023-11-12 22:54 ` mhmdanas
  2023-11-12 22:55 ` exiv2: update to 0.28.1 mhmdanas
                   ` (10 subsequent siblings)
  25 siblings, 0 replies; 27+ messages in thread
From: mhmdanas @ 2023-11-12 22:54 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 2086 bytes --]

There is an updated pull request by mhmdanas against master on the void-packages repository

https://github.com/mhmdanas/void-packages exiv2-0.28.0
https://github.com/void-linux/void-packages/pull/46838

exiv2: update to 0.28.0.
<!-- Uncomment relevant sections and delete options which are not applicable -->

#### Testing the changes
- I tested the changes in this PR: **briefly**

TODO:
- [x] Fix `gwenview`'s failed checks (not really fixed but the exact same tests fail on master as well)
- [x] `test_exiv2` fails for `libextractor`
- [x] `kfilemetadata5` tests fail (same tests fail on master)
- [ ] Fix `nufraw` cross-build
- [ ] `digikam` fails to build

@Johnnynator ufraw has been [unmaintained since December 2016](https://sourceforge.net/p/ufraw/discussion/434060/thread/30b4249b/), and it doesn't build with this PR; here are the options:
- remove the package entirely
- replace it with the newer [nufraw](https://sourceforge.net/projects/nufraw/), which already has [an exiv 0.28.x patch floating around](https://aur.archlinux.org/cgit/aur.git/tree/exiv2-error.patch?h=nufraw)
- patch it to build with this PR

What do you think? (edit: `nufraw` now replaces `ufraw` in this PR)

<!--
#### New package
- This new package conforms to the [package requirements](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTItest_exiv2NG.md#package-requirements): **YES**|**NO**
-->

<!-- Note: If the build is likely to take more than 2 hours, please add ci skip tag as described in
https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration
and test at least one native build and, if supported, at least one cross build.
Ignore this section if this PR is not skipping CI.
-->
<!--
#### Local build testing
- I built this PR locally for my native architecture, (ARCH-LIBC)
- I built this PR locally for these architectures (if supported. mark crossbuilds):
  - aarch64-musl
  - armv7l
  - armv6l-musl
-->


A patch file from https://github.com/void-linux/void-packages/pull/46838.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-exiv2-0.28.0-46838.patch --]
[-- Type: text/x-diff, Size: 74549 bytes --]

From aaeb758609d3ce7e57de5fbc33b14d3a7aab8bd4 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Mon, 23 Oct 2023 01:20:09 +0100
Subject: [PATCH 01/22] inih: add `libINIReader.so.0` common/shlibs entry.

---
 common/shlibs | 1 +
 1 file changed, 1 insertion(+)

diff --git a/common/shlibs b/common/shlibs
index 64643f5b3c009..dbf46cf4e5c73 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -3903,6 +3903,7 @@ libnotcurses++.so.3 notcurses-3.0.5_1
 libnotcurses-ffi.so.3 notcurses-3.0.5_1
 libevemu.so.3 evemu-2.7.0_1
 libinih.so.0 inih-52_1
+libINIReader.so.0 inih-57_1
 libpcaudio.so.0 pcaudiolib-1.1_1
 libdcerpc-samr.so.0 samba-4.13.2_1
 libdcerpc-server-core.so.0 samba-4.13.2_1

From 6db5d38721969bbb926eb9a01630cbb25dad82a6 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:12 +0100
Subject: [PATCH 02/22] exiv2: update to 0.28.1.

---
 common/shlibs          |  2 +-
 srcpkgs/exiv2/template | 18 +++++++++++-------
 2 files changed, 12 insertions(+), 8 deletions(-)

diff --git a/common/shlibs b/common/shlibs
index dbf46cf4e5c73..b66e4fae5bd59 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -555,7 +555,7 @@ libgimpcolor-2.0.so.0 libgimp-2.10.0_1
 libgimpmodule-2.0.so.0 libgimp-2.10.0_1
 libgmic.so.3 gmic-3.1.6_1
 libcgmic.so.3 gmic-3.1.6_1
-libexiv2.so.27 exiv2-0.27_1
+libexiv2.so.28 exiv2-0.28.0_1
 libKF5Holidays.so.5 kholidays-5.47.0_1
 libPhabricatorHelpers.so.5 purpose-5.48.0_1
 libKF5PurposeWidgets.so.5 purpose-5.48.0_1
diff --git a/srcpkgs/exiv2/template b/srcpkgs/exiv2/template
index 49985fe82cc14..4517906521b4e 100644
--- a/srcpkgs/exiv2/template
+++ b/srcpkgs/exiv2/template
@@ -1,17 +1,17 @@
 # Template file for 'exiv2'
 pkgname=exiv2
-version=0.27.6
+version=0.28.1
 revision=1
 build_style=cmake
 configure_args="-DEXIV2_BUILD_SAMPLES=OFF -DEXIV2_ENABLE_BMFF=ON"
-makedepends="zlib-devel expat-devel"
-checkdepends="gtest-devel"
+makedepends="zlib-devel brotli-devel expat-devel inih-devel"
+checkdepends="gtest-devel python3"
 short_desc="Image metadata manipulation"
 maintainer="Enno Boland <gottox@voidlinux.org>"
 license="GPL-2.0-or-later"
 homepage="https://www.exiv2.org"
-distfiles="https://github.com/Exiv2/exiv2/releases/download/v${version}/exiv2-${version}-Source.tar.gz"
-checksum=4c192483a1125dc59a3d70b30d30d32edace9e14adf52802d2f853abf72db8a6
+distfiles="https://github.com/Exiv2/exiv2/archive/refs/tags/v${version}.zip"
+checksum=eab4c4b919930905e2128c56cb15919cb8105d431ccef8712f98fd4871f3d09a
 
 if [ -n "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DEXIV2_BUILD_UNIT_TESTS=ON"
@@ -21,14 +21,18 @@ if [ -n "$XBPS_CCACHE" ]; then
 	configure_args+=" -DBUILD_WITH_CCACHE=ON"
 fi
 
+pre_check() {
+	# https://github.com/Exiv2/exiv2/issues/2762
+	rm -f tests/bugfixes/github/test_issue_2427.py
+}
+
 exiv2-devel_package() {
 	depends="${makedepends} ${sourcepkg}-${version}_${revision}"
 	short_desc+=" - development files"
 	pkg_install() {
 		vmove usr/include
-		vmove usr/lib/cmake
 		vmove usr/lib/pkgconfig
-		vmove "usr/lib/*.a"
+		vmove usr/share/cmake
 		vmove "usr/lib/*.so"
 	}
 }

From df9d74f0d24db30d53abcb16e516faf42caf9ae1 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:37 +0100
Subject: [PATCH 03/22] ART: revbump for exiv2-0.28.1.

---
 srcpkgs/ART/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/ART/template b/srcpkgs/ART/template
index b6c47fc6c4cdf..94c7aa0378061 100644
--- a/srcpkgs/ART/template
+++ b/srcpkgs/ART/template
@@ -1,7 +1,7 @@
 # Template file for 'ART'
 pkgname=ART
 version=1.20.2
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="pkg-config"
 makedepends="fftw-devel gtkmm-devel lensfun-devel

From d3c6b14f1c43e9bb3974fbf55aa426254e11a897 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 04/22] digikam: revbump for exiv2-0.28.1.

---
 .../patches/fix-build-with-exiv2-0.28.1.patch | 422 ++++++++++++++++++
 srcpkgs/digikam/template                      |   2 +-
 2 files changed, 423 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/digikam/patches/fix-build-with-exiv2-0.28.1.patch

diff --git a/srcpkgs/digikam/patches/fix-build-with-exiv2-0.28.1.patch b/srcpkgs/digikam/patches/fix-build-with-exiv2-0.28.1.patch
new file mode 100644
index 0000000000000..2a01b4545e76d
--- /dev/null
+++ b/srcpkgs/digikam/patches/fix-build-with-exiv2-0.28.1.patch
@@ -0,0 +1,422 @@
+From a76a561b20e7300510b29edc97afab01e381c0ec Mon Sep 17 00:00:00 2001
+From: Maik Qualmann <metzpinguin@gmail.com>
+Date: Wed, 8 Nov 2023 23:13:26 +0100
+Subject: [PATCH 1/5] fix compile with Exiv2-0.28.1 It should still compile
+ even with smaller Exiv2 versions.
+
+---
+ core/CMakeLists.txt                     | 4 ++--
+ core/app/DigikamCoreTarget.cmake        | 2 +-
+ core/cmake/rules/RulesLibExiv2.cmake    | 8 ++++----
+ core/libs/metadataengine/CMakeLists.txt | 4 ++--
+ 4 files changed, 9 insertions(+), 9 deletions(-)
+
+diff --git a/core/CMakeLists.txt b/core/CMakeLists.txt
+index c694c4b176..d5dc2f0dd8 100644
+--- a/core/CMakeLists.txt
++++ b/core/CMakeLists.txt
+@@ -255,7 +255,7 @@ PRINT_COMPONENT_COMPILE_STATUS("Media Player Support"                       ENAB
+ # ==============================================================================
+ 
+ PRINT_LIBRARY_STATUS("libboostgraph" "https://github.com/boostorg/boost"                 "(version >= 1.43.0)"                Boost_FOUND)
+-PRINT_LIBRARY_STATUS("libexiv2"      "https://github.com/Exiv2/exiv2"                    "(version >= ${EXIV2_MIN_VERSION}"   exiv2_FOUND)
++PRINT_LIBRARY_STATUS("libexiv2"      "https://github.com/Exiv2/exiv2"                    "(version >= ${EXIV2_MIN_VERSION}"   LibExiv2_FOUND)
+ PRINT_LIBRARY_STATUS("libexpat"      "https://libexpat.github.io"                        "(version >= 2.0.0)"                 EXPAT_FOUND)
+ PRINT_LIBRARY_STATUS("libjpeg"       "https://github.com/libjpeg-turbo/libjpeg-turbo"    "(version >= 6b)"                    JPEG_FOUND)
+ PRINT_LIBRARY_STATUS("libkde"        "https://invent.kde.org/frameworks/"                "(version >= ${KF5_MIN_VERSION})"    KF5_FOUND)
+@@ -306,7 +306,7 @@ endif()
+ # ==============================================================================
+ 
+ if(Boost_FOUND                          AND
+-   exiv2_FOUND                          AND
++   LibExiv2_FOUND                       AND
+    EXPAT_FOUND                          AND
+    JPEG_FOUND                           AND
+    KF5_FOUND                            AND
+diff --git a/core/app/DigikamCoreTarget.cmake b/core/app/DigikamCoreTarget.cmake
+index 83fda1b35f..8221a2d632 100644
+--- a/core/app/DigikamCoreTarget.cmake
++++ b/core/app/DigikamCoreTarget.cmake
+@@ -151,7 +151,7 @@ target_link_libraries(digikamcore
+                       ${TIFF_LIBRARIES}
+                       PNG::PNG
+                       ${JPEG_LIBRARIES}
+-                      exiv2lib
++                      ${LibExiv2_LIBRARIES}
+ 
+                       ${OPENMP_LDFLAGS}
+ 
+diff --git a/core/cmake/rules/RulesLibExiv2.cmake b/core/cmake/rules/RulesLibExiv2.cmake
+index c8b37d307c..a8ca259432 100644
+--- a/core/cmake/rules/RulesLibExiv2.cmake
++++ b/core/cmake/rules/RulesLibExiv2.cmake
+@@ -4,7 +4,7 @@
+ # SPDX-License-Identifier: BSD-3-Clause
+ #
+ 
+-find_package(exiv2 REQUIRED)
++find_package(LibExiv2 REQUIRED)
+ 
+ set_package_properties("exiv2"     PROPERTIES
+                        DESCRIPTION "Required to build digiKam"
+@@ -13,13 +13,13 @@ set_package_properties("exiv2"     PROPERTIES
+                        PURPOSE     "Library to manage image metadata"
+ )
+ 
+-if("${exiv2_VERSION}" VERSION_LESS ${EXIV2_MIN_VERSION})
++if("${LibExiv2_VERSION}" VERSION_LESS ${EXIV2_MIN_VERSION})
+ 
+-    message(FATAL_ERROR "Exiv2 version is too old (${exiv2_VERSION})! Minimal version required:${EXIV2_MIN_VERSION}.")
++    message(FATAL_ERROR "Exiv2 version is too old (${LibExiv2_VERSION})! Minimal version required:${EXIV2_MIN_VERSION}.")
+ 
+ endif()
+ 
+-if("${exiv2_VERSION}" VERSION_LESS "0.27.99")
++if("${LibExiv2_VERSION}" VERSION_LESS "0.27.99")
+ 
+     set(EXIV2_CXX_STANDARD 11)
+ 
+diff --git a/core/libs/metadataengine/CMakeLists.txt b/core/libs/metadataengine/CMakeLists.txt
+index 47aa889d5e..bd4dba0bbd 100644
+--- a/core/libs/metadataengine/CMakeLists.txt
++++ b/core/libs/metadataengine/CMakeLists.txt
+@@ -18,7 +18,7 @@ endif()
+ 
+ # Exiv2 version < 0.28 use auto_ptr instead unique_ptr which is deprecated.
+ 
+-if("${exiv2_VERSION}" VERSION_LESS "0.27.99")
++if("${LibExiv2_VERSION}" VERSION_LESS "0.27.99")
+ 
+     DISABLE_GCC_COMPILER_WARNINGS("5.99.99" "-Wno-deprecated")
+ 
+@@ -112,7 +112,7 @@ include_directories(
+     $<TARGET_PROPERTY:KF5::ConfigCore,INTERFACE_INCLUDE_DIRECTORIES>
+     $<TARGET_PROPERTY:KF5::I18n,INTERFACE_INCLUDE_DIRECTORIES>
+ 
+-    $<TARGET_PROPERTY:exiv2lib,INTERFACE_INCLUDE_DIRECTORIES>
++    $<TARGET_PROPERTY:LibExiv2_INCLUDE_DIRS>
+ )
+ 
+ # Used by digikamcore
+-- 
+2.42.0
+
+
+From ee487a753a652c588b88fa18aeb885105c17368d Mon Sep 17 00:00:00 2001
+From: Maik Qualmann <metzpinguin@gmail.com>
+Date: Thu, 9 Nov 2023 18:49:18 +0100
+Subject: [PATCH 2/5] recognize both Exiv2 CMake variants
+
+---
+ core/CMakeLists.txt                     | 14 ++++++--
+ core/app/DigikamCoreTarget.cmake        | 17 ++++++++-
+ core/cmake/rules/RulesLibExiv2.cmake    | 46 +++++++++++++++++++++----
+ core/libs/metadataengine/CMakeLists.txt | 12 +++++--
+ 4 files changed, 77 insertions(+), 12 deletions(-)
+
+diff --git a/core/CMakeLists.txt b/core/CMakeLists.txt
+index d5dc2f0dd8..855fdcf185 100644
+--- a/core/CMakeLists.txt
++++ b/core/CMakeLists.txt
+@@ -255,7 +255,17 @@ PRINT_COMPONENT_COMPILE_STATUS("Media Player Support"                       ENAB
+ # ==============================================================================
+ 
+ PRINT_LIBRARY_STATUS("libboostgraph" "https://github.com/boostorg/boost"                 "(version >= 1.43.0)"                Boost_FOUND)
+-PRINT_LIBRARY_STATUS("libexiv2"      "https://github.com/Exiv2/exiv2"                    "(version >= ${EXIV2_MIN_VERSION}"   LibExiv2_FOUND)
++
++if(LibExiv2_FOUND)
++
++    PRINT_LIBRARY_STATUS("libexiv2"  "https://github.com/Exiv2/exiv2"                    "(version >= ${EXIV2_MIN_VERSION}"   LibExiv2_FOUND)
++
++else()
++
++    PRINT_LIBRARY_STATUS("libexiv2"  "https://github.com/Exiv2/exiv2"                    "(version >= ${EXIV2_MIN_VERSION}"   exiv2_FOUND)
++
++endif()
++
+ PRINT_LIBRARY_STATUS("libexpat"      "https://libexpat.github.io"                        "(version >= 2.0.0)"                 EXPAT_FOUND)
+ PRINT_LIBRARY_STATUS("libjpeg"       "https://github.com/libjpeg-turbo/libjpeg-turbo"    "(version >= 6b)"                    JPEG_FOUND)
+ PRINT_LIBRARY_STATUS("libkde"        "https://invent.kde.org/frameworks/"                "(version >= ${KF5_MIN_VERSION})"    KF5_FOUND)
+@@ -306,7 +316,7 @@ endif()
+ # ==============================================================================
+ 
+ if(Boost_FOUND                          AND
+-   LibExiv2_FOUND                       AND
++   (LibExiv2_FOUND OR exiv2_FOUND)      AND
+    EXPAT_FOUND                          AND
+    JPEG_FOUND                           AND
+    KF5_FOUND                            AND
+diff --git a/core/app/DigikamCoreTarget.cmake b/core/app/DigikamCoreTarget.cmake
+index 8221a2d632..80bd153caa 100644
+--- a/core/app/DigikamCoreTarget.cmake
++++ b/core/app/DigikamCoreTarget.cmake
+@@ -151,7 +151,6 @@ target_link_libraries(digikamcore
+                       ${TIFF_LIBRARIES}
+                       PNG::PNG
+                       ${JPEG_LIBRARIES}
+-                      ${LibExiv2_LIBRARIES}
+ 
+                       ${OPENMP_LDFLAGS}
+ 
+@@ -164,6 +163,22 @@ target_link_libraries(digikamcore
+                       opencv_flann
+ )
+ 
++if(LibExiv2_FOUND)
++
++    target_link_libraries(digikamcore
++                          PRIVATE
++                          ${LibExiv2_LIBRARIES}
++    )
++
++else()
++
++    target_link_libraries(digikamcore
++                          PRIVATE
++                          exiv2lib
++    )
++
++endif()
++
+ if(Qt6_FOUND)
+     target_link_libraries(digikamcore
+                           PRIVATE
+diff --git a/core/cmake/rules/RulesLibExiv2.cmake b/core/cmake/rules/RulesLibExiv2.cmake
+index a8ca259432..e568644ca4 100644
+--- a/core/cmake/rules/RulesLibExiv2.cmake
++++ b/core/cmake/rules/RulesLibExiv2.cmake
+@@ -4,7 +4,17 @@
+ # SPDX-License-Identifier: BSD-3-Clause
+ #
+ 
+-find_package(LibExiv2 REQUIRED)
++find_package(LibExiv2 OPTIONAL_COMPONENTS)
++
++if(LibExiv2_FOUND)
++
++    find_package(LibExiv2 REQUIRED)
++
++else()
++
++    find_package(exiv2 REQUIRED)
++
++endif()
+ 
+ set_package_properties("exiv2"     PROPERTIES
+                        DESCRIPTION "Required to build digiKam"
+@@ -13,18 +23,40 @@ set_package_properties("exiv2"     PROPERTIES
+                        PURPOSE     "Library to manage image metadata"
+ )
+ 
+-if("${LibExiv2_VERSION}" VERSION_LESS ${EXIV2_MIN_VERSION})
++if(LibExiv2_FOUND)
+ 
+-    message(FATAL_ERROR "Exiv2 version is too old (${LibExiv2_VERSION})! Minimal version required:${EXIV2_MIN_VERSION}.")
++    if("${LibExiv2_VERSION}" VERSION_LESS ${EXIV2_MIN_VERSION})
+ 
+-endif()
++        message(FATAL_ERROR "Exiv2 version is too old (${LibExiv2_VERSION})! Minimal version required:${EXIV2_MIN_VERSION}.")
++
++    endif()
++
++    if("${LibExiv2_VERSION}" VERSION_LESS "0.27.99")
+ 
+-if("${LibExiv2_VERSION}" VERSION_LESS "0.27.99")
++        set(EXIV2_CXX_STANDARD 11)
+ 
+-    set(EXIV2_CXX_STANDARD 11)
++    else()
++
++        set(EXIV2_CXX_STANDARD 17)
++
++    endif()
+ 
+ else()
+ 
+-    set(EXIV2_CXX_STANDARD 17)
++    if("${exiv2_VERSION}" VERSION_LESS ${EXIV2_MIN_VERSION})
++
++        message(FATAL_ERROR "Exiv2 version is too old (${exiv2_VERSION})! Minimal version required:${EXIV2_MIN_VERSION}.")
++
++    endif()
++
++    if("${exiv2_VERSION}" VERSION_LESS "0.27.99")
++
++        set(EXIV2_CXX_STANDARD 11)
++
++    else()
++
++        set(EXIV2_CXX_STANDARD 17)
++
++    endif()
+ 
+ endif()
+diff --git a/core/libs/metadataengine/CMakeLists.txt b/core/libs/metadataengine/CMakeLists.txt
+index bd4dba0bbd..a4124d17e0 100644
+--- a/core/libs/metadataengine/CMakeLists.txt
++++ b/core/libs/metadataengine/CMakeLists.txt
+@@ -111,10 +111,18 @@ include_directories(
+ 
+     $<TARGET_PROPERTY:KF5::ConfigCore,INTERFACE_INCLUDE_DIRECTORIES>
+     $<TARGET_PROPERTY:KF5::I18n,INTERFACE_INCLUDE_DIRECTORIES>
+-
+-    $<TARGET_PROPERTY:LibExiv2_INCLUDE_DIRS>
+ )
+ 
++if(LibExiv2_FOUND)
++
++    include_directories($<TARGET_PROPERTY:LibExiv2_INCLUDE_DIRS>)
++
++else()
++
++    include_directories($<TARGET_PROPERTY:exiv2lib,INTERFACE_INCLUDE_DIRECTORIES>)
++
++endif()
++
+ # Used by digikamcore
+ add_library(core_dmetadata_obj OBJECT ${libdmetadata_SRCS})
+ 
+-- 
+2.42.0
+
+
+From af221dd7700fbf1e6e3b5245184381d2b74ec781 Mon Sep 17 00:00:00 2001
+From: Maik Qualmann <metzpinguin@gmail.com>
+Date: Thu, 9 Nov 2023 19:12:44 +0100
+Subject: [PATCH 3/5] check version und clear LibExiv2_FOUND
+
+---
+ core/cmake/rules/RulesLibExiv2.cmake | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+diff --git a/core/cmake/rules/RulesLibExiv2.cmake b/core/cmake/rules/RulesLibExiv2.cmake
+index e568644ca4..de5ea80ec6 100644
+--- a/core/cmake/rules/RulesLibExiv2.cmake
++++ b/core/cmake/rules/RulesLibExiv2.cmake
+@@ -6,12 +6,13 @@
+ 
+ find_package(LibExiv2 OPTIONAL_COMPONENTS)
+ 
+-if(LibExiv2_FOUND)
++if(LibExiv2_FOUND AND ("${LibExiv2_VERSION}" VERSION_GREATER "0.28.0"))
+ 
+     find_package(LibExiv2 REQUIRED)
+ 
+ else()
+ 
++    set (LibExiv2_FOUND FALSE)
+     find_package(exiv2 REQUIRED)
+ 
+ endif()
+-- 
+2.42.0
+
+
+From fda83a6f7e03e4088f3a5903d036c1425d6303b9 Mon Sep 17 00:00:00 2001
+From: Maik Qualmann <metzpinguin@gmail.com>
+Date: Thu, 9 Nov 2023 19:15:41 +0100
+Subject: [PATCH 4/5] adjust Exiv2 version
+
+---
+ core/cmake/rules/RulesLibExiv2.cmake | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/core/cmake/rules/RulesLibExiv2.cmake b/core/cmake/rules/RulesLibExiv2.cmake
+index de5ea80ec6..3db233cad2 100644
+--- a/core/cmake/rules/RulesLibExiv2.cmake
++++ b/core/cmake/rules/RulesLibExiv2.cmake
+@@ -6,7 +6,7 @@
+ 
+ find_package(LibExiv2 OPTIONAL_COMPONENTS)
+ 
+-if(LibExiv2_FOUND AND ("${LibExiv2_VERSION}" VERSION_GREATER "0.28.0"))
++if(LibExiv2_FOUND AND ("${LibExiv2_VERSION}" VERSION_GREATER "0.27.99"))
+ 
+     find_package(LibExiv2 REQUIRED)
+ 
+-- 
+2.42.0
+
+
+From 921ee9945f8c438f23b83add58d5737b539cd312 Mon Sep 17 00:00:00 2001
+From: Maik Qualmann <metzpinguin@gmail.com>
+Date: Thu, 9 Nov 2023 21:35:09 +0100
+Subject: [PATCH 5/5] set correct exiv2 package name and less duplicate CMake
+ code
+
+---
+ core/cmake/rules/RulesLibExiv2.cmake | 34 +++++++++++-----------------
+ 1 file changed, 13 insertions(+), 21 deletions(-)
+
+diff --git a/core/cmake/rules/RulesLibExiv2.cmake b/core/cmake/rules/RulesLibExiv2.cmake
+index 3db233cad2..e3e667d946 100644
+--- a/core/cmake/rules/RulesLibExiv2.cmake
++++ b/core/cmake/rules/RulesLibExiv2.cmake
+@@ -9,19 +9,21 @@ find_package(LibExiv2 OPTIONAL_COMPONENTS)
+ if(LibExiv2_FOUND AND ("${LibExiv2_VERSION}" VERSION_GREATER "0.27.99"))
+ 
+     find_package(LibExiv2 REQUIRED)
++    set(EXIV2_PACKAGE_NAME "LibExiv2")
+ 
+ else()
+ 
+-    set (LibExiv2_FOUND FALSE)
++    set(LibExiv2_FOUND FALSE)
+     find_package(exiv2 REQUIRED)
++    set(EXIV2_PACKAGE_NAME "exiv2")
+ 
+ endif()
+ 
+-set_package_properties("exiv2"     PROPERTIES
+-                       DESCRIPTION "Required to build digiKam"
+-                       URL         "https://www.exiv2.org"
+-                       TYPE        RECOMMENDED
+-                       PURPOSE     "Library to manage image metadata"
++set_package_properties(${EXIV2_PACKAGE_NAME} PROPERTIES
++                       DESCRIPTION           "Required to build digiKam"
++                       URL                   "https://www.exiv2.org"
++                       TYPE                  RECOMMENDED
++                       PURPOSE               "Library to manage image metadata"
+ )
+ 
+ if(LibExiv2_FOUND)
+@@ -32,16 +34,6 @@ if(LibExiv2_FOUND)
+ 
+     endif()
+ 
+-    if("${LibExiv2_VERSION}" VERSION_LESS "0.27.99")
+-
+-        set(EXIV2_CXX_STANDARD 11)
+-
+-    else()
+-
+-        set(EXIV2_CXX_STANDARD 17)
+-
+-    endif()
+-
+ else()
+ 
+     if("${exiv2_VERSION}" VERSION_LESS ${EXIV2_MIN_VERSION})
+@@ -50,14 +42,14 @@ else()
+ 
+     endif()
+ 
+-    if("${exiv2_VERSION}" VERSION_LESS "0.27.99")
++endif()
+ 
+-        set(EXIV2_CXX_STANDARD 11)
++if(("${exiv2_VERSION}" VERSION_GREATER "0.27.99") OR ("${LibExiv2_VERSION}" VERSION_GREATER "0.27.99"))
+ 
+-    else()
++    set(EXIV2_CXX_STANDARD 17)
+ 
+-        set(EXIV2_CXX_STANDARD 17)
++else()
+ 
+-    endif()
++    set(EXIV2_CXX_STANDARD 11)
+ 
+ endif()
+-- 
+2.42.0
+
diff --git a/srcpkgs/digikam/template b/srcpkgs/digikam/template
index 206185f565488..4784bf7d62a8e 100644
--- a/srcpkgs/digikam/template
+++ b/srcpkgs/digikam/template
@@ -1,7 +1,7 @@
 # Template file for 'digikam'
 pkgname=digikam
 version=8.1.0
-revision=1
+revision=2
 build_style=cmake
 configure_args="-DBUILD_TESTING=OFF"
 hostmakedepends="extra-cmake-modules gettext pkg-config bison flex qt5-qmake

From 942d196a1a1c81893556903d20789fcebbd7a6fe Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 05/22] geeqie: revbump for exiv2-0.28.1.

---
 srcpkgs/geeqie/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/geeqie/template b/srcpkgs/geeqie/template
index b5f958f854c1b..b494bc149e957 100644
--- a/srcpkgs/geeqie/template
+++ b/srcpkgs/geeqie/template
@@ -1,7 +1,7 @@
 # Template file for 'geeqie'
 pkgname=geeqie
 version=2.1
-revision=1
+revision=2
 build_style=meson
 hostmakedepends="pkg-config gettext xxd gdk-pixbuf-devel glib-devel"
 makedepends="gtk+3-devel glib-devel lcms2-devel exiv2-devel libheif-devel

From aaf8aae2857a413bfe47996df01eaa6a44b53e21 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 06/22] gthumb: revbump for exiv2-0.28.1.

---
 srcpkgs/gthumb/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/gthumb/template b/srcpkgs/gthumb/template
index c8e19f0dedb61..732d5e1c6089f 100644
--- a/srcpkgs/gthumb/template
+++ b/srcpkgs/gthumb/template
@@ -1,7 +1,7 @@
 # Template file for 'gthumb'
 pkgname=gthumb
 version=3.12.3
-revision=1
+revision=2
 build_style=meson
 hostmakedepends="gettext pkg-config itstool glib-devel"
 makedepends="webkit2gtk-devel json-glib-devel libsecret-devel librsvg-devel

From 9ad2b53c4de3b8131c01f603e8d85fc730376d22 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 07/22] gwenview: revbump for exiv2-0.28.1.

---
 srcpkgs/gwenview/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/gwenview/template b/srcpkgs/gwenview/template
index 1a9978f384084..c6ec9494eb067 100644
--- a/srcpkgs/gwenview/template
+++ b/srcpkgs/gwenview/template
@@ -1,7 +1,7 @@
 # Template file for 'gwenview'
 pkgname=gwenview
 version=23.08.3
-revision=1
+revision=2
 build_style=cmake
 build_helper=qemu
 hostmakedepends="extra-cmake-modules pkg-config qt5-qmake qt5-host-tools

From 5861d97c17050927f2f44d8bb6fbb01de63e805f Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 08/22] hugin: revbump for exiv2-0.28.1.

---
 srcpkgs/hugin/patches/exiv2-0.28.patch | 77 ++++++++++++++++++++++++++
 1 file changed, 77 insertions(+)
 create mode 100644 srcpkgs/hugin/patches/exiv2-0.28.patch

diff --git a/srcpkgs/hugin/patches/exiv2-0.28.patch b/srcpkgs/hugin/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..49f0518117020
--- /dev/null
+++ b/srcpkgs/hugin/patches/exiv2-0.28.patch
@@ -0,0 +1,77 @@
+Patch-Source: https://gitlab.archlinux.org/archlinux/packaging/packages/hugin/-/blob/main/exiv2-0.28.patch
+diff -r 79cd11a7a66f src/hugin_base/panodata/Exiv2Helper.cpp
+--- a/src/hugin_base/panodata/Exiv2Helper.cpp	Wed May 24 19:13:20 2023 +0200
++++ b/src/hugin_base/panodata/Exiv2Helper.cpp	Mon Jun 05 00:31:19 2023 +0200
+@@ -40,7 +40,7 @@
+             Exiv2::ExifData::iterator itr = exifData.findKey(Exiv2::ExifKey(keyName));
+             if (itr != exifData.end() && itr->count())
+             {
+-                value = itr->toLong();
++                value = itr->toUint32();
+                 return true;
+             }
+             else
+@@ -165,7 +165,7 @@
+         {
+             if(it!=exifData.end() && it->count())
+             {
+-                return it->toLong();
++                return it->toUint32();
+             }
+             return 0;
+         };
+@@ -600,4 +600,4 @@
+         };
+ 
+     }; //namespace Exiv2Helper
+-}; //namespace HuginBase
+\ No newline at end of file
++}; //namespace HuginBase
+diff -r 79cd11a7a66f src/hugin_base/panodata/SrcPanoImage.cpp
+--- a/src/hugin_base/panodata/SrcPanoImage.cpp	Wed May 24 19:13:20 2023 +0200
++++ b/src/hugin_base/panodata/SrcPanoImage.cpp	Mon Jun 05 00:31:19 2023 +0200
+@@ -384,7 +384,7 @@
+                     pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaImageWidthPixels"));
+                     if (pos != xmpData.end())
+                     {
+-                        croppedWidth = pos->toLong();
++                        croppedWidth = pos->toUint32();
+                     }
+                     else
+                     {
+@@ -394,7 +394,7 @@
+                     pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaImageHeightPixels"));
+                     if (pos != xmpData.end())
+                     {
+-                        croppedHeight = pos->toLong();
++                        croppedHeight = pos->toUint32();
+                     }
+                     else
+                     {
+@@ -408,7 +408,7 @@
+                         double hfov = 0;
+                         if (pos != xmpData.end())
+                         {
+-                            hfov = 360 * croppedWidth / (double)pos->toLong();
++                            hfov = 360 * croppedWidth / (double)pos->toUint32();
+                         }
+                         else
+                         {
+@@ -419,7 +419,7 @@
+                         pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.FullPanoHeightPixels"));
+                         if (pos != xmpData.end())
+                         {
+-                            fullHeight = pos->toLong();
++                            fullHeight = pos->toUint32();
+                         }
+                         else
+                         {
+@@ -430,7 +430,7 @@
+                         pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaTopPixels"));
+                         if (pos != xmpData.end())
+                         {
+-                            cropTop = pos->toLong();
++                            cropTop = pos->toUint32();
+                         }
+                         else
+                         {

From 5e215295607efabc5e50a33a1bad57012db7442d Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 09/22] kfilemetadata5: revbump for exiv2-0.28.1.

---
 srcpkgs/kfilemetadata5/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/kfilemetadata5/template b/srcpkgs/kfilemetadata5/template
index 00f7a98cf6399..e294ae5af947c 100644
--- a/srcpkgs/kfilemetadata5/template
+++ b/srcpkgs/kfilemetadata5/template
@@ -1,7 +1,7 @@
 # Template file for 'kfilemetadata5'
 pkgname=kfilemetadata5
 version=5.111.0
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="kcoreaddons extra-cmake-modules pkg-config qt5-host-tools qt5-qmake
  gettext kcoreaddons python3"

From 76e5b4bad03acfa67bffc2eb09cac944e7bdaaf2 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 10/22] krename: revbump for exiv2-0.28.1.

---
 srcpkgs/krename/patches/e7dd767a.patch | 90 ++++++++++++++++++++++++++
 srcpkgs/krename/template               |  2 +-
 2 files changed, 91 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/krename/patches/e7dd767a.patch

diff --git a/srcpkgs/krename/patches/e7dd767a.patch b/srcpkgs/krename/patches/e7dd767a.patch
new file mode 100644
index 0000000000000..a0ef428ce46b1
--- /dev/null
+++ b/srcpkgs/krename/patches/e7dd767a.patch
@@ -0,0 +1,90 @@
+Patch-Source: https://invent.kde.org/utilities/krename/-/commit/e7dd767a
+From e7dd767a9a1068ee1fe1502c4d619b57d3b12add Mon Sep 17 00:00:00 2001
+From: Andreas Sturmlechner <asturm@gentoo.org>
+Date: Fri, 26 May 2023 23:23:10 +0200
+Subject: [PATCH] Fix build with >=exiv2-0.28, raise minimum to 0.27
+
+- enables use of EXIV2_TEST_VERSION macro
+- exiv2 headers cleanup
+
+Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>
+---
+ CMakeLists.txt         |  6 +-----
+ config-krename.h.cmake |  3 ---
+ src/exiv2plugin.cpp    | 17 +++++------------
+ 3 files changed, 6 insertions(+), 20 deletions(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 0bda8ac..72e7297 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -56,13 +56,9 @@ set_package_properties(Taglib PROPERTIES
+     TYPE OPTIONAL)
+ 
+ # Find exiv2
+-find_package(LibExiv2 0.13) # AccessMode was added in 0.13
++find_package(LibExiv2 0.27) # EXIV2_TEST_VERSION was added in 0.27
+ set_package_properties(LibExiv2 PROPERTIES TYPE OPTIONAL)
+ 
+-if (LibExiv2_VERSION VERSION_GREATER_EQUAL "0.27")
+-    set(HAVE_LIBEXIV2_0_27 TRUE)
+-endif()
+-
+ # Find podofo
+ find_package(PoDoFo)
+ set_package_properties(PoDoFo PROPERTIES
+diff --git a/config-krename.h.cmake b/config-krename.h.cmake
+index 76c3d30..862e40b 100644
+--- a/config-krename.h.cmake
++++ b/config-krename.h.cmake
+@@ -6,9 +6,6 @@
+ /* have Exiv2 */
+ #cmakedefine01 HAVE_EXIV2
+ 
+-/* Defined if we have libexiv2 >= 0.27 */
+-#cmakedefine HAVE_LIBEXIV2_0_27
+-
+ /* have PoDoFo */
+ #cmakedefine01 HAVE_PODOFO
+ 
+diff --git a/src/exiv2plugin.cpp b/src/exiv2plugin.cpp
+index 5694d8c..25e8869 100644
+--- a/src/exiv2plugin.cpp
++++ b/src/exiv2plugin.cpp
+@@ -3,20 +3,9 @@
+ 
+ #include "exiv2plugin.h"
+ 
+-#include "../config-krename.h"
+-
+ #include <KLocalizedString>
+ 
+-#include <exiv2/error.hpp>
+-#include <exiv2/exif.hpp>
+-#include <exiv2/image.hpp>
+-#include <exiv2/iptc.hpp>
+-#ifdef HAVE_LIBEXIV2_0_27
+-    #include <exiv2/xmp_exiv2.hpp>
+-#else
+-    #include <exiv2/xmp.hpp>
+-#endif
+-#include <exiv2/tags.hpp>
++#include <exiv2/exiv2.hpp>
+ 
+ #include "batchrenamer.h"
+ #include "tokenhelpdialog.h"
+@@ -381,7 +370,11 @@ QString Exiv2Plugin::processFile(BatchRenamer *b, int index, const QString &file
+     std::string strFilename(asc.constData(), asc.length());
+ 
+     try {
++#if EXIV2_TEST_VERSION(0,28,0)
++        Image::UniquePtr image = Exiv2::ImageFactory::open(strFilename);
++#else
+         Image::AutoPtr image = Exiv2::ImageFactory::open(strFilename);
++#endif
+         if (image.get() != nullptr && image->good()) {
+             image->readMetadata();
+ 
+-- 
+GitLab
+
diff --git a/srcpkgs/krename/template b/srcpkgs/krename/template
index 66023163e3293..df5535007714a 100644
--- a/srcpkgs/krename/template
+++ b/srcpkgs/krename/template
@@ -1,7 +1,7 @@
 # Template file for 'krename'
 pkgname=krename
 version=5.0.2
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="extra-cmake-modules gettext kcoreaddons pkg-config qt5-host-tools qt5-qmake"
 makedepends="exiv2-devel freetype-devel kjs-devel kparts-devel libpodofo-devel

From 60d47ce5c1307f3122e1e4db60db05dee81423a9 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 11/22] libextractor: revbump for exiv2-0.28.1.

---
 srcpkgs/libextractor/patches/exiv2-0.28.patch | 286 ++++++++++++++++++
 srcpkgs/libextractor/patches/fix-tests.diff   |  24 ++
 2 files changed, 310 insertions(+)
 create mode 100644 srcpkgs/libextractor/patches/exiv2-0.28.patch
 create mode 100644 srcpkgs/libextractor/patches/fix-tests.diff

diff --git a/srcpkgs/libextractor/patches/exiv2-0.28.patch b/srcpkgs/libextractor/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..270a626d8ab06
--- /dev/null
+++ b/srcpkgs/libextractor/patches/exiv2-0.28.patch
@@ -0,0 +1,286 @@
+Patch-Source: https://gitlab.archlinux.org/archlinux/packaging/packages/libextractor/-/blob/main/exiv2-0.28.patch
+diff --git a/src/plugins/exiv2_extractor.cc b/src/plugins/exiv2_extractor.cc
+index 78f9bda..d32ed6a 100644
+--- a/src/plugins/exiv2_extractor.cc
++++ b/src/plugins/exiv2_extractor.cc
+@@ -90,7 +90,11 @@ virtual int close ();
+  * @param rcount number of bytes to read
+  * @return buffer with data read, empty buffer (!) on failure (!)
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++virtual Exiv2::DataBuf read (size_t rcount);
++#else
+ virtual Exiv2::DataBuf read (long rcount);
++#endif
+ 
+ /**
+  * Read up to 'rcount' bytes into 'buf'.
+@@ -99,8 +103,17 @@ virtual Exiv2::DataBuf read (long rcount);
+  * @param rcount size of 'buf'
+  * @return number of bytes read successfully, 0 on failure (!)
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++virtual size_t read (Exiv2::byte *buf,
++                   size_t rcount);
++#else
+ virtual long read (Exiv2::byte *buf,
+                    long rcount);
++#endif
++
++#if EXIV2_TEST_VERSION (0,28,0)
++virtual void populateFakeData();
++#endif
+ 
+ /**
+  * Read a single character.
+@@ -117,8 +130,13 @@ virtual int getb ();
+  * @param wcount how many bytes to write
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual size_t write (const Exiv2::byte *data,
++                    size_t wcount);
++#else
+ virtual long write (const Exiv2::byte *data,
+                     long wcount);
++#endif
+ 
+ /**
+  * Write to stream.
+@@ -126,7 +144,11 @@ virtual long write (const Exiv2::byte *data,
+  * @param src stream to copy
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual size_t write (Exiv2::BasicIo &src);
++#else
+ virtual long write (Exiv2::BasicIo &src);
++#endif
+ 
+ /**
+  * Write a single byte.
+@@ -172,7 +194,11 @@ virtual int munmap ();
+  *
+  * @return -1 on error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual size_t tell (void) const;
++#else
+ virtual long int tell (void) const;
++#endif
+ 
+ /**
+  * Return overall size of the file.
+@@ -213,7 +239,11 @@ virtual bool eof () const;
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual const std::string& path () const noexcept;
++#else
+ virtual std::string path () const;
++#endif
+ 
+ #ifdef EXV_UNICODE_PATH
+ /**
+@@ -230,7 +260,11 @@ virtual std::wstring wpath () const;
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual Exiv2::BasicIo::UniquePtr temporary () const;
++#else
+ virtual Exiv2::BasicIo::AutoPtr temporary () const;
++#endif
+ 
+ };
+ 
+@@ -266,7 +300,11 @@ ExtractorIO::close ()
+  * @return buffer with data read, empty buffer (!) on failure (!)
+  */
+ Exiv2::DataBuf
++#if EXIV2_TEST_VERSION (0,28,0)
++ExtractorIO::read (size_t rcount)
++#else
+ ExtractorIO::read (long rcount)
++#endif
+ {
+   void *data;
+   ssize_t ret;
+@@ -284,9 +322,15 @@ ExtractorIO::read (long rcount)
+  * @param rcount size of 'buf'
+  * @return number of bytes read successfully, 0 on failure (!)
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++size_t
++ExtractorIO::read (Exiv2::byte *buf,
++                   size_t rcount)
++#else
+ long
+ ExtractorIO::read (Exiv2::byte *buf,
+                    long rcount)
++#endif
+ {
+   void *data;
+   ssize_t ret;
+@@ -305,6 +349,12 @@ ExtractorIO::read (Exiv2::byte *buf,
+   return got;
+ }
+ 
++#if EXIV2_TEST_VERSION (0,28,0)
++void ExtractorIO::populateFakeData()
++{
++  return;
++}
++#endif
+ 
+ /**
+  * Read a single character.
+@@ -319,7 +369,9 @@ ExtractorIO::getb ()
+   const unsigned char *r;
+ 
+   if (1 != ec->read (ec->cls, &data, 1))
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION(0,28,0)
++    throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+     throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+     throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -336,9 +388,15 @@ ExtractorIO::getb ()
+  * @param wcount how many bytes to write
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++size_t
++ExtractorIO::write (const Exiv2::byte *data,
++                    size_t wcount)
++#else
+ long
+ ExtractorIO::write (const Exiv2::byte *data,
+                     long wcount)
++#endif
+ {
+   return -1;
+ }
+@@ -350,7 +408,11 @@ ExtractorIO::write (const Exiv2::byte *data,
+  * @param src stream to copy
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++size_t
++#else
+ long
++#endif
+ ExtractorIO::write (Exiv2::BasicIo &src)
+ {
+   return -1;
+@@ -378,7 +440,9 @@ ExtractorIO::putb (Exiv2::byte data)
+ void
+ ExtractorIO::transfer (Exiv2::BasicIo& src)
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION(0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -427,7 +491,9 @@ ExtractorIO::seek (long offset,
+ Exiv2::byte *
+ ExtractorIO::mmap (bool isWritable)
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION (0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -452,7 +518,11 @@ ExtractorIO::munmap ()
+  *
+  * @return -1 on error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++size_t
++#else
+ long int
++#endif
+ ExtractorIO::tell (void) const
+ {
+   return (long) ec->seek (ec->cls, 0, SEEK_CUR);
+@@ -516,10 +586,17 @@ ExtractorIO::eof () const
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++const std::string&
++ExtractorIO::path () const noexcept
++#else
+ std::string
+ ExtractorIO::path () const
++#endif
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION (0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -536,7 +613,9 @@ ExtractorIO::path () const
+ std::wstring
+ ExtractorIO::wpath () const
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION (0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -552,11 +631,17 @@ ExtractorIO::wpath () const
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++Exiv2::BasicIo::UniquePtr
++#else
+ Exiv2::BasicIo::AutoPtr
++#endif
+ ExtractorIO::temporary () const
+ {
+   fprintf (stderr, "throwing temporary error\n");
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION(0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -737,8 +822,13 @@ EXTRACTOR_exiv2_extract_method (struct EXTRACTOR_ExtractContext *ec)
+ #if ! EXIV2_TEST_VERSION (0,24,0)
+     Exiv2::LogMsg::setLevel (Exiv2::LogMsg::mute);
+ #endif
++#if EXIV2_TEST_VERSION(0,28,0)
++    std::unique_ptr<Exiv2::BasicIo> eio (new ExtractorIO (ec));
++    Exiv2::Image::UniquePtr image = Exiv2::ImageFactory::open (std::move(eio));
++#else
+     std::auto_ptr<Exiv2::BasicIo> eio (new ExtractorIO (ec));
+     Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open (eio);
++#endif
+     if (0 == image.get ())
+       return;
+     image->readMetadata ();
+@@ -822,7 +912,11 @@ EXTRACTOR_exiv2_extract_method (struct EXTRACTOR_ExtractContext *ec)
+       ADDXMP ("Xmp.lr.hierarchicalSubject", EXTRACTOR_METATYPE_SUBJECT);
+     }
+   }
++#if EXIV2_TEST_VERSION (0,28,0)
++  catch (const Exiv2::Error& e)
++#else
+   catch (const Exiv2::AnyError& e)
++#endif
+   {
+ #if DEBUG
+     std::cerr << "Caught Exiv2 exception '" << e << "'\n";
diff --git a/srcpkgs/libextractor/patches/fix-tests.diff b/srcpkgs/libextractor/patches/fix-tests.diff
new file mode 100644
index 0000000000000..3b4ee7cbeea33
--- /dev/null
+++ b/srcpkgs/libextractor/patches/fix-tests.diff
@@ -0,0 +1,24 @@
+--- a/src/plugins/test_exiv2.c	2021-01-30 13:20:23.000000000 +0000
++++ b/src/plugins/test_exiv2.c	2023-11-03 19:39:43.115274492 +0000
+@@ -49,8 +49,8 @@
+       EXTRACTOR_METATYPE_GPS_LATITUDE,
+       EXTRACTOR_METAFORMAT_UTF8,
+       "text/plain",
+-      "28deg 8' (18|17.585)\" ?",
+-      strlen ("28deg 8' (18|17.585)\" ?") + 1,
++      "28 deg 8' (18|17.58)\" ?",
++      strlen ("28 deg 8' (18|17.58)\" ?") + 1,
+       0,
+       .regex = 1
+     },
+@@ -66,8 +66,8 @@
+       EXTRACTOR_METATYPE_GPS_LONGITUDE,
+       EXTRACTOR_METAFORMAT_UTF8,
+       "text/plain",
+-      "14deg 14' (22|21.713)\" ?",
+-      strlen ("14deg 14' (22|21.713)\" ?"),
++      "14 deg 14' (22|21.71)\" ?",
++      strlen ("14 deg 14' (22|21.71)\" ?"),
+       0,
+       .regex = 1
+     },

From 3c06fcc741eaa9f39e7b1da894f74ee3ca132c5d Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 12/22] libgexiv2: update to 0.14.2.

---
 srcpkgs/libgexiv2/template | 14 +++++++-------
 1 file changed, 7 insertions(+), 7 deletions(-)

diff --git a/srcpkgs/libgexiv2/template b/srcpkgs/libgexiv2/template
index 23780e5397dc4..91dbcaa9aca52 100644
--- a/srcpkgs/libgexiv2/template
+++ b/srcpkgs/libgexiv2/template
@@ -1,19 +1,19 @@
 # Template file for 'libgexiv2'
 pkgname=libgexiv2
-version=0.14.0
-revision=3
+version=0.14.2
+revision=1
 build_style=meson
 build_helper="gir"
-configure_args="-Dintrospection=$(vopt_if gir true false)
- -Dvapi=$(vopt_if vala true false)"
+configure_args="$(vopt_bool gir introspection) $(vopt_bool vala vapi)"
 hostmakedepends="pkg-config glib-devel $(vopt_if vala 'vala') python3-gobject"
 makedepends="libglib-devel exiv2-devel"
 short_desc="GObject-based wrapper around the Exiv2 library"
 maintainer="Enno Boland <gottox@voidlinux.org>"
 license="GPL-2.0-or-later"
 homepage="https://wiki.gnome.org/Projects/gexiv2"
-distfiles="${GNOME_SITE}/gexiv2/${version%.*}/${pkgname/lib/}-${version}.tar.xz"
-checksum=e58279a6ff20b6f64fa499615da5e9b57cf65ba7850b72fafdf17221a9d6d69e
+changelog="https://gitlab.gnome.org/GNOME/gexiv2/-/raw/master/NEWS"
+distfiles="${GNOME_SITE}/gexiv2/${version%.*}/gexiv2-${version}.tar.xz"
+checksum=2a0c9cf48fbe8b3435008866ffd40b8eddb0667d2212b42396fdf688e93ce0be
 
 build_options="gir vala"
 build_options_default="gir vala"
@@ -23,7 +23,7 @@ libgexiv2-devel_package() {
 	short_desc+=" - development files"
 	pkg_install() {
 		vmove usr/include
-		vmove usr/lib/*.so
+		vmove "usr/lib/*.so"
 		vmove usr/lib/pkgconfig
 		if [ "$build_option_vala" ]; then
 			vmove usr/share/vala

From 655a0dfadb452edfadb2982eb221958c3bc0eac5 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 13/22] libkexiv25: update to 23.08.2.

---
 srcpkgs/libkexiv25/template | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/srcpkgs/libkexiv25/template b/srcpkgs/libkexiv25/template
index b439a42ef2b97..4d7f9600572ea 100644
--- a/srcpkgs/libkexiv25/template
+++ b/srcpkgs/libkexiv25/template
@@ -1,6 +1,6 @@
 # Template file for 'libkexiv25'
 pkgname=libkexiv25
-version=23.04.0
+version=23.08.2
 revision=1
 build_style=cmake
 configure_args="-DBUILD_TESTING=OFF"
@@ -11,7 +11,7 @@ maintainer="Orphaned <orphan@voidlinux.org>"
 license="GPL-2.0-or-later"
 homepage="https://invent.kde.org/graphics/libkexiv2"
 distfiles="${KDE_SITE}/release-service/${version}/src/libkexiv2-${version}.tar.xz"
-checksum=18d3eed06df9d1e31d8434ed9887e305aba176d0856e19a8cd3bdb555b80d391
+checksum=d06e36a408bf2e846a18056a1f15e61d981fa2a1fceb81f7c15136604319d033
 
 libkexiv25-devel_package() {
 	short_desc+=" - development files"

From 01c6ca2bd700d70aa7f5d2d69293ab78e1fed542 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 14/22] nomacs: update to 3.17.2287.

---
 srcpkgs/nomacs/template | 17 +++++++++++++----
 1 file changed, 13 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/nomacs/template b/srcpkgs/nomacs/template
index c52cd54e294db..956bd21ebb129 100644
--- a/srcpkgs/nomacs/template
+++ b/srcpkgs/nomacs/template
@@ -1,7 +1,8 @@
 # Template file for 'nomacs'
 pkgname=nomacs
-version=3.16.224
-revision=5
+version=3.17.2287
+revision=1
+_plugins_ver=3.17.2285
 build_wrksrc=ImageLounge
 build_style=cmake
 configure_args="-DCMAKE_BUILD_TYPE=None -DENABLE_TRANSLATIONS=1
@@ -13,5 +14,13 @@ short_desc="Simple yet powerful Qt imageviewer"
 maintainer="Orphaned <orphan@voidlinux.org>"
 license="GPL-3.0-or-later"
 homepage="https://github.com/nomacs/nomacs"
-distfiles="https://github.com/nomacs/nomacs/archive/${version}.tar.gz"
-checksum=bbc7e9048026ef9e0d2b64902c88050f17a679ef3d3c009de2c3b7de5d1d217c
+distfiles="https://github.com/nomacs/nomacs/archive/${version}.tar.gz
+ https://github.com/novomesk/nomacs-plugins/archive/refs/tags/${_plugins_ver}.tar.gz>plugins.tar.gz"
+checksum="6905ea615358f84a0c83d5b1b7077871dea0526ec667500a1951448cb845a92c
+ 946b2d754be9ecca5cb155f7ecc5dcafb164f6c3dcc7bf5c3c0610d3b47774aa"
+skip_extraction="plugins.tar.gz"
+
+post_extract() {
+ cd ${build_wrksrc}
+ vsrcextract -C plugins "plugins.tar.gz"
+}

From 1bc32f3cba4b792282b32660bbc9f6d449e93aaf Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 15/22] pdf2djvu: revbump for exiv2-0.28.1.

---
 srcpkgs/pdf2djvu/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/pdf2djvu/template b/srcpkgs/pdf2djvu/template
index ef7433c0c98ae..5a6f3ddf4ed35 100644
--- a/srcpkgs/pdf2djvu/template
+++ b/srcpkgs/pdf2djvu/template
@@ -1,7 +1,7 @@
 # Template file for 'pdf2djvu'
 pkgname=pdf2djvu
 version=0.9.19
-revision=4
+revision=5
 build_style=gnu-configure
 hostmakedepends="pkg-config djvulibre gettext"
 makedepends="djvulibre-devel poppler-devel libgraphicsmagick-devel exiv2-devel libuuid-devel"

From 35ba5ff67fe55cb83255b70e7609af60a5b28292 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 16/22] phototonic: revbump for exiv2-0.28.1.

---
 srcpkgs/phototonic/patches/exiv2-0.28.patch | 135 ++++++++++++++++++++
 srcpkgs/phototonic/template                 |   2 +-
 2 files changed, 136 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/phototonic/patches/exiv2-0.28.patch

diff --git a/srcpkgs/phototonic/patches/exiv2-0.28.patch b/srcpkgs/phototonic/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..1c75b628dab33
--- /dev/null
+++ b/srcpkgs/phototonic/patches/exiv2-0.28.patch
@@ -0,0 +1,135 @@
+From 923a3fc14de0b779a45696c5f0aef34c74d84f13 Mon Sep 17 00:00:00 2001
+From: Andreas Sturmlechner <asturm@gentoo.org>
+Date: Sun, 28 May 2023 18:54:10 +0200
+Subject: [PATCH] Fix build with exiv2-0.28
+
+Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>
+---
+ ImageViewer.cpp   | 9 +++++++++
+ MetadataCache.cpp | 8 ++++++++
+ Phototonic.cpp    | 4 ++++
+ Tags.cpp          | 8 ++++++++
+ ThumbsViewer.cpp  | 4 ++++
+ 5 files changed, 33 insertions(+)
+
+diff --git a/ImageViewer.cpp b/ImageViewer.cpp
+index 357d223..df3ac43 100644
+--- a/ImageViewer.cpp
++++ b/ImageViewer.cpp
+@@ -945,7 +945,11 @@ void ImageViewer::keyMoveEvent(int direction) {
+ }
+ 
+ void ImageViewer::saveImage() {
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr image;
++#else
+     Exiv2::Image::AutoPtr image;
++#endif
+     bool exifError = false;
+ 
+     if (newImage) {
+@@ -985,8 +989,13 @@ void ImageViewer::saveImage() {
+ }
+ 
+ void ImageViewer::saveImageAs() {
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++    Exiv2::Image::UniquePtr newExifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
+     Exiv2::Image::AutoPtr newExifImage;
++#endif
+     bool exifError = false;
+ 
+     setCursorHiding(false);
+diff --git a/MetadataCache.cpp b/MetadataCache.cpp
+index 524ae74..5ddd4c8 100644
+--- a/MetadataCache.cpp
++++ b/MetadataCache.cpp
+@@ -64,7 +64,11 @@ void MetadataCache::clear() {
+ }
+ 
+ bool MetadataCache::loadImageMetadata(const QString &imageFullPath) {
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
++#endif
+     QSet<QString> tags;
+     long orientation = 0;
+ 
+@@ -78,7 +82,11 @@ bool MetadataCache::loadImageMetadata(const QString &imageFullPath) {
+     try {
+         Exiv2::ExifData &exifData = exifImage->exifData();
+         if (!exifData.empty()) {
++#if EXIV2_TEST_VERSION(0,28,0)
++            orientation = exifData["Exif.Image.Orientation"].value().toUint32();
++#else
+             orientation = exifData["Exif.Image.Orientation"].value().toLong();
++#endif
+         }
+     } catch (Exiv2::Error &error) {
+         qWarning() << "Failed to read Exif metadata";
+diff --git a/Phototonic.cpp b/Phototonic.cpp
+index 6cc95b3..bd5497d 100644
+--- a/Phototonic.cpp
++++ b/Phototonic.cpp
+@@ -3151,7 +3151,11 @@ void Phototonic::removeMetadata() {
+ 
+     if (ret == MessageBox::Yes) {
+         for (int file = 0; file < fileList.size(); ++file) {
++#if EXIV2_TEST_VERSION(0,28,0)
++            Exiv2::Image::UniquePtr image;
++#else
+             Exiv2::Image::AutoPtr image;
++#endif
+             try {
+                 image = Exiv2::ImageFactory::open(fileList[file].toStdString());
+                 image->clearMetadata();
+diff --git a/Tags.cpp b/Tags.cpp
+index 84eea16..a62da9d 100644
+--- a/Tags.cpp
++++ b/Tags.cpp
+@@ -136,7 +136,11 @@ void ImageTags::addTag(QString tagName, bool tagChecked) {
+ 
+ bool ImageTags::writeTagsToImage(QString &imageFileName, QSet<QString> &newTags) {
+     QSet<QString> imageTags;
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
++#endif
+ 
+     try {
+         exifImage = Exiv2::ImageFactory::open(imageFileName.toStdString());
+@@ -160,7 +164,11 @@ bool ImageTags::writeTagsToImage(QString &imageFileName, QSet<QString> &newTags)
+         QSetIterator<QString> newTagsIt(newTags);
+         while (newTagsIt.hasNext()) {
+             QString tag = newTagsIt.next();
++#if EXIV2_TEST_VERSION(0,28,0)
++            Exiv2::Value::UniquePtr value = Exiv2::Value::create(Exiv2::string);
++#else
+             Exiv2::Value::AutoPtr value = Exiv2::Value::create(Exiv2::string);
++#endif
+             value->read(tag.toStdString());
+             Exiv2::IptcKey key("Iptc.Application2.Keywords");
+             newIptcData.add(key, value.get());
+diff --git a/ThumbsViewer.cpp b/ThumbsViewer.cpp
+index 77a6189..4a11475 100644
+--- a/ThumbsViewer.cpp
++++ b/ThumbsViewer.cpp
+@@ -210,7 +210,11 @@ void ThumbsViewer::updateImageInfoViewer(QString imageFullPath) {
+         infoView->addEntry(key, val);
+     }
+ 
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
++#endif
+     try {
+         exifImage = Exiv2::ImageFactory::open(imageFullPath.toStdString());
+         exifImage->readMetadata();
+-- 
+2.40.1
+
diff --git a/srcpkgs/phototonic/template b/srcpkgs/phototonic/template
index 77ae8bf6a4406..4af006cb7da41 100644
--- a/srcpkgs/phototonic/template
+++ b/srcpkgs/phototonic/template
@@ -1,7 +1,7 @@
 # Template file for 'phototonic'
 pkgname=phototonic
 version=2.1
-revision=3
+revision=4
 build_style=qmake
 hostmakedepends="pkg-config qt5-qmake qt5-host-tools"
 makedepends="qt5-svg-devel exiv2-devel"

From ea225833de13cef3453f5aae2d4927cb6448255d Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 17/22] qimgv: revbump for exiv2-0.28.1.

---
 srcpkgs/qimgv/patches/exiv2-0.28.patch | 16 ++++++++++++++++
 srcpkgs/qimgv/template                 |  2 +-
 2 files changed, 17 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/qimgv/patches/exiv2-0.28.patch

diff --git a/srcpkgs/qimgv/patches/exiv2-0.28.patch b/srcpkgs/qimgv/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..11f37b5ae2be3
--- /dev/null
+++ b/srcpkgs/qimgv/patches/exiv2-0.28.patch
@@ -0,0 +1,16 @@
+Patch-Source: https://git.alpinelinux.org/aports/tree/community/qimgv/exiv2-0.28.patch
+diff --git a/qimgv/sourcecontainers/documentinfo.cpp b/qimgv/sourcecontainers/documentinfo.cpp
+index 98a68f7..c062474 100644
+--- a/qimgv/sourcecontainers/documentinfo.cpp
++++ b/qimgv/sourcecontainers/documentinfo.cpp
+@@ -271,10 +271,6 @@ void DocumentInfo::loadExifTags() {
+         //std::cout << "Caught Exiv2 exception '" << e.what() << "'\n";
+         return;
+     }
+-    catch (Exiv2::BasicError<CharType> e) {
+-        //std::cout << "Caught BasicError Exiv2 exception '" << e.what() << "'\n";
+-        return;
+-    }
+ #endif
+ }
+ 
diff --git a/srcpkgs/qimgv/template b/srcpkgs/qimgv/template
index 7eb30db33992c..dd341dfe1bfce 100644
--- a/srcpkgs/qimgv/template
+++ b/srcpkgs/qimgv/template
@@ -1,7 +1,7 @@
 # Template file for 'qimgv'
 pkgname=qimgv
 version=1.0.2
-revision=2
+revision=3
 build_style=cmake
 configure_args="$(vopt_if video -DVIDEO_SUPPORT=ON -DVIDEO_SUPPORT=OFF)
  $(vopt_if scale -DOPENCV_SUPPORT=ON -DOPENCV_SUPPORT=OFF)

From 21dac152919e6a0b9c7450338d5c40e54908469c Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 18/22] SIR: revbump for exiv2-0.28.1.

---
 srcpkgs/SIR/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/SIR/template b/srcpkgs/SIR/template
index 113077acad354..c6da4c26b6c71 100644
--- a/srcpkgs/SIR/template
+++ b/srcpkgs/SIR/template
@@ -1,7 +1,7 @@
 # Template file for 'SIR'
 pkgname=SIR
 version=3.2.2
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="pkg-config"
 makedepends="exiv2-devel qt5-svg-devel qt5-tools-devel"

From 68fa4a661425426e8c92d90a3ad75cbcb3d02e1b Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 19/22] viewnior: revbump for exiv2-0.28.1.

---
 srcpkgs/viewnior/patches/exiv2-0.28.patch | 147 ++++++++++++++++++++++
 srcpkgs/viewnior/template                 |   2 +-
 2 files changed, 148 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/viewnior/patches/exiv2-0.28.patch

diff --git a/srcpkgs/viewnior/patches/exiv2-0.28.patch b/srcpkgs/viewnior/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..71459dee15768
--- /dev/null
+++ b/srcpkgs/viewnior/patches/exiv2-0.28.patch
@@ -0,0 +1,147 @@
+Patch-Source: https://gitlab.archlinux.org/archlinux/packaging/packages/viewnior/-/blob/f206ce6c22a3ec5f1f9ea1bde4077584f80458dd/exiv2-0.28.patch
+--
+From b6bb81a1b46e911d15bbf9a730972523de177705 Mon Sep 17 00:00:00 2001
+From: tastytea <tastytea@tastytea.de>
+Date: Tue, 16 May 2023 10:54:40 +0200
+Subject: [PATCH 1/2] change exiv2 AutoPtr to unique_ptr
+
+exiv2-0.28.0 removed Exiv2::Image::AutoPtr and added
+Exiv2::Image::UniquePtr instead. since it's a typedef for
+std::unique_ptr<Image>, i'm using that directly instead of adding a
+condition on the exiv2 version.
+---
+ src/uni-exiv2.cpp | 21 +++++++++++----------
+ 1 file changed, 11 insertions(+), 10 deletions(-)
+
+diff --git a/src/uni-exiv2.cpp b/src/uni-exiv2.cpp
+index 0d14b9f..77064c2 100644
+--- a/src/uni-exiv2.cpp
++++ b/src/uni-exiv2.cpp
+@@ -22,12 +22,13 @@
+ 
+ #include <exiv2/exiv2.hpp>
+ #include <iostream>
++#include <memory>
+ 
+ #include "uni-exiv2.hpp"
+ 
+ #define ARRAY_SIZE(array) (sizeof array/sizeof(array[0]))
+ 
+-static Exiv2::Image::AutoPtr cached_image;
++static std::unique_ptr<Exiv2::Image> cached_image;
+ 
+ extern "C"
+ void
+@@ -35,8 +36,8 @@ uni_read_exiv2_map(const char *uri, void (*callback)(const char*, const char*, v
+ {
+     Exiv2::LogMsg::setLevel(Exiv2::LogMsg::mute);
+     try {
+-        Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open(uri);
+-        if ( image.get() == 0 ) {
++        std::unique_ptr<Exiv2::Image> image = Exiv2::ImageFactory::open(uri);
++        if (image == nullptr) {
+             return;
+         }
+ 
+@@ -91,14 +92,14 @@ uni_read_exiv2_to_cache(const char *uri)
+ {
+     Exiv2::LogMsg::setLevel(Exiv2::LogMsg::mute);
+ 
+-    if ( cached_image.get() != NULL ) {
++    if (cached_image != nullptr) {
+         cached_image->clearMetadata();
+-        cached_image.reset(NULL);
++        cached_image.reset(nullptr);
+     }
+ 
+     try {
+         cached_image = Exiv2::ImageFactory::open(uri);
+-        if ( cached_image.get() == 0 ) {
++        if (cached_image == nullptr) {
+             return 1;
+         }
+ 
+@@ -116,13 +117,13 @@ uni_write_exiv2_from_cache(const char *uri)
+ {
+     Exiv2::LogMsg::setLevel(Exiv2::LogMsg::mute);
+ 
+-    if ( cached_image.get() == NULL ) {
++    if (cached_image == nullptr) {
+         return 1;
+     }
+ 
+     try {
+-        Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open(uri);
+-        if ( image.get() == 0 ) {
++        std::unique_ptr<Exiv2::Image> image = Exiv2::ImageFactory::open(uri);
++        if (image == nullptr) {
+             return 2;
+         }
+ 
+@@ -130,7 +131,7 @@ uni_write_exiv2_from_cache(const char *uri)
+         image->writeMetadata();
+ 
+         cached_image->clearMetadata();
+-        cached_image.reset(NULL);
++        cached_image.reset(nullptr);
+ 
+         return 0;
+     } catch (Exiv2::AnyError& e) {
+
+From 47d0b98cb46526aa8aa035bebcabc14a11fa57ee Mon Sep 17 00:00:00 2001
+From: tastytea <tastytea@tastytea.de>
+Date: Tue, 16 May 2023 11:17:00 +0200
+Subject: [PATCH 2/2] add support for exiv-0.28.0 errors
+
+exiv2-0.28.0 changed Exiv2::AnyError to Exiv2::Error.
+---
+ src/uni-exiv2.cpp | 15 ++++++++++++---
+ 1 file changed, 12 insertions(+), 3 deletions(-)
+
+diff --git a/src/uni-exiv2.cpp b/src/uni-exiv2.cpp
+index 77064c2..567a50f 100644
+--- a/src/uni-exiv2.cpp
++++ b/src/uni-exiv2.cpp
+@@ -28,6 +28,15 @@
+ 
+ #define ARRAY_SIZE(array) (sizeof array/sizeof(array[0]))
+ 
++#define EXIV_ERROR Exiv2::AnyError
++#ifdef EXIV2_VERSION
++    #ifdef EXIV2_TEST_VERSION
++        #if EXIV2_TEST_VERSION(0,28,0)
++            #define EXIV_ERROR Exiv2::Error
++        #endif
++    #endif
++#endif
++
+ static std::unique_ptr<Exiv2::Image> cached_image;
+ 
+ extern "C"
+@@ -81,7 +90,7 @@ uni_read_exiv2_map(const char *uri, void (*callback)(const char*, const char*, v
+                 }
+             }
+         }
+-    } catch (Exiv2::AnyError& e) {
++    } catch (EXIV_ERROR& e) {
+         std::cerr << "Exiv2: '" << e << "'\n";
+     }
+ }
+@@ -104,7 +113,7 @@ uni_read_exiv2_to_cache(const char *uri)
+         }
+ 
+         cached_image->readMetadata();
+-    } catch (Exiv2::AnyError& e) {
++    } catch (EXIV_ERROR& e) {
+         std::cerr << "Exiv2: '" << e << "'\n";
+     }
+ 
+@@ -134,7 +143,7 @@ uni_write_exiv2_from_cache(const char *uri)
+         cached_image.reset(nullptr);
+ 
+         return 0;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (EXIV_ERROR& e) {
+         std::cerr << "Exiv2: '" << e << "'\n";
+     }
+ 
diff --git a/srcpkgs/viewnior/template b/srcpkgs/viewnior/template
index ea1e528a8651f..4c73226662ca0 100644
--- a/srcpkgs/viewnior/template
+++ b/srcpkgs/viewnior/template
@@ -1,7 +1,7 @@
 # Template file for 'viewnior'
 pkgname=viewnior
 version=1.8
-revision=1
+revision=2
 build_style=meson
 hostmakedepends="pkg-config intltool glib-devel gettext-devel"
 makedepends="gtk+-devel exiv2-devel"

From ef918e6d1c87d21917ce3c05d08b27562e687328 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Mon, 23 Oct 2023 19:06:34 +0200
Subject: [PATCH 20/22] New package: nufraw-0.43.3

Co-authored-by: triallax <triallax@tutanota.com>
---
 srcpkgs/nufraw-gimp                           |  1 +
 .../patches/0001-nufraw-glib-2.70.patch       | 20 +++++++
 srcpkgs/nufraw/patches/exiv-0.28.x.diff       | 59 +++++++++++++++++++
 srcpkgs/nufraw/template                       | 55 +++++++++++++++++
 srcpkgs/removed-packages/template             |  4 +-
 srcpkgs/ufraw                                 |  1 +
 srcpkgs/ufraw-gimp                            |  2 +-
 .../ufraw/patches/001-no-gimp-remote.patch    | 12 ----
 srcpkgs/ufraw/patches/002-fix_abs_int.patch   | 11 ----
 .../ufraw/patches/03_fix-unsigned-char.patch  | 14 -----
 srcpkgs/ufraw/patches/exiv-0.27.patch         | 25 --------
 srcpkgs/ufraw/patches/glib-2.68.patch         | 30 ----------
 srcpkgs/ufraw/patches/iostream.patch          | 13 ----
 srcpkgs/ufraw/template                        | 38 ------------
 14 files changed, 140 insertions(+), 145 deletions(-)
 create mode 120000 srcpkgs/nufraw-gimp
 create mode 100644 srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch
 create mode 100644 srcpkgs/nufraw/patches/exiv-0.28.x.diff
 create mode 100644 srcpkgs/nufraw/template
 create mode 120000 srcpkgs/ufraw
 delete mode 100644 srcpkgs/ufraw/patches/001-no-gimp-remote.patch
 delete mode 100644 srcpkgs/ufraw/patches/002-fix_abs_int.patch
 delete mode 100644 srcpkgs/ufraw/patches/03_fix-unsigned-char.patch
 delete mode 100644 srcpkgs/ufraw/patches/exiv-0.27.patch
 delete mode 100644 srcpkgs/ufraw/patches/glib-2.68.patch
 delete mode 100644 srcpkgs/ufraw/patches/iostream.patch
 delete mode 100644 srcpkgs/ufraw/template

diff --git a/srcpkgs/nufraw-gimp b/srcpkgs/nufraw-gimp
new file mode 120000
index 0000000000000..0bd1459b2a16f
--- /dev/null
+++ b/srcpkgs/nufraw-gimp
@@ -0,0 +1 @@
+nufraw
\ No newline at end of file
diff --git a/srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch b/srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch
new file mode 100644
index 0000000000000..41f10bfbafa1f
--- /dev/null
+++ b/srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch
@@ -0,0 +1,20 @@
+diff -ru nufraw/uf_glib.h nufraw/uf_glib.h
+--- nufraw/uf_glib.h	2022-02-23 09:03:44.700472919 +0100
++++ nufraw/uf_glib.h	2022-02-23 09:04:50.260308805 +0100
+@@ -13,13 +13,13 @@
+ #ifndef _UF_GLIB_H
+ #define _UF_GLIB_H
+ 
++#include <glib.h>
++#include <glib/gstdio.h>
++
+ #ifdef __cplusplus
+ extern "C" {
+ #endif
+ 
+-#include <glib.h>
+-#include <glib/gstdio.h>
+-
+ // g_win32_locale_filename_from_utf8 is needed only on win32
+ #ifdef _WIN32
+ #define uf_win32_locale_filename_from_utf8(__some_string__) \
diff --git a/srcpkgs/nufraw/patches/exiv-0.28.x.diff b/srcpkgs/nufraw/patches/exiv-0.28.x.diff
new file mode 100644
index 0000000000000..6c23359bf706c
--- /dev/null
+++ b/srcpkgs/nufraw/patches/exiv-0.28.x.diff
@@ -0,0 +1,59 @@
+Patch taken from AUR package: https://aur.archlinux.org/cgit/aur.git/tree/exiv2-error.patch?h=nufraw&id=29e467f2c297fcd0f36548642d6d2cab6428d08f
+diff --git a/nufraw_exiv2.cc b/nufraw_exiv2.cc
+index 2de4cc3..45aea87 100644
+--- a/nufraw_exiv2.cc
++++ b/nufraw_exiv2.cc
+@@ -54,7 +54,7 @@ extern "C" int nufraw_exif_read_input(nufraw_data *uf)
+         uf->inputExifBuf = NULL;
+         uf->inputExifBufLen = 0;
+ 
+-        Exiv2::Image::AutoPtr image;
++        Exiv2::Image::UniquePtr image;
+         if (uf->unzippedBuf != NULL) {
+             image = Exiv2::ImageFactory::open(
+                         (const Exiv2::byte*)uf->unzippedBuf, uf->unzippedBufLen);
+@@ -135,7 +135,7 @@ extern "C" int nufraw_exif_read_input(nufraw_data *uf)
+         nufraw_message(NUFRAW_SET_LOG, "%s\n", stderror.str().c_str());
+ 
+         return NUFRAW_SUCCESS;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (Exiv2::Error& e) {
+         std::cerr.rdbuf(savecerr);
+         std::string s(e.what());
+         nufraw_message(NUFRAW_SET_WARNING, "%s\n", s.c_str());
+@@ -156,7 +156,7 @@ static Exiv2::ExifData nufraw_prepare_exifdata(nufraw_data *uf)
+         if ((pos = exifData.findKey(Exiv2::ExifKey("Exif.Image.Orientation")))
+                 != exifData.end()) {
+             nufraw_message(NUFRAW_SET_LOG, "Resetting %s from '%d' to '1'\n",
+-                          pos->key().c_str(), pos->value().toLong());
++                          pos->key().c_str(), pos->value().toInt64());
+             pos->setValue("1"); /* 1 = Normal orientation */
+         }
+     }
+@@ -327,7 +327,7 @@ extern "C" int nufraw_exif_prepare_output(nufraw_data *uf)
+         nufraw_message(NUFRAW_SET_LOG, "%s\n", stderror.str().c_str());
+ 
+         return NUFRAW_SUCCESS;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (Exiv2::Error& e) {
+         std::cerr.rdbuf(savecerr);
+         std::string s(e.what());
+         nufraw_message(NUFRAW_SET_WARNING, "%s\n", s.c_str());
+@@ -347,7 +347,7 @@ extern "C" int nufraw_exif_write(nufraw_data *uf)
+ 
+         char *filename =
+             uf_win32_locale_filename_from_utf8(uf->conf->outputFilename);
+-        Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open(filename);
++        Exiv2::Image::UniquePtr image = Exiv2::ImageFactory::open(filename);
+         uf_win32_locale_filename_free(filename);
+         assert(image.get() != 0);
+ 
+@@ -367,7 +367,7 @@ extern "C" int nufraw_exif_write(nufraw_data *uf)
+         nufraw_message(NUFRAW_SET_LOG, "%s\n", stderror.str().c_str());
+ 
+         return NUFRAW_SUCCESS;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (Exiv2::Error& e) {
+         std::cerr.rdbuf(savecerr);
+         std::string s(e.what());
+         nufraw_message(NUFRAW_SET_WARNING, "%s\n", s.c_str());
diff --git a/srcpkgs/nufraw/template b/srcpkgs/nufraw/template
new file mode 100644
index 0000000000000..1f15119ec4179
--- /dev/null
+++ b/srcpkgs/nufraw/template
@@ -0,0 +1,55 @@
+# Template file for 'nufraw'
+pkgname=nufraw
+version=0.43.3
+revision=1
+_ver="${version%.*}-${version##*.}"
+build_style=gnu-configure
+configure_args="--enable-contrast --enable-mime --enable-openmp --with-gimp
+ --enable-extras"
+hostmakedepends="pkg-config automake libtool glib-devel"
+# libgexiv2-devel is only here to fix build order, remove on next template
+# change
+makedepends="exiv2-devel gimp-devel glib-devel gtkimageview-devel lcms2-devel
+ lensfun-devel jasper-devel libgexiv2-devel"
+depends="desktop-file-utils"
+short_desc="Utility to read and manipulate raw images from digital cameras"
+maintainer="John <me@johnnynator.dev>"
+license="GPL-2.0-or-later"
+homepage="https://sourceforge.net/projects/nufraw/"
+distfiles="${SOURCEFORGE_SITE}/nufraw/nufraw-${_ver}.tar.gz"
+checksum=2c7dcc1590993ec267b3112562b2433010d6f94f6acc6506c76aa29cf8c6c32c
+
+case "$XBPS_TARGET_MACHINE" in
+	armv[67]l* | aarch64*)
+		make_build_args="CXXFLAGS+=-fsigned-char LDFLAGS+=-fopenmp"
+		;;
+esac
+
+pre_configure() {
+	autoreconf -fi
+}
+
+pre_build() {
+	mv nufraw.desktop{.desktop,}
+	chmod +x generate_schemas.sh
+}
+
+nufraw-gimp_package() {
+	depends="${sourcepkg}>=${version}_${revision}"
+	short_desc+=" - gimp plugin"
+	pkg_install() {
+		vmove usr/lib/gimp
+	}
+}
+
+ufraw_package() {
+	depends="${sourcepkg}>=${version}_${revision}"
+	build_style=meta
+	short_desc+=" (transitional dummy package)"
+}
+
+ufraw-gimp_package() {
+	depends="nufraw-gimp>=${version}_${revision}"
+	build_style=meta
+	short_desc+=" - gimp plugin (transitional dummy package)"
+}
diff --git a/srcpkgs/removed-packages/template b/srcpkgs/removed-packages/template
index c25c5c3e720ea..d42bc9de4a8bd 100644
--- a/srcpkgs/removed-packages/template
+++ b/srcpkgs/removed-packages/template
@@ -1,6 +1,6 @@
 # Template file for 'removed-packages'
 pkgname=removed-packages
-version=0.1.20231110
+version=0.1.20231112
 revision=1
 build_style=meta
 short_desc="Uninstalls packages removed from repository"
@@ -676,6 +676,8 @@ replaces="
  traverso<=0.49.6_2
  ttyload-git<=20141117_4
  tuxc<=1.1_3
+ ufraw-gimp<=0.22_5
+ ufraw<=0.22_5
  unicorn-python<=1.0.2_2
  upwork<=5.6.10.0_1
  urlmatch-git<=20141116_2
diff --git a/srcpkgs/ufraw b/srcpkgs/ufraw
new file mode 120000
index 0000000000000..0bd1459b2a16f
--- /dev/null
+++ b/srcpkgs/ufraw
@@ -0,0 +1 @@
+nufraw
\ No newline at end of file
diff --git a/srcpkgs/ufraw-gimp b/srcpkgs/ufraw-gimp
index 967dc902dd02b..0bd1459b2a16f 120000
--- a/srcpkgs/ufraw-gimp
+++ b/srcpkgs/ufraw-gimp
@@ -1 +1 @@
-ufraw
\ No newline at end of file
+nufraw
\ No newline at end of file
diff --git a/srcpkgs/ufraw/patches/001-no-gimp-remote.patch b/srcpkgs/ufraw/patches/001-no-gimp-remote.patch
deleted file mode 100644
index ca4f4beb6240f..0000000000000
--- a/srcpkgs/ufraw/patches/001-no-gimp-remote.patch
+++ /dev/null
@@ -1,12 +0,0 @@
-Don't use gimp-remote since gimp 2.4 already includes gimp-remote functionality
---- a/ufraw_conf.c
-+++ b/ufraw_conf.c
-@@ -137,7 +137,7 @@
- #elif HAVE_GIMP_2_4
-     "gimp", /* remoteGimpCommand */
- #else
--    "gimp-remote", /* remoteGimpCommand */
-+    "gimp", /* remoteGimpCommand */
- #endif
- 
-     /* EXIF data */
diff --git a/srcpkgs/ufraw/patches/002-fix_abs_int.patch b/srcpkgs/ufraw/patches/002-fix_abs_int.patch
deleted file mode 100644
index 6fc552769c9f8..0000000000000
--- a/srcpkgs/ufraw/patches/002-fix_abs_int.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- a/dcraw.cc	2015-06-16 05:58:38.000000000 +0200
-+++ b/dcraw.cc	2018-02-04 14:46:54.489951076 +0100
-@@ -9242,7 +9242,7 @@
-     if (make[0] == 'O') {
-       i = find_green (12, 32, 1188864, 3576832);
-       c = find_green (12, 32, 2383920, 2387016);
--      if (abs(i) < abs(c)) {
-+      if (abs((int)i) < abs((int)c)) {
- 	SWAP(i,c);
- 	load_flags = 24;
-       }
diff --git a/srcpkgs/ufraw/patches/03_fix-unsigned-char.patch b/srcpkgs/ufraw/patches/03_fix-unsigned-char.patch
deleted file mode 100644
index 8690f87ca7d59..0000000000000
--- a/srcpkgs/ufraw/patches/03_fix-unsigned-char.patch
+++ /dev/null
@@ -1,14 +0,0 @@
-Source: written by John Paul Adrian Glaubitz for Debian
-Upstream: https://sourceforge.net/p/ufraw/bugs/417
-Reason: fixes a compilation failure on arm architectures
---- a/dcraw.cc
-+++ b/dcraw.cc
-@@ -2285,7 +2285,7 @@ void CLASS quicktake_100_load_raw()
- 
- void CLASS kodak_radc_load_raw()
- {
--  static const char src[] = {
-+  static const signed char src[] = {
-     1,1, 2,3, 3,4, 4,2, 5,7, 6,5, 7,6, 7,8,
-     1,0, 2,1, 3,3, 4,4, 5,2, 6,7, 7,6, 8,5, 8,8,
-     2,1, 2,3, 3,0, 3,2, 3,4, 4,6, 5,5, 6,7, 6,8,
diff --git a/srcpkgs/ufraw/patches/exiv-0.27.patch b/srcpkgs/ufraw/patches/exiv-0.27.patch
deleted file mode 100644
index b5b4140fff8ed..0000000000000
--- a/srcpkgs/ufraw/patches/exiv-0.27.patch
+++ /dev/null
@@ -1,25 +0,0 @@
---- a/ufraw_exiv2.cc	2015-06-16 05:58:38.000000000 +0200
-+++ b/ufraw_exiv2.cc	2018-12-29 22:51:23.291894430 +0100
-@@ -15,9 +15,7 @@
- #include "ufraw.h"
- 
- #ifdef HAVE_EXIV2
--#include <exiv2/image.hpp>
--#include <exiv2/easyaccess.hpp>
--#include <exiv2/exif.hpp>
-+#include <exiv2/exiv2.hpp>
- #include <sstream>
- #include <cassert>
- 
-@@ -67,7 +65,11 @@
-         if (exifData.empty()) {
-             std::string error(uf->filename);
-             error += ": No Exif data found in the file";
-+#if EXIV2_TEST_VERSION(0,27,0)
-+            throw Exiv2::Error(Exiv2::kerErrorMessage, error);
-+#else
-             throw Exiv2::Error(1, error);
-+#endif
-         }
- 
-         /* List of tag names taken from exiv2's printSummary() in actions.cpp */
diff --git a/srcpkgs/ufraw/patches/glib-2.68.patch b/srcpkgs/ufraw/patches/glib-2.68.patch
deleted file mode 100644
index 5b61468f118aa..0000000000000
--- a/srcpkgs/ufraw/patches/glib-2.68.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-From c56f8be3caf1cf3d9a5c80597bdbaf1325faacc0 Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?S=C3=A9rgio=20M=2E=20Basto?= <sergio@serjux.com>
-Date: Tue, 13 Apr 2021 23:45:39 +0100
-Subject: [PATCH] Fix build against glib-2.68 fixes #10
-
----
- uf_glib.h | 6 +++---
- 1 file changed, 3 insertions(+), 3 deletions(-)
-
-diff --git a/uf_glib.h b/uf_glib.h
-index 21c10b19..56cd6971 100644
---- a/uf_glib.h
-+++ b/uf_glib.h
-@@ -13,13 +13,13 @@
- #ifndef _UF_GLIB_H
- #define _UF_GLIB_H
- 
-+#include <glib.h>
-+#include <glib/gstdio.h>
-+
- #ifdef __cplusplus
- extern "C" {
- #endif
- 
--#include <glib.h>
--#include <glib/gstdio.h>
--
- // g_win32_locale_filename_from_utf8 is needed only on win32
- #ifdef _WIN32
- #define uf_win32_locale_filename_from_utf8(__some_string__) \
diff --git a/srcpkgs/ufraw/patches/iostream.patch b/srcpkgs/ufraw/patches/iostream.patch
deleted file mode 100644
index 6d15869f63db8..0000000000000
--- a/srcpkgs/ufraw/patches/iostream.patch
+++ /dev/null
@@ -1,13 +0,0 @@
-ufraw_exiv2.cc:343:10: note: 'std::cerr' is defined in header '<iostream>'
-ufraw_exiv2.cc:365:14: error: 'cerr' is not a member of 'std'
-
---- a/ufraw_exiv2.cc
-+++ b/ufraw_exiv2.cc
-@@ -17,6 +17,7 @@
- #ifdef HAVE_EXIV2
- #include <exiv2/exiv2.hpp>
- #include <sstream>
-+#include <iostream>
- #include <cassert>
- 
- /*
diff --git a/srcpkgs/ufraw/template b/srcpkgs/ufraw/template
deleted file mode 100644
index ceddcacacefb2..0000000000000
--- a/srcpkgs/ufraw/template
+++ /dev/null
@@ -1,38 +0,0 @@
-# Template file for 'ufraw'
-pkgname=ufraw
-version=0.22
-revision=5
-build_style=gnu-configure
-configure_args="--enable-contrast --enable-mime --enable-openmp --with-gimp
- $(vopt_enable extras)"
-hostmakedepends="pkg-config dcraw gettext"
-makedepends="exiv2-devel gimp-devel glib-devel gtkimageview-devel lcms2-devel lensfun-devel
- jasper-devel"
-depends="desktop-file-utils"
-short_desc="Utility to read and manipulate raw images from digital cameras"
-maintainer="John <me@johnnynator.dev>"
-license="GPL-2.0-or-later"
-homepage="http://ufraw.sourceforge.net/"
-distfiles="${SOURCEFORGE_SITE}/ufraw/ufraw/ufraw-${version}/ufraw-${version}.tar.gz"
-checksum=f7abd28ce587db2a74b4c54149bd8a2523a7ddc09bedf4f923246ff0ae09a25e
-
-build_options="extras"
-
-post_patch() {
-	vsed -e 's/default(none)//g' \
-		-i dcraw_indi.c \
-		-i dcraw_api.cc \
-		-i ufraw_ufraw.c \
-		-i ufraw_developer.c
-	vsed -i -e '/DATADIRNAME=/s/=.*/=share/' configure
-	vsed -i -e "s,^localedir =.*,localedir = /usr/share/locale," \
-		po/Makefile.in.in
-}
-
-ufraw-gimp_package() {
-	depends="${sourcepkg}>=${version}_${revision}"
-	short_desc+=" - gimp plugin"
-	pkg_install() {
-		vmove usr/lib/gimp
-	}
-}

From 97f1b182debd6433ff7ca1fe990ba944258d27fb Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 8 Nov 2023 12:53:45 +0000
Subject: [PATCH 21/22] krita: revbump for exiv2-0.28.1.

---
 srcpkgs/krita/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/krita/template b/srcpkgs/krita/template
index f4d665daf7c31..d804b581a8689 100644
--- a/srcpkgs/krita/template
+++ b/srcpkgs/krita/template
@@ -1,7 +1,7 @@
 # Template file for 'krita'
 pkgname=krita
 version=5.2.1
-revision=2
+revision=3
 build_style=cmake
 configure_args="-Wno-dev -DBUILD_TESTING=OFF"
 hostmakedepends="extra-cmake-modules gettext pkg-config python3

From 52385ace4c6566b59d2dac126c9df18d452a1fd5 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 8 Nov 2023 18:25:01 +0000
Subject: [PATCH 22/22] darktable: revbump for exiv2-0.28.1.

---
 srcpkgs/darktable/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/darktable/template b/srcpkgs/darktable/template
index f76936a1692e8..97dfae3471e7c 100644
--- a/srcpkgs/darktable/template
+++ b/srcpkgs/darktable/template
@@ -1,7 +1,7 @@
 # Template file for 'darktable'
 pkgname=darktable
 version=4.4.2
-revision=4
+revision=5
 # upstream only supports these archs:
 archs="x86_64* aarch64* ppc64le*"
 build_style=cmake

^ permalink raw reply	[flat|nested] 27+ messages in thread

* Re: exiv2: update to 0.28.1.
  2023-10-23  0:10 [PR PATCH] exiv2: update to 0.28.0 mhmdanas
                   ` (14 preceding siblings ...)
  2023-11-12 22:54 ` [PR PATCH] [Updated] " mhmdanas
@ 2023-11-12 22:55 ` mhmdanas
  2023-11-13  0:00 ` [PR PATCH] [Updated] " mhmdanas
                   ` (9 subsequent siblings)
  25 siblings, 0 replies; 27+ messages in thread
From: mhmdanas @ 2023-11-12 22:55 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 183 bytes --]

New comment by mhmdanas on void-packages repository

https://github.com/void-linux/void-packages/pull/46838#issuecomment-1807269822

Comment:
Done, plesae give it a try now @biopsin.

^ permalink raw reply	[flat|nested] 27+ messages in thread

* Re: [PR PATCH] [Updated] exiv2: update to 0.28.1.
  2023-10-23  0:10 [PR PATCH] exiv2: update to 0.28.0 mhmdanas
                   ` (15 preceding siblings ...)
  2023-11-12 22:55 ` exiv2: update to 0.28.1 mhmdanas
@ 2023-11-13  0:00 ` mhmdanas
  2023-11-15 17:40 ` mhmdanas
                   ` (8 subsequent siblings)
  25 siblings, 0 replies; 27+ messages in thread
From: mhmdanas @ 2023-11-13  0:00 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 2086 bytes --]

There is an updated pull request by mhmdanas against master on the void-packages repository

https://github.com/mhmdanas/void-packages exiv2-0.28.0
https://github.com/void-linux/void-packages/pull/46838

exiv2: update to 0.28.1.
<!-- Uncomment relevant sections and delete options which are not applicable -->

#### Testing the changes
- I tested the changes in this PR: **briefly**

TODO:
- [x] Fix `gwenview`'s failed checks (not really fixed but the exact same tests fail on master as well)
- [x] `test_exiv2` fails for `libextractor`
- [x] `kfilemetadata5` tests fail (same tests fail on master)
- [x] Fix `nufraw` cross-build
- [x] `digikam` fails to build

@Johnnynator ufraw has been [unmaintained since December 2016](https://sourceforge.net/p/ufraw/discussion/434060/thread/30b4249b/), and it doesn't build with this PR; here are the options:
- remove the package entirely
- replace it with the newer [nufraw](https://sourceforge.net/projects/nufraw/), which already has [an exiv 0.28.x patch floating around](https://aur.archlinux.org/cgit/aur.git/tree/exiv2-error.patch?h=nufraw)
- patch it to build with this PR

What do you think? (edit: `nufraw` now replaces `ufraw` in this PR)

<!--
#### New package
- This new package conforms to the [package requirements](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTItest_exiv2NG.md#package-requirements): **YES**|**NO**
-->

<!-- Note: If the build is likely to take more than 2 hours, please add ci skip tag as described in
https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration
and test at least one native build and, if supported, at least one cross build.
Ignore this section if this PR is not skipping CI.
-->
<!--
#### Local build testing
- I built this PR locally for my native architecture, (ARCH-LIBC)
- I built this PR locally for these architectures (if supported. mark crossbuilds):
  - aarch64-musl
  - armv7l
  - armv6l-musl
-->


A patch file from https://github.com/void-linux/void-packages/pull/46838.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-exiv2-0.28.0-46838.patch --]
[-- Type: text/x-diff, Size: 74583 bytes --]

From aaeb758609d3ce7e57de5fbc33b14d3a7aab8bd4 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Mon, 23 Oct 2023 01:20:09 +0100
Subject: [PATCH 01/22] inih: add `libINIReader.so.0` common/shlibs entry.

---
 common/shlibs | 1 +
 1 file changed, 1 insertion(+)

diff --git a/common/shlibs b/common/shlibs
index 64643f5b3c009..dbf46cf4e5c73 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -3903,6 +3903,7 @@ libnotcurses++.so.3 notcurses-3.0.5_1
 libnotcurses-ffi.so.3 notcurses-3.0.5_1
 libevemu.so.3 evemu-2.7.0_1
 libinih.so.0 inih-52_1
+libINIReader.so.0 inih-57_1
 libpcaudio.so.0 pcaudiolib-1.1_1
 libdcerpc-samr.so.0 samba-4.13.2_1
 libdcerpc-server-core.so.0 samba-4.13.2_1

From 6db5d38721969bbb926eb9a01630cbb25dad82a6 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:12 +0100
Subject: [PATCH 02/22] exiv2: update to 0.28.1.

---
 common/shlibs          |  2 +-
 srcpkgs/exiv2/template | 18 +++++++++++-------
 2 files changed, 12 insertions(+), 8 deletions(-)

diff --git a/common/shlibs b/common/shlibs
index dbf46cf4e5c73..b66e4fae5bd59 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -555,7 +555,7 @@ libgimpcolor-2.0.so.0 libgimp-2.10.0_1
 libgimpmodule-2.0.so.0 libgimp-2.10.0_1
 libgmic.so.3 gmic-3.1.6_1
 libcgmic.so.3 gmic-3.1.6_1
-libexiv2.so.27 exiv2-0.27_1
+libexiv2.so.28 exiv2-0.28.0_1
 libKF5Holidays.so.5 kholidays-5.47.0_1
 libPhabricatorHelpers.so.5 purpose-5.48.0_1
 libKF5PurposeWidgets.so.5 purpose-5.48.0_1
diff --git a/srcpkgs/exiv2/template b/srcpkgs/exiv2/template
index 49985fe82cc14..4517906521b4e 100644
--- a/srcpkgs/exiv2/template
+++ b/srcpkgs/exiv2/template
@@ -1,17 +1,17 @@
 # Template file for 'exiv2'
 pkgname=exiv2
-version=0.27.6
+version=0.28.1
 revision=1
 build_style=cmake
 configure_args="-DEXIV2_BUILD_SAMPLES=OFF -DEXIV2_ENABLE_BMFF=ON"
-makedepends="zlib-devel expat-devel"
-checkdepends="gtest-devel"
+makedepends="zlib-devel brotli-devel expat-devel inih-devel"
+checkdepends="gtest-devel python3"
 short_desc="Image metadata manipulation"
 maintainer="Enno Boland <gottox@voidlinux.org>"
 license="GPL-2.0-or-later"
 homepage="https://www.exiv2.org"
-distfiles="https://github.com/Exiv2/exiv2/releases/download/v${version}/exiv2-${version}-Source.tar.gz"
-checksum=4c192483a1125dc59a3d70b30d30d32edace9e14adf52802d2f853abf72db8a6
+distfiles="https://github.com/Exiv2/exiv2/archive/refs/tags/v${version}.zip"
+checksum=eab4c4b919930905e2128c56cb15919cb8105d431ccef8712f98fd4871f3d09a
 
 if [ -n "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DEXIV2_BUILD_UNIT_TESTS=ON"
@@ -21,14 +21,18 @@ if [ -n "$XBPS_CCACHE" ]; then
 	configure_args+=" -DBUILD_WITH_CCACHE=ON"
 fi
 
+pre_check() {
+	# https://github.com/Exiv2/exiv2/issues/2762
+	rm -f tests/bugfixes/github/test_issue_2427.py
+}
+
 exiv2-devel_package() {
 	depends="${makedepends} ${sourcepkg}-${version}_${revision}"
 	short_desc+=" - development files"
 	pkg_install() {
 		vmove usr/include
-		vmove usr/lib/cmake
 		vmove usr/lib/pkgconfig
-		vmove "usr/lib/*.a"
+		vmove usr/share/cmake
 		vmove "usr/lib/*.so"
 	}
 }

From df9d74f0d24db30d53abcb16e516faf42caf9ae1 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:37 +0100
Subject: [PATCH 03/22] ART: revbump for exiv2-0.28.1.

---
 srcpkgs/ART/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/ART/template b/srcpkgs/ART/template
index b6c47fc6c4cdf..94c7aa0378061 100644
--- a/srcpkgs/ART/template
+++ b/srcpkgs/ART/template
@@ -1,7 +1,7 @@
 # Template file for 'ART'
 pkgname=ART
 version=1.20.2
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="pkg-config"
 makedepends="fftw-devel gtkmm-devel lensfun-devel

From d3c6b14f1c43e9bb3974fbf55aa426254e11a897 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 04/22] digikam: revbump for exiv2-0.28.1.

---
 .../patches/fix-build-with-exiv2-0.28.1.patch | 422 ++++++++++++++++++
 srcpkgs/digikam/template                      |   2 +-
 2 files changed, 423 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/digikam/patches/fix-build-with-exiv2-0.28.1.patch

diff --git a/srcpkgs/digikam/patches/fix-build-with-exiv2-0.28.1.patch b/srcpkgs/digikam/patches/fix-build-with-exiv2-0.28.1.patch
new file mode 100644
index 0000000000000..2a01b4545e76d
--- /dev/null
+++ b/srcpkgs/digikam/patches/fix-build-with-exiv2-0.28.1.patch
@@ -0,0 +1,422 @@
+From a76a561b20e7300510b29edc97afab01e381c0ec Mon Sep 17 00:00:00 2001
+From: Maik Qualmann <metzpinguin@gmail.com>
+Date: Wed, 8 Nov 2023 23:13:26 +0100
+Subject: [PATCH 1/5] fix compile with Exiv2-0.28.1 It should still compile
+ even with smaller Exiv2 versions.
+
+---
+ core/CMakeLists.txt                     | 4 ++--
+ core/app/DigikamCoreTarget.cmake        | 2 +-
+ core/cmake/rules/RulesLibExiv2.cmake    | 8 ++++----
+ core/libs/metadataengine/CMakeLists.txt | 4 ++--
+ 4 files changed, 9 insertions(+), 9 deletions(-)
+
+diff --git a/core/CMakeLists.txt b/core/CMakeLists.txt
+index c694c4b176..d5dc2f0dd8 100644
+--- a/core/CMakeLists.txt
++++ b/core/CMakeLists.txt
+@@ -255,7 +255,7 @@ PRINT_COMPONENT_COMPILE_STATUS("Media Player Support"                       ENAB
+ # ==============================================================================
+ 
+ PRINT_LIBRARY_STATUS("libboostgraph" "https://github.com/boostorg/boost"                 "(version >= 1.43.0)"                Boost_FOUND)
+-PRINT_LIBRARY_STATUS("libexiv2"      "https://github.com/Exiv2/exiv2"                    "(version >= ${EXIV2_MIN_VERSION}"   exiv2_FOUND)
++PRINT_LIBRARY_STATUS("libexiv2"      "https://github.com/Exiv2/exiv2"                    "(version >= ${EXIV2_MIN_VERSION}"   LibExiv2_FOUND)
+ PRINT_LIBRARY_STATUS("libexpat"      "https://libexpat.github.io"                        "(version >= 2.0.0)"                 EXPAT_FOUND)
+ PRINT_LIBRARY_STATUS("libjpeg"       "https://github.com/libjpeg-turbo/libjpeg-turbo"    "(version >= 6b)"                    JPEG_FOUND)
+ PRINT_LIBRARY_STATUS("libkde"        "https://invent.kde.org/frameworks/"                "(version >= ${KF5_MIN_VERSION})"    KF5_FOUND)
+@@ -306,7 +306,7 @@ endif()
+ # ==============================================================================
+ 
+ if(Boost_FOUND                          AND
+-   exiv2_FOUND                          AND
++   LibExiv2_FOUND                       AND
+    EXPAT_FOUND                          AND
+    JPEG_FOUND                           AND
+    KF5_FOUND                            AND
+diff --git a/core/app/DigikamCoreTarget.cmake b/core/app/DigikamCoreTarget.cmake
+index 83fda1b35f..8221a2d632 100644
+--- a/core/app/DigikamCoreTarget.cmake
++++ b/core/app/DigikamCoreTarget.cmake
+@@ -151,7 +151,7 @@ target_link_libraries(digikamcore
+                       ${TIFF_LIBRARIES}
+                       PNG::PNG
+                       ${JPEG_LIBRARIES}
+-                      exiv2lib
++                      ${LibExiv2_LIBRARIES}
+ 
+                       ${OPENMP_LDFLAGS}
+ 
+diff --git a/core/cmake/rules/RulesLibExiv2.cmake b/core/cmake/rules/RulesLibExiv2.cmake
+index c8b37d307c..a8ca259432 100644
+--- a/core/cmake/rules/RulesLibExiv2.cmake
++++ b/core/cmake/rules/RulesLibExiv2.cmake
+@@ -4,7 +4,7 @@
+ # SPDX-License-Identifier: BSD-3-Clause
+ #
+ 
+-find_package(exiv2 REQUIRED)
++find_package(LibExiv2 REQUIRED)
+ 
+ set_package_properties("exiv2"     PROPERTIES
+                        DESCRIPTION "Required to build digiKam"
+@@ -13,13 +13,13 @@ set_package_properties("exiv2"     PROPERTIES
+                        PURPOSE     "Library to manage image metadata"
+ )
+ 
+-if("${exiv2_VERSION}" VERSION_LESS ${EXIV2_MIN_VERSION})
++if("${LibExiv2_VERSION}" VERSION_LESS ${EXIV2_MIN_VERSION})
+ 
+-    message(FATAL_ERROR "Exiv2 version is too old (${exiv2_VERSION})! Minimal version required:${EXIV2_MIN_VERSION}.")
++    message(FATAL_ERROR "Exiv2 version is too old (${LibExiv2_VERSION})! Minimal version required:${EXIV2_MIN_VERSION}.")
+ 
+ endif()
+ 
+-if("${exiv2_VERSION}" VERSION_LESS "0.27.99")
++if("${LibExiv2_VERSION}" VERSION_LESS "0.27.99")
+ 
+     set(EXIV2_CXX_STANDARD 11)
+ 
+diff --git a/core/libs/metadataengine/CMakeLists.txt b/core/libs/metadataengine/CMakeLists.txt
+index 47aa889d5e..bd4dba0bbd 100644
+--- a/core/libs/metadataengine/CMakeLists.txt
++++ b/core/libs/metadataengine/CMakeLists.txt
+@@ -18,7 +18,7 @@ endif()
+ 
+ # Exiv2 version < 0.28 use auto_ptr instead unique_ptr which is deprecated.
+ 
+-if("${exiv2_VERSION}" VERSION_LESS "0.27.99")
++if("${LibExiv2_VERSION}" VERSION_LESS "0.27.99")
+ 
+     DISABLE_GCC_COMPILER_WARNINGS("5.99.99" "-Wno-deprecated")
+ 
+@@ -112,7 +112,7 @@ include_directories(
+     $<TARGET_PROPERTY:KF5::ConfigCore,INTERFACE_INCLUDE_DIRECTORIES>
+     $<TARGET_PROPERTY:KF5::I18n,INTERFACE_INCLUDE_DIRECTORIES>
+ 
+-    $<TARGET_PROPERTY:exiv2lib,INTERFACE_INCLUDE_DIRECTORIES>
++    $<TARGET_PROPERTY:LibExiv2_INCLUDE_DIRS>
+ )
+ 
+ # Used by digikamcore
+-- 
+2.42.0
+
+
+From ee487a753a652c588b88fa18aeb885105c17368d Mon Sep 17 00:00:00 2001
+From: Maik Qualmann <metzpinguin@gmail.com>
+Date: Thu, 9 Nov 2023 18:49:18 +0100
+Subject: [PATCH 2/5] recognize both Exiv2 CMake variants
+
+---
+ core/CMakeLists.txt                     | 14 ++++++--
+ core/app/DigikamCoreTarget.cmake        | 17 ++++++++-
+ core/cmake/rules/RulesLibExiv2.cmake    | 46 +++++++++++++++++++++----
+ core/libs/metadataengine/CMakeLists.txt | 12 +++++--
+ 4 files changed, 77 insertions(+), 12 deletions(-)
+
+diff --git a/core/CMakeLists.txt b/core/CMakeLists.txt
+index d5dc2f0dd8..855fdcf185 100644
+--- a/core/CMakeLists.txt
++++ b/core/CMakeLists.txt
+@@ -255,7 +255,17 @@ PRINT_COMPONENT_COMPILE_STATUS("Media Player Support"                       ENAB
+ # ==============================================================================
+ 
+ PRINT_LIBRARY_STATUS("libboostgraph" "https://github.com/boostorg/boost"                 "(version >= 1.43.0)"                Boost_FOUND)
+-PRINT_LIBRARY_STATUS("libexiv2"      "https://github.com/Exiv2/exiv2"                    "(version >= ${EXIV2_MIN_VERSION}"   LibExiv2_FOUND)
++
++if(LibExiv2_FOUND)
++
++    PRINT_LIBRARY_STATUS("libexiv2"  "https://github.com/Exiv2/exiv2"                    "(version >= ${EXIV2_MIN_VERSION}"   LibExiv2_FOUND)
++
++else()
++
++    PRINT_LIBRARY_STATUS("libexiv2"  "https://github.com/Exiv2/exiv2"                    "(version >= ${EXIV2_MIN_VERSION}"   exiv2_FOUND)
++
++endif()
++
+ PRINT_LIBRARY_STATUS("libexpat"      "https://libexpat.github.io"                        "(version >= 2.0.0)"                 EXPAT_FOUND)
+ PRINT_LIBRARY_STATUS("libjpeg"       "https://github.com/libjpeg-turbo/libjpeg-turbo"    "(version >= 6b)"                    JPEG_FOUND)
+ PRINT_LIBRARY_STATUS("libkde"        "https://invent.kde.org/frameworks/"                "(version >= ${KF5_MIN_VERSION})"    KF5_FOUND)
+@@ -306,7 +316,7 @@ endif()
+ # ==============================================================================
+ 
+ if(Boost_FOUND                          AND
+-   LibExiv2_FOUND                       AND
++   (LibExiv2_FOUND OR exiv2_FOUND)      AND
+    EXPAT_FOUND                          AND
+    JPEG_FOUND                           AND
+    KF5_FOUND                            AND
+diff --git a/core/app/DigikamCoreTarget.cmake b/core/app/DigikamCoreTarget.cmake
+index 8221a2d632..80bd153caa 100644
+--- a/core/app/DigikamCoreTarget.cmake
++++ b/core/app/DigikamCoreTarget.cmake
+@@ -151,7 +151,6 @@ target_link_libraries(digikamcore
+                       ${TIFF_LIBRARIES}
+                       PNG::PNG
+                       ${JPEG_LIBRARIES}
+-                      ${LibExiv2_LIBRARIES}
+ 
+                       ${OPENMP_LDFLAGS}
+ 
+@@ -164,6 +163,22 @@ target_link_libraries(digikamcore
+                       opencv_flann
+ )
+ 
++if(LibExiv2_FOUND)
++
++    target_link_libraries(digikamcore
++                          PRIVATE
++                          ${LibExiv2_LIBRARIES}
++    )
++
++else()
++
++    target_link_libraries(digikamcore
++                          PRIVATE
++                          exiv2lib
++    )
++
++endif()
++
+ if(Qt6_FOUND)
+     target_link_libraries(digikamcore
+                           PRIVATE
+diff --git a/core/cmake/rules/RulesLibExiv2.cmake b/core/cmake/rules/RulesLibExiv2.cmake
+index a8ca259432..e568644ca4 100644
+--- a/core/cmake/rules/RulesLibExiv2.cmake
++++ b/core/cmake/rules/RulesLibExiv2.cmake
+@@ -4,7 +4,17 @@
+ # SPDX-License-Identifier: BSD-3-Clause
+ #
+ 
+-find_package(LibExiv2 REQUIRED)
++find_package(LibExiv2 OPTIONAL_COMPONENTS)
++
++if(LibExiv2_FOUND)
++
++    find_package(LibExiv2 REQUIRED)
++
++else()
++
++    find_package(exiv2 REQUIRED)
++
++endif()
+ 
+ set_package_properties("exiv2"     PROPERTIES
+                        DESCRIPTION "Required to build digiKam"
+@@ -13,18 +23,40 @@ set_package_properties("exiv2"     PROPERTIES
+                        PURPOSE     "Library to manage image metadata"
+ )
+ 
+-if("${LibExiv2_VERSION}" VERSION_LESS ${EXIV2_MIN_VERSION})
++if(LibExiv2_FOUND)
+ 
+-    message(FATAL_ERROR "Exiv2 version is too old (${LibExiv2_VERSION})! Minimal version required:${EXIV2_MIN_VERSION}.")
++    if("${LibExiv2_VERSION}" VERSION_LESS ${EXIV2_MIN_VERSION})
+ 
+-endif()
++        message(FATAL_ERROR "Exiv2 version is too old (${LibExiv2_VERSION})! Minimal version required:${EXIV2_MIN_VERSION}.")
++
++    endif()
++
++    if("${LibExiv2_VERSION}" VERSION_LESS "0.27.99")
+ 
+-if("${LibExiv2_VERSION}" VERSION_LESS "0.27.99")
++        set(EXIV2_CXX_STANDARD 11)
+ 
+-    set(EXIV2_CXX_STANDARD 11)
++    else()
++
++        set(EXIV2_CXX_STANDARD 17)
++
++    endif()
+ 
+ else()
+ 
+-    set(EXIV2_CXX_STANDARD 17)
++    if("${exiv2_VERSION}" VERSION_LESS ${EXIV2_MIN_VERSION})
++
++        message(FATAL_ERROR "Exiv2 version is too old (${exiv2_VERSION})! Minimal version required:${EXIV2_MIN_VERSION}.")
++
++    endif()
++
++    if("${exiv2_VERSION}" VERSION_LESS "0.27.99")
++
++        set(EXIV2_CXX_STANDARD 11)
++
++    else()
++
++        set(EXIV2_CXX_STANDARD 17)
++
++    endif()
+ 
+ endif()
+diff --git a/core/libs/metadataengine/CMakeLists.txt b/core/libs/metadataengine/CMakeLists.txt
+index bd4dba0bbd..a4124d17e0 100644
+--- a/core/libs/metadataengine/CMakeLists.txt
++++ b/core/libs/metadataengine/CMakeLists.txt
+@@ -111,10 +111,18 @@ include_directories(
+ 
+     $<TARGET_PROPERTY:KF5::ConfigCore,INTERFACE_INCLUDE_DIRECTORIES>
+     $<TARGET_PROPERTY:KF5::I18n,INTERFACE_INCLUDE_DIRECTORIES>
+-
+-    $<TARGET_PROPERTY:LibExiv2_INCLUDE_DIRS>
+ )
+ 
++if(LibExiv2_FOUND)
++
++    include_directories($<TARGET_PROPERTY:LibExiv2_INCLUDE_DIRS>)
++
++else()
++
++    include_directories($<TARGET_PROPERTY:exiv2lib,INTERFACE_INCLUDE_DIRECTORIES>)
++
++endif()
++
+ # Used by digikamcore
+ add_library(core_dmetadata_obj OBJECT ${libdmetadata_SRCS})
+ 
+-- 
+2.42.0
+
+
+From af221dd7700fbf1e6e3b5245184381d2b74ec781 Mon Sep 17 00:00:00 2001
+From: Maik Qualmann <metzpinguin@gmail.com>
+Date: Thu, 9 Nov 2023 19:12:44 +0100
+Subject: [PATCH 3/5] check version und clear LibExiv2_FOUND
+
+---
+ core/cmake/rules/RulesLibExiv2.cmake | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+diff --git a/core/cmake/rules/RulesLibExiv2.cmake b/core/cmake/rules/RulesLibExiv2.cmake
+index e568644ca4..de5ea80ec6 100644
+--- a/core/cmake/rules/RulesLibExiv2.cmake
++++ b/core/cmake/rules/RulesLibExiv2.cmake
+@@ -6,12 +6,13 @@
+ 
+ find_package(LibExiv2 OPTIONAL_COMPONENTS)
+ 
+-if(LibExiv2_FOUND)
++if(LibExiv2_FOUND AND ("${LibExiv2_VERSION}" VERSION_GREATER "0.28.0"))
+ 
+     find_package(LibExiv2 REQUIRED)
+ 
+ else()
+ 
++    set (LibExiv2_FOUND FALSE)
+     find_package(exiv2 REQUIRED)
+ 
+ endif()
+-- 
+2.42.0
+
+
+From fda83a6f7e03e4088f3a5903d036c1425d6303b9 Mon Sep 17 00:00:00 2001
+From: Maik Qualmann <metzpinguin@gmail.com>
+Date: Thu, 9 Nov 2023 19:15:41 +0100
+Subject: [PATCH 4/5] adjust Exiv2 version
+
+---
+ core/cmake/rules/RulesLibExiv2.cmake | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/core/cmake/rules/RulesLibExiv2.cmake b/core/cmake/rules/RulesLibExiv2.cmake
+index de5ea80ec6..3db233cad2 100644
+--- a/core/cmake/rules/RulesLibExiv2.cmake
++++ b/core/cmake/rules/RulesLibExiv2.cmake
+@@ -6,7 +6,7 @@
+ 
+ find_package(LibExiv2 OPTIONAL_COMPONENTS)
+ 
+-if(LibExiv2_FOUND AND ("${LibExiv2_VERSION}" VERSION_GREATER "0.28.0"))
++if(LibExiv2_FOUND AND ("${LibExiv2_VERSION}" VERSION_GREATER "0.27.99"))
+ 
+     find_package(LibExiv2 REQUIRED)
+ 
+-- 
+2.42.0
+
+
+From 921ee9945f8c438f23b83add58d5737b539cd312 Mon Sep 17 00:00:00 2001
+From: Maik Qualmann <metzpinguin@gmail.com>
+Date: Thu, 9 Nov 2023 21:35:09 +0100
+Subject: [PATCH 5/5] set correct exiv2 package name and less duplicate CMake
+ code
+
+---
+ core/cmake/rules/RulesLibExiv2.cmake | 34 +++++++++++-----------------
+ 1 file changed, 13 insertions(+), 21 deletions(-)
+
+diff --git a/core/cmake/rules/RulesLibExiv2.cmake b/core/cmake/rules/RulesLibExiv2.cmake
+index 3db233cad2..e3e667d946 100644
+--- a/core/cmake/rules/RulesLibExiv2.cmake
++++ b/core/cmake/rules/RulesLibExiv2.cmake
+@@ -9,19 +9,21 @@ find_package(LibExiv2 OPTIONAL_COMPONENTS)
+ if(LibExiv2_FOUND AND ("${LibExiv2_VERSION}" VERSION_GREATER "0.27.99"))
+ 
+     find_package(LibExiv2 REQUIRED)
++    set(EXIV2_PACKAGE_NAME "LibExiv2")
+ 
+ else()
+ 
+-    set (LibExiv2_FOUND FALSE)
++    set(LibExiv2_FOUND FALSE)
+     find_package(exiv2 REQUIRED)
++    set(EXIV2_PACKAGE_NAME "exiv2")
+ 
+ endif()
+ 
+-set_package_properties("exiv2"     PROPERTIES
+-                       DESCRIPTION "Required to build digiKam"
+-                       URL         "https://www.exiv2.org"
+-                       TYPE        RECOMMENDED
+-                       PURPOSE     "Library to manage image metadata"
++set_package_properties(${EXIV2_PACKAGE_NAME} PROPERTIES
++                       DESCRIPTION           "Required to build digiKam"
++                       URL                   "https://www.exiv2.org"
++                       TYPE                  RECOMMENDED
++                       PURPOSE               "Library to manage image metadata"
+ )
+ 
+ if(LibExiv2_FOUND)
+@@ -32,16 +34,6 @@ if(LibExiv2_FOUND)
+ 
+     endif()
+ 
+-    if("${LibExiv2_VERSION}" VERSION_LESS "0.27.99")
+-
+-        set(EXIV2_CXX_STANDARD 11)
+-
+-    else()
+-
+-        set(EXIV2_CXX_STANDARD 17)
+-
+-    endif()
+-
+ else()
+ 
+     if("${exiv2_VERSION}" VERSION_LESS ${EXIV2_MIN_VERSION})
+@@ -50,14 +42,14 @@ else()
+ 
+     endif()
+ 
+-    if("${exiv2_VERSION}" VERSION_LESS "0.27.99")
++endif()
+ 
+-        set(EXIV2_CXX_STANDARD 11)
++if(("${exiv2_VERSION}" VERSION_GREATER "0.27.99") OR ("${LibExiv2_VERSION}" VERSION_GREATER "0.27.99"))
+ 
+-    else()
++    set(EXIV2_CXX_STANDARD 17)
+ 
+-        set(EXIV2_CXX_STANDARD 17)
++else()
+ 
+-    endif()
++    set(EXIV2_CXX_STANDARD 11)
+ 
+ endif()
+-- 
+2.42.0
+
diff --git a/srcpkgs/digikam/template b/srcpkgs/digikam/template
index 206185f565488..4784bf7d62a8e 100644
--- a/srcpkgs/digikam/template
+++ b/srcpkgs/digikam/template
@@ -1,7 +1,7 @@
 # Template file for 'digikam'
 pkgname=digikam
 version=8.1.0
-revision=1
+revision=2
 build_style=cmake
 configure_args="-DBUILD_TESTING=OFF"
 hostmakedepends="extra-cmake-modules gettext pkg-config bison flex qt5-qmake

From 942d196a1a1c81893556903d20789fcebbd7a6fe Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 05/22] geeqie: revbump for exiv2-0.28.1.

---
 srcpkgs/geeqie/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/geeqie/template b/srcpkgs/geeqie/template
index b5f958f854c1b..b494bc149e957 100644
--- a/srcpkgs/geeqie/template
+++ b/srcpkgs/geeqie/template
@@ -1,7 +1,7 @@
 # Template file for 'geeqie'
 pkgname=geeqie
 version=2.1
-revision=1
+revision=2
 build_style=meson
 hostmakedepends="pkg-config gettext xxd gdk-pixbuf-devel glib-devel"
 makedepends="gtk+3-devel glib-devel lcms2-devel exiv2-devel libheif-devel

From aaf8aae2857a413bfe47996df01eaa6a44b53e21 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 06/22] gthumb: revbump for exiv2-0.28.1.

---
 srcpkgs/gthumb/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/gthumb/template b/srcpkgs/gthumb/template
index c8e19f0dedb61..732d5e1c6089f 100644
--- a/srcpkgs/gthumb/template
+++ b/srcpkgs/gthumb/template
@@ -1,7 +1,7 @@
 # Template file for 'gthumb'
 pkgname=gthumb
 version=3.12.3
-revision=1
+revision=2
 build_style=meson
 hostmakedepends="gettext pkg-config itstool glib-devel"
 makedepends="webkit2gtk-devel json-glib-devel libsecret-devel librsvg-devel

From 9ad2b53c4de3b8131c01f603e8d85fc730376d22 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 07/22] gwenview: revbump for exiv2-0.28.1.

---
 srcpkgs/gwenview/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/gwenview/template b/srcpkgs/gwenview/template
index 1a9978f384084..c6ec9494eb067 100644
--- a/srcpkgs/gwenview/template
+++ b/srcpkgs/gwenview/template
@@ -1,7 +1,7 @@
 # Template file for 'gwenview'
 pkgname=gwenview
 version=23.08.3
-revision=1
+revision=2
 build_style=cmake
 build_helper=qemu
 hostmakedepends="extra-cmake-modules pkg-config qt5-qmake qt5-host-tools

From 5861d97c17050927f2f44d8bb6fbb01de63e805f Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 08/22] hugin: revbump for exiv2-0.28.1.

---
 srcpkgs/hugin/patches/exiv2-0.28.patch | 77 ++++++++++++++++++++++++++
 1 file changed, 77 insertions(+)
 create mode 100644 srcpkgs/hugin/patches/exiv2-0.28.patch

diff --git a/srcpkgs/hugin/patches/exiv2-0.28.patch b/srcpkgs/hugin/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..49f0518117020
--- /dev/null
+++ b/srcpkgs/hugin/patches/exiv2-0.28.patch
@@ -0,0 +1,77 @@
+Patch-Source: https://gitlab.archlinux.org/archlinux/packaging/packages/hugin/-/blob/main/exiv2-0.28.patch
+diff -r 79cd11a7a66f src/hugin_base/panodata/Exiv2Helper.cpp
+--- a/src/hugin_base/panodata/Exiv2Helper.cpp	Wed May 24 19:13:20 2023 +0200
++++ b/src/hugin_base/panodata/Exiv2Helper.cpp	Mon Jun 05 00:31:19 2023 +0200
+@@ -40,7 +40,7 @@
+             Exiv2::ExifData::iterator itr = exifData.findKey(Exiv2::ExifKey(keyName));
+             if (itr != exifData.end() && itr->count())
+             {
+-                value = itr->toLong();
++                value = itr->toUint32();
+                 return true;
+             }
+             else
+@@ -165,7 +165,7 @@
+         {
+             if(it!=exifData.end() && it->count())
+             {
+-                return it->toLong();
++                return it->toUint32();
+             }
+             return 0;
+         };
+@@ -600,4 +600,4 @@
+         };
+ 
+     }; //namespace Exiv2Helper
+-}; //namespace HuginBase
+\ No newline at end of file
++}; //namespace HuginBase
+diff -r 79cd11a7a66f src/hugin_base/panodata/SrcPanoImage.cpp
+--- a/src/hugin_base/panodata/SrcPanoImage.cpp	Wed May 24 19:13:20 2023 +0200
++++ b/src/hugin_base/panodata/SrcPanoImage.cpp	Mon Jun 05 00:31:19 2023 +0200
+@@ -384,7 +384,7 @@
+                     pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaImageWidthPixels"));
+                     if (pos != xmpData.end())
+                     {
+-                        croppedWidth = pos->toLong();
++                        croppedWidth = pos->toUint32();
+                     }
+                     else
+                     {
+@@ -394,7 +394,7 @@
+                     pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaImageHeightPixels"));
+                     if (pos != xmpData.end())
+                     {
+-                        croppedHeight = pos->toLong();
++                        croppedHeight = pos->toUint32();
+                     }
+                     else
+                     {
+@@ -408,7 +408,7 @@
+                         double hfov = 0;
+                         if (pos != xmpData.end())
+                         {
+-                            hfov = 360 * croppedWidth / (double)pos->toLong();
++                            hfov = 360 * croppedWidth / (double)pos->toUint32();
+                         }
+                         else
+                         {
+@@ -419,7 +419,7 @@
+                         pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.FullPanoHeightPixels"));
+                         if (pos != xmpData.end())
+                         {
+-                            fullHeight = pos->toLong();
++                            fullHeight = pos->toUint32();
+                         }
+                         else
+                         {
+@@ -430,7 +430,7 @@
+                         pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaTopPixels"));
+                         if (pos != xmpData.end())
+                         {
+-                            cropTop = pos->toLong();
++                            cropTop = pos->toUint32();
+                         }
+                         else
+                         {

From 5e215295607efabc5e50a33a1bad57012db7442d Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 09/22] kfilemetadata5: revbump for exiv2-0.28.1.

---
 srcpkgs/kfilemetadata5/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/kfilemetadata5/template b/srcpkgs/kfilemetadata5/template
index 00f7a98cf6399..e294ae5af947c 100644
--- a/srcpkgs/kfilemetadata5/template
+++ b/srcpkgs/kfilemetadata5/template
@@ -1,7 +1,7 @@
 # Template file for 'kfilemetadata5'
 pkgname=kfilemetadata5
 version=5.111.0
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="kcoreaddons extra-cmake-modules pkg-config qt5-host-tools qt5-qmake
  gettext kcoreaddons python3"

From 76e5b4bad03acfa67bffc2eb09cac944e7bdaaf2 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 10/22] krename: revbump for exiv2-0.28.1.

---
 srcpkgs/krename/patches/e7dd767a.patch | 90 ++++++++++++++++++++++++++
 srcpkgs/krename/template               |  2 +-
 2 files changed, 91 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/krename/patches/e7dd767a.patch

diff --git a/srcpkgs/krename/patches/e7dd767a.patch b/srcpkgs/krename/patches/e7dd767a.patch
new file mode 100644
index 0000000000000..a0ef428ce46b1
--- /dev/null
+++ b/srcpkgs/krename/patches/e7dd767a.patch
@@ -0,0 +1,90 @@
+Patch-Source: https://invent.kde.org/utilities/krename/-/commit/e7dd767a
+From e7dd767a9a1068ee1fe1502c4d619b57d3b12add Mon Sep 17 00:00:00 2001
+From: Andreas Sturmlechner <asturm@gentoo.org>
+Date: Fri, 26 May 2023 23:23:10 +0200
+Subject: [PATCH] Fix build with >=exiv2-0.28, raise minimum to 0.27
+
+- enables use of EXIV2_TEST_VERSION macro
+- exiv2 headers cleanup
+
+Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>
+---
+ CMakeLists.txt         |  6 +-----
+ config-krename.h.cmake |  3 ---
+ src/exiv2plugin.cpp    | 17 +++++------------
+ 3 files changed, 6 insertions(+), 20 deletions(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 0bda8ac..72e7297 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -56,13 +56,9 @@ set_package_properties(Taglib PROPERTIES
+     TYPE OPTIONAL)
+ 
+ # Find exiv2
+-find_package(LibExiv2 0.13) # AccessMode was added in 0.13
++find_package(LibExiv2 0.27) # EXIV2_TEST_VERSION was added in 0.27
+ set_package_properties(LibExiv2 PROPERTIES TYPE OPTIONAL)
+ 
+-if (LibExiv2_VERSION VERSION_GREATER_EQUAL "0.27")
+-    set(HAVE_LIBEXIV2_0_27 TRUE)
+-endif()
+-
+ # Find podofo
+ find_package(PoDoFo)
+ set_package_properties(PoDoFo PROPERTIES
+diff --git a/config-krename.h.cmake b/config-krename.h.cmake
+index 76c3d30..862e40b 100644
+--- a/config-krename.h.cmake
++++ b/config-krename.h.cmake
+@@ -6,9 +6,6 @@
+ /* have Exiv2 */
+ #cmakedefine01 HAVE_EXIV2
+ 
+-/* Defined if we have libexiv2 >= 0.27 */
+-#cmakedefine HAVE_LIBEXIV2_0_27
+-
+ /* have PoDoFo */
+ #cmakedefine01 HAVE_PODOFO
+ 
+diff --git a/src/exiv2plugin.cpp b/src/exiv2plugin.cpp
+index 5694d8c..25e8869 100644
+--- a/src/exiv2plugin.cpp
++++ b/src/exiv2plugin.cpp
+@@ -3,20 +3,9 @@
+ 
+ #include "exiv2plugin.h"
+ 
+-#include "../config-krename.h"
+-
+ #include <KLocalizedString>
+ 
+-#include <exiv2/error.hpp>
+-#include <exiv2/exif.hpp>
+-#include <exiv2/image.hpp>
+-#include <exiv2/iptc.hpp>
+-#ifdef HAVE_LIBEXIV2_0_27
+-    #include <exiv2/xmp_exiv2.hpp>
+-#else
+-    #include <exiv2/xmp.hpp>
+-#endif
+-#include <exiv2/tags.hpp>
++#include <exiv2/exiv2.hpp>
+ 
+ #include "batchrenamer.h"
+ #include "tokenhelpdialog.h"
+@@ -381,7 +370,11 @@ QString Exiv2Plugin::processFile(BatchRenamer *b, int index, const QString &file
+     std::string strFilename(asc.constData(), asc.length());
+ 
+     try {
++#if EXIV2_TEST_VERSION(0,28,0)
++        Image::UniquePtr image = Exiv2::ImageFactory::open(strFilename);
++#else
+         Image::AutoPtr image = Exiv2::ImageFactory::open(strFilename);
++#endif
+         if (image.get() != nullptr && image->good()) {
+             image->readMetadata();
+ 
+-- 
+GitLab
+
diff --git a/srcpkgs/krename/template b/srcpkgs/krename/template
index 66023163e3293..df5535007714a 100644
--- a/srcpkgs/krename/template
+++ b/srcpkgs/krename/template
@@ -1,7 +1,7 @@
 # Template file for 'krename'
 pkgname=krename
 version=5.0.2
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="extra-cmake-modules gettext kcoreaddons pkg-config qt5-host-tools qt5-qmake"
 makedepends="exiv2-devel freetype-devel kjs-devel kparts-devel libpodofo-devel

From 60d47ce5c1307f3122e1e4db60db05dee81423a9 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 11/22] libextractor: revbump for exiv2-0.28.1.

---
 srcpkgs/libextractor/patches/exiv2-0.28.patch | 286 ++++++++++++++++++
 srcpkgs/libextractor/patches/fix-tests.diff   |  24 ++
 2 files changed, 310 insertions(+)
 create mode 100644 srcpkgs/libextractor/patches/exiv2-0.28.patch
 create mode 100644 srcpkgs/libextractor/patches/fix-tests.diff

diff --git a/srcpkgs/libextractor/patches/exiv2-0.28.patch b/srcpkgs/libextractor/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..270a626d8ab06
--- /dev/null
+++ b/srcpkgs/libextractor/patches/exiv2-0.28.patch
@@ -0,0 +1,286 @@
+Patch-Source: https://gitlab.archlinux.org/archlinux/packaging/packages/libextractor/-/blob/main/exiv2-0.28.patch
+diff --git a/src/plugins/exiv2_extractor.cc b/src/plugins/exiv2_extractor.cc
+index 78f9bda..d32ed6a 100644
+--- a/src/plugins/exiv2_extractor.cc
++++ b/src/plugins/exiv2_extractor.cc
+@@ -90,7 +90,11 @@ virtual int close ();
+  * @param rcount number of bytes to read
+  * @return buffer with data read, empty buffer (!) on failure (!)
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++virtual Exiv2::DataBuf read (size_t rcount);
++#else
+ virtual Exiv2::DataBuf read (long rcount);
++#endif
+ 
+ /**
+  * Read up to 'rcount' bytes into 'buf'.
+@@ -99,8 +103,17 @@ virtual Exiv2::DataBuf read (long rcount);
+  * @param rcount size of 'buf'
+  * @return number of bytes read successfully, 0 on failure (!)
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++virtual size_t read (Exiv2::byte *buf,
++                   size_t rcount);
++#else
+ virtual long read (Exiv2::byte *buf,
+                    long rcount);
++#endif
++
++#if EXIV2_TEST_VERSION (0,28,0)
++virtual void populateFakeData();
++#endif
+ 
+ /**
+  * Read a single character.
+@@ -117,8 +130,13 @@ virtual int getb ();
+  * @param wcount how many bytes to write
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual size_t write (const Exiv2::byte *data,
++                    size_t wcount);
++#else
+ virtual long write (const Exiv2::byte *data,
+                     long wcount);
++#endif
+ 
+ /**
+  * Write to stream.
+@@ -126,7 +144,11 @@ virtual long write (const Exiv2::byte *data,
+  * @param src stream to copy
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual size_t write (Exiv2::BasicIo &src);
++#else
+ virtual long write (Exiv2::BasicIo &src);
++#endif
+ 
+ /**
+  * Write a single byte.
+@@ -172,7 +194,11 @@ virtual int munmap ();
+  *
+  * @return -1 on error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual size_t tell (void) const;
++#else
+ virtual long int tell (void) const;
++#endif
+ 
+ /**
+  * Return overall size of the file.
+@@ -213,7 +239,11 @@ virtual bool eof () const;
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual const std::string& path () const noexcept;
++#else
+ virtual std::string path () const;
++#endif
+ 
+ #ifdef EXV_UNICODE_PATH
+ /**
+@@ -230,7 +260,11 @@ virtual std::wstring wpath () const;
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual Exiv2::BasicIo::UniquePtr temporary () const;
++#else
+ virtual Exiv2::BasicIo::AutoPtr temporary () const;
++#endif
+ 
+ };
+ 
+@@ -266,7 +300,11 @@ ExtractorIO::close ()
+  * @return buffer with data read, empty buffer (!) on failure (!)
+  */
+ Exiv2::DataBuf
++#if EXIV2_TEST_VERSION (0,28,0)
++ExtractorIO::read (size_t rcount)
++#else
+ ExtractorIO::read (long rcount)
++#endif
+ {
+   void *data;
+   ssize_t ret;
+@@ -284,9 +322,15 @@ ExtractorIO::read (long rcount)
+  * @param rcount size of 'buf'
+  * @return number of bytes read successfully, 0 on failure (!)
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++size_t
++ExtractorIO::read (Exiv2::byte *buf,
++                   size_t rcount)
++#else
+ long
+ ExtractorIO::read (Exiv2::byte *buf,
+                    long rcount)
++#endif
+ {
+   void *data;
+   ssize_t ret;
+@@ -305,6 +349,12 @@ ExtractorIO::read (Exiv2::byte *buf,
+   return got;
+ }
+ 
++#if EXIV2_TEST_VERSION (0,28,0)
++void ExtractorIO::populateFakeData()
++{
++  return;
++}
++#endif
+ 
+ /**
+  * Read a single character.
+@@ -319,7 +369,9 @@ ExtractorIO::getb ()
+   const unsigned char *r;
+ 
+   if (1 != ec->read (ec->cls, &data, 1))
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION(0,28,0)
++    throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+     throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+     throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -336,9 +388,15 @@ ExtractorIO::getb ()
+  * @param wcount how many bytes to write
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++size_t
++ExtractorIO::write (const Exiv2::byte *data,
++                    size_t wcount)
++#else
+ long
+ ExtractorIO::write (const Exiv2::byte *data,
+                     long wcount)
++#endif
+ {
+   return -1;
+ }
+@@ -350,7 +408,11 @@ ExtractorIO::write (const Exiv2::byte *data,
+  * @param src stream to copy
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++size_t
++#else
+ long
++#endif
+ ExtractorIO::write (Exiv2::BasicIo &src)
+ {
+   return -1;
+@@ -378,7 +440,9 @@ ExtractorIO::putb (Exiv2::byte data)
+ void
+ ExtractorIO::transfer (Exiv2::BasicIo& src)
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION(0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -427,7 +491,9 @@ ExtractorIO::seek (long offset,
+ Exiv2::byte *
+ ExtractorIO::mmap (bool isWritable)
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION (0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -452,7 +518,11 @@ ExtractorIO::munmap ()
+  *
+  * @return -1 on error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++size_t
++#else
+ long int
++#endif
+ ExtractorIO::tell (void) const
+ {
+   return (long) ec->seek (ec->cls, 0, SEEK_CUR);
+@@ -516,10 +586,17 @@ ExtractorIO::eof () const
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++const std::string&
++ExtractorIO::path () const noexcept
++#else
+ std::string
+ ExtractorIO::path () const
++#endif
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION (0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -536,7 +613,9 @@ ExtractorIO::path () const
+ std::wstring
+ ExtractorIO::wpath () const
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION (0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -552,11 +631,17 @@ ExtractorIO::wpath () const
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++Exiv2::BasicIo::UniquePtr
++#else
+ Exiv2::BasicIo::AutoPtr
++#endif
+ ExtractorIO::temporary () const
+ {
+   fprintf (stderr, "throwing temporary error\n");
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION(0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -737,8 +822,13 @@ EXTRACTOR_exiv2_extract_method (struct EXTRACTOR_ExtractContext *ec)
+ #if ! EXIV2_TEST_VERSION (0,24,0)
+     Exiv2::LogMsg::setLevel (Exiv2::LogMsg::mute);
+ #endif
++#if EXIV2_TEST_VERSION(0,28,0)
++    std::unique_ptr<Exiv2::BasicIo> eio (new ExtractorIO (ec));
++    Exiv2::Image::UniquePtr image = Exiv2::ImageFactory::open (std::move(eio));
++#else
+     std::auto_ptr<Exiv2::BasicIo> eio (new ExtractorIO (ec));
+     Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open (eio);
++#endif
+     if (0 == image.get ())
+       return;
+     image->readMetadata ();
+@@ -822,7 +912,11 @@ EXTRACTOR_exiv2_extract_method (struct EXTRACTOR_ExtractContext *ec)
+       ADDXMP ("Xmp.lr.hierarchicalSubject", EXTRACTOR_METATYPE_SUBJECT);
+     }
+   }
++#if EXIV2_TEST_VERSION (0,28,0)
++  catch (const Exiv2::Error& e)
++#else
+   catch (const Exiv2::AnyError& e)
++#endif
+   {
+ #if DEBUG
+     std::cerr << "Caught Exiv2 exception '" << e << "'\n";
diff --git a/srcpkgs/libextractor/patches/fix-tests.diff b/srcpkgs/libextractor/patches/fix-tests.diff
new file mode 100644
index 0000000000000..3b4ee7cbeea33
--- /dev/null
+++ b/srcpkgs/libextractor/patches/fix-tests.diff
@@ -0,0 +1,24 @@
+--- a/src/plugins/test_exiv2.c	2021-01-30 13:20:23.000000000 +0000
++++ b/src/plugins/test_exiv2.c	2023-11-03 19:39:43.115274492 +0000
+@@ -49,8 +49,8 @@
+       EXTRACTOR_METATYPE_GPS_LATITUDE,
+       EXTRACTOR_METAFORMAT_UTF8,
+       "text/plain",
+-      "28deg 8' (18|17.585)\" ?",
+-      strlen ("28deg 8' (18|17.585)\" ?") + 1,
++      "28 deg 8' (18|17.58)\" ?",
++      strlen ("28 deg 8' (18|17.58)\" ?") + 1,
+       0,
+       .regex = 1
+     },
+@@ -66,8 +66,8 @@
+       EXTRACTOR_METATYPE_GPS_LONGITUDE,
+       EXTRACTOR_METAFORMAT_UTF8,
+       "text/plain",
+-      "14deg 14' (22|21.713)\" ?",
+-      strlen ("14deg 14' (22|21.713)\" ?"),
++      "14 deg 14' (22|21.71)\" ?",
++      strlen ("14 deg 14' (22|21.71)\" ?"),
+       0,
+       .regex = 1
+     },

From 3c06fcc741eaa9f39e7b1da894f74ee3ca132c5d Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 12/22] libgexiv2: update to 0.14.2.

---
 srcpkgs/libgexiv2/template | 14 +++++++-------
 1 file changed, 7 insertions(+), 7 deletions(-)

diff --git a/srcpkgs/libgexiv2/template b/srcpkgs/libgexiv2/template
index 23780e5397dc4..91dbcaa9aca52 100644
--- a/srcpkgs/libgexiv2/template
+++ b/srcpkgs/libgexiv2/template
@@ -1,19 +1,19 @@
 # Template file for 'libgexiv2'
 pkgname=libgexiv2
-version=0.14.0
-revision=3
+version=0.14.2
+revision=1
 build_style=meson
 build_helper="gir"
-configure_args="-Dintrospection=$(vopt_if gir true false)
- -Dvapi=$(vopt_if vala true false)"
+configure_args="$(vopt_bool gir introspection) $(vopt_bool vala vapi)"
 hostmakedepends="pkg-config glib-devel $(vopt_if vala 'vala') python3-gobject"
 makedepends="libglib-devel exiv2-devel"
 short_desc="GObject-based wrapper around the Exiv2 library"
 maintainer="Enno Boland <gottox@voidlinux.org>"
 license="GPL-2.0-or-later"
 homepage="https://wiki.gnome.org/Projects/gexiv2"
-distfiles="${GNOME_SITE}/gexiv2/${version%.*}/${pkgname/lib/}-${version}.tar.xz"
-checksum=e58279a6ff20b6f64fa499615da5e9b57cf65ba7850b72fafdf17221a9d6d69e
+changelog="https://gitlab.gnome.org/GNOME/gexiv2/-/raw/master/NEWS"
+distfiles="${GNOME_SITE}/gexiv2/${version%.*}/gexiv2-${version}.tar.xz"
+checksum=2a0c9cf48fbe8b3435008866ffd40b8eddb0667d2212b42396fdf688e93ce0be
 
 build_options="gir vala"
 build_options_default="gir vala"
@@ -23,7 +23,7 @@ libgexiv2-devel_package() {
 	short_desc+=" - development files"
 	pkg_install() {
 		vmove usr/include
-		vmove usr/lib/*.so
+		vmove "usr/lib/*.so"
 		vmove usr/lib/pkgconfig
 		if [ "$build_option_vala" ]; then
 			vmove usr/share/vala

From 655a0dfadb452edfadb2982eb221958c3bc0eac5 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 13/22] libkexiv25: update to 23.08.2.

---
 srcpkgs/libkexiv25/template | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/srcpkgs/libkexiv25/template b/srcpkgs/libkexiv25/template
index b439a42ef2b97..4d7f9600572ea 100644
--- a/srcpkgs/libkexiv25/template
+++ b/srcpkgs/libkexiv25/template
@@ -1,6 +1,6 @@
 # Template file for 'libkexiv25'
 pkgname=libkexiv25
-version=23.04.0
+version=23.08.2
 revision=1
 build_style=cmake
 configure_args="-DBUILD_TESTING=OFF"
@@ -11,7 +11,7 @@ maintainer="Orphaned <orphan@voidlinux.org>"
 license="GPL-2.0-or-later"
 homepage="https://invent.kde.org/graphics/libkexiv2"
 distfiles="${KDE_SITE}/release-service/${version}/src/libkexiv2-${version}.tar.xz"
-checksum=18d3eed06df9d1e31d8434ed9887e305aba176d0856e19a8cd3bdb555b80d391
+checksum=d06e36a408bf2e846a18056a1f15e61d981fa2a1fceb81f7c15136604319d033
 
 libkexiv25-devel_package() {
 	short_desc+=" - development files"

From 01c6ca2bd700d70aa7f5d2d69293ab78e1fed542 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 14/22] nomacs: update to 3.17.2287.

---
 srcpkgs/nomacs/template | 17 +++++++++++++----
 1 file changed, 13 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/nomacs/template b/srcpkgs/nomacs/template
index c52cd54e294db..956bd21ebb129 100644
--- a/srcpkgs/nomacs/template
+++ b/srcpkgs/nomacs/template
@@ -1,7 +1,8 @@
 # Template file for 'nomacs'
 pkgname=nomacs
-version=3.16.224
-revision=5
+version=3.17.2287
+revision=1
+_plugins_ver=3.17.2285
 build_wrksrc=ImageLounge
 build_style=cmake
 configure_args="-DCMAKE_BUILD_TYPE=None -DENABLE_TRANSLATIONS=1
@@ -13,5 +14,13 @@ short_desc="Simple yet powerful Qt imageviewer"
 maintainer="Orphaned <orphan@voidlinux.org>"
 license="GPL-3.0-or-later"
 homepage="https://github.com/nomacs/nomacs"
-distfiles="https://github.com/nomacs/nomacs/archive/${version}.tar.gz"
-checksum=bbc7e9048026ef9e0d2b64902c88050f17a679ef3d3c009de2c3b7de5d1d217c
+distfiles="https://github.com/nomacs/nomacs/archive/${version}.tar.gz
+ https://github.com/novomesk/nomacs-plugins/archive/refs/tags/${_plugins_ver}.tar.gz>plugins.tar.gz"
+checksum="6905ea615358f84a0c83d5b1b7077871dea0526ec667500a1951448cb845a92c
+ 946b2d754be9ecca5cb155f7ecc5dcafb164f6c3dcc7bf5c3c0610d3b47774aa"
+skip_extraction="plugins.tar.gz"
+
+post_extract() {
+ cd ${build_wrksrc}
+ vsrcextract -C plugins "plugins.tar.gz"
+}

From 1bc32f3cba4b792282b32660bbc9f6d449e93aaf Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 15/22] pdf2djvu: revbump for exiv2-0.28.1.

---
 srcpkgs/pdf2djvu/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/pdf2djvu/template b/srcpkgs/pdf2djvu/template
index ef7433c0c98ae..5a6f3ddf4ed35 100644
--- a/srcpkgs/pdf2djvu/template
+++ b/srcpkgs/pdf2djvu/template
@@ -1,7 +1,7 @@
 # Template file for 'pdf2djvu'
 pkgname=pdf2djvu
 version=0.9.19
-revision=4
+revision=5
 build_style=gnu-configure
 hostmakedepends="pkg-config djvulibre gettext"
 makedepends="djvulibre-devel poppler-devel libgraphicsmagick-devel exiv2-devel libuuid-devel"

From 35ba5ff67fe55cb83255b70e7609af60a5b28292 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 16/22] phototonic: revbump for exiv2-0.28.1.

---
 srcpkgs/phototonic/patches/exiv2-0.28.patch | 135 ++++++++++++++++++++
 srcpkgs/phototonic/template                 |   2 +-
 2 files changed, 136 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/phototonic/patches/exiv2-0.28.patch

diff --git a/srcpkgs/phototonic/patches/exiv2-0.28.patch b/srcpkgs/phototonic/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..1c75b628dab33
--- /dev/null
+++ b/srcpkgs/phototonic/patches/exiv2-0.28.patch
@@ -0,0 +1,135 @@
+From 923a3fc14de0b779a45696c5f0aef34c74d84f13 Mon Sep 17 00:00:00 2001
+From: Andreas Sturmlechner <asturm@gentoo.org>
+Date: Sun, 28 May 2023 18:54:10 +0200
+Subject: [PATCH] Fix build with exiv2-0.28
+
+Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>
+---
+ ImageViewer.cpp   | 9 +++++++++
+ MetadataCache.cpp | 8 ++++++++
+ Phototonic.cpp    | 4 ++++
+ Tags.cpp          | 8 ++++++++
+ ThumbsViewer.cpp  | 4 ++++
+ 5 files changed, 33 insertions(+)
+
+diff --git a/ImageViewer.cpp b/ImageViewer.cpp
+index 357d223..df3ac43 100644
+--- a/ImageViewer.cpp
++++ b/ImageViewer.cpp
+@@ -945,7 +945,11 @@ void ImageViewer::keyMoveEvent(int direction) {
+ }
+ 
+ void ImageViewer::saveImage() {
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr image;
++#else
+     Exiv2::Image::AutoPtr image;
++#endif
+     bool exifError = false;
+ 
+     if (newImage) {
+@@ -985,8 +989,13 @@ void ImageViewer::saveImage() {
+ }
+ 
+ void ImageViewer::saveImageAs() {
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++    Exiv2::Image::UniquePtr newExifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
+     Exiv2::Image::AutoPtr newExifImage;
++#endif
+     bool exifError = false;
+ 
+     setCursorHiding(false);
+diff --git a/MetadataCache.cpp b/MetadataCache.cpp
+index 524ae74..5ddd4c8 100644
+--- a/MetadataCache.cpp
++++ b/MetadataCache.cpp
+@@ -64,7 +64,11 @@ void MetadataCache::clear() {
+ }
+ 
+ bool MetadataCache::loadImageMetadata(const QString &imageFullPath) {
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
++#endif
+     QSet<QString> tags;
+     long orientation = 0;
+ 
+@@ -78,7 +82,11 @@ bool MetadataCache::loadImageMetadata(const QString &imageFullPath) {
+     try {
+         Exiv2::ExifData &exifData = exifImage->exifData();
+         if (!exifData.empty()) {
++#if EXIV2_TEST_VERSION(0,28,0)
++            orientation = exifData["Exif.Image.Orientation"].value().toUint32();
++#else
+             orientation = exifData["Exif.Image.Orientation"].value().toLong();
++#endif
+         }
+     } catch (Exiv2::Error &error) {
+         qWarning() << "Failed to read Exif metadata";
+diff --git a/Phototonic.cpp b/Phototonic.cpp
+index 6cc95b3..bd5497d 100644
+--- a/Phototonic.cpp
++++ b/Phototonic.cpp
+@@ -3151,7 +3151,11 @@ void Phototonic::removeMetadata() {
+ 
+     if (ret == MessageBox::Yes) {
+         for (int file = 0; file < fileList.size(); ++file) {
++#if EXIV2_TEST_VERSION(0,28,0)
++            Exiv2::Image::UniquePtr image;
++#else
+             Exiv2::Image::AutoPtr image;
++#endif
+             try {
+                 image = Exiv2::ImageFactory::open(fileList[file].toStdString());
+                 image->clearMetadata();
+diff --git a/Tags.cpp b/Tags.cpp
+index 84eea16..a62da9d 100644
+--- a/Tags.cpp
++++ b/Tags.cpp
+@@ -136,7 +136,11 @@ void ImageTags::addTag(QString tagName, bool tagChecked) {
+ 
+ bool ImageTags::writeTagsToImage(QString &imageFileName, QSet<QString> &newTags) {
+     QSet<QString> imageTags;
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
++#endif
+ 
+     try {
+         exifImage = Exiv2::ImageFactory::open(imageFileName.toStdString());
+@@ -160,7 +164,11 @@ bool ImageTags::writeTagsToImage(QString &imageFileName, QSet<QString> &newTags)
+         QSetIterator<QString> newTagsIt(newTags);
+         while (newTagsIt.hasNext()) {
+             QString tag = newTagsIt.next();
++#if EXIV2_TEST_VERSION(0,28,0)
++            Exiv2::Value::UniquePtr value = Exiv2::Value::create(Exiv2::string);
++#else
+             Exiv2::Value::AutoPtr value = Exiv2::Value::create(Exiv2::string);
++#endif
+             value->read(tag.toStdString());
+             Exiv2::IptcKey key("Iptc.Application2.Keywords");
+             newIptcData.add(key, value.get());
+diff --git a/ThumbsViewer.cpp b/ThumbsViewer.cpp
+index 77a6189..4a11475 100644
+--- a/ThumbsViewer.cpp
++++ b/ThumbsViewer.cpp
+@@ -210,7 +210,11 @@ void ThumbsViewer::updateImageInfoViewer(QString imageFullPath) {
+         infoView->addEntry(key, val);
+     }
+ 
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
++#endif
+     try {
+         exifImage = Exiv2::ImageFactory::open(imageFullPath.toStdString());
+         exifImage->readMetadata();
+-- 
+2.40.1
+
diff --git a/srcpkgs/phototonic/template b/srcpkgs/phototonic/template
index 77ae8bf6a4406..4af006cb7da41 100644
--- a/srcpkgs/phototonic/template
+++ b/srcpkgs/phototonic/template
@@ -1,7 +1,7 @@
 # Template file for 'phototonic'
 pkgname=phototonic
 version=2.1
-revision=3
+revision=4
 build_style=qmake
 hostmakedepends="pkg-config qt5-qmake qt5-host-tools"
 makedepends="qt5-svg-devel exiv2-devel"

From ea225833de13cef3453f5aae2d4927cb6448255d Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 17/22] qimgv: revbump for exiv2-0.28.1.

---
 srcpkgs/qimgv/patches/exiv2-0.28.patch | 16 ++++++++++++++++
 srcpkgs/qimgv/template                 |  2 +-
 2 files changed, 17 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/qimgv/patches/exiv2-0.28.patch

diff --git a/srcpkgs/qimgv/patches/exiv2-0.28.patch b/srcpkgs/qimgv/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..11f37b5ae2be3
--- /dev/null
+++ b/srcpkgs/qimgv/patches/exiv2-0.28.patch
@@ -0,0 +1,16 @@
+Patch-Source: https://git.alpinelinux.org/aports/tree/community/qimgv/exiv2-0.28.patch
+diff --git a/qimgv/sourcecontainers/documentinfo.cpp b/qimgv/sourcecontainers/documentinfo.cpp
+index 98a68f7..c062474 100644
+--- a/qimgv/sourcecontainers/documentinfo.cpp
++++ b/qimgv/sourcecontainers/documentinfo.cpp
+@@ -271,10 +271,6 @@ void DocumentInfo::loadExifTags() {
+         //std::cout << "Caught Exiv2 exception '" << e.what() << "'\n";
+         return;
+     }
+-    catch (Exiv2::BasicError<CharType> e) {
+-        //std::cout << "Caught BasicError Exiv2 exception '" << e.what() << "'\n";
+-        return;
+-    }
+ #endif
+ }
+ 
diff --git a/srcpkgs/qimgv/template b/srcpkgs/qimgv/template
index 7eb30db33992c..dd341dfe1bfce 100644
--- a/srcpkgs/qimgv/template
+++ b/srcpkgs/qimgv/template
@@ -1,7 +1,7 @@
 # Template file for 'qimgv'
 pkgname=qimgv
 version=1.0.2
-revision=2
+revision=3
 build_style=cmake
 configure_args="$(vopt_if video -DVIDEO_SUPPORT=ON -DVIDEO_SUPPORT=OFF)
  $(vopt_if scale -DOPENCV_SUPPORT=ON -DOPENCV_SUPPORT=OFF)

From 21dac152919e6a0b9c7450338d5c40e54908469c Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 18/22] SIR: revbump for exiv2-0.28.1.

---
 srcpkgs/SIR/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/SIR/template b/srcpkgs/SIR/template
index 113077acad354..c6da4c26b6c71 100644
--- a/srcpkgs/SIR/template
+++ b/srcpkgs/SIR/template
@@ -1,7 +1,7 @@
 # Template file for 'SIR'
 pkgname=SIR
 version=3.2.2
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="pkg-config"
 makedepends="exiv2-devel qt5-svg-devel qt5-tools-devel"

From 68fa4a661425426e8c92d90a3ad75cbcb3d02e1b Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 19/22] viewnior: revbump for exiv2-0.28.1.

---
 srcpkgs/viewnior/patches/exiv2-0.28.patch | 147 ++++++++++++++++++++++
 srcpkgs/viewnior/template                 |   2 +-
 2 files changed, 148 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/viewnior/patches/exiv2-0.28.patch

diff --git a/srcpkgs/viewnior/patches/exiv2-0.28.patch b/srcpkgs/viewnior/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..71459dee15768
--- /dev/null
+++ b/srcpkgs/viewnior/patches/exiv2-0.28.patch
@@ -0,0 +1,147 @@
+Patch-Source: https://gitlab.archlinux.org/archlinux/packaging/packages/viewnior/-/blob/f206ce6c22a3ec5f1f9ea1bde4077584f80458dd/exiv2-0.28.patch
+--
+From b6bb81a1b46e911d15bbf9a730972523de177705 Mon Sep 17 00:00:00 2001
+From: tastytea <tastytea@tastytea.de>
+Date: Tue, 16 May 2023 10:54:40 +0200
+Subject: [PATCH 1/2] change exiv2 AutoPtr to unique_ptr
+
+exiv2-0.28.0 removed Exiv2::Image::AutoPtr and added
+Exiv2::Image::UniquePtr instead. since it's a typedef for
+std::unique_ptr<Image>, i'm using that directly instead of adding a
+condition on the exiv2 version.
+---
+ src/uni-exiv2.cpp | 21 +++++++++++----------
+ 1 file changed, 11 insertions(+), 10 deletions(-)
+
+diff --git a/src/uni-exiv2.cpp b/src/uni-exiv2.cpp
+index 0d14b9f..77064c2 100644
+--- a/src/uni-exiv2.cpp
++++ b/src/uni-exiv2.cpp
+@@ -22,12 +22,13 @@
+ 
+ #include <exiv2/exiv2.hpp>
+ #include <iostream>
++#include <memory>
+ 
+ #include "uni-exiv2.hpp"
+ 
+ #define ARRAY_SIZE(array) (sizeof array/sizeof(array[0]))
+ 
+-static Exiv2::Image::AutoPtr cached_image;
++static std::unique_ptr<Exiv2::Image> cached_image;
+ 
+ extern "C"
+ void
+@@ -35,8 +36,8 @@ uni_read_exiv2_map(const char *uri, void (*callback)(const char*, const char*, v
+ {
+     Exiv2::LogMsg::setLevel(Exiv2::LogMsg::mute);
+     try {
+-        Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open(uri);
+-        if ( image.get() == 0 ) {
++        std::unique_ptr<Exiv2::Image> image = Exiv2::ImageFactory::open(uri);
++        if (image == nullptr) {
+             return;
+         }
+ 
+@@ -91,14 +92,14 @@ uni_read_exiv2_to_cache(const char *uri)
+ {
+     Exiv2::LogMsg::setLevel(Exiv2::LogMsg::mute);
+ 
+-    if ( cached_image.get() != NULL ) {
++    if (cached_image != nullptr) {
+         cached_image->clearMetadata();
+-        cached_image.reset(NULL);
++        cached_image.reset(nullptr);
+     }
+ 
+     try {
+         cached_image = Exiv2::ImageFactory::open(uri);
+-        if ( cached_image.get() == 0 ) {
++        if (cached_image == nullptr) {
+             return 1;
+         }
+ 
+@@ -116,13 +117,13 @@ uni_write_exiv2_from_cache(const char *uri)
+ {
+     Exiv2::LogMsg::setLevel(Exiv2::LogMsg::mute);
+ 
+-    if ( cached_image.get() == NULL ) {
++    if (cached_image == nullptr) {
+         return 1;
+     }
+ 
+     try {
+-        Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open(uri);
+-        if ( image.get() == 0 ) {
++        std::unique_ptr<Exiv2::Image> image = Exiv2::ImageFactory::open(uri);
++        if (image == nullptr) {
+             return 2;
+         }
+ 
+@@ -130,7 +131,7 @@ uni_write_exiv2_from_cache(const char *uri)
+         image->writeMetadata();
+ 
+         cached_image->clearMetadata();
+-        cached_image.reset(NULL);
++        cached_image.reset(nullptr);
+ 
+         return 0;
+     } catch (Exiv2::AnyError& e) {
+
+From 47d0b98cb46526aa8aa035bebcabc14a11fa57ee Mon Sep 17 00:00:00 2001
+From: tastytea <tastytea@tastytea.de>
+Date: Tue, 16 May 2023 11:17:00 +0200
+Subject: [PATCH 2/2] add support for exiv-0.28.0 errors
+
+exiv2-0.28.0 changed Exiv2::AnyError to Exiv2::Error.
+---
+ src/uni-exiv2.cpp | 15 ++++++++++++---
+ 1 file changed, 12 insertions(+), 3 deletions(-)
+
+diff --git a/src/uni-exiv2.cpp b/src/uni-exiv2.cpp
+index 77064c2..567a50f 100644
+--- a/src/uni-exiv2.cpp
++++ b/src/uni-exiv2.cpp
+@@ -28,6 +28,15 @@
+ 
+ #define ARRAY_SIZE(array) (sizeof array/sizeof(array[0]))
+ 
++#define EXIV_ERROR Exiv2::AnyError
++#ifdef EXIV2_VERSION
++    #ifdef EXIV2_TEST_VERSION
++        #if EXIV2_TEST_VERSION(0,28,0)
++            #define EXIV_ERROR Exiv2::Error
++        #endif
++    #endif
++#endif
++
+ static std::unique_ptr<Exiv2::Image> cached_image;
+ 
+ extern "C"
+@@ -81,7 +90,7 @@ uni_read_exiv2_map(const char *uri, void (*callback)(const char*, const char*, v
+                 }
+             }
+         }
+-    } catch (Exiv2::AnyError& e) {
++    } catch (EXIV_ERROR& e) {
+         std::cerr << "Exiv2: '" << e << "'\n";
+     }
+ }
+@@ -104,7 +113,7 @@ uni_read_exiv2_to_cache(const char *uri)
+         }
+ 
+         cached_image->readMetadata();
+-    } catch (Exiv2::AnyError& e) {
++    } catch (EXIV_ERROR& e) {
+         std::cerr << "Exiv2: '" << e << "'\n";
+     }
+ 
+@@ -134,7 +143,7 @@ uni_write_exiv2_from_cache(const char *uri)
+         cached_image.reset(nullptr);
+ 
+         return 0;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (EXIV_ERROR& e) {
+         std::cerr << "Exiv2: '" << e << "'\n";
+     }
+ 
diff --git a/srcpkgs/viewnior/template b/srcpkgs/viewnior/template
index ea1e528a8651f..4c73226662ca0 100644
--- a/srcpkgs/viewnior/template
+++ b/srcpkgs/viewnior/template
@@ -1,7 +1,7 @@
 # Template file for 'viewnior'
 pkgname=viewnior
 version=1.8
-revision=1
+revision=2
 build_style=meson
 hostmakedepends="pkg-config intltool glib-devel gettext-devel"
 makedepends="gtk+-devel exiv2-devel"

From 0fc80c3ecc04227f43415d1ebdd41e004bc2f876 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Mon, 23 Oct 2023 19:06:34 +0200
Subject: [PATCH 20/22] New package: nufraw-0.43.3

Co-authored-by: triallax <triallax@tutanota.com>
---
 srcpkgs/nufraw-gimp                           |  1 +
 .../patches/0001-nufraw-glib-2.70.patch       | 20 +++++++
 srcpkgs/nufraw/patches/exiv-0.28.x.diff       | 59 +++++++++++++++++++
 srcpkgs/nufraw/template                       | 56 ++++++++++++++++++
 srcpkgs/removed-packages/template             |  4 +-
 srcpkgs/ufraw                                 |  1 +
 srcpkgs/ufraw-gimp                            |  2 +-
 .../ufraw/patches/001-no-gimp-remote.patch    | 12 ----
 srcpkgs/ufraw/patches/002-fix_abs_int.patch   | 11 ----
 .../ufraw/patches/03_fix-unsigned-char.patch  | 14 -----
 srcpkgs/ufraw/patches/exiv-0.27.patch         | 25 --------
 srcpkgs/ufraw/patches/glib-2.68.patch         | 30 ----------
 srcpkgs/ufraw/patches/iostream.patch          | 13 ----
 srcpkgs/ufraw/template                        | 38 ------------
 14 files changed, 141 insertions(+), 145 deletions(-)
 create mode 120000 srcpkgs/nufraw-gimp
 create mode 100644 srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch
 create mode 100644 srcpkgs/nufraw/patches/exiv-0.28.x.diff
 create mode 100644 srcpkgs/nufraw/template
 create mode 120000 srcpkgs/ufraw
 delete mode 100644 srcpkgs/ufraw/patches/001-no-gimp-remote.patch
 delete mode 100644 srcpkgs/ufraw/patches/002-fix_abs_int.patch
 delete mode 100644 srcpkgs/ufraw/patches/03_fix-unsigned-char.patch
 delete mode 100644 srcpkgs/ufraw/patches/exiv-0.27.patch
 delete mode 100644 srcpkgs/ufraw/patches/glib-2.68.patch
 delete mode 100644 srcpkgs/ufraw/patches/iostream.patch
 delete mode 100644 srcpkgs/ufraw/template

diff --git a/srcpkgs/nufraw-gimp b/srcpkgs/nufraw-gimp
new file mode 120000
index 0000000000000..0bd1459b2a16f
--- /dev/null
+++ b/srcpkgs/nufraw-gimp
@@ -0,0 +1 @@
+nufraw
\ No newline at end of file
diff --git a/srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch b/srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch
new file mode 100644
index 0000000000000..41f10bfbafa1f
--- /dev/null
+++ b/srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch
@@ -0,0 +1,20 @@
+diff -ru nufraw/uf_glib.h nufraw/uf_glib.h
+--- nufraw/uf_glib.h	2022-02-23 09:03:44.700472919 +0100
++++ nufraw/uf_glib.h	2022-02-23 09:04:50.260308805 +0100
+@@ -13,13 +13,13 @@
+ #ifndef _UF_GLIB_H
+ #define _UF_GLIB_H
+ 
++#include <glib.h>
++#include <glib/gstdio.h>
++
+ #ifdef __cplusplus
+ extern "C" {
+ #endif
+ 
+-#include <glib.h>
+-#include <glib/gstdio.h>
+-
+ // g_win32_locale_filename_from_utf8 is needed only on win32
+ #ifdef _WIN32
+ #define uf_win32_locale_filename_from_utf8(__some_string__) \
diff --git a/srcpkgs/nufraw/patches/exiv-0.28.x.diff b/srcpkgs/nufraw/patches/exiv-0.28.x.diff
new file mode 100644
index 0000000000000..6c23359bf706c
--- /dev/null
+++ b/srcpkgs/nufraw/patches/exiv-0.28.x.diff
@@ -0,0 +1,59 @@
+Patch taken from AUR package: https://aur.archlinux.org/cgit/aur.git/tree/exiv2-error.patch?h=nufraw&id=29e467f2c297fcd0f36548642d6d2cab6428d08f
+diff --git a/nufraw_exiv2.cc b/nufraw_exiv2.cc
+index 2de4cc3..45aea87 100644
+--- a/nufraw_exiv2.cc
++++ b/nufraw_exiv2.cc
+@@ -54,7 +54,7 @@ extern "C" int nufraw_exif_read_input(nufraw_data *uf)
+         uf->inputExifBuf = NULL;
+         uf->inputExifBufLen = 0;
+ 
+-        Exiv2::Image::AutoPtr image;
++        Exiv2::Image::UniquePtr image;
+         if (uf->unzippedBuf != NULL) {
+             image = Exiv2::ImageFactory::open(
+                         (const Exiv2::byte*)uf->unzippedBuf, uf->unzippedBufLen);
+@@ -135,7 +135,7 @@ extern "C" int nufraw_exif_read_input(nufraw_data *uf)
+         nufraw_message(NUFRAW_SET_LOG, "%s\n", stderror.str().c_str());
+ 
+         return NUFRAW_SUCCESS;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (Exiv2::Error& e) {
+         std::cerr.rdbuf(savecerr);
+         std::string s(e.what());
+         nufraw_message(NUFRAW_SET_WARNING, "%s\n", s.c_str());
+@@ -156,7 +156,7 @@ static Exiv2::ExifData nufraw_prepare_exifdata(nufraw_data *uf)
+         if ((pos = exifData.findKey(Exiv2::ExifKey("Exif.Image.Orientation")))
+                 != exifData.end()) {
+             nufraw_message(NUFRAW_SET_LOG, "Resetting %s from '%d' to '1'\n",
+-                          pos->key().c_str(), pos->value().toLong());
++                          pos->key().c_str(), pos->value().toInt64());
+             pos->setValue("1"); /* 1 = Normal orientation */
+         }
+     }
+@@ -327,7 +327,7 @@ extern "C" int nufraw_exif_prepare_output(nufraw_data *uf)
+         nufraw_message(NUFRAW_SET_LOG, "%s\n", stderror.str().c_str());
+ 
+         return NUFRAW_SUCCESS;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (Exiv2::Error& e) {
+         std::cerr.rdbuf(savecerr);
+         std::string s(e.what());
+         nufraw_message(NUFRAW_SET_WARNING, "%s\n", s.c_str());
+@@ -347,7 +347,7 @@ extern "C" int nufraw_exif_write(nufraw_data *uf)
+ 
+         char *filename =
+             uf_win32_locale_filename_from_utf8(uf->conf->outputFilename);
+-        Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open(filename);
++        Exiv2::Image::UniquePtr image = Exiv2::ImageFactory::open(filename);
+         uf_win32_locale_filename_free(filename);
+         assert(image.get() != 0);
+ 
+@@ -367,7 +367,7 @@ extern "C" int nufraw_exif_write(nufraw_data *uf)
+         nufraw_message(NUFRAW_SET_LOG, "%s\n", stderror.str().c_str());
+ 
+         return NUFRAW_SUCCESS;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (Exiv2::Error& e) {
+         std::cerr.rdbuf(savecerr);
+         std::string s(e.what());
+         nufraw_message(NUFRAW_SET_WARNING, "%s\n", s.c_str());
diff --git a/srcpkgs/nufraw/template b/srcpkgs/nufraw/template
new file mode 100644
index 0000000000000..7d75a4d372555
--- /dev/null
+++ b/srcpkgs/nufraw/template
@@ -0,0 +1,56 @@
+# Template file for 'nufraw'
+pkgname=nufraw
+version=0.43.3
+revision=1
+_ver="${version%.*}-${version##*.}"
+build_style=gnu-configure
+configure_args="--enable-contrast --enable-mime --enable-openmp --with-gimp
+ --enable-extras"
+hostmakedepends="pkg-config automake libtool glib-devel"
+# libgexiv2-devel is only here to fix build order, remove on next template
+# change
+makedepends="exiv2-devel gimp-devel glib-devel gtkimageview-devel lcms2-devel
+ lensfun-devel jasper-devel libgexiv2-devel"
+depends="desktop-file-utils"
+short_desc="Utility to read and manipulate raw images from digital cameras"
+maintainer="John <me@johnnynator.dev>"
+license="GPL-2.0-or-later"
+homepage="https://sourceforge.net/projects/nufraw/"
+distfiles="${SOURCEFORGE_SITE}/nufraw/nufraw-${_ver}.tar.gz"
+checksum=2c7dcc1590993ec267b3112562b2433010d6f94f6acc6506c76aa29cf8c6c32c
+
+case "$XBPS_TARGET_MACHINE" in
+	armv[67]l* | aarch64*)
+		makedepends+=" libgomp-devel"
+		make_build_args="CXXFLAGS+=-fsigned-char LDFLAGS+=-fopenmp"
+		;;
+esac
+
+pre_configure() {
+	autoreconf -fi
+}
+
+pre_build() {
+	mv nufraw.desktop{.desktop,}
+	chmod +x generate_schemas.sh
+}
+
+nufraw-gimp_package() {
+	depends="${sourcepkg}>=${version}_${revision}"
+	short_desc+=" - gimp plugin"
+	pkg_install() {
+		vmove usr/lib/gimp
+	}
+}
+
+ufraw_package() {
+	depends="${sourcepkg}>=${version}_${revision}"
+	build_style=meta
+	short_desc+=" (transitional dummy package)"
+}
+
+ufraw-gimp_package() {
+	depends="nufraw-gimp>=${version}_${revision}"
+	build_style=meta
+	short_desc+=" - gimp plugin (transitional dummy package)"
+}
diff --git a/srcpkgs/removed-packages/template b/srcpkgs/removed-packages/template
index c25c5c3e720ea..d42bc9de4a8bd 100644
--- a/srcpkgs/removed-packages/template
+++ b/srcpkgs/removed-packages/template
@@ -1,6 +1,6 @@
 # Template file for 'removed-packages'
 pkgname=removed-packages
-version=0.1.20231110
+version=0.1.20231112
 revision=1
 build_style=meta
 short_desc="Uninstalls packages removed from repository"
@@ -676,6 +676,8 @@ replaces="
  traverso<=0.49.6_2
  ttyload-git<=20141117_4
  tuxc<=1.1_3
+ ufraw-gimp<=0.22_5
+ ufraw<=0.22_5
  unicorn-python<=1.0.2_2
  upwork<=5.6.10.0_1
  urlmatch-git<=20141116_2
diff --git a/srcpkgs/ufraw b/srcpkgs/ufraw
new file mode 120000
index 0000000000000..0bd1459b2a16f
--- /dev/null
+++ b/srcpkgs/ufraw
@@ -0,0 +1 @@
+nufraw
\ No newline at end of file
diff --git a/srcpkgs/ufraw-gimp b/srcpkgs/ufraw-gimp
index 967dc902dd02b..0bd1459b2a16f 120000
--- a/srcpkgs/ufraw-gimp
+++ b/srcpkgs/ufraw-gimp
@@ -1 +1 @@
-ufraw
\ No newline at end of file
+nufraw
\ No newline at end of file
diff --git a/srcpkgs/ufraw/patches/001-no-gimp-remote.patch b/srcpkgs/ufraw/patches/001-no-gimp-remote.patch
deleted file mode 100644
index ca4f4beb6240f..0000000000000
--- a/srcpkgs/ufraw/patches/001-no-gimp-remote.patch
+++ /dev/null
@@ -1,12 +0,0 @@
-Don't use gimp-remote since gimp 2.4 already includes gimp-remote functionality
---- a/ufraw_conf.c
-+++ b/ufraw_conf.c
-@@ -137,7 +137,7 @@
- #elif HAVE_GIMP_2_4
-     "gimp", /* remoteGimpCommand */
- #else
--    "gimp-remote", /* remoteGimpCommand */
-+    "gimp", /* remoteGimpCommand */
- #endif
- 
-     /* EXIF data */
diff --git a/srcpkgs/ufraw/patches/002-fix_abs_int.patch b/srcpkgs/ufraw/patches/002-fix_abs_int.patch
deleted file mode 100644
index 6fc552769c9f8..0000000000000
--- a/srcpkgs/ufraw/patches/002-fix_abs_int.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- a/dcraw.cc	2015-06-16 05:58:38.000000000 +0200
-+++ b/dcraw.cc	2018-02-04 14:46:54.489951076 +0100
-@@ -9242,7 +9242,7 @@
-     if (make[0] == 'O') {
-       i = find_green (12, 32, 1188864, 3576832);
-       c = find_green (12, 32, 2383920, 2387016);
--      if (abs(i) < abs(c)) {
-+      if (abs((int)i) < abs((int)c)) {
- 	SWAP(i,c);
- 	load_flags = 24;
-       }
diff --git a/srcpkgs/ufraw/patches/03_fix-unsigned-char.patch b/srcpkgs/ufraw/patches/03_fix-unsigned-char.patch
deleted file mode 100644
index 8690f87ca7d59..0000000000000
--- a/srcpkgs/ufraw/patches/03_fix-unsigned-char.patch
+++ /dev/null
@@ -1,14 +0,0 @@
-Source: written by John Paul Adrian Glaubitz for Debian
-Upstream: https://sourceforge.net/p/ufraw/bugs/417
-Reason: fixes a compilation failure on arm architectures
---- a/dcraw.cc
-+++ b/dcraw.cc
-@@ -2285,7 +2285,7 @@ void CLASS quicktake_100_load_raw()
- 
- void CLASS kodak_radc_load_raw()
- {
--  static const char src[] = {
-+  static const signed char src[] = {
-     1,1, 2,3, 3,4, 4,2, 5,7, 6,5, 7,6, 7,8,
-     1,0, 2,1, 3,3, 4,4, 5,2, 6,7, 7,6, 8,5, 8,8,
-     2,1, 2,3, 3,0, 3,2, 3,4, 4,6, 5,5, 6,7, 6,8,
diff --git a/srcpkgs/ufraw/patches/exiv-0.27.patch b/srcpkgs/ufraw/patches/exiv-0.27.patch
deleted file mode 100644
index b5b4140fff8ed..0000000000000
--- a/srcpkgs/ufraw/patches/exiv-0.27.patch
+++ /dev/null
@@ -1,25 +0,0 @@
---- a/ufraw_exiv2.cc	2015-06-16 05:58:38.000000000 +0200
-+++ b/ufraw_exiv2.cc	2018-12-29 22:51:23.291894430 +0100
-@@ -15,9 +15,7 @@
- #include "ufraw.h"
- 
- #ifdef HAVE_EXIV2
--#include <exiv2/image.hpp>
--#include <exiv2/easyaccess.hpp>
--#include <exiv2/exif.hpp>
-+#include <exiv2/exiv2.hpp>
- #include <sstream>
- #include <cassert>
- 
-@@ -67,7 +65,11 @@
-         if (exifData.empty()) {
-             std::string error(uf->filename);
-             error += ": No Exif data found in the file";
-+#if EXIV2_TEST_VERSION(0,27,0)
-+            throw Exiv2::Error(Exiv2::kerErrorMessage, error);
-+#else
-             throw Exiv2::Error(1, error);
-+#endif
-         }
- 
-         /* List of tag names taken from exiv2's printSummary() in actions.cpp */
diff --git a/srcpkgs/ufraw/patches/glib-2.68.patch b/srcpkgs/ufraw/patches/glib-2.68.patch
deleted file mode 100644
index 5b61468f118aa..0000000000000
--- a/srcpkgs/ufraw/patches/glib-2.68.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-From c56f8be3caf1cf3d9a5c80597bdbaf1325faacc0 Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?S=C3=A9rgio=20M=2E=20Basto?= <sergio@serjux.com>
-Date: Tue, 13 Apr 2021 23:45:39 +0100
-Subject: [PATCH] Fix build against glib-2.68 fixes #10
-
----
- uf_glib.h | 6 +++---
- 1 file changed, 3 insertions(+), 3 deletions(-)
-
-diff --git a/uf_glib.h b/uf_glib.h
-index 21c10b19..56cd6971 100644
---- a/uf_glib.h
-+++ b/uf_glib.h
-@@ -13,13 +13,13 @@
- #ifndef _UF_GLIB_H
- #define _UF_GLIB_H
- 
-+#include <glib.h>
-+#include <glib/gstdio.h>
-+
- #ifdef __cplusplus
- extern "C" {
- #endif
- 
--#include <glib.h>
--#include <glib/gstdio.h>
--
- // g_win32_locale_filename_from_utf8 is needed only on win32
- #ifdef _WIN32
- #define uf_win32_locale_filename_from_utf8(__some_string__) \
diff --git a/srcpkgs/ufraw/patches/iostream.patch b/srcpkgs/ufraw/patches/iostream.patch
deleted file mode 100644
index 6d15869f63db8..0000000000000
--- a/srcpkgs/ufraw/patches/iostream.patch
+++ /dev/null
@@ -1,13 +0,0 @@
-ufraw_exiv2.cc:343:10: note: 'std::cerr' is defined in header '<iostream>'
-ufraw_exiv2.cc:365:14: error: 'cerr' is not a member of 'std'
-
---- a/ufraw_exiv2.cc
-+++ b/ufraw_exiv2.cc
-@@ -17,6 +17,7 @@
- #ifdef HAVE_EXIV2
- #include <exiv2/exiv2.hpp>
- #include <sstream>
-+#include <iostream>
- #include <cassert>
- 
- /*
diff --git a/srcpkgs/ufraw/template b/srcpkgs/ufraw/template
deleted file mode 100644
index ceddcacacefb2..0000000000000
--- a/srcpkgs/ufraw/template
+++ /dev/null
@@ -1,38 +0,0 @@
-# Template file for 'ufraw'
-pkgname=ufraw
-version=0.22
-revision=5
-build_style=gnu-configure
-configure_args="--enable-contrast --enable-mime --enable-openmp --with-gimp
- $(vopt_enable extras)"
-hostmakedepends="pkg-config dcraw gettext"
-makedepends="exiv2-devel gimp-devel glib-devel gtkimageview-devel lcms2-devel lensfun-devel
- jasper-devel"
-depends="desktop-file-utils"
-short_desc="Utility to read and manipulate raw images from digital cameras"
-maintainer="John <me@johnnynator.dev>"
-license="GPL-2.0-or-later"
-homepage="http://ufraw.sourceforge.net/"
-distfiles="${SOURCEFORGE_SITE}/ufraw/ufraw/ufraw-${version}/ufraw-${version}.tar.gz"
-checksum=f7abd28ce587db2a74b4c54149bd8a2523a7ddc09bedf4f923246ff0ae09a25e
-
-build_options="extras"
-
-post_patch() {
-	vsed -e 's/default(none)//g' \
-		-i dcraw_indi.c \
-		-i dcraw_api.cc \
-		-i ufraw_ufraw.c \
-		-i ufraw_developer.c
-	vsed -i -e '/DATADIRNAME=/s/=.*/=share/' configure
-	vsed -i -e "s,^localedir =.*,localedir = /usr/share/locale," \
-		po/Makefile.in.in
-}
-
-ufraw-gimp_package() {
-	depends="${sourcepkg}>=${version}_${revision}"
-	short_desc+=" - gimp plugin"
-	pkg_install() {
-		vmove usr/lib/gimp
-	}
-}

From d9724b9ebec6032e2f2dae1cb67434663b8dcafe Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 8 Nov 2023 12:53:45 +0000
Subject: [PATCH 21/22] krita: revbump for exiv2-0.28.1.

---
 srcpkgs/krita/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/krita/template b/srcpkgs/krita/template
index f4d665daf7c31..d804b581a8689 100644
--- a/srcpkgs/krita/template
+++ b/srcpkgs/krita/template
@@ -1,7 +1,7 @@
 # Template file for 'krita'
 pkgname=krita
 version=5.2.1
-revision=2
+revision=3
 build_style=cmake
 configure_args="-Wno-dev -DBUILD_TESTING=OFF"
 hostmakedepends="extra-cmake-modules gettext pkg-config python3

From a3f9299f1aee8d7ef251e7ef7a1ef2811f96ac53 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 8 Nov 2023 18:25:01 +0000
Subject: [PATCH 22/22] darktable: revbump for exiv2-0.28.1.

---
 srcpkgs/darktable/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/darktable/template b/srcpkgs/darktable/template
index f76936a1692e8..97dfae3471e7c 100644
--- a/srcpkgs/darktable/template
+++ b/srcpkgs/darktable/template
@@ -1,7 +1,7 @@
 # Template file for 'darktable'
 pkgname=darktable
 version=4.4.2
-revision=4
+revision=5
 # upstream only supports these archs:
 archs="x86_64* aarch64* ppc64le*"
 build_style=cmake

^ permalink raw reply	[flat|nested] 27+ messages in thread

* Re: [PR PATCH] [Updated] exiv2: update to 0.28.1.
  2023-10-23  0:10 [PR PATCH] exiv2: update to 0.28.0 mhmdanas
                   ` (16 preceding siblings ...)
  2023-11-13  0:00 ` [PR PATCH] [Updated] " mhmdanas
@ 2023-11-15 17:40 ` mhmdanas
  2023-11-15 17:57 ` mhmdanas
                   ` (7 subsequent siblings)
  25 siblings, 0 replies; 27+ messages in thread
From: mhmdanas @ 2023-11-15 17:40 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 2086 bytes --]

There is an updated pull request by mhmdanas against master on the void-packages repository

https://github.com/mhmdanas/void-packages exiv2-0.28.0
https://github.com/void-linux/void-packages/pull/46838

exiv2: update to 0.28.1.
<!-- Uncomment relevant sections and delete options which are not applicable -->

#### Testing the changes
- I tested the changes in this PR: **briefly**

TODO:
- [x] Fix `gwenview`'s failed checks (not really fixed but the exact same tests fail on master as well)
- [x] `test_exiv2` fails for `libextractor`
- [x] `kfilemetadata5` tests fail (same tests fail on master)
- [x] Fix `nufraw` cross-build
- [x] `digikam` fails to build

@Johnnynator ufraw has been [unmaintained since December 2016](https://sourceforge.net/p/ufraw/discussion/434060/thread/30b4249b/), and it doesn't build with this PR; here are the options:
- remove the package entirely
- replace it with the newer [nufraw](https://sourceforge.net/projects/nufraw/), which already has [an exiv 0.28.x patch floating around](https://aur.archlinux.org/cgit/aur.git/tree/exiv2-error.patch?h=nufraw)
- patch it to build with this PR

What do you think? (edit: `nufraw` now replaces `ufraw` in this PR)

<!--
#### New package
- This new package conforms to the [package requirements](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTItest_exiv2NG.md#package-requirements): **YES**|**NO**
-->

<!-- Note: If the build is likely to take more than 2 hours, please add ci skip tag as described in
https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration
and test at least one native build and, if supported, at least one cross build.
Ignore this section if this PR is not skipping CI.
-->
<!--
#### Local build testing
- I built this PR locally for my native architecture, (ARCH-LIBC)
- I built this PR locally for these architectures (if supported. mark crossbuilds):
  - aarch64-musl
  - armv7l
  - armv6l-musl
-->


A patch file from https://github.com/void-linux/void-packages/pull/46838.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-exiv2-0.28.0-46838.patch --]
[-- Type: text/x-diff, Size: 75326 bytes --]

From b22b03c200e2b6aa3e995cfaff9826c3c6188d15 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 15 Nov 2023 17:19:46 +0000
Subject: [PATCH 01/23] Revert "xsimd: update to 11.2.0."

This reverts commit de75fb145239a14517310ec0e516491e9e2feae7.

Breaks 32-bit krita build: https://github.com/void-linux/void-packages/issues/47243
---
 srcpkgs/xsimd/template | 10 ++++------
 1 file changed, 4 insertions(+), 6 deletions(-)

diff --git a/srcpkgs/xsimd/template b/srcpkgs/xsimd/template
index ffc806bd7d111..0edc9a91316a6 100644
--- a/srcpkgs/xsimd/template
+++ b/srcpkgs/xsimd/template
@@ -1,20 +1,18 @@
 # Template file for 'xsimd'
 pkgname=xsimd
-version=11.2.0
+version=11.1.0
 revision=1
 build_style=cmake
-checkdepends="doctest-devel"
 short_desc="C++ wrappers for SIMD intrinsics and parallelized, optimized mathematical functions"
 maintainer="John <me@johnnynator.dev>"
 license="BSD-3-Clause"
 homepage="https://github.com/xtensor-stack/xsimd"
 distfiles="https://github.com/xtensor-stack/xsimd/archive/refs/tags/${version}.tar.gz"
-checksum=509bbfe12e78ee1a0e81711019e7c7a372dabcff566dbf15b95cc94339443242
+checksum=aa54dba8daade472656eba0d27154f072fec06ee3831aefcac69a5f6c7dbbae7
 
-if [ "$XBPS_CHECK_PKGS" ]; then
+if [ -z "$CROSS_BUILD" ]; then
 	configure_args="-DBUILD_TESTS=ON"
-else
-	configure_args="-DBUILD_TESTS=OFF"
+	makedepends="doctest-devel"
 fi
 
 post_install() {

From 3432bb15b6070370ebad5337b2d7c209b8dd1e9e Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Mon, 23 Oct 2023 01:20:09 +0100
Subject: [PATCH 02/23] inih: add `libINIReader.so.0` common/shlibs entry.

---
 common/shlibs | 1 +
 1 file changed, 1 insertion(+)

diff --git a/common/shlibs b/common/shlibs
index 1a721780f8545..6ff3fd244a49c 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -3902,6 +3902,7 @@ libnotcurses++.so.3 notcurses-3.0.5_1
 libnotcurses-ffi.so.3 notcurses-3.0.5_1
 libevemu.so.3 evemu-2.7.0_1
 libinih.so.0 inih-52_1
+libINIReader.so.0 inih-57_1
 libpcaudio.so.0 pcaudiolib-1.1_1
 libdcerpc-samr.so.0 samba-4.13.2_1
 libdcerpc-server-core.so.0 samba-4.13.2_1

From de79edc283bd08b69afa10dd2769b114445ec8bb Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:12 +0100
Subject: [PATCH 03/23] exiv2: update to 0.28.1.

---
 common/shlibs          |  2 +-
 srcpkgs/exiv2/template | 18 +++++++++++-------
 2 files changed, 12 insertions(+), 8 deletions(-)

diff --git a/common/shlibs b/common/shlibs
index 6ff3fd244a49c..4fa10586d145c 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -555,7 +555,7 @@ libgimpcolor-2.0.so.0 libgimp-2.10.0_1
 libgimpmodule-2.0.so.0 libgimp-2.10.0_1
 libgmic.so.3 gmic-3.1.6_1
 libcgmic.so.3 gmic-3.1.6_1
-libexiv2.so.27 exiv2-0.27_1
+libexiv2.so.28 exiv2-0.28.0_1
 libKF5Holidays.so.5 kholidays-5.47.0_1
 libPhabricatorHelpers.so.5 purpose-5.48.0_1
 libKF5PurposeWidgets.so.5 purpose-5.48.0_1
diff --git a/srcpkgs/exiv2/template b/srcpkgs/exiv2/template
index 49985fe82cc14..4517906521b4e 100644
--- a/srcpkgs/exiv2/template
+++ b/srcpkgs/exiv2/template
@@ -1,17 +1,17 @@
 # Template file for 'exiv2'
 pkgname=exiv2
-version=0.27.6
+version=0.28.1
 revision=1
 build_style=cmake
 configure_args="-DEXIV2_BUILD_SAMPLES=OFF -DEXIV2_ENABLE_BMFF=ON"
-makedepends="zlib-devel expat-devel"
-checkdepends="gtest-devel"
+makedepends="zlib-devel brotli-devel expat-devel inih-devel"
+checkdepends="gtest-devel python3"
 short_desc="Image metadata manipulation"
 maintainer="Enno Boland <gottox@voidlinux.org>"
 license="GPL-2.0-or-later"
 homepage="https://www.exiv2.org"
-distfiles="https://github.com/Exiv2/exiv2/releases/download/v${version}/exiv2-${version}-Source.tar.gz"
-checksum=4c192483a1125dc59a3d70b30d30d32edace9e14adf52802d2f853abf72db8a6
+distfiles="https://github.com/Exiv2/exiv2/archive/refs/tags/v${version}.zip"
+checksum=eab4c4b919930905e2128c56cb15919cb8105d431ccef8712f98fd4871f3d09a
 
 if [ -n "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DEXIV2_BUILD_UNIT_TESTS=ON"
@@ -21,14 +21,18 @@ if [ -n "$XBPS_CCACHE" ]; then
 	configure_args+=" -DBUILD_WITH_CCACHE=ON"
 fi
 
+pre_check() {
+	# https://github.com/Exiv2/exiv2/issues/2762
+	rm -f tests/bugfixes/github/test_issue_2427.py
+}
+
 exiv2-devel_package() {
 	depends="${makedepends} ${sourcepkg}-${version}_${revision}"
 	short_desc+=" - development files"
 	pkg_install() {
 		vmove usr/include
-		vmove usr/lib/cmake
 		vmove usr/lib/pkgconfig
-		vmove "usr/lib/*.a"
+		vmove usr/share/cmake
 		vmove "usr/lib/*.so"
 	}
 }

From 9b0eec1d3e63b95691d7bd130b66d5c6de794a49 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:37 +0100
Subject: [PATCH 04/23] ART: revbump for exiv2-0.28.1.

---
 srcpkgs/ART/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/ART/template b/srcpkgs/ART/template
index b6c47fc6c4cdf..94c7aa0378061 100644
--- a/srcpkgs/ART/template
+++ b/srcpkgs/ART/template
@@ -1,7 +1,7 @@
 # Template file for 'ART'
 pkgname=ART
 version=1.20.2
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="pkg-config"
 makedepends="fftw-devel gtkmm-devel lensfun-devel

From b143befad6ea3180fe6fcaa30de86db3903678a2 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 05/23] digikam: revbump for exiv2-0.28.1.

---
 .../patches/fix-build-with-exiv2-0.28.1.patch | 422 ++++++++++++++++++
 srcpkgs/digikam/template                      |   2 +-
 2 files changed, 423 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/digikam/patches/fix-build-with-exiv2-0.28.1.patch

diff --git a/srcpkgs/digikam/patches/fix-build-with-exiv2-0.28.1.patch b/srcpkgs/digikam/patches/fix-build-with-exiv2-0.28.1.patch
new file mode 100644
index 0000000000000..2a01b4545e76d
--- /dev/null
+++ b/srcpkgs/digikam/patches/fix-build-with-exiv2-0.28.1.patch
@@ -0,0 +1,422 @@
+From a76a561b20e7300510b29edc97afab01e381c0ec Mon Sep 17 00:00:00 2001
+From: Maik Qualmann <metzpinguin@gmail.com>
+Date: Wed, 8 Nov 2023 23:13:26 +0100
+Subject: [PATCH 1/5] fix compile with Exiv2-0.28.1 It should still compile
+ even with smaller Exiv2 versions.
+
+---
+ core/CMakeLists.txt                     | 4 ++--
+ core/app/DigikamCoreTarget.cmake        | 2 +-
+ core/cmake/rules/RulesLibExiv2.cmake    | 8 ++++----
+ core/libs/metadataengine/CMakeLists.txt | 4 ++--
+ 4 files changed, 9 insertions(+), 9 deletions(-)
+
+diff --git a/core/CMakeLists.txt b/core/CMakeLists.txt
+index c694c4b176..d5dc2f0dd8 100644
+--- a/core/CMakeLists.txt
++++ b/core/CMakeLists.txt
+@@ -255,7 +255,7 @@ PRINT_COMPONENT_COMPILE_STATUS("Media Player Support"                       ENAB
+ # ==============================================================================
+ 
+ PRINT_LIBRARY_STATUS("libboostgraph" "https://github.com/boostorg/boost"                 "(version >= 1.43.0)"                Boost_FOUND)
+-PRINT_LIBRARY_STATUS("libexiv2"      "https://github.com/Exiv2/exiv2"                    "(version >= ${EXIV2_MIN_VERSION}"   exiv2_FOUND)
++PRINT_LIBRARY_STATUS("libexiv2"      "https://github.com/Exiv2/exiv2"                    "(version >= ${EXIV2_MIN_VERSION}"   LibExiv2_FOUND)
+ PRINT_LIBRARY_STATUS("libexpat"      "https://libexpat.github.io"                        "(version >= 2.0.0)"                 EXPAT_FOUND)
+ PRINT_LIBRARY_STATUS("libjpeg"       "https://github.com/libjpeg-turbo/libjpeg-turbo"    "(version >= 6b)"                    JPEG_FOUND)
+ PRINT_LIBRARY_STATUS("libkde"        "https://invent.kde.org/frameworks/"                "(version >= ${KF5_MIN_VERSION})"    KF5_FOUND)
+@@ -306,7 +306,7 @@ endif()
+ # ==============================================================================
+ 
+ if(Boost_FOUND                          AND
+-   exiv2_FOUND                          AND
++   LibExiv2_FOUND                       AND
+    EXPAT_FOUND                          AND
+    JPEG_FOUND                           AND
+    KF5_FOUND                            AND
+diff --git a/core/app/DigikamCoreTarget.cmake b/core/app/DigikamCoreTarget.cmake
+index 83fda1b35f..8221a2d632 100644
+--- a/core/app/DigikamCoreTarget.cmake
++++ b/core/app/DigikamCoreTarget.cmake
+@@ -151,7 +151,7 @@ target_link_libraries(digikamcore
+                       ${TIFF_LIBRARIES}
+                       PNG::PNG
+                       ${JPEG_LIBRARIES}
+-                      exiv2lib
++                      ${LibExiv2_LIBRARIES}
+ 
+                       ${OPENMP_LDFLAGS}
+ 
+diff --git a/core/cmake/rules/RulesLibExiv2.cmake b/core/cmake/rules/RulesLibExiv2.cmake
+index c8b37d307c..a8ca259432 100644
+--- a/core/cmake/rules/RulesLibExiv2.cmake
++++ b/core/cmake/rules/RulesLibExiv2.cmake
+@@ -4,7 +4,7 @@
+ # SPDX-License-Identifier: BSD-3-Clause
+ #
+ 
+-find_package(exiv2 REQUIRED)
++find_package(LibExiv2 REQUIRED)
+ 
+ set_package_properties("exiv2"     PROPERTIES
+                        DESCRIPTION "Required to build digiKam"
+@@ -13,13 +13,13 @@ set_package_properties("exiv2"     PROPERTIES
+                        PURPOSE     "Library to manage image metadata"
+ )
+ 
+-if("${exiv2_VERSION}" VERSION_LESS ${EXIV2_MIN_VERSION})
++if("${LibExiv2_VERSION}" VERSION_LESS ${EXIV2_MIN_VERSION})
+ 
+-    message(FATAL_ERROR "Exiv2 version is too old (${exiv2_VERSION})! Minimal version required:${EXIV2_MIN_VERSION}.")
++    message(FATAL_ERROR "Exiv2 version is too old (${LibExiv2_VERSION})! Minimal version required:${EXIV2_MIN_VERSION}.")
+ 
+ endif()
+ 
+-if("${exiv2_VERSION}" VERSION_LESS "0.27.99")
++if("${LibExiv2_VERSION}" VERSION_LESS "0.27.99")
+ 
+     set(EXIV2_CXX_STANDARD 11)
+ 
+diff --git a/core/libs/metadataengine/CMakeLists.txt b/core/libs/metadataengine/CMakeLists.txt
+index 47aa889d5e..bd4dba0bbd 100644
+--- a/core/libs/metadataengine/CMakeLists.txt
++++ b/core/libs/metadataengine/CMakeLists.txt
+@@ -18,7 +18,7 @@ endif()
+ 
+ # Exiv2 version < 0.28 use auto_ptr instead unique_ptr which is deprecated.
+ 
+-if("${exiv2_VERSION}" VERSION_LESS "0.27.99")
++if("${LibExiv2_VERSION}" VERSION_LESS "0.27.99")
+ 
+     DISABLE_GCC_COMPILER_WARNINGS("5.99.99" "-Wno-deprecated")
+ 
+@@ -112,7 +112,7 @@ include_directories(
+     $<TARGET_PROPERTY:KF5::ConfigCore,INTERFACE_INCLUDE_DIRECTORIES>
+     $<TARGET_PROPERTY:KF5::I18n,INTERFACE_INCLUDE_DIRECTORIES>
+ 
+-    $<TARGET_PROPERTY:exiv2lib,INTERFACE_INCLUDE_DIRECTORIES>
++    $<TARGET_PROPERTY:LibExiv2_INCLUDE_DIRS>
+ )
+ 
+ # Used by digikamcore
+-- 
+2.42.0
+
+
+From ee487a753a652c588b88fa18aeb885105c17368d Mon Sep 17 00:00:00 2001
+From: Maik Qualmann <metzpinguin@gmail.com>
+Date: Thu, 9 Nov 2023 18:49:18 +0100
+Subject: [PATCH 2/5] recognize both Exiv2 CMake variants
+
+---
+ core/CMakeLists.txt                     | 14 ++++++--
+ core/app/DigikamCoreTarget.cmake        | 17 ++++++++-
+ core/cmake/rules/RulesLibExiv2.cmake    | 46 +++++++++++++++++++++----
+ core/libs/metadataengine/CMakeLists.txt | 12 +++++--
+ 4 files changed, 77 insertions(+), 12 deletions(-)
+
+diff --git a/core/CMakeLists.txt b/core/CMakeLists.txt
+index d5dc2f0dd8..855fdcf185 100644
+--- a/core/CMakeLists.txt
++++ b/core/CMakeLists.txt
+@@ -255,7 +255,17 @@ PRINT_COMPONENT_COMPILE_STATUS("Media Player Support"                       ENAB
+ # ==============================================================================
+ 
+ PRINT_LIBRARY_STATUS("libboostgraph" "https://github.com/boostorg/boost"                 "(version >= 1.43.0)"                Boost_FOUND)
+-PRINT_LIBRARY_STATUS("libexiv2"      "https://github.com/Exiv2/exiv2"                    "(version >= ${EXIV2_MIN_VERSION}"   LibExiv2_FOUND)
++
++if(LibExiv2_FOUND)
++
++    PRINT_LIBRARY_STATUS("libexiv2"  "https://github.com/Exiv2/exiv2"                    "(version >= ${EXIV2_MIN_VERSION}"   LibExiv2_FOUND)
++
++else()
++
++    PRINT_LIBRARY_STATUS("libexiv2"  "https://github.com/Exiv2/exiv2"                    "(version >= ${EXIV2_MIN_VERSION}"   exiv2_FOUND)
++
++endif()
++
+ PRINT_LIBRARY_STATUS("libexpat"      "https://libexpat.github.io"                        "(version >= 2.0.0)"                 EXPAT_FOUND)
+ PRINT_LIBRARY_STATUS("libjpeg"       "https://github.com/libjpeg-turbo/libjpeg-turbo"    "(version >= 6b)"                    JPEG_FOUND)
+ PRINT_LIBRARY_STATUS("libkde"        "https://invent.kde.org/frameworks/"                "(version >= ${KF5_MIN_VERSION})"    KF5_FOUND)
+@@ -306,7 +316,7 @@ endif()
+ # ==============================================================================
+ 
+ if(Boost_FOUND                          AND
+-   LibExiv2_FOUND                       AND
++   (LibExiv2_FOUND OR exiv2_FOUND)      AND
+    EXPAT_FOUND                          AND
+    JPEG_FOUND                           AND
+    KF5_FOUND                            AND
+diff --git a/core/app/DigikamCoreTarget.cmake b/core/app/DigikamCoreTarget.cmake
+index 8221a2d632..80bd153caa 100644
+--- a/core/app/DigikamCoreTarget.cmake
++++ b/core/app/DigikamCoreTarget.cmake
+@@ -151,7 +151,6 @@ target_link_libraries(digikamcore
+                       ${TIFF_LIBRARIES}
+                       PNG::PNG
+                       ${JPEG_LIBRARIES}
+-                      ${LibExiv2_LIBRARIES}
+ 
+                       ${OPENMP_LDFLAGS}
+ 
+@@ -164,6 +163,22 @@ target_link_libraries(digikamcore
+                       opencv_flann
+ )
+ 
++if(LibExiv2_FOUND)
++
++    target_link_libraries(digikamcore
++                          PRIVATE
++                          ${LibExiv2_LIBRARIES}
++    )
++
++else()
++
++    target_link_libraries(digikamcore
++                          PRIVATE
++                          exiv2lib
++    )
++
++endif()
++
+ if(Qt6_FOUND)
+     target_link_libraries(digikamcore
+                           PRIVATE
+diff --git a/core/cmake/rules/RulesLibExiv2.cmake b/core/cmake/rules/RulesLibExiv2.cmake
+index a8ca259432..e568644ca4 100644
+--- a/core/cmake/rules/RulesLibExiv2.cmake
++++ b/core/cmake/rules/RulesLibExiv2.cmake
+@@ -4,7 +4,17 @@
+ # SPDX-License-Identifier: BSD-3-Clause
+ #
+ 
+-find_package(LibExiv2 REQUIRED)
++find_package(LibExiv2 OPTIONAL_COMPONENTS)
++
++if(LibExiv2_FOUND)
++
++    find_package(LibExiv2 REQUIRED)
++
++else()
++
++    find_package(exiv2 REQUIRED)
++
++endif()
+ 
+ set_package_properties("exiv2"     PROPERTIES
+                        DESCRIPTION "Required to build digiKam"
+@@ -13,18 +23,40 @@ set_package_properties("exiv2"     PROPERTIES
+                        PURPOSE     "Library to manage image metadata"
+ )
+ 
+-if("${LibExiv2_VERSION}" VERSION_LESS ${EXIV2_MIN_VERSION})
++if(LibExiv2_FOUND)
+ 
+-    message(FATAL_ERROR "Exiv2 version is too old (${LibExiv2_VERSION})! Minimal version required:${EXIV2_MIN_VERSION}.")
++    if("${LibExiv2_VERSION}" VERSION_LESS ${EXIV2_MIN_VERSION})
+ 
+-endif()
++        message(FATAL_ERROR "Exiv2 version is too old (${LibExiv2_VERSION})! Minimal version required:${EXIV2_MIN_VERSION}.")
++
++    endif()
++
++    if("${LibExiv2_VERSION}" VERSION_LESS "0.27.99")
+ 
+-if("${LibExiv2_VERSION}" VERSION_LESS "0.27.99")
++        set(EXIV2_CXX_STANDARD 11)
+ 
+-    set(EXIV2_CXX_STANDARD 11)
++    else()
++
++        set(EXIV2_CXX_STANDARD 17)
++
++    endif()
+ 
+ else()
+ 
+-    set(EXIV2_CXX_STANDARD 17)
++    if("${exiv2_VERSION}" VERSION_LESS ${EXIV2_MIN_VERSION})
++
++        message(FATAL_ERROR "Exiv2 version is too old (${exiv2_VERSION})! Minimal version required:${EXIV2_MIN_VERSION}.")
++
++    endif()
++
++    if("${exiv2_VERSION}" VERSION_LESS "0.27.99")
++
++        set(EXIV2_CXX_STANDARD 11)
++
++    else()
++
++        set(EXIV2_CXX_STANDARD 17)
++
++    endif()
+ 
+ endif()
+diff --git a/core/libs/metadataengine/CMakeLists.txt b/core/libs/metadataengine/CMakeLists.txt
+index bd4dba0bbd..a4124d17e0 100644
+--- a/core/libs/metadataengine/CMakeLists.txt
++++ b/core/libs/metadataengine/CMakeLists.txt
+@@ -111,10 +111,18 @@ include_directories(
+ 
+     $<TARGET_PROPERTY:KF5::ConfigCore,INTERFACE_INCLUDE_DIRECTORIES>
+     $<TARGET_PROPERTY:KF5::I18n,INTERFACE_INCLUDE_DIRECTORIES>
+-
+-    $<TARGET_PROPERTY:LibExiv2_INCLUDE_DIRS>
+ )
+ 
++if(LibExiv2_FOUND)
++
++    include_directories($<TARGET_PROPERTY:LibExiv2_INCLUDE_DIRS>)
++
++else()
++
++    include_directories($<TARGET_PROPERTY:exiv2lib,INTERFACE_INCLUDE_DIRECTORIES>)
++
++endif()
++
+ # Used by digikamcore
+ add_library(core_dmetadata_obj OBJECT ${libdmetadata_SRCS})
+ 
+-- 
+2.42.0
+
+
+From af221dd7700fbf1e6e3b5245184381d2b74ec781 Mon Sep 17 00:00:00 2001
+From: Maik Qualmann <metzpinguin@gmail.com>
+Date: Thu, 9 Nov 2023 19:12:44 +0100
+Subject: [PATCH 3/5] check version und clear LibExiv2_FOUND
+
+---
+ core/cmake/rules/RulesLibExiv2.cmake | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+diff --git a/core/cmake/rules/RulesLibExiv2.cmake b/core/cmake/rules/RulesLibExiv2.cmake
+index e568644ca4..de5ea80ec6 100644
+--- a/core/cmake/rules/RulesLibExiv2.cmake
++++ b/core/cmake/rules/RulesLibExiv2.cmake
+@@ -6,12 +6,13 @@
+ 
+ find_package(LibExiv2 OPTIONAL_COMPONENTS)
+ 
+-if(LibExiv2_FOUND)
++if(LibExiv2_FOUND AND ("${LibExiv2_VERSION}" VERSION_GREATER "0.28.0"))
+ 
+     find_package(LibExiv2 REQUIRED)
+ 
+ else()
+ 
++    set (LibExiv2_FOUND FALSE)
+     find_package(exiv2 REQUIRED)
+ 
+ endif()
+-- 
+2.42.0
+
+
+From fda83a6f7e03e4088f3a5903d036c1425d6303b9 Mon Sep 17 00:00:00 2001
+From: Maik Qualmann <metzpinguin@gmail.com>
+Date: Thu, 9 Nov 2023 19:15:41 +0100
+Subject: [PATCH 4/5] adjust Exiv2 version
+
+---
+ core/cmake/rules/RulesLibExiv2.cmake | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/core/cmake/rules/RulesLibExiv2.cmake b/core/cmake/rules/RulesLibExiv2.cmake
+index de5ea80ec6..3db233cad2 100644
+--- a/core/cmake/rules/RulesLibExiv2.cmake
++++ b/core/cmake/rules/RulesLibExiv2.cmake
+@@ -6,7 +6,7 @@
+ 
+ find_package(LibExiv2 OPTIONAL_COMPONENTS)
+ 
+-if(LibExiv2_FOUND AND ("${LibExiv2_VERSION}" VERSION_GREATER "0.28.0"))
++if(LibExiv2_FOUND AND ("${LibExiv2_VERSION}" VERSION_GREATER "0.27.99"))
+ 
+     find_package(LibExiv2 REQUIRED)
+ 
+-- 
+2.42.0
+
+
+From 921ee9945f8c438f23b83add58d5737b539cd312 Mon Sep 17 00:00:00 2001
+From: Maik Qualmann <metzpinguin@gmail.com>
+Date: Thu, 9 Nov 2023 21:35:09 +0100
+Subject: [PATCH 5/5] set correct exiv2 package name and less duplicate CMake
+ code
+
+---
+ core/cmake/rules/RulesLibExiv2.cmake | 34 +++++++++++-----------------
+ 1 file changed, 13 insertions(+), 21 deletions(-)
+
+diff --git a/core/cmake/rules/RulesLibExiv2.cmake b/core/cmake/rules/RulesLibExiv2.cmake
+index 3db233cad2..e3e667d946 100644
+--- a/core/cmake/rules/RulesLibExiv2.cmake
++++ b/core/cmake/rules/RulesLibExiv2.cmake
+@@ -9,19 +9,21 @@ find_package(LibExiv2 OPTIONAL_COMPONENTS)
+ if(LibExiv2_FOUND AND ("${LibExiv2_VERSION}" VERSION_GREATER "0.27.99"))
+ 
+     find_package(LibExiv2 REQUIRED)
++    set(EXIV2_PACKAGE_NAME "LibExiv2")
+ 
+ else()
+ 
+-    set (LibExiv2_FOUND FALSE)
++    set(LibExiv2_FOUND FALSE)
+     find_package(exiv2 REQUIRED)
++    set(EXIV2_PACKAGE_NAME "exiv2")
+ 
+ endif()
+ 
+-set_package_properties("exiv2"     PROPERTIES
+-                       DESCRIPTION "Required to build digiKam"
+-                       URL         "https://www.exiv2.org"
+-                       TYPE        RECOMMENDED
+-                       PURPOSE     "Library to manage image metadata"
++set_package_properties(${EXIV2_PACKAGE_NAME} PROPERTIES
++                       DESCRIPTION           "Required to build digiKam"
++                       URL                   "https://www.exiv2.org"
++                       TYPE                  RECOMMENDED
++                       PURPOSE               "Library to manage image metadata"
+ )
+ 
+ if(LibExiv2_FOUND)
+@@ -32,16 +34,6 @@ if(LibExiv2_FOUND)
+ 
+     endif()
+ 
+-    if("${LibExiv2_VERSION}" VERSION_LESS "0.27.99")
+-
+-        set(EXIV2_CXX_STANDARD 11)
+-
+-    else()
+-
+-        set(EXIV2_CXX_STANDARD 17)
+-
+-    endif()
+-
+ else()
+ 
+     if("${exiv2_VERSION}" VERSION_LESS ${EXIV2_MIN_VERSION})
+@@ -50,14 +42,14 @@ else()
+ 
+     endif()
+ 
+-    if("${exiv2_VERSION}" VERSION_LESS "0.27.99")
++endif()
+ 
+-        set(EXIV2_CXX_STANDARD 11)
++if(("${exiv2_VERSION}" VERSION_GREATER "0.27.99") OR ("${LibExiv2_VERSION}" VERSION_GREATER "0.27.99"))
+ 
+-    else()
++    set(EXIV2_CXX_STANDARD 17)
+ 
+-        set(EXIV2_CXX_STANDARD 17)
++else()
+ 
+-    endif()
++    set(EXIV2_CXX_STANDARD 11)
+ 
+ endif()
+-- 
+2.42.0
+
diff --git a/srcpkgs/digikam/template b/srcpkgs/digikam/template
index 206185f565488..4784bf7d62a8e 100644
--- a/srcpkgs/digikam/template
+++ b/srcpkgs/digikam/template
@@ -1,7 +1,7 @@
 # Template file for 'digikam'
 pkgname=digikam
 version=8.1.0
-revision=1
+revision=2
 build_style=cmake
 configure_args="-DBUILD_TESTING=OFF"
 hostmakedepends="extra-cmake-modules gettext pkg-config bison flex qt5-qmake

From b6698a830576e9278fd0ac83237bde662c475aeb Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 06/23] geeqie: revbump for exiv2-0.28.1.

---
 srcpkgs/geeqie/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/geeqie/template b/srcpkgs/geeqie/template
index b5f958f854c1b..b494bc149e957 100644
--- a/srcpkgs/geeqie/template
+++ b/srcpkgs/geeqie/template
@@ -1,7 +1,7 @@
 # Template file for 'geeqie'
 pkgname=geeqie
 version=2.1
-revision=1
+revision=2
 build_style=meson
 hostmakedepends="pkg-config gettext xxd gdk-pixbuf-devel glib-devel"
 makedepends="gtk+3-devel glib-devel lcms2-devel exiv2-devel libheif-devel

From ebf1f99e5075ed642a0e669ee8f6a58d010ff639 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 07/23] gthumb: revbump for exiv2-0.28.1.

---
 srcpkgs/gthumb/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/gthumb/template b/srcpkgs/gthumb/template
index 02d2bc2ed04d6..50c1778f39435 100644
--- a/srcpkgs/gthumb/template
+++ b/srcpkgs/gthumb/template
@@ -1,7 +1,7 @@
 # Template file for 'gthumb'
 pkgname=gthumb
 version=3.12.4
-revision=1
+revision=2
 build_style=meson
 hostmakedepends="gettext pkg-config itstool glib-devel"
 makedepends="webkit2gtk-devel json-glib-devel libsecret-devel librsvg-devel

From 20bb5d06d621a231ece5147acc1fd6b9d394c621 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 08/23] gwenview: revbump for exiv2-0.28.1.

---
 srcpkgs/gwenview/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/gwenview/template b/srcpkgs/gwenview/template
index 1a9978f384084..c6ec9494eb067 100644
--- a/srcpkgs/gwenview/template
+++ b/srcpkgs/gwenview/template
@@ -1,7 +1,7 @@
 # Template file for 'gwenview'
 pkgname=gwenview
 version=23.08.3
-revision=1
+revision=2
 build_style=cmake
 build_helper=qemu
 hostmakedepends="extra-cmake-modules pkg-config qt5-qmake qt5-host-tools

From b208724ef2f164f4ef8454eabeb259960be0ec21 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 09/23] hugin: revbump for exiv2-0.28.1.

---
 srcpkgs/hugin/patches/exiv2-0.28.patch | 77 ++++++++++++++++++++++++++
 1 file changed, 77 insertions(+)
 create mode 100644 srcpkgs/hugin/patches/exiv2-0.28.patch

diff --git a/srcpkgs/hugin/patches/exiv2-0.28.patch b/srcpkgs/hugin/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..49f0518117020
--- /dev/null
+++ b/srcpkgs/hugin/patches/exiv2-0.28.patch
@@ -0,0 +1,77 @@
+Patch-Source: https://gitlab.archlinux.org/archlinux/packaging/packages/hugin/-/blob/main/exiv2-0.28.patch
+diff -r 79cd11a7a66f src/hugin_base/panodata/Exiv2Helper.cpp
+--- a/src/hugin_base/panodata/Exiv2Helper.cpp	Wed May 24 19:13:20 2023 +0200
++++ b/src/hugin_base/panodata/Exiv2Helper.cpp	Mon Jun 05 00:31:19 2023 +0200
+@@ -40,7 +40,7 @@
+             Exiv2::ExifData::iterator itr = exifData.findKey(Exiv2::ExifKey(keyName));
+             if (itr != exifData.end() && itr->count())
+             {
+-                value = itr->toLong();
++                value = itr->toUint32();
+                 return true;
+             }
+             else
+@@ -165,7 +165,7 @@
+         {
+             if(it!=exifData.end() && it->count())
+             {
+-                return it->toLong();
++                return it->toUint32();
+             }
+             return 0;
+         };
+@@ -600,4 +600,4 @@
+         };
+ 
+     }; //namespace Exiv2Helper
+-}; //namespace HuginBase
+\ No newline at end of file
++}; //namespace HuginBase
+diff -r 79cd11a7a66f src/hugin_base/panodata/SrcPanoImage.cpp
+--- a/src/hugin_base/panodata/SrcPanoImage.cpp	Wed May 24 19:13:20 2023 +0200
++++ b/src/hugin_base/panodata/SrcPanoImage.cpp	Mon Jun 05 00:31:19 2023 +0200
+@@ -384,7 +384,7 @@
+                     pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaImageWidthPixels"));
+                     if (pos != xmpData.end())
+                     {
+-                        croppedWidth = pos->toLong();
++                        croppedWidth = pos->toUint32();
+                     }
+                     else
+                     {
+@@ -394,7 +394,7 @@
+                     pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaImageHeightPixels"));
+                     if (pos != xmpData.end())
+                     {
+-                        croppedHeight = pos->toLong();
++                        croppedHeight = pos->toUint32();
+                     }
+                     else
+                     {
+@@ -408,7 +408,7 @@
+                         double hfov = 0;
+                         if (pos != xmpData.end())
+                         {
+-                            hfov = 360 * croppedWidth / (double)pos->toLong();
++                            hfov = 360 * croppedWidth / (double)pos->toUint32();
+                         }
+                         else
+                         {
+@@ -419,7 +419,7 @@
+                         pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.FullPanoHeightPixels"));
+                         if (pos != xmpData.end())
+                         {
+-                            fullHeight = pos->toLong();
++                            fullHeight = pos->toUint32();
+                         }
+                         else
+                         {
+@@ -430,7 +430,7 @@
+                         pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaTopPixels"));
+                         if (pos != xmpData.end())
+                         {
+-                            cropTop = pos->toLong();
++                            cropTop = pos->toUint32();
+                         }
+                         else
+                         {

From c8f894cf156b358aaacdf422d18e250711841959 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 10/23] kfilemetadata5: revbump for exiv2-0.28.1.

---
 srcpkgs/kfilemetadata5/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/kfilemetadata5/template b/srcpkgs/kfilemetadata5/template
index 00f7a98cf6399..e294ae5af947c 100644
--- a/srcpkgs/kfilemetadata5/template
+++ b/srcpkgs/kfilemetadata5/template
@@ -1,7 +1,7 @@
 # Template file for 'kfilemetadata5'
 pkgname=kfilemetadata5
 version=5.111.0
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="kcoreaddons extra-cmake-modules pkg-config qt5-host-tools qt5-qmake
  gettext kcoreaddons python3"

From 3609875d3cbd3a2435a58a8c5bee89169f5408dc Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 11/23] krename: revbump for exiv2-0.28.1.

---
 srcpkgs/krename/patches/e7dd767a.patch | 90 ++++++++++++++++++++++++++
 srcpkgs/krename/template               |  2 +-
 2 files changed, 91 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/krename/patches/e7dd767a.patch

diff --git a/srcpkgs/krename/patches/e7dd767a.patch b/srcpkgs/krename/patches/e7dd767a.patch
new file mode 100644
index 0000000000000..a0ef428ce46b1
--- /dev/null
+++ b/srcpkgs/krename/patches/e7dd767a.patch
@@ -0,0 +1,90 @@
+Patch-Source: https://invent.kde.org/utilities/krename/-/commit/e7dd767a
+From e7dd767a9a1068ee1fe1502c4d619b57d3b12add Mon Sep 17 00:00:00 2001
+From: Andreas Sturmlechner <asturm@gentoo.org>
+Date: Fri, 26 May 2023 23:23:10 +0200
+Subject: [PATCH] Fix build with >=exiv2-0.28, raise minimum to 0.27
+
+- enables use of EXIV2_TEST_VERSION macro
+- exiv2 headers cleanup
+
+Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>
+---
+ CMakeLists.txt         |  6 +-----
+ config-krename.h.cmake |  3 ---
+ src/exiv2plugin.cpp    | 17 +++++------------
+ 3 files changed, 6 insertions(+), 20 deletions(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 0bda8ac..72e7297 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -56,13 +56,9 @@ set_package_properties(Taglib PROPERTIES
+     TYPE OPTIONAL)
+ 
+ # Find exiv2
+-find_package(LibExiv2 0.13) # AccessMode was added in 0.13
++find_package(LibExiv2 0.27) # EXIV2_TEST_VERSION was added in 0.27
+ set_package_properties(LibExiv2 PROPERTIES TYPE OPTIONAL)
+ 
+-if (LibExiv2_VERSION VERSION_GREATER_EQUAL "0.27")
+-    set(HAVE_LIBEXIV2_0_27 TRUE)
+-endif()
+-
+ # Find podofo
+ find_package(PoDoFo)
+ set_package_properties(PoDoFo PROPERTIES
+diff --git a/config-krename.h.cmake b/config-krename.h.cmake
+index 76c3d30..862e40b 100644
+--- a/config-krename.h.cmake
++++ b/config-krename.h.cmake
+@@ -6,9 +6,6 @@
+ /* have Exiv2 */
+ #cmakedefine01 HAVE_EXIV2
+ 
+-/* Defined if we have libexiv2 >= 0.27 */
+-#cmakedefine HAVE_LIBEXIV2_0_27
+-
+ /* have PoDoFo */
+ #cmakedefine01 HAVE_PODOFO
+ 
+diff --git a/src/exiv2plugin.cpp b/src/exiv2plugin.cpp
+index 5694d8c..25e8869 100644
+--- a/src/exiv2plugin.cpp
++++ b/src/exiv2plugin.cpp
+@@ -3,20 +3,9 @@
+ 
+ #include "exiv2plugin.h"
+ 
+-#include "../config-krename.h"
+-
+ #include <KLocalizedString>
+ 
+-#include <exiv2/error.hpp>
+-#include <exiv2/exif.hpp>
+-#include <exiv2/image.hpp>
+-#include <exiv2/iptc.hpp>
+-#ifdef HAVE_LIBEXIV2_0_27
+-    #include <exiv2/xmp_exiv2.hpp>
+-#else
+-    #include <exiv2/xmp.hpp>
+-#endif
+-#include <exiv2/tags.hpp>
++#include <exiv2/exiv2.hpp>
+ 
+ #include "batchrenamer.h"
+ #include "tokenhelpdialog.h"
+@@ -381,7 +370,11 @@ QString Exiv2Plugin::processFile(BatchRenamer *b, int index, const QString &file
+     std::string strFilename(asc.constData(), asc.length());
+ 
+     try {
++#if EXIV2_TEST_VERSION(0,28,0)
++        Image::UniquePtr image = Exiv2::ImageFactory::open(strFilename);
++#else
+         Image::AutoPtr image = Exiv2::ImageFactory::open(strFilename);
++#endif
+         if (image.get() != nullptr && image->good()) {
+             image->readMetadata();
+ 
+-- 
+GitLab
+
diff --git a/srcpkgs/krename/template b/srcpkgs/krename/template
index 66023163e3293..df5535007714a 100644
--- a/srcpkgs/krename/template
+++ b/srcpkgs/krename/template
@@ -1,7 +1,7 @@
 # Template file for 'krename'
 pkgname=krename
 version=5.0.2
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="extra-cmake-modules gettext kcoreaddons pkg-config qt5-host-tools qt5-qmake"
 makedepends="exiv2-devel freetype-devel kjs-devel kparts-devel libpodofo-devel

From 5228802cb787e4b74966d26775264c43eb9967f7 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 12/23] libextractor: revbump for exiv2-0.28.1.

---
 srcpkgs/libextractor/patches/exiv2-0.28.patch | 286 ++++++++++++++++++
 srcpkgs/libextractor/patches/fix-tests.diff   |  24 ++
 2 files changed, 310 insertions(+)
 create mode 100644 srcpkgs/libextractor/patches/exiv2-0.28.patch
 create mode 100644 srcpkgs/libextractor/patches/fix-tests.diff

diff --git a/srcpkgs/libextractor/patches/exiv2-0.28.patch b/srcpkgs/libextractor/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..270a626d8ab06
--- /dev/null
+++ b/srcpkgs/libextractor/patches/exiv2-0.28.patch
@@ -0,0 +1,286 @@
+Patch-Source: https://gitlab.archlinux.org/archlinux/packaging/packages/libextractor/-/blob/main/exiv2-0.28.patch
+diff --git a/src/plugins/exiv2_extractor.cc b/src/plugins/exiv2_extractor.cc
+index 78f9bda..d32ed6a 100644
+--- a/src/plugins/exiv2_extractor.cc
++++ b/src/plugins/exiv2_extractor.cc
+@@ -90,7 +90,11 @@ virtual int close ();
+  * @param rcount number of bytes to read
+  * @return buffer with data read, empty buffer (!) on failure (!)
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++virtual Exiv2::DataBuf read (size_t rcount);
++#else
+ virtual Exiv2::DataBuf read (long rcount);
++#endif
+ 
+ /**
+  * Read up to 'rcount' bytes into 'buf'.
+@@ -99,8 +103,17 @@ virtual Exiv2::DataBuf read (long rcount);
+  * @param rcount size of 'buf'
+  * @return number of bytes read successfully, 0 on failure (!)
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++virtual size_t read (Exiv2::byte *buf,
++                   size_t rcount);
++#else
+ virtual long read (Exiv2::byte *buf,
+                    long rcount);
++#endif
++
++#if EXIV2_TEST_VERSION (0,28,0)
++virtual void populateFakeData();
++#endif
+ 
+ /**
+  * Read a single character.
+@@ -117,8 +130,13 @@ virtual int getb ();
+  * @param wcount how many bytes to write
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual size_t write (const Exiv2::byte *data,
++                    size_t wcount);
++#else
+ virtual long write (const Exiv2::byte *data,
+                     long wcount);
++#endif
+ 
+ /**
+  * Write to stream.
+@@ -126,7 +144,11 @@ virtual long write (const Exiv2::byte *data,
+  * @param src stream to copy
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual size_t write (Exiv2::BasicIo &src);
++#else
+ virtual long write (Exiv2::BasicIo &src);
++#endif
+ 
+ /**
+  * Write a single byte.
+@@ -172,7 +194,11 @@ virtual int munmap ();
+  *
+  * @return -1 on error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual size_t tell (void) const;
++#else
+ virtual long int tell (void) const;
++#endif
+ 
+ /**
+  * Return overall size of the file.
+@@ -213,7 +239,11 @@ virtual bool eof () const;
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual const std::string& path () const noexcept;
++#else
+ virtual std::string path () const;
++#endif
+ 
+ #ifdef EXV_UNICODE_PATH
+ /**
+@@ -230,7 +260,11 @@ virtual std::wstring wpath () const;
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual Exiv2::BasicIo::UniquePtr temporary () const;
++#else
+ virtual Exiv2::BasicIo::AutoPtr temporary () const;
++#endif
+ 
+ };
+ 
+@@ -266,7 +300,11 @@ ExtractorIO::close ()
+  * @return buffer with data read, empty buffer (!) on failure (!)
+  */
+ Exiv2::DataBuf
++#if EXIV2_TEST_VERSION (0,28,0)
++ExtractorIO::read (size_t rcount)
++#else
+ ExtractorIO::read (long rcount)
++#endif
+ {
+   void *data;
+   ssize_t ret;
+@@ -284,9 +322,15 @@ ExtractorIO::read (long rcount)
+  * @param rcount size of 'buf'
+  * @return number of bytes read successfully, 0 on failure (!)
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++size_t
++ExtractorIO::read (Exiv2::byte *buf,
++                   size_t rcount)
++#else
+ long
+ ExtractorIO::read (Exiv2::byte *buf,
+                    long rcount)
++#endif
+ {
+   void *data;
+   ssize_t ret;
+@@ -305,6 +349,12 @@ ExtractorIO::read (Exiv2::byte *buf,
+   return got;
+ }
+ 
++#if EXIV2_TEST_VERSION (0,28,0)
++void ExtractorIO::populateFakeData()
++{
++  return;
++}
++#endif
+ 
+ /**
+  * Read a single character.
+@@ -319,7 +369,9 @@ ExtractorIO::getb ()
+   const unsigned char *r;
+ 
+   if (1 != ec->read (ec->cls, &data, 1))
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION(0,28,0)
++    throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+     throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+     throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -336,9 +388,15 @@ ExtractorIO::getb ()
+  * @param wcount how many bytes to write
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++size_t
++ExtractorIO::write (const Exiv2::byte *data,
++                    size_t wcount)
++#else
+ long
+ ExtractorIO::write (const Exiv2::byte *data,
+                     long wcount)
++#endif
+ {
+   return -1;
+ }
+@@ -350,7 +408,11 @@ ExtractorIO::write (const Exiv2::byte *data,
+  * @param src stream to copy
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++size_t
++#else
+ long
++#endif
+ ExtractorIO::write (Exiv2::BasicIo &src)
+ {
+   return -1;
+@@ -378,7 +440,9 @@ ExtractorIO::putb (Exiv2::byte data)
+ void
+ ExtractorIO::transfer (Exiv2::BasicIo& src)
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION(0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -427,7 +491,9 @@ ExtractorIO::seek (long offset,
+ Exiv2::byte *
+ ExtractorIO::mmap (bool isWritable)
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION (0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -452,7 +518,11 @@ ExtractorIO::munmap ()
+  *
+  * @return -1 on error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++size_t
++#else
+ long int
++#endif
+ ExtractorIO::tell (void) const
+ {
+   return (long) ec->seek (ec->cls, 0, SEEK_CUR);
+@@ -516,10 +586,17 @@ ExtractorIO::eof () const
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++const std::string&
++ExtractorIO::path () const noexcept
++#else
+ std::string
+ ExtractorIO::path () const
++#endif
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION (0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -536,7 +613,9 @@ ExtractorIO::path () const
+ std::wstring
+ ExtractorIO::wpath () const
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION (0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -552,11 +631,17 @@ ExtractorIO::wpath () const
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++Exiv2::BasicIo::UniquePtr
++#else
+ Exiv2::BasicIo::AutoPtr
++#endif
+ ExtractorIO::temporary () const
+ {
+   fprintf (stderr, "throwing temporary error\n");
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION(0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -737,8 +822,13 @@ EXTRACTOR_exiv2_extract_method (struct EXTRACTOR_ExtractContext *ec)
+ #if ! EXIV2_TEST_VERSION (0,24,0)
+     Exiv2::LogMsg::setLevel (Exiv2::LogMsg::mute);
+ #endif
++#if EXIV2_TEST_VERSION(0,28,0)
++    std::unique_ptr<Exiv2::BasicIo> eio (new ExtractorIO (ec));
++    Exiv2::Image::UniquePtr image = Exiv2::ImageFactory::open (std::move(eio));
++#else
+     std::auto_ptr<Exiv2::BasicIo> eio (new ExtractorIO (ec));
+     Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open (eio);
++#endif
+     if (0 == image.get ())
+       return;
+     image->readMetadata ();
+@@ -822,7 +912,11 @@ EXTRACTOR_exiv2_extract_method (struct EXTRACTOR_ExtractContext *ec)
+       ADDXMP ("Xmp.lr.hierarchicalSubject", EXTRACTOR_METATYPE_SUBJECT);
+     }
+   }
++#if EXIV2_TEST_VERSION (0,28,0)
++  catch (const Exiv2::Error& e)
++#else
+   catch (const Exiv2::AnyError& e)
++#endif
+   {
+ #if DEBUG
+     std::cerr << "Caught Exiv2 exception '" << e << "'\n";
diff --git a/srcpkgs/libextractor/patches/fix-tests.diff b/srcpkgs/libextractor/patches/fix-tests.diff
new file mode 100644
index 0000000000000..3b4ee7cbeea33
--- /dev/null
+++ b/srcpkgs/libextractor/patches/fix-tests.diff
@@ -0,0 +1,24 @@
+--- a/src/plugins/test_exiv2.c	2021-01-30 13:20:23.000000000 +0000
++++ b/src/plugins/test_exiv2.c	2023-11-03 19:39:43.115274492 +0000
+@@ -49,8 +49,8 @@
+       EXTRACTOR_METATYPE_GPS_LATITUDE,
+       EXTRACTOR_METAFORMAT_UTF8,
+       "text/plain",
+-      "28deg 8' (18|17.585)\" ?",
+-      strlen ("28deg 8' (18|17.585)\" ?") + 1,
++      "28 deg 8' (18|17.58)\" ?",
++      strlen ("28 deg 8' (18|17.58)\" ?") + 1,
+       0,
+       .regex = 1
+     },
+@@ -66,8 +66,8 @@
+       EXTRACTOR_METATYPE_GPS_LONGITUDE,
+       EXTRACTOR_METAFORMAT_UTF8,
+       "text/plain",
+-      "14deg 14' (22|21.713)\" ?",
+-      strlen ("14deg 14' (22|21.713)\" ?"),
++      "14 deg 14' (22|21.71)\" ?",
++      strlen ("14 deg 14' (22|21.71)\" ?"),
+       0,
+       .regex = 1
+     },

From 707ae55ad624793e615cf16b271dabe675830977 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 13/23] libgexiv2: update to 0.14.2.

---
 srcpkgs/libgexiv2/template | 14 +++++++-------
 1 file changed, 7 insertions(+), 7 deletions(-)

diff --git a/srcpkgs/libgexiv2/template b/srcpkgs/libgexiv2/template
index 23780e5397dc4..91dbcaa9aca52 100644
--- a/srcpkgs/libgexiv2/template
+++ b/srcpkgs/libgexiv2/template
@@ -1,19 +1,19 @@
 # Template file for 'libgexiv2'
 pkgname=libgexiv2
-version=0.14.0
-revision=3
+version=0.14.2
+revision=1
 build_style=meson
 build_helper="gir"
-configure_args="-Dintrospection=$(vopt_if gir true false)
- -Dvapi=$(vopt_if vala true false)"
+configure_args="$(vopt_bool gir introspection) $(vopt_bool vala vapi)"
 hostmakedepends="pkg-config glib-devel $(vopt_if vala 'vala') python3-gobject"
 makedepends="libglib-devel exiv2-devel"
 short_desc="GObject-based wrapper around the Exiv2 library"
 maintainer="Enno Boland <gottox@voidlinux.org>"
 license="GPL-2.0-or-later"
 homepage="https://wiki.gnome.org/Projects/gexiv2"
-distfiles="${GNOME_SITE}/gexiv2/${version%.*}/${pkgname/lib/}-${version}.tar.xz"
-checksum=e58279a6ff20b6f64fa499615da5e9b57cf65ba7850b72fafdf17221a9d6d69e
+changelog="https://gitlab.gnome.org/GNOME/gexiv2/-/raw/master/NEWS"
+distfiles="${GNOME_SITE}/gexiv2/${version%.*}/gexiv2-${version}.tar.xz"
+checksum=2a0c9cf48fbe8b3435008866ffd40b8eddb0667d2212b42396fdf688e93ce0be
 
 build_options="gir vala"
 build_options_default="gir vala"
@@ -23,7 +23,7 @@ libgexiv2-devel_package() {
 	short_desc+=" - development files"
 	pkg_install() {
 		vmove usr/include
-		vmove usr/lib/*.so
+		vmove "usr/lib/*.so"
 		vmove usr/lib/pkgconfig
 		if [ "$build_option_vala" ]; then
 			vmove usr/share/vala

From 52ca4b4a07508961ab567f5816a87bdcac504ffd Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 14/23] libkexiv25: update to 23.08.2.

---
 srcpkgs/libkexiv25/template | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/srcpkgs/libkexiv25/template b/srcpkgs/libkexiv25/template
index b439a42ef2b97..4d7f9600572ea 100644
--- a/srcpkgs/libkexiv25/template
+++ b/srcpkgs/libkexiv25/template
@@ -1,6 +1,6 @@
 # Template file for 'libkexiv25'
 pkgname=libkexiv25
-version=23.04.0
+version=23.08.2
 revision=1
 build_style=cmake
 configure_args="-DBUILD_TESTING=OFF"
@@ -11,7 +11,7 @@ maintainer="Orphaned <orphan@voidlinux.org>"
 license="GPL-2.0-or-later"
 homepage="https://invent.kde.org/graphics/libkexiv2"
 distfiles="${KDE_SITE}/release-service/${version}/src/libkexiv2-${version}.tar.xz"
-checksum=18d3eed06df9d1e31d8434ed9887e305aba176d0856e19a8cd3bdb555b80d391
+checksum=d06e36a408bf2e846a18056a1f15e61d981fa2a1fceb81f7c15136604319d033
 
 libkexiv25-devel_package() {
 	short_desc+=" - development files"

From 72f1e2090c347076f2e8ddd2c52d6357b9f5aacc Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 15/23] nomacs: update to 3.17.2287.

---
 srcpkgs/nomacs/template | 17 +++++++++++++----
 1 file changed, 13 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/nomacs/template b/srcpkgs/nomacs/template
index c52cd54e294db..956bd21ebb129 100644
--- a/srcpkgs/nomacs/template
+++ b/srcpkgs/nomacs/template
@@ -1,7 +1,8 @@
 # Template file for 'nomacs'
 pkgname=nomacs
-version=3.16.224
-revision=5
+version=3.17.2287
+revision=1
+_plugins_ver=3.17.2285
 build_wrksrc=ImageLounge
 build_style=cmake
 configure_args="-DCMAKE_BUILD_TYPE=None -DENABLE_TRANSLATIONS=1
@@ -13,5 +14,13 @@ short_desc="Simple yet powerful Qt imageviewer"
 maintainer="Orphaned <orphan@voidlinux.org>"
 license="GPL-3.0-or-later"
 homepage="https://github.com/nomacs/nomacs"
-distfiles="https://github.com/nomacs/nomacs/archive/${version}.tar.gz"
-checksum=bbc7e9048026ef9e0d2b64902c88050f17a679ef3d3c009de2c3b7de5d1d217c
+distfiles="https://github.com/nomacs/nomacs/archive/${version}.tar.gz
+ https://github.com/novomesk/nomacs-plugins/archive/refs/tags/${_plugins_ver}.tar.gz>plugins.tar.gz"
+checksum="6905ea615358f84a0c83d5b1b7077871dea0526ec667500a1951448cb845a92c
+ 946b2d754be9ecca5cb155f7ecc5dcafb164f6c3dcc7bf5c3c0610d3b47774aa"
+skip_extraction="plugins.tar.gz"
+
+post_extract() {
+ cd ${build_wrksrc}
+ vsrcextract -C plugins "plugins.tar.gz"
+}

From 660bbd11ef012706eb581fe7003a3f6688442bc4 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 16/23] pdf2djvu: revbump for exiv2-0.28.1.

---
 srcpkgs/pdf2djvu/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/pdf2djvu/template b/srcpkgs/pdf2djvu/template
index ef7433c0c98ae..5a6f3ddf4ed35 100644
--- a/srcpkgs/pdf2djvu/template
+++ b/srcpkgs/pdf2djvu/template
@@ -1,7 +1,7 @@
 # Template file for 'pdf2djvu'
 pkgname=pdf2djvu
 version=0.9.19
-revision=4
+revision=5
 build_style=gnu-configure
 hostmakedepends="pkg-config djvulibre gettext"
 makedepends="djvulibre-devel poppler-devel libgraphicsmagick-devel exiv2-devel libuuid-devel"

From ae4b57ec5491490dd454d85761d3b7aa1e0cca87 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 17/23] phototonic: revbump for exiv2-0.28.1.

---
 srcpkgs/phototonic/patches/exiv2-0.28.patch | 135 ++++++++++++++++++++
 srcpkgs/phototonic/template                 |   2 +-
 2 files changed, 136 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/phototonic/patches/exiv2-0.28.patch

diff --git a/srcpkgs/phototonic/patches/exiv2-0.28.patch b/srcpkgs/phototonic/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..1c75b628dab33
--- /dev/null
+++ b/srcpkgs/phototonic/patches/exiv2-0.28.patch
@@ -0,0 +1,135 @@
+From 923a3fc14de0b779a45696c5f0aef34c74d84f13 Mon Sep 17 00:00:00 2001
+From: Andreas Sturmlechner <asturm@gentoo.org>
+Date: Sun, 28 May 2023 18:54:10 +0200
+Subject: [PATCH] Fix build with exiv2-0.28
+
+Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>
+---
+ ImageViewer.cpp   | 9 +++++++++
+ MetadataCache.cpp | 8 ++++++++
+ Phototonic.cpp    | 4 ++++
+ Tags.cpp          | 8 ++++++++
+ ThumbsViewer.cpp  | 4 ++++
+ 5 files changed, 33 insertions(+)
+
+diff --git a/ImageViewer.cpp b/ImageViewer.cpp
+index 357d223..df3ac43 100644
+--- a/ImageViewer.cpp
++++ b/ImageViewer.cpp
+@@ -945,7 +945,11 @@ void ImageViewer::keyMoveEvent(int direction) {
+ }
+ 
+ void ImageViewer::saveImage() {
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr image;
++#else
+     Exiv2::Image::AutoPtr image;
++#endif
+     bool exifError = false;
+ 
+     if (newImage) {
+@@ -985,8 +989,13 @@ void ImageViewer::saveImage() {
+ }
+ 
+ void ImageViewer::saveImageAs() {
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++    Exiv2::Image::UniquePtr newExifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
+     Exiv2::Image::AutoPtr newExifImage;
++#endif
+     bool exifError = false;
+ 
+     setCursorHiding(false);
+diff --git a/MetadataCache.cpp b/MetadataCache.cpp
+index 524ae74..5ddd4c8 100644
+--- a/MetadataCache.cpp
++++ b/MetadataCache.cpp
+@@ -64,7 +64,11 @@ void MetadataCache::clear() {
+ }
+ 
+ bool MetadataCache::loadImageMetadata(const QString &imageFullPath) {
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
++#endif
+     QSet<QString> tags;
+     long orientation = 0;
+ 
+@@ -78,7 +82,11 @@ bool MetadataCache::loadImageMetadata(const QString &imageFullPath) {
+     try {
+         Exiv2::ExifData &exifData = exifImage->exifData();
+         if (!exifData.empty()) {
++#if EXIV2_TEST_VERSION(0,28,0)
++            orientation = exifData["Exif.Image.Orientation"].value().toUint32();
++#else
+             orientation = exifData["Exif.Image.Orientation"].value().toLong();
++#endif
+         }
+     } catch (Exiv2::Error &error) {
+         qWarning() << "Failed to read Exif metadata";
+diff --git a/Phototonic.cpp b/Phototonic.cpp
+index 6cc95b3..bd5497d 100644
+--- a/Phototonic.cpp
++++ b/Phototonic.cpp
+@@ -3151,7 +3151,11 @@ void Phototonic::removeMetadata() {
+ 
+     if (ret == MessageBox::Yes) {
+         for (int file = 0; file < fileList.size(); ++file) {
++#if EXIV2_TEST_VERSION(0,28,0)
++            Exiv2::Image::UniquePtr image;
++#else
+             Exiv2::Image::AutoPtr image;
++#endif
+             try {
+                 image = Exiv2::ImageFactory::open(fileList[file].toStdString());
+                 image->clearMetadata();
+diff --git a/Tags.cpp b/Tags.cpp
+index 84eea16..a62da9d 100644
+--- a/Tags.cpp
++++ b/Tags.cpp
+@@ -136,7 +136,11 @@ void ImageTags::addTag(QString tagName, bool tagChecked) {
+ 
+ bool ImageTags::writeTagsToImage(QString &imageFileName, QSet<QString> &newTags) {
+     QSet<QString> imageTags;
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
++#endif
+ 
+     try {
+         exifImage = Exiv2::ImageFactory::open(imageFileName.toStdString());
+@@ -160,7 +164,11 @@ bool ImageTags::writeTagsToImage(QString &imageFileName, QSet<QString> &newTags)
+         QSetIterator<QString> newTagsIt(newTags);
+         while (newTagsIt.hasNext()) {
+             QString tag = newTagsIt.next();
++#if EXIV2_TEST_VERSION(0,28,0)
++            Exiv2::Value::UniquePtr value = Exiv2::Value::create(Exiv2::string);
++#else
+             Exiv2::Value::AutoPtr value = Exiv2::Value::create(Exiv2::string);
++#endif
+             value->read(tag.toStdString());
+             Exiv2::IptcKey key("Iptc.Application2.Keywords");
+             newIptcData.add(key, value.get());
+diff --git a/ThumbsViewer.cpp b/ThumbsViewer.cpp
+index 77a6189..4a11475 100644
+--- a/ThumbsViewer.cpp
++++ b/ThumbsViewer.cpp
+@@ -210,7 +210,11 @@ void ThumbsViewer::updateImageInfoViewer(QString imageFullPath) {
+         infoView->addEntry(key, val);
+     }
+ 
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
++#endif
+     try {
+         exifImage = Exiv2::ImageFactory::open(imageFullPath.toStdString());
+         exifImage->readMetadata();
+-- 
+2.40.1
+
diff --git a/srcpkgs/phototonic/template b/srcpkgs/phototonic/template
index 77ae8bf6a4406..4af006cb7da41 100644
--- a/srcpkgs/phototonic/template
+++ b/srcpkgs/phototonic/template
@@ -1,7 +1,7 @@
 # Template file for 'phototonic'
 pkgname=phototonic
 version=2.1
-revision=3
+revision=4
 build_style=qmake
 hostmakedepends="pkg-config qt5-qmake qt5-host-tools"
 makedepends="qt5-svg-devel exiv2-devel"

From eb8f40a99491b2ed6911bb1e81785fa3adaab7c1 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 18/23] qimgv: revbump for exiv2-0.28.1.

---
 srcpkgs/qimgv/patches/exiv2-0.28.patch | 16 ++++++++++++++++
 srcpkgs/qimgv/template                 |  2 +-
 2 files changed, 17 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/qimgv/patches/exiv2-0.28.patch

diff --git a/srcpkgs/qimgv/patches/exiv2-0.28.patch b/srcpkgs/qimgv/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..11f37b5ae2be3
--- /dev/null
+++ b/srcpkgs/qimgv/patches/exiv2-0.28.patch
@@ -0,0 +1,16 @@
+Patch-Source: https://git.alpinelinux.org/aports/tree/community/qimgv/exiv2-0.28.patch
+diff --git a/qimgv/sourcecontainers/documentinfo.cpp b/qimgv/sourcecontainers/documentinfo.cpp
+index 98a68f7..c062474 100644
+--- a/qimgv/sourcecontainers/documentinfo.cpp
++++ b/qimgv/sourcecontainers/documentinfo.cpp
+@@ -271,10 +271,6 @@ void DocumentInfo::loadExifTags() {
+         //std::cout << "Caught Exiv2 exception '" << e.what() << "'\n";
+         return;
+     }
+-    catch (Exiv2::BasicError<CharType> e) {
+-        //std::cout << "Caught BasicError Exiv2 exception '" << e.what() << "'\n";
+-        return;
+-    }
+ #endif
+ }
+ 
diff --git a/srcpkgs/qimgv/template b/srcpkgs/qimgv/template
index 7eb30db33992c..dd341dfe1bfce 100644
--- a/srcpkgs/qimgv/template
+++ b/srcpkgs/qimgv/template
@@ -1,7 +1,7 @@
 # Template file for 'qimgv'
 pkgname=qimgv
 version=1.0.2
-revision=2
+revision=3
 build_style=cmake
 configure_args="$(vopt_if video -DVIDEO_SUPPORT=ON -DVIDEO_SUPPORT=OFF)
  $(vopt_if scale -DOPENCV_SUPPORT=ON -DOPENCV_SUPPORT=OFF)

From 99060a6b82b862eb8fad35548efde7e20741d1d9 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 19/23] SIR: revbump for exiv2-0.28.1.

---
 srcpkgs/SIR/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/SIR/template b/srcpkgs/SIR/template
index 113077acad354..c6da4c26b6c71 100644
--- a/srcpkgs/SIR/template
+++ b/srcpkgs/SIR/template
@@ -1,7 +1,7 @@
 # Template file for 'SIR'
 pkgname=SIR
 version=3.2.2
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="pkg-config"
 makedepends="exiv2-devel qt5-svg-devel qt5-tools-devel"

From cb29403f662343e22c3d1e30ab8fd53adda093ce Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 20/23] viewnior: revbump for exiv2-0.28.1.

---
 srcpkgs/viewnior/patches/exiv2-0.28.patch | 147 ++++++++++++++++++++++
 srcpkgs/viewnior/template                 |   2 +-
 2 files changed, 148 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/viewnior/patches/exiv2-0.28.patch

diff --git a/srcpkgs/viewnior/patches/exiv2-0.28.patch b/srcpkgs/viewnior/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..71459dee15768
--- /dev/null
+++ b/srcpkgs/viewnior/patches/exiv2-0.28.patch
@@ -0,0 +1,147 @@
+Patch-Source: https://gitlab.archlinux.org/archlinux/packaging/packages/viewnior/-/blob/f206ce6c22a3ec5f1f9ea1bde4077584f80458dd/exiv2-0.28.patch
+--
+From b6bb81a1b46e911d15bbf9a730972523de177705 Mon Sep 17 00:00:00 2001
+From: tastytea <tastytea@tastytea.de>
+Date: Tue, 16 May 2023 10:54:40 +0200
+Subject: [PATCH 1/2] change exiv2 AutoPtr to unique_ptr
+
+exiv2-0.28.0 removed Exiv2::Image::AutoPtr and added
+Exiv2::Image::UniquePtr instead. since it's a typedef for
+std::unique_ptr<Image>, i'm using that directly instead of adding a
+condition on the exiv2 version.
+---
+ src/uni-exiv2.cpp | 21 +++++++++++----------
+ 1 file changed, 11 insertions(+), 10 deletions(-)
+
+diff --git a/src/uni-exiv2.cpp b/src/uni-exiv2.cpp
+index 0d14b9f..77064c2 100644
+--- a/src/uni-exiv2.cpp
++++ b/src/uni-exiv2.cpp
+@@ -22,12 +22,13 @@
+ 
+ #include <exiv2/exiv2.hpp>
+ #include <iostream>
++#include <memory>
+ 
+ #include "uni-exiv2.hpp"
+ 
+ #define ARRAY_SIZE(array) (sizeof array/sizeof(array[0]))
+ 
+-static Exiv2::Image::AutoPtr cached_image;
++static std::unique_ptr<Exiv2::Image> cached_image;
+ 
+ extern "C"
+ void
+@@ -35,8 +36,8 @@ uni_read_exiv2_map(const char *uri, void (*callback)(const char*, const char*, v
+ {
+     Exiv2::LogMsg::setLevel(Exiv2::LogMsg::mute);
+     try {
+-        Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open(uri);
+-        if ( image.get() == 0 ) {
++        std::unique_ptr<Exiv2::Image> image = Exiv2::ImageFactory::open(uri);
++        if (image == nullptr) {
+             return;
+         }
+ 
+@@ -91,14 +92,14 @@ uni_read_exiv2_to_cache(const char *uri)
+ {
+     Exiv2::LogMsg::setLevel(Exiv2::LogMsg::mute);
+ 
+-    if ( cached_image.get() != NULL ) {
++    if (cached_image != nullptr) {
+         cached_image->clearMetadata();
+-        cached_image.reset(NULL);
++        cached_image.reset(nullptr);
+     }
+ 
+     try {
+         cached_image = Exiv2::ImageFactory::open(uri);
+-        if ( cached_image.get() == 0 ) {
++        if (cached_image == nullptr) {
+             return 1;
+         }
+ 
+@@ -116,13 +117,13 @@ uni_write_exiv2_from_cache(const char *uri)
+ {
+     Exiv2::LogMsg::setLevel(Exiv2::LogMsg::mute);
+ 
+-    if ( cached_image.get() == NULL ) {
++    if (cached_image == nullptr) {
+         return 1;
+     }
+ 
+     try {
+-        Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open(uri);
+-        if ( image.get() == 0 ) {
++        std::unique_ptr<Exiv2::Image> image = Exiv2::ImageFactory::open(uri);
++        if (image == nullptr) {
+             return 2;
+         }
+ 
+@@ -130,7 +131,7 @@ uni_write_exiv2_from_cache(const char *uri)
+         image->writeMetadata();
+ 
+         cached_image->clearMetadata();
+-        cached_image.reset(NULL);
++        cached_image.reset(nullptr);
+ 
+         return 0;
+     } catch (Exiv2::AnyError& e) {
+
+From 47d0b98cb46526aa8aa035bebcabc14a11fa57ee Mon Sep 17 00:00:00 2001
+From: tastytea <tastytea@tastytea.de>
+Date: Tue, 16 May 2023 11:17:00 +0200
+Subject: [PATCH 2/2] add support for exiv-0.28.0 errors
+
+exiv2-0.28.0 changed Exiv2::AnyError to Exiv2::Error.
+---
+ src/uni-exiv2.cpp | 15 ++++++++++++---
+ 1 file changed, 12 insertions(+), 3 deletions(-)
+
+diff --git a/src/uni-exiv2.cpp b/src/uni-exiv2.cpp
+index 77064c2..567a50f 100644
+--- a/src/uni-exiv2.cpp
++++ b/src/uni-exiv2.cpp
+@@ -28,6 +28,15 @@
+ 
+ #define ARRAY_SIZE(array) (sizeof array/sizeof(array[0]))
+ 
++#define EXIV_ERROR Exiv2::AnyError
++#ifdef EXIV2_VERSION
++    #ifdef EXIV2_TEST_VERSION
++        #if EXIV2_TEST_VERSION(0,28,0)
++            #define EXIV_ERROR Exiv2::Error
++        #endif
++    #endif
++#endif
++
+ static std::unique_ptr<Exiv2::Image> cached_image;
+ 
+ extern "C"
+@@ -81,7 +90,7 @@ uni_read_exiv2_map(const char *uri, void (*callback)(const char*, const char*, v
+                 }
+             }
+         }
+-    } catch (Exiv2::AnyError& e) {
++    } catch (EXIV_ERROR& e) {
+         std::cerr << "Exiv2: '" << e << "'\n";
+     }
+ }
+@@ -104,7 +113,7 @@ uni_read_exiv2_to_cache(const char *uri)
+         }
+ 
+         cached_image->readMetadata();
+-    } catch (Exiv2::AnyError& e) {
++    } catch (EXIV_ERROR& e) {
+         std::cerr << "Exiv2: '" << e << "'\n";
+     }
+ 
+@@ -134,7 +143,7 @@ uni_write_exiv2_from_cache(const char *uri)
+         cached_image.reset(nullptr);
+ 
+         return 0;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (EXIV_ERROR& e) {
+         std::cerr << "Exiv2: '" << e << "'\n";
+     }
+ 
diff --git a/srcpkgs/viewnior/template b/srcpkgs/viewnior/template
index ea1e528a8651f..4c73226662ca0 100644
--- a/srcpkgs/viewnior/template
+++ b/srcpkgs/viewnior/template
@@ -1,7 +1,7 @@
 # Template file for 'viewnior'
 pkgname=viewnior
 version=1.8
-revision=1
+revision=2
 build_style=meson
 hostmakedepends="pkg-config intltool glib-devel gettext-devel"
 makedepends="gtk+-devel exiv2-devel"

From a721769416a3c3d5e32b132ae929ea8a84b0c8a8 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Mon, 23 Oct 2023 19:06:34 +0200
Subject: [PATCH 21/23] New package: nufraw-0.43.3

Co-authored-by: triallax <triallax@tutanota.com>
---
 srcpkgs/nufraw-gimp                           |  1 +
 .../patches/0001-nufraw-glib-2.70.patch       | 20 +++++++
 srcpkgs/nufraw/patches/exiv-0.28.x.diff       | 59 +++++++++++++++++++
 srcpkgs/nufraw/template                       | 56 ++++++++++++++++++
 srcpkgs/ufraw                                 |  1 +
 srcpkgs/ufraw-gimp                            |  2 +-
 .../ufraw/patches/001-no-gimp-remote.patch    | 12 ----
 srcpkgs/ufraw/patches/002-fix_abs_int.patch   | 11 ----
 .../ufraw/patches/03_fix-unsigned-char.patch  | 14 -----
 srcpkgs/ufraw/patches/exiv-0.27.patch         | 25 --------
 srcpkgs/ufraw/patches/glib-2.68.patch         | 30 ----------
 srcpkgs/ufraw/patches/iostream.patch          | 13 ----
 srcpkgs/ufraw/template                        | 38 ------------
 13 files changed, 138 insertions(+), 144 deletions(-)
 create mode 120000 srcpkgs/nufraw-gimp
 create mode 100644 srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch
 create mode 100644 srcpkgs/nufraw/patches/exiv-0.28.x.diff
 create mode 100644 srcpkgs/nufraw/template
 create mode 120000 srcpkgs/ufraw
 delete mode 100644 srcpkgs/ufraw/patches/001-no-gimp-remote.patch
 delete mode 100644 srcpkgs/ufraw/patches/002-fix_abs_int.patch
 delete mode 100644 srcpkgs/ufraw/patches/03_fix-unsigned-char.patch
 delete mode 100644 srcpkgs/ufraw/patches/exiv-0.27.patch
 delete mode 100644 srcpkgs/ufraw/patches/glib-2.68.patch
 delete mode 100644 srcpkgs/ufraw/patches/iostream.patch
 delete mode 100644 srcpkgs/ufraw/template

diff --git a/srcpkgs/nufraw-gimp b/srcpkgs/nufraw-gimp
new file mode 120000
index 0000000000000..0bd1459b2a16f
--- /dev/null
+++ b/srcpkgs/nufraw-gimp
@@ -0,0 +1 @@
+nufraw
\ No newline at end of file
diff --git a/srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch b/srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch
new file mode 100644
index 0000000000000..41f10bfbafa1f
--- /dev/null
+++ b/srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch
@@ -0,0 +1,20 @@
+diff -ru nufraw/uf_glib.h nufraw/uf_glib.h
+--- nufraw/uf_glib.h	2022-02-23 09:03:44.700472919 +0100
++++ nufraw/uf_glib.h	2022-02-23 09:04:50.260308805 +0100
+@@ -13,13 +13,13 @@
+ #ifndef _UF_GLIB_H
+ #define _UF_GLIB_H
+ 
++#include <glib.h>
++#include <glib/gstdio.h>
++
+ #ifdef __cplusplus
+ extern "C" {
+ #endif
+ 
+-#include <glib.h>
+-#include <glib/gstdio.h>
+-
+ // g_win32_locale_filename_from_utf8 is needed only on win32
+ #ifdef _WIN32
+ #define uf_win32_locale_filename_from_utf8(__some_string__) \
diff --git a/srcpkgs/nufraw/patches/exiv-0.28.x.diff b/srcpkgs/nufraw/patches/exiv-0.28.x.diff
new file mode 100644
index 0000000000000..6c23359bf706c
--- /dev/null
+++ b/srcpkgs/nufraw/patches/exiv-0.28.x.diff
@@ -0,0 +1,59 @@
+Patch taken from AUR package: https://aur.archlinux.org/cgit/aur.git/tree/exiv2-error.patch?h=nufraw&id=29e467f2c297fcd0f36548642d6d2cab6428d08f
+diff --git a/nufraw_exiv2.cc b/nufraw_exiv2.cc
+index 2de4cc3..45aea87 100644
+--- a/nufraw_exiv2.cc
++++ b/nufraw_exiv2.cc
+@@ -54,7 +54,7 @@ extern "C" int nufraw_exif_read_input(nufraw_data *uf)
+         uf->inputExifBuf = NULL;
+         uf->inputExifBufLen = 0;
+ 
+-        Exiv2::Image::AutoPtr image;
++        Exiv2::Image::UniquePtr image;
+         if (uf->unzippedBuf != NULL) {
+             image = Exiv2::ImageFactory::open(
+                         (const Exiv2::byte*)uf->unzippedBuf, uf->unzippedBufLen);
+@@ -135,7 +135,7 @@ extern "C" int nufraw_exif_read_input(nufraw_data *uf)
+         nufraw_message(NUFRAW_SET_LOG, "%s\n", stderror.str().c_str());
+ 
+         return NUFRAW_SUCCESS;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (Exiv2::Error& e) {
+         std::cerr.rdbuf(savecerr);
+         std::string s(e.what());
+         nufraw_message(NUFRAW_SET_WARNING, "%s\n", s.c_str());
+@@ -156,7 +156,7 @@ static Exiv2::ExifData nufraw_prepare_exifdata(nufraw_data *uf)
+         if ((pos = exifData.findKey(Exiv2::ExifKey("Exif.Image.Orientation")))
+                 != exifData.end()) {
+             nufraw_message(NUFRAW_SET_LOG, "Resetting %s from '%d' to '1'\n",
+-                          pos->key().c_str(), pos->value().toLong());
++                          pos->key().c_str(), pos->value().toInt64());
+             pos->setValue("1"); /* 1 = Normal orientation */
+         }
+     }
+@@ -327,7 +327,7 @@ extern "C" int nufraw_exif_prepare_output(nufraw_data *uf)
+         nufraw_message(NUFRAW_SET_LOG, "%s\n", stderror.str().c_str());
+ 
+         return NUFRAW_SUCCESS;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (Exiv2::Error& e) {
+         std::cerr.rdbuf(savecerr);
+         std::string s(e.what());
+         nufraw_message(NUFRAW_SET_WARNING, "%s\n", s.c_str());
+@@ -347,7 +347,7 @@ extern "C" int nufraw_exif_write(nufraw_data *uf)
+ 
+         char *filename =
+             uf_win32_locale_filename_from_utf8(uf->conf->outputFilename);
+-        Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open(filename);
++        Exiv2::Image::UniquePtr image = Exiv2::ImageFactory::open(filename);
+         uf_win32_locale_filename_free(filename);
+         assert(image.get() != 0);
+ 
+@@ -367,7 +367,7 @@ extern "C" int nufraw_exif_write(nufraw_data *uf)
+         nufraw_message(NUFRAW_SET_LOG, "%s\n", stderror.str().c_str());
+ 
+         return NUFRAW_SUCCESS;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (Exiv2::Error& e) {
+         std::cerr.rdbuf(savecerr);
+         std::string s(e.what());
+         nufraw_message(NUFRAW_SET_WARNING, "%s\n", s.c_str());
diff --git a/srcpkgs/nufraw/template b/srcpkgs/nufraw/template
new file mode 100644
index 0000000000000..7d75a4d372555
--- /dev/null
+++ b/srcpkgs/nufraw/template
@@ -0,0 +1,56 @@
+# Template file for 'nufraw'
+pkgname=nufraw
+version=0.43.3
+revision=1
+_ver="${version%.*}-${version##*.}"
+build_style=gnu-configure
+configure_args="--enable-contrast --enable-mime --enable-openmp --with-gimp
+ --enable-extras"
+hostmakedepends="pkg-config automake libtool glib-devel"
+# libgexiv2-devel is only here to fix build order, remove on next template
+# change
+makedepends="exiv2-devel gimp-devel glib-devel gtkimageview-devel lcms2-devel
+ lensfun-devel jasper-devel libgexiv2-devel"
+depends="desktop-file-utils"
+short_desc="Utility to read and manipulate raw images from digital cameras"
+maintainer="John <me@johnnynator.dev>"
+license="GPL-2.0-or-later"
+homepage="https://sourceforge.net/projects/nufraw/"
+distfiles="${SOURCEFORGE_SITE}/nufraw/nufraw-${_ver}.tar.gz"
+checksum=2c7dcc1590993ec267b3112562b2433010d6f94f6acc6506c76aa29cf8c6c32c
+
+case "$XBPS_TARGET_MACHINE" in
+	armv[67]l* | aarch64*)
+		makedepends+=" libgomp-devel"
+		make_build_args="CXXFLAGS+=-fsigned-char LDFLAGS+=-fopenmp"
+		;;
+esac
+
+pre_configure() {
+	autoreconf -fi
+}
+
+pre_build() {
+	mv nufraw.desktop{.desktop,}
+	chmod +x generate_schemas.sh
+}
+
+nufraw-gimp_package() {
+	depends="${sourcepkg}>=${version}_${revision}"
+	short_desc+=" - gimp plugin"
+	pkg_install() {
+		vmove usr/lib/gimp
+	}
+}
+
+ufraw_package() {
+	depends="${sourcepkg}>=${version}_${revision}"
+	build_style=meta
+	short_desc+=" (transitional dummy package)"
+}
+
+ufraw-gimp_package() {
+	depends="nufraw-gimp>=${version}_${revision}"
+	build_style=meta
+	short_desc+=" - gimp plugin (transitional dummy package)"
+}
diff --git a/srcpkgs/ufraw b/srcpkgs/ufraw
new file mode 120000
index 0000000000000..0bd1459b2a16f
--- /dev/null
+++ b/srcpkgs/ufraw
@@ -0,0 +1 @@
+nufraw
\ No newline at end of file
diff --git a/srcpkgs/ufraw-gimp b/srcpkgs/ufraw-gimp
index 967dc902dd02b..0bd1459b2a16f 120000
--- a/srcpkgs/ufraw-gimp
+++ b/srcpkgs/ufraw-gimp
@@ -1 +1 @@
-ufraw
\ No newline at end of file
+nufraw
\ No newline at end of file
diff --git a/srcpkgs/ufraw/patches/001-no-gimp-remote.patch b/srcpkgs/ufraw/patches/001-no-gimp-remote.patch
deleted file mode 100644
index ca4f4beb6240f..0000000000000
--- a/srcpkgs/ufraw/patches/001-no-gimp-remote.patch
+++ /dev/null
@@ -1,12 +0,0 @@
-Don't use gimp-remote since gimp 2.4 already includes gimp-remote functionality
---- a/ufraw_conf.c
-+++ b/ufraw_conf.c
-@@ -137,7 +137,7 @@
- #elif HAVE_GIMP_2_4
-     "gimp", /* remoteGimpCommand */
- #else
--    "gimp-remote", /* remoteGimpCommand */
-+    "gimp", /* remoteGimpCommand */
- #endif
- 
-     /* EXIF data */
diff --git a/srcpkgs/ufraw/patches/002-fix_abs_int.patch b/srcpkgs/ufraw/patches/002-fix_abs_int.patch
deleted file mode 100644
index 6fc552769c9f8..0000000000000
--- a/srcpkgs/ufraw/patches/002-fix_abs_int.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- a/dcraw.cc	2015-06-16 05:58:38.000000000 +0200
-+++ b/dcraw.cc	2018-02-04 14:46:54.489951076 +0100
-@@ -9242,7 +9242,7 @@
-     if (make[0] == 'O') {
-       i = find_green (12, 32, 1188864, 3576832);
-       c = find_green (12, 32, 2383920, 2387016);
--      if (abs(i) < abs(c)) {
-+      if (abs((int)i) < abs((int)c)) {
- 	SWAP(i,c);
- 	load_flags = 24;
-       }
diff --git a/srcpkgs/ufraw/patches/03_fix-unsigned-char.patch b/srcpkgs/ufraw/patches/03_fix-unsigned-char.patch
deleted file mode 100644
index 8690f87ca7d59..0000000000000
--- a/srcpkgs/ufraw/patches/03_fix-unsigned-char.patch
+++ /dev/null
@@ -1,14 +0,0 @@
-Source: written by John Paul Adrian Glaubitz for Debian
-Upstream: https://sourceforge.net/p/ufraw/bugs/417
-Reason: fixes a compilation failure on arm architectures
---- a/dcraw.cc
-+++ b/dcraw.cc
-@@ -2285,7 +2285,7 @@ void CLASS quicktake_100_load_raw()
- 
- void CLASS kodak_radc_load_raw()
- {
--  static const char src[] = {
-+  static const signed char src[] = {
-     1,1, 2,3, 3,4, 4,2, 5,7, 6,5, 7,6, 7,8,
-     1,0, 2,1, 3,3, 4,4, 5,2, 6,7, 7,6, 8,5, 8,8,
-     2,1, 2,3, 3,0, 3,2, 3,4, 4,6, 5,5, 6,7, 6,8,
diff --git a/srcpkgs/ufraw/patches/exiv-0.27.patch b/srcpkgs/ufraw/patches/exiv-0.27.patch
deleted file mode 100644
index b5b4140fff8ed..0000000000000
--- a/srcpkgs/ufraw/patches/exiv-0.27.patch
+++ /dev/null
@@ -1,25 +0,0 @@
---- a/ufraw_exiv2.cc	2015-06-16 05:58:38.000000000 +0200
-+++ b/ufraw_exiv2.cc	2018-12-29 22:51:23.291894430 +0100
-@@ -15,9 +15,7 @@
- #include "ufraw.h"
- 
- #ifdef HAVE_EXIV2
--#include <exiv2/image.hpp>
--#include <exiv2/easyaccess.hpp>
--#include <exiv2/exif.hpp>
-+#include <exiv2/exiv2.hpp>
- #include <sstream>
- #include <cassert>
- 
-@@ -67,7 +65,11 @@
-         if (exifData.empty()) {
-             std::string error(uf->filename);
-             error += ": No Exif data found in the file";
-+#if EXIV2_TEST_VERSION(0,27,0)
-+            throw Exiv2::Error(Exiv2::kerErrorMessage, error);
-+#else
-             throw Exiv2::Error(1, error);
-+#endif
-         }
- 
-         /* List of tag names taken from exiv2's printSummary() in actions.cpp */
diff --git a/srcpkgs/ufraw/patches/glib-2.68.patch b/srcpkgs/ufraw/patches/glib-2.68.patch
deleted file mode 100644
index 5b61468f118aa..0000000000000
--- a/srcpkgs/ufraw/patches/glib-2.68.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-From c56f8be3caf1cf3d9a5c80597bdbaf1325faacc0 Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?S=C3=A9rgio=20M=2E=20Basto?= <sergio@serjux.com>
-Date: Tue, 13 Apr 2021 23:45:39 +0100
-Subject: [PATCH] Fix build against glib-2.68 fixes #10
-
----
- uf_glib.h | 6 +++---
- 1 file changed, 3 insertions(+), 3 deletions(-)
-
-diff --git a/uf_glib.h b/uf_glib.h
-index 21c10b19..56cd6971 100644
---- a/uf_glib.h
-+++ b/uf_glib.h
-@@ -13,13 +13,13 @@
- #ifndef _UF_GLIB_H
- #define _UF_GLIB_H
- 
-+#include <glib.h>
-+#include <glib/gstdio.h>
-+
- #ifdef __cplusplus
- extern "C" {
- #endif
- 
--#include <glib.h>
--#include <glib/gstdio.h>
--
- // g_win32_locale_filename_from_utf8 is needed only on win32
- #ifdef _WIN32
- #define uf_win32_locale_filename_from_utf8(__some_string__) \
diff --git a/srcpkgs/ufraw/patches/iostream.patch b/srcpkgs/ufraw/patches/iostream.patch
deleted file mode 100644
index 6d15869f63db8..0000000000000
--- a/srcpkgs/ufraw/patches/iostream.patch
+++ /dev/null
@@ -1,13 +0,0 @@
-ufraw_exiv2.cc:343:10: note: 'std::cerr' is defined in header '<iostream>'
-ufraw_exiv2.cc:365:14: error: 'cerr' is not a member of 'std'
-
---- a/ufraw_exiv2.cc
-+++ b/ufraw_exiv2.cc
-@@ -17,6 +17,7 @@
- #ifdef HAVE_EXIV2
- #include <exiv2/exiv2.hpp>
- #include <sstream>
-+#include <iostream>
- #include <cassert>
- 
- /*
diff --git a/srcpkgs/ufraw/template b/srcpkgs/ufraw/template
deleted file mode 100644
index ceddcacacefb2..0000000000000
--- a/srcpkgs/ufraw/template
+++ /dev/null
@@ -1,38 +0,0 @@
-# Template file for 'ufraw'
-pkgname=ufraw
-version=0.22
-revision=5
-build_style=gnu-configure
-configure_args="--enable-contrast --enable-mime --enable-openmp --with-gimp
- $(vopt_enable extras)"
-hostmakedepends="pkg-config dcraw gettext"
-makedepends="exiv2-devel gimp-devel glib-devel gtkimageview-devel lcms2-devel lensfun-devel
- jasper-devel"
-depends="desktop-file-utils"
-short_desc="Utility to read and manipulate raw images from digital cameras"
-maintainer="John <me@johnnynator.dev>"
-license="GPL-2.0-or-later"
-homepage="http://ufraw.sourceforge.net/"
-distfiles="${SOURCEFORGE_SITE}/ufraw/ufraw/ufraw-${version}/ufraw-${version}.tar.gz"
-checksum=f7abd28ce587db2a74b4c54149bd8a2523a7ddc09bedf4f923246ff0ae09a25e
-
-build_options="extras"
-
-post_patch() {
-	vsed -e 's/default(none)//g' \
-		-i dcraw_indi.c \
-		-i dcraw_api.cc \
-		-i ufraw_ufraw.c \
-		-i ufraw_developer.c
-	vsed -i -e '/DATADIRNAME=/s/=.*/=share/' configure
-	vsed -i -e "s,^localedir =.*,localedir = /usr/share/locale," \
-		po/Makefile.in.in
-}
-
-ufraw-gimp_package() {
-	depends="${sourcepkg}>=${version}_${revision}"
-	short_desc+=" - gimp plugin"
-	pkg_install() {
-		vmove usr/lib/gimp
-	}
-}

From dc866d9bf4c9a25485fdbd8b3728eade830499d9 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 8 Nov 2023 12:53:45 +0000
Subject: [PATCH 22/23] krita: revbump for exiv2-0.28.1.

---
 srcpkgs/krita/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/krita/template b/srcpkgs/krita/template
index f4d665daf7c31..d804b581a8689 100644
--- a/srcpkgs/krita/template
+++ b/srcpkgs/krita/template
@@ -1,7 +1,7 @@
 # Template file for 'krita'
 pkgname=krita
 version=5.2.1
-revision=2
+revision=3
 build_style=cmake
 configure_args="-Wno-dev -DBUILD_TESTING=OFF"
 hostmakedepends="extra-cmake-modules gettext pkg-config python3

From 11fd3f1095cc8c0b9efcbfd3cd150c2b8b4f5e99 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 8 Nov 2023 18:25:01 +0000
Subject: [PATCH 23/23] darktable: revbump for exiv2-0.28.1.

---
 srcpkgs/darktable/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/darktable/template b/srcpkgs/darktable/template
index f76936a1692e8..97dfae3471e7c 100644
--- a/srcpkgs/darktable/template
+++ b/srcpkgs/darktable/template
@@ -1,7 +1,7 @@
 # Template file for 'darktable'
 pkgname=darktable
 version=4.4.2
-revision=4
+revision=5
 # upstream only supports these archs:
 archs="x86_64* aarch64* ppc64le*"
 build_style=cmake

^ permalink raw reply	[flat|nested] 27+ messages in thread

* Re: [PR PATCH] [Updated] exiv2: update to 0.28.1.
  2023-10-23  0:10 [PR PATCH] exiv2: update to 0.28.0 mhmdanas
                   ` (17 preceding siblings ...)
  2023-11-15 17:40 ` mhmdanas
@ 2023-11-15 17:57 ` mhmdanas
  2023-11-16 15:12 ` [PR REVIEW] " sh1r4s3
                   ` (6 subsequent siblings)
  25 siblings, 0 replies; 27+ messages in thread
From: mhmdanas @ 2023-11-15 17:57 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 2086 bytes --]

There is an updated pull request by mhmdanas against master on the void-packages repository

https://github.com/mhmdanas/void-packages exiv2-0.28.0
https://github.com/void-linux/void-packages/pull/46838

exiv2: update to 0.28.1.
<!-- Uncomment relevant sections and delete options which are not applicable -->

#### Testing the changes
- I tested the changes in this PR: **briefly**

TODO:
- [x] Fix `gwenview`'s failed checks (not really fixed but the exact same tests fail on master as well)
- [x] `test_exiv2` fails for `libextractor`
- [x] `kfilemetadata5` tests fail (same tests fail on master)
- [x] Fix `nufraw` cross-build
- [x] `digikam` fails to build

@Johnnynator ufraw has been [unmaintained since December 2016](https://sourceforge.net/p/ufraw/discussion/434060/thread/30b4249b/), and it doesn't build with this PR; here are the options:
- remove the package entirely
- replace it with the newer [nufraw](https://sourceforge.net/projects/nufraw/), which already has [an exiv 0.28.x patch floating around](https://aur.archlinux.org/cgit/aur.git/tree/exiv2-error.patch?h=nufraw)
- patch it to build with this PR

What do you think? (edit: `nufraw` now replaces `ufraw` in this PR)

<!--
#### New package
- This new package conforms to the [package requirements](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTItest_exiv2NG.md#package-requirements): **YES**|**NO**
-->

<!-- Note: If the build is likely to take more than 2 hours, please add ci skip tag as described in
https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration
and test at least one native build and, if supported, at least one cross build.
Ignore this section if this PR is not skipping CI.
-->
<!--
#### Local build testing
- I built this PR locally for my native architecture, (ARCH-LIBC)
- I built this PR locally for these architectures (if supported. mark crossbuilds):
  - aarch64-musl
  - armv7l
  - armv6l-musl
-->


A patch file from https://github.com/void-linux/void-packages/pull/46838.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-exiv2-0.28.0-46838.patch --]
[-- Type: text/x-diff, Size: 75364 bytes --]

From 21979814e2330def5222b6963ea7eea4cc21af30 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 15 Nov 2023 17:19:46 +0000
Subject: [PATCH 01/23] Revert "xsimd: update to 11.2.0."

This reverts commit de75fb145239a14517310ec0e516491e9e2feae7.

Breaks 32-bit krita build:
https://github.com/void-linux/void-packages/issues/47243
---
 srcpkgs/xsimd/template | 13 ++++++-------
 1 file changed, 6 insertions(+), 7 deletions(-)

diff --git a/srcpkgs/xsimd/template b/srcpkgs/xsimd/template
index ffc806bd7d111..7ab79e3a6de09 100644
--- a/srcpkgs/xsimd/template
+++ b/srcpkgs/xsimd/template
@@ -1,20 +1,19 @@
 # Template file for 'xsimd'
 pkgname=xsimd
-version=11.2.0
-revision=1
+reverts="11.2.0_1"
+version=11.1.0
+revision=2
 build_style=cmake
-checkdepends="doctest-devel"
 short_desc="C++ wrappers for SIMD intrinsics and parallelized, optimized mathematical functions"
 maintainer="John <me@johnnynator.dev>"
 license="BSD-3-Clause"
 homepage="https://github.com/xtensor-stack/xsimd"
 distfiles="https://github.com/xtensor-stack/xsimd/archive/refs/tags/${version}.tar.gz"
-checksum=509bbfe12e78ee1a0e81711019e7c7a372dabcff566dbf15b95cc94339443242
+checksum=aa54dba8daade472656eba0d27154f072fec06ee3831aefcac69a5f6c7dbbae7
 
-if [ "$XBPS_CHECK_PKGS" ]; then
+if [ -z "$CROSS_BUILD" ]; then
 	configure_args="-DBUILD_TESTS=ON"
-else
-	configure_args="-DBUILD_TESTS=OFF"
+	makedepends="doctest-devel"
 fi
 
 post_install() {

From 65d7d58e9576ff06f2ea41d7faf24a99db713e3d Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Mon, 23 Oct 2023 01:20:09 +0100
Subject: [PATCH 02/23] inih: add `libINIReader.so.0` common/shlibs entry.

---
 common/shlibs | 1 +
 1 file changed, 1 insertion(+)

diff --git a/common/shlibs b/common/shlibs
index 1a721780f8545..6ff3fd244a49c 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -3902,6 +3902,7 @@ libnotcurses++.so.3 notcurses-3.0.5_1
 libnotcurses-ffi.so.3 notcurses-3.0.5_1
 libevemu.so.3 evemu-2.7.0_1
 libinih.so.0 inih-52_1
+libINIReader.so.0 inih-57_1
 libpcaudio.so.0 pcaudiolib-1.1_1
 libdcerpc-samr.so.0 samba-4.13.2_1
 libdcerpc-server-core.so.0 samba-4.13.2_1

From 9abbe1722c32a398c16308c48a80a9b1a8f98b1a Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:12 +0100
Subject: [PATCH 03/23] exiv2: update to 0.28.1.

---
 common/shlibs          |  2 +-
 srcpkgs/exiv2/template | 18 +++++++++++-------
 2 files changed, 12 insertions(+), 8 deletions(-)

diff --git a/common/shlibs b/common/shlibs
index 6ff3fd244a49c..4fa10586d145c 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -555,7 +555,7 @@ libgimpcolor-2.0.so.0 libgimp-2.10.0_1
 libgimpmodule-2.0.so.0 libgimp-2.10.0_1
 libgmic.so.3 gmic-3.1.6_1
 libcgmic.so.3 gmic-3.1.6_1
-libexiv2.so.27 exiv2-0.27_1
+libexiv2.so.28 exiv2-0.28.0_1
 libKF5Holidays.so.5 kholidays-5.47.0_1
 libPhabricatorHelpers.so.5 purpose-5.48.0_1
 libKF5PurposeWidgets.so.5 purpose-5.48.0_1
diff --git a/srcpkgs/exiv2/template b/srcpkgs/exiv2/template
index 49985fe82cc14..b068757bcf201 100644
--- a/srcpkgs/exiv2/template
+++ b/srcpkgs/exiv2/template
@@ -1,17 +1,17 @@
 # Template file for 'exiv2'
 pkgname=exiv2
-version=0.27.6
+version=0.28.1
 revision=1
 build_style=cmake
 configure_args="-DEXIV2_BUILD_SAMPLES=OFF -DEXIV2_ENABLE_BMFF=ON"
-makedepends="zlib-devel expat-devel"
-checkdepends="gtest-devel"
+makedepends="zlib-devel brotli-devel expat-devel inih-devel"
+checkdepends="gtest-devel python3"
 short_desc="Image metadata manipulation"
 maintainer="Enno Boland <gottox@voidlinux.org>"
 license="GPL-2.0-or-later"
 homepage="https://www.exiv2.org"
-distfiles="https://github.com/Exiv2/exiv2/releases/download/v${version}/exiv2-${version}-Source.tar.gz"
-checksum=4c192483a1125dc59a3d70b30d30d32edace9e14adf52802d2f853abf72db8a6
+distfiles="https://github.com/Exiv2/exiv2/archive/refs/tags/v${version}.tar.gz"
+checksum=3078651f995cb6313b1041f07f4dd1bf0e9e4d394d6e2adc6e92ad0b621291fa
 
 if [ -n "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DEXIV2_BUILD_UNIT_TESTS=ON"
@@ -21,14 +21,18 @@ if [ -n "$XBPS_CCACHE" ]; then
 	configure_args+=" -DBUILD_WITH_CCACHE=ON"
 fi
 
+pre_check() {
+	# https://github.com/Exiv2/exiv2/issues/2762
+	rm -f tests/bugfixes/github/test_issue_2427.py
+}
+
 exiv2-devel_package() {
 	depends="${makedepends} ${sourcepkg}-${version}_${revision}"
 	short_desc+=" - development files"
 	pkg_install() {
 		vmove usr/include
-		vmove usr/lib/cmake
 		vmove usr/lib/pkgconfig
-		vmove "usr/lib/*.a"
+		vmove usr/share/cmake
 		vmove "usr/lib/*.so"
 	}
 }

From 74d0995890eca8d4182b7deeb440b313f675fc92 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:37 +0100
Subject: [PATCH 04/23] ART: revbump for exiv2-0.28.1.

---
 srcpkgs/ART/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/ART/template b/srcpkgs/ART/template
index b6c47fc6c4cdf..94c7aa0378061 100644
--- a/srcpkgs/ART/template
+++ b/srcpkgs/ART/template
@@ -1,7 +1,7 @@
 # Template file for 'ART'
 pkgname=ART
 version=1.20.2
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="pkg-config"
 makedepends="fftw-devel gtkmm-devel lensfun-devel

From 16ab91c8ff30841f622545910fc6d873cafc2af2 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 05/23] digikam: revbump for exiv2-0.28.1.

---
 .../patches/fix-build-with-exiv2-0.28.1.patch | 422 ++++++++++++++++++
 srcpkgs/digikam/template                      |   2 +-
 2 files changed, 423 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/digikam/patches/fix-build-with-exiv2-0.28.1.patch

diff --git a/srcpkgs/digikam/patches/fix-build-with-exiv2-0.28.1.patch b/srcpkgs/digikam/patches/fix-build-with-exiv2-0.28.1.patch
new file mode 100644
index 0000000000000..2a01b4545e76d
--- /dev/null
+++ b/srcpkgs/digikam/patches/fix-build-with-exiv2-0.28.1.patch
@@ -0,0 +1,422 @@
+From a76a561b20e7300510b29edc97afab01e381c0ec Mon Sep 17 00:00:00 2001
+From: Maik Qualmann <metzpinguin@gmail.com>
+Date: Wed, 8 Nov 2023 23:13:26 +0100
+Subject: [PATCH 1/5] fix compile with Exiv2-0.28.1 It should still compile
+ even with smaller Exiv2 versions.
+
+---
+ core/CMakeLists.txt                     | 4 ++--
+ core/app/DigikamCoreTarget.cmake        | 2 +-
+ core/cmake/rules/RulesLibExiv2.cmake    | 8 ++++----
+ core/libs/metadataengine/CMakeLists.txt | 4 ++--
+ 4 files changed, 9 insertions(+), 9 deletions(-)
+
+diff --git a/core/CMakeLists.txt b/core/CMakeLists.txt
+index c694c4b176..d5dc2f0dd8 100644
+--- a/core/CMakeLists.txt
++++ b/core/CMakeLists.txt
+@@ -255,7 +255,7 @@ PRINT_COMPONENT_COMPILE_STATUS("Media Player Support"                       ENAB
+ # ==============================================================================
+ 
+ PRINT_LIBRARY_STATUS("libboostgraph" "https://github.com/boostorg/boost"                 "(version >= 1.43.0)"                Boost_FOUND)
+-PRINT_LIBRARY_STATUS("libexiv2"      "https://github.com/Exiv2/exiv2"                    "(version >= ${EXIV2_MIN_VERSION}"   exiv2_FOUND)
++PRINT_LIBRARY_STATUS("libexiv2"      "https://github.com/Exiv2/exiv2"                    "(version >= ${EXIV2_MIN_VERSION}"   LibExiv2_FOUND)
+ PRINT_LIBRARY_STATUS("libexpat"      "https://libexpat.github.io"                        "(version >= 2.0.0)"                 EXPAT_FOUND)
+ PRINT_LIBRARY_STATUS("libjpeg"       "https://github.com/libjpeg-turbo/libjpeg-turbo"    "(version >= 6b)"                    JPEG_FOUND)
+ PRINT_LIBRARY_STATUS("libkde"        "https://invent.kde.org/frameworks/"                "(version >= ${KF5_MIN_VERSION})"    KF5_FOUND)
+@@ -306,7 +306,7 @@ endif()
+ # ==============================================================================
+ 
+ if(Boost_FOUND                          AND
+-   exiv2_FOUND                          AND
++   LibExiv2_FOUND                       AND
+    EXPAT_FOUND                          AND
+    JPEG_FOUND                           AND
+    KF5_FOUND                            AND
+diff --git a/core/app/DigikamCoreTarget.cmake b/core/app/DigikamCoreTarget.cmake
+index 83fda1b35f..8221a2d632 100644
+--- a/core/app/DigikamCoreTarget.cmake
++++ b/core/app/DigikamCoreTarget.cmake
+@@ -151,7 +151,7 @@ target_link_libraries(digikamcore
+                       ${TIFF_LIBRARIES}
+                       PNG::PNG
+                       ${JPEG_LIBRARIES}
+-                      exiv2lib
++                      ${LibExiv2_LIBRARIES}
+ 
+                       ${OPENMP_LDFLAGS}
+ 
+diff --git a/core/cmake/rules/RulesLibExiv2.cmake b/core/cmake/rules/RulesLibExiv2.cmake
+index c8b37d307c..a8ca259432 100644
+--- a/core/cmake/rules/RulesLibExiv2.cmake
++++ b/core/cmake/rules/RulesLibExiv2.cmake
+@@ -4,7 +4,7 @@
+ # SPDX-License-Identifier: BSD-3-Clause
+ #
+ 
+-find_package(exiv2 REQUIRED)
++find_package(LibExiv2 REQUIRED)
+ 
+ set_package_properties("exiv2"     PROPERTIES
+                        DESCRIPTION "Required to build digiKam"
+@@ -13,13 +13,13 @@ set_package_properties("exiv2"     PROPERTIES
+                        PURPOSE     "Library to manage image metadata"
+ )
+ 
+-if("${exiv2_VERSION}" VERSION_LESS ${EXIV2_MIN_VERSION})
++if("${LibExiv2_VERSION}" VERSION_LESS ${EXIV2_MIN_VERSION})
+ 
+-    message(FATAL_ERROR "Exiv2 version is too old (${exiv2_VERSION})! Minimal version required:${EXIV2_MIN_VERSION}.")
++    message(FATAL_ERROR "Exiv2 version is too old (${LibExiv2_VERSION})! Minimal version required:${EXIV2_MIN_VERSION}.")
+ 
+ endif()
+ 
+-if("${exiv2_VERSION}" VERSION_LESS "0.27.99")
++if("${LibExiv2_VERSION}" VERSION_LESS "0.27.99")
+ 
+     set(EXIV2_CXX_STANDARD 11)
+ 
+diff --git a/core/libs/metadataengine/CMakeLists.txt b/core/libs/metadataengine/CMakeLists.txt
+index 47aa889d5e..bd4dba0bbd 100644
+--- a/core/libs/metadataengine/CMakeLists.txt
++++ b/core/libs/metadataengine/CMakeLists.txt
+@@ -18,7 +18,7 @@ endif()
+ 
+ # Exiv2 version < 0.28 use auto_ptr instead unique_ptr which is deprecated.
+ 
+-if("${exiv2_VERSION}" VERSION_LESS "0.27.99")
++if("${LibExiv2_VERSION}" VERSION_LESS "0.27.99")
+ 
+     DISABLE_GCC_COMPILER_WARNINGS("5.99.99" "-Wno-deprecated")
+ 
+@@ -112,7 +112,7 @@ include_directories(
+     $<TARGET_PROPERTY:KF5::ConfigCore,INTERFACE_INCLUDE_DIRECTORIES>
+     $<TARGET_PROPERTY:KF5::I18n,INTERFACE_INCLUDE_DIRECTORIES>
+ 
+-    $<TARGET_PROPERTY:exiv2lib,INTERFACE_INCLUDE_DIRECTORIES>
++    $<TARGET_PROPERTY:LibExiv2_INCLUDE_DIRS>
+ )
+ 
+ # Used by digikamcore
+-- 
+2.42.0
+
+
+From ee487a753a652c588b88fa18aeb885105c17368d Mon Sep 17 00:00:00 2001
+From: Maik Qualmann <metzpinguin@gmail.com>
+Date: Thu, 9 Nov 2023 18:49:18 +0100
+Subject: [PATCH 2/5] recognize both Exiv2 CMake variants
+
+---
+ core/CMakeLists.txt                     | 14 ++++++--
+ core/app/DigikamCoreTarget.cmake        | 17 ++++++++-
+ core/cmake/rules/RulesLibExiv2.cmake    | 46 +++++++++++++++++++++----
+ core/libs/metadataengine/CMakeLists.txt | 12 +++++--
+ 4 files changed, 77 insertions(+), 12 deletions(-)
+
+diff --git a/core/CMakeLists.txt b/core/CMakeLists.txt
+index d5dc2f0dd8..855fdcf185 100644
+--- a/core/CMakeLists.txt
++++ b/core/CMakeLists.txt
+@@ -255,7 +255,17 @@ PRINT_COMPONENT_COMPILE_STATUS("Media Player Support"                       ENAB
+ # ==============================================================================
+ 
+ PRINT_LIBRARY_STATUS("libboostgraph" "https://github.com/boostorg/boost"                 "(version >= 1.43.0)"                Boost_FOUND)
+-PRINT_LIBRARY_STATUS("libexiv2"      "https://github.com/Exiv2/exiv2"                    "(version >= ${EXIV2_MIN_VERSION}"   LibExiv2_FOUND)
++
++if(LibExiv2_FOUND)
++
++    PRINT_LIBRARY_STATUS("libexiv2"  "https://github.com/Exiv2/exiv2"                    "(version >= ${EXIV2_MIN_VERSION}"   LibExiv2_FOUND)
++
++else()
++
++    PRINT_LIBRARY_STATUS("libexiv2"  "https://github.com/Exiv2/exiv2"                    "(version >= ${EXIV2_MIN_VERSION}"   exiv2_FOUND)
++
++endif()
++
+ PRINT_LIBRARY_STATUS("libexpat"      "https://libexpat.github.io"                        "(version >= 2.0.0)"                 EXPAT_FOUND)
+ PRINT_LIBRARY_STATUS("libjpeg"       "https://github.com/libjpeg-turbo/libjpeg-turbo"    "(version >= 6b)"                    JPEG_FOUND)
+ PRINT_LIBRARY_STATUS("libkde"        "https://invent.kde.org/frameworks/"                "(version >= ${KF5_MIN_VERSION})"    KF5_FOUND)
+@@ -306,7 +316,7 @@ endif()
+ # ==============================================================================
+ 
+ if(Boost_FOUND                          AND
+-   LibExiv2_FOUND                       AND
++   (LibExiv2_FOUND OR exiv2_FOUND)      AND
+    EXPAT_FOUND                          AND
+    JPEG_FOUND                           AND
+    KF5_FOUND                            AND
+diff --git a/core/app/DigikamCoreTarget.cmake b/core/app/DigikamCoreTarget.cmake
+index 8221a2d632..80bd153caa 100644
+--- a/core/app/DigikamCoreTarget.cmake
++++ b/core/app/DigikamCoreTarget.cmake
+@@ -151,7 +151,6 @@ target_link_libraries(digikamcore
+                       ${TIFF_LIBRARIES}
+                       PNG::PNG
+                       ${JPEG_LIBRARIES}
+-                      ${LibExiv2_LIBRARIES}
+ 
+                       ${OPENMP_LDFLAGS}
+ 
+@@ -164,6 +163,22 @@ target_link_libraries(digikamcore
+                       opencv_flann
+ )
+ 
++if(LibExiv2_FOUND)
++
++    target_link_libraries(digikamcore
++                          PRIVATE
++                          ${LibExiv2_LIBRARIES}
++    )
++
++else()
++
++    target_link_libraries(digikamcore
++                          PRIVATE
++                          exiv2lib
++    )
++
++endif()
++
+ if(Qt6_FOUND)
+     target_link_libraries(digikamcore
+                           PRIVATE
+diff --git a/core/cmake/rules/RulesLibExiv2.cmake b/core/cmake/rules/RulesLibExiv2.cmake
+index a8ca259432..e568644ca4 100644
+--- a/core/cmake/rules/RulesLibExiv2.cmake
++++ b/core/cmake/rules/RulesLibExiv2.cmake
+@@ -4,7 +4,17 @@
+ # SPDX-License-Identifier: BSD-3-Clause
+ #
+ 
+-find_package(LibExiv2 REQUIRED)
++find_package(LibExiv2 OPTIONAL_COMPONENTS)
++
++if(LibExiv2_FOUND)
++
++    find_package(LibExiv2 REQUIRED)
++
++else()
++
++    find_package(exiv2 REQUIRED)
++
++endif()
+ 
+ set_package_properties("exiv2"     PROPERTIES
+                        DESCRIPTION "Required to build digiKam"
+@@ -13,18 +23,40 @@ set_package_properties("exiv2"     PROPERTIES
+                        PURPOSE     "Library to manage image metadata"
+ )
+ 
+-if("${LibExiv2_VERSION}" VERSION_LESS ${EXIV2_MIN_VERSION})
++if(LibExiv2_FOUND)
+ 
+-    message(FATAL_ERROR "Exiv2 version is too old (${LibExiv2_VERSION})! Minimal version required:${EXIV2_MIN_VERSION}.")
++    if("${LibExiv2_VERSION}" VERSION_LESS ${EXIV2_MIN_VERSION})
+ 
+-endif()
++        message(FATAL_ERROR "Exiv2 version is too old (${LibExiv2_VERSION})! Minimal version required:${EXIV2_MIN_VERSION}.")
++
++    endif()
++
++    if("${LibExiv2_VERSION}" VERSION_LESS "0.27.99")
+ 
+-if("${LibExiv2_VERSION}" VERSION_LESS "0.27.99")
++        set(EXIV2_CXX_STANDARD 11)
+ 
+-    set(EXIV2_CXX_STANDARD 11)
++    else()
++
++        set(EXIV2_CXX_STANDARD 17)
++
++    endif()
+ 
+ else()
+ 
+-    set(EXIV2_CXX_STANDARD 17)
++    if("${exiv2_VERSION}" VERSION_LESS ${EXIV2_MIN_VERSION})
++
++        message(FATAL_ERROR "Exiv2 version is too old (${exiv2_VERSION})! Minimal version required:${EXIV2_MIN_VERSION}.")
++
++    endif()
++
++    if("${exiv2_VERSION}" VERSION_LESS "0.27.99")
++
++        set(EXIV2_CXX_STANDARD 11)
++
++    else()
++
++        set(EXIV2_CXX_STANDARD 17)
++
++    endif()
+ 
+ endif()
+diff --git a/core/libs/metadataengine/CMakeLists.txt b/core/libs/metadataengine/CMakeLists.txt
+index bd4dba0bbd..a4124d17e0 100644
+--- a/core/libs/metadataengine/CMakeLists.txt
++++ b/core/libs/metadataengine/CMakeLists.txt
+@@ -111,10 +111,18 @@ include_directories(
+ 
+     $<TARGET_PROPERTY:KF5::ConfigCore,INTERFACE_INCLUDE_DIRECTORIES>
+     $<TARGET_PROPERTY:KF5::I18n,INTERFACE_INCLUDE_DIRECTORIES>
+-
+-    $<TARGET_PROPERTY:LibExiv2_INCLUDE_DIRS>
+ )
+ 
++if(LibExiv2_FOUND)
++
++    include_directories($<TARGET_PROPERTY:LibExiv2_INCLUDE_DIRS>)
++
++else()
++
++    include_directories($<TARGET_PROPERTY:exiv2lib,INTERFACE_INCLUDE_DIRECTORIES>)
++
++endif()
++
+ # Used by digikamcore
+ add_library(core_dmetadata_obj OBJECT ${libdmetadata_SRCS})
+ 
+-- 
+2.42.0
+
+
+From af221dd7700fbf1e6e3b5245184381d2b74ec781 Mon Sep 17 00:00:00 2001
+From: Maik Qualmann <metzpinguin@gmail.com>
+Date: Thu, 9 Nov 2023 19:12:44 +0100
+Subject: [PATCH 3/5] check version und clear LibExiv2_FOUND
+
+---
+ core/cmake/rules/RulesLibExiv2.cmake | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+diff --git a/core/cmake/rules/RulesLibExiv2.cmake b/core/cmake/rules/RulesLibExiv2.cmake
+index e568644ca4..de5ea80ec6 100644
+--- a/core/cmake/rules/RulesLibExiv2.cmake
++++ b/core/cmake/rules/RulesLibExiv2.cmake
+@@ -6,12 +6,13 @@
+ 
+ find_package(LibExiv2 OPTIONAL_COMPONENTS)
+ 
+-if(LibExiv2_FOUND)
++if(LibExiv2_FOUND AND ("${LibExiv2_VERSION}" VERSION_GREATER "0.28.0"))
+ 
+     find_package(LibExiv2 REQUIRED)
+ 
+ else()
+ 
++    set (LibExiv2_FOUND FALSE)
+     find_package(exiv2 REQUIRED)
+ 
+ endif()
+-- 
+2.42.0
+
+
+From fda83a6f7e03e4088f3a5903d036c1425d6303b9 Mon Sep 17 00:00:00 2001
+From: Maik Qualmann <metzpinguin@gmail.com>
+Date: Thu, 9 Nov 2023 19:15:41 +0100
+Subject: [PATCH 4/5] adjust Exiv2 version
+
+---
+ core/cmake/rules/RulesLibExiv2.cmake | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/core/cmake/rules/RulesLibExiv2.cmake b/core/cmake/rules/RulesLibExiv2.cmake
+index de5ea80ec6..3db233cad2 100644
+--- a/core/cmake/rules/RulesLibExiv2.cmake
++++ b/core/cmake/rules/RulesLibExiv2.cmake
+@@ -6,7 +6,7 @@
+ 
+ find_package(LibExiv2 OPTIONAL_COMPONENTS)
+ 
+-if(LibExiv2_FOUND AND ("${LibExiv2_VERSION}" VERSION_GREATER "0.28.0"))
++if(LibExiv2_FOUND AND ("${LibExiv2_VERSION}" VERSION_GREATER "0.27.99"))
+ 
+     find_package(LibExiv2 REQUIRED)
+ 
+-- 
+2.42.0
+
+
+From 921ee9945f8c438f23b83add58d5737b539cd312 Mon Sep 17 00:00:00 2001
+From: Maik Qualmann <metzpinguin@gmail.com>
+Date: Thu, 9 Nov 2023 21:35:09 +0100
+Subject: [PATCH 5/5] set correct exiv2 package name and less duplicate CMake
+ code
+
+---
+ core/cmake/rules/RulesLibExiv2.cmake | 34 +++++++++++-----------------
+ 1 file changed, 13 insertions(+), 21 deletions(-)
+
+diff --git a/core/cmake/rules/RulesLibExiv2.cmake b/core/cmake/rules/RulesLibExiv2.cmake
+index 3db233cad2..e3e667d946 100644
+--- a/core/cmake/rules/RulesLibExiv2.cmake
++++ b/core/cmake/rules/RulesLibExiv2.cmake
+@@ -9,19 +9,21 @@ find_package(LibExiv2 OPTIONAL_COMPONENTS)
+ if(LibExiv2_FOUND AND ("${LibExiv2_VERSION}" VERSION_GREATER "0.27.99"))
+ 
+     find_package(LibExiv2 REQUIRED)
++    set(EXIV2_PACKAGE_NAME "LibExiv2")
+ 
+ else()
+ 
+-    set (LibExiv2_FOUND FALSE)
++    set(LibExiv2_FOUND FALSE)
+     find_package(exiv2 REQUIRED)
++    set(EXIV2_PACKAGE_NAME "exiv2")
+ 
+ endif()
+ 
+-set_package_properties("exiv2"     PROPERTIES
+-                       DESCRIPTION "Required to build digiKam"
+-                       URL         "https://www.exiv2.org"
+-                       TYPE        RECOMMENDED
+-                       PURPOSE     "Library to manage image metadata"
++set_package_properties(${EXIV2_PACKAGE_NAME} PROPERTIES
++                       DESCRIPTION           "Required to build digiKam"
++                       URL                   "https://www.exiv2.org"
++                       TYPE                  RECOMMENDED
++                       PURPOSE               "Library to manage image metadata"
+ )
+ 
+ if(LibExiv2_FOUND)
+@@ -32,16 +34,6 @@ if(LibExiv2_FOUND)
+ 
+     endif()
+ 
+-    if("${LibExiv2_VERSION}" VERSION_LESS "0.27.99")
+-
+-        set(EXIV2_CXX_STANDARD 11)
+-
+-    else()
+-
+-        set(EXIV2_CXX_STANDARD 17)
+-
+-    endif()
+-
+ else()
+ 
+     if("${exiv2_VERSION}" VERSION_LESS ${EXIV2_MIN_VERSION})
+@@ -50,14 +42,14 @@ else()
+ 
+     endif()
+ 
+-    if("${exiv2_VERSION}" VERSION_LESS "0.27.99")
++endif()
+ 
+-        set(EXIV2_CXX_STANDARD 11)
++if(("${exiv2_VERSION}" VERSION_GREATER "0.27.99") OR ("${LibExiv2_VERSION}" VERSION_GREATER "0.27.99"))
+ 
+-    else()
++    set(EXIV2_CXX_STANDARD 17)
+ 
+-        set(EXIV2_CXX_STANDARD 17)
++else()
+ 
+-    endif()
++    set(EXIV2_CXX_STANDARD 11)
+ 
+ endif()
+-- 
+2.42.0
+
diff --git a/srcpkgs/digikam/template b/srcpkgs/digikam/template
index 206185f565488..4784bf7d62a8e 100644
--- a/srcpkgs/digikam/template
+++ b/srcpkgs/digikam/template
@@ -1,7 +1,7 @@
 # Template file for 'digikam'
 pkgname=digikam
 version=8.1.0
-revision=1
+revision=2
 build_style=cmake
 configure_args="-DBUILD_TESTING=OFF"
 hostmakedepends="extra-cmake-modules gettext pkg-config bison flex qt5-qmake

From 095faa13474cbe867a22697fe91247814a044a5c Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 06/23] geeqie: revbump for exiv2-0.28.1.

---
 srcpkgs/geeqie/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/geeqie/template b/srcpkgs/geeqie/template
index b5f958f854c1b..b494bc149e957 100644
--- a/srcpkgs/geeqie/template
+++ b/srcpkgs/geeqie/template
@@ -1,7 +1,7 @@
 # Template file for 'geeqie'
 pkgname=geeqie
 version=2.1
-revision=1
+revision=2
 build_style=meson
 hostmakedepends="pkg-config gettext xxd gdk-pixbuf-devel glib-devel"
 makedepends="gtk+3-devel glib-devel lcms2-devel exiv2-devel libheif-devel

From 34081944cd2ad53e5610ac70065dadb3cdb5b258 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 07/23] gthumb: revbump for exiv2-0.28.1.

---
 srcpkgs/gthumb/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/gthumb/template b/srcpkgs/gthumb/template
index 02d2bc2ed04d6..50c1778f39435 100644
--- a/srcpkgs/gthumb/template
+++ b/srcpkgs/gthumb/template
@@ -1,7 +1,7 @@
 # Template file for 'gthumb'
 pkgname=gthumb
 version=3.12.4
-revision=1
+revision=2
 build_style=meson
 hostmakedepends="gettext pkg-config itstool glib-devel"
 makedepends="webkit2gtk-devel json-glib-devel libsecret-devel librsvg-devel

From 4de05fbd76972c0bd81395bbdd4421752fb9152d Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 08/23] gwenview: revbump for exiv2-0.28.1.

---
 srcpkgs/gwenview/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/gwenview/template b/srcpkgs/gwenview/template
index 1a9978f384084..c6ec9494eb067 100644
--- a/srcpkgs/gwenview/template
+++ b/srcpkgs/gwenview/template
@@ -1,7 +1,7 @@
 # Template file for 'gwenview'
 pkgname=gwenview
 version=23.08.3
-revision=1
+revision=2
 build_style=cmake
 build_helper=qemu
 hostmakedepends="extra-cmake-modules pkg-config qt5-qmake qt5-host-tools

From 029e289883b0f8b2b6ee369a693c526c92811d3c Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 09/23] hugin: revbump for exiv2-0.28.1.

---
 srcpkgs/hugin/patches/exiv2-0.28.patch | 77 ++++++++++++++++++++++++++
 1 file changed, 77 insertions(+)
 create mode 100644 srcpkgs/hugin/patches/exiv2-0.28.patch

diff --git a/srcpkgs/hugin/patches/exiv2-0.28.patch b/srcpkgs/hugin/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..49f0518117020
--- /dev/null
+++ b/srcpkgs/hugin/patches/exiv2-0.28.patch
@@ -0,0 +1,77 @@
+Patch-Source: https://gitlab.archlinux.org/archlinux/packaging/packages/hugin/-/blob/main/exiv2-0.28.patch
+diff -r 79cd11a7a66f src/hugin_base/panodata/Exiv2Helper.cpp
+--- a/src/hugin_base/panodata/Exiv2Helper.cpp	Wed May 24 19:13:20 2023 +0200
++++ b/src/hugin_base/panodata/Exiv2Helper.cpp	Mon Jun 05 00:31:19 2023 +0200
+@@ -40,7 +40,7 @@
+             Exiv2::ExifData::iterator itr = exifData.findKey(Exiv2::ExifKey(keyName));
+             if (itr != exifData.end() && itr->count())
+             {
+-                value = itr->toLong();
++                value = itr->toUint32();
+                 return true;
+             }
+             else
+@@ -165,7 +165,7 @@
+         {
+             if(it!=exifData.end() && it->count())
+             {
+-                return it->toLong();
++                return it->toUint32();
+             }
+             return 0;
+         };
+@@ -600,4 +600,4 @@
+         };
+ 
+     }; //namespace Exiv2Helper
+-}; //namespace HuginBase
+\ No newline at end of file
++}; //namespace HuginBase
+diff -r 79cd11a7a66f src/hugin_base/panodata/SrcPanoImage.cpp
+--- a/src/hugin_base/panodata/SrcPanoImage.cpp	Wed May 24 19:13:20 2023 +0200
++++ b/src/hugin_base/panodata/SrcPanoImage.cpp	Mon Jun 05 00:31:19 2023 +0200
+@@ -384,7 +384,7 @@
+                     pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaImageWidthPixels"));
+                     if (pos != xmpData.end())
+                     {
+-                        croppedWidth = pos->toLong();
++                        croppedWidth = pos->toUint32();
+                     }
+                     else
+                     {
+@@ -394,7 +394,7 @@
+                     pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaImageHeightPixels"));
+                     if (pos != xmpData.end())
+                     {
+-                        croppedHeight = pos->toLong();
++                        croppedHeight = pos->toUint32();
+                     }
+                     else
+                     {
+@@ -408,7 +408,7 @@
+                         double hfov = 0;
+                         if (pos != xmpData.end())
+                         {
+-                            hfov = 360 * croppedWidth / (double)pos->toLong();
++                            hfov = 360 * croppedWidth / (double)pos->toUint32();
+                         }
+                         else
+                         {
+@@ -419,7 +419,7 @@
+                         pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.FullPanoHeightPixels"));
+                         if (pos != xmpData.end())
+                         {
+-                            fullHeight = pos->toLong();
++                            fullHeight = pos->toUint32();
+                         }
+                         else
+                         {
+@@ -430,7 +430,7 @@
+                         pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaTopPixels"));
+                         if (pos != xmpData.end())
+                         {
+-                            cropTop = pos->toLong();
++                            cropTop = pos->toUint32();
+                         }
+                         else
+                         {

From 549045c87199bdeceeb512d3e4f46ee0fba9afbe Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 10/23] kfilemetadata5: revbump for exiv2-0.28.1.

---
 srcpkgs/kfilemetadata5/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/kfilemetadata5/template b/srcpkgs/kfilemetadata5/template
index 00f7a98cf6399..e294ae5af947c 100644
--- a/srcpkgs/kfilemetadata5/template
+++ b/srcpkgs/kfilemetadata5/template
@@ -1,7 +1,7 @@
 # Template file for 'kfilemetadata5'
 pkgname=kfilemetadata5
 version=5.111.0
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="kcoreaddons extra-cmake-modules pkg-config qt5-host-tools qt5-qmake
  gettext kcoreaddons python3"

From d20f231b1b40b34cab9bbf7008610671fcd614ed Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 11/23] krename: revbump for exiv2-0.28.1.

---
 srcpkgs/krename/patches/e7dd767a.patch | 90 ++++++++++++++++++++++++++
 srcpkgs/krename/template               |  2 +-
 2 files changed, 91 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/krename/patches/e7dd767a.patch

diff --git a/srcpkgs/krename/patches/e7dd767a.patch b/srcpkgs/krename/patches/e7dd767a.patch
new file mode 100644
index 0000000000000..a0ef428ce46b1
--- /dev/null
+++ b/srcpkgs/krename/patches/e7dd767a.patch
@@ -0,0 +1,90 @@
+Patch-Source: https://invent.kde.org/utilities/krename/-/commit/e7dd767a
+From e7dd767a9a1068ee1fe1502c4d619b57d3b12add Mon Sep 17 00:00:00 2001
+From: Andreas Sturmlechner <asturm@gentoo.org>
+Date: Fri, 26 May 2023 23:23:10 +0200
+Subject: [PATCH] Fix build with >=exiv2-0.28, raise minimum to 0.27
+
+- enables use of EXIV2_TEST_VERSION macro
+- exiv2 headers cleanup
+
+Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>
+---
+ CMakeLists.txt         |  6 +-----
+ config-krename.h.cmake |  3 ---
+ src/exiv2plugin.cpp    | 17 +++++------------
+ 3 files changed, 6 insertions(+), 20 deletions(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 0bda8ac..72e7297 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -56,13 +56,9 @@ set_package_properties(Taglib PROPERTIES
+     TYPE OPTIONAL)
+ 
+ # Find exiv2
+-find_package(LibExiv2 0.13) # AccessMode was added in 0.13
++find_package(LibExiv2 0.27) # EXIV2_TEST_VERSION was added in 0.27
+ set_package_properties(LibExiv2 PROPERTIES TYPE OPTIONAL)
+ 
+-if (LibExiv2_VERSION VERSION_GREATER_EQUAL "0.27")
+-    set(HAVE_LIBEXIV2_0_27 TRUE)
+-endif()
+-
+ # Find podofo
+ find_package(PoDoFo)
+ set_package_properties(PoDoFo PROPERTIES
+diff --git a/config-krename.h.cmake b/config-krename.h.cmake
+index 76c3d30..862e40b 100644
+--- a/config-krename.h.cmake
++++ b/config-krename.h.cmake
+@@ -6,9 +6,6 @@
+ /* have Exiv2 */
+ #cmakedefine01 HAVE_EXIV2
+ 
+-/* Defined if we have libexiv2 >= 0.27 */
+-#cmakedefine HAVE_LIBEXIV2_0_27
+-
+ /* have PoDoFo */
+ #cmakedefine01 HAVE_PODOFO
+ 
+diff --git a/src/exiv2plugin.cpp b/src/exiv2plugin.cpp
+index 5694d8c..25e8869 100644
+--- a/src/exiv2plugin.cpp
++++ b/src/exiv2plugin.cpp
+@@ -3,20 +3,9 @@
+ 
+ #include "exiv2plugin.h"
+ 
+-#include "../config-krename.h"
+-
+ #include <KLocalizedString>
+ 
+-#include <exiv2/error.hpp>
+-#include <exiv2/exif.hpp>
+-#include <exiv2/image.hpp>
+-#include <exiv2/iptc.hpp>
+-#ifdef HAVE_LIBEXIV2_0_27
+-    #include <exiv2/xmp_exiv2.hpp>
+-#else
+-    #include <exiv2/xmp.hpp>
+-#endif
+-#include <exiv2/tags.hpp>
++#include <exiv2/exiv2.hpp>
+ 
+ #include "batchrenamer.h"
+ #include "tokenhelpdialog.h"
+@@ -381,7 +370,11 @@ QString Exiv2Plugin::processFile(BatchRenamer *b, int index, const QString &file
+     std::string strFilename(asc.constData(), asc.length());
+ 
+     try {
++#if EXIV2_TEST_VERSION(0,28,0)
++        Image::UniquePtr image = Exiv2::ImageFactory::open(strFilename);
++#else
+         Image::AutoPtr image = Exiv2::ImageFactory::open(strFilename);
++#endif
+         if (image.get() != nullptr && image->good()) {
+             image->readMetadata();
+ 
+-- 
+GitLab
+
diff --git a/srcpkgs/krename/template b/srcpkgs/krename/template
index 66023163e3293..df5535007714a 100644
--- a/srcpkgs/krename/template
+++ b/srcpkgs/krename/template
@@ -1,7 +1,7 @@
 # Template file for 'krename'
 pkgname=krename
 version=5.0.2
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="extra-cmake-modules gettext kcoreaddons pkg-config qt5-host-tools qt5-qmake"
 makedepends="exiv2-devel freetype-devel kjs-devel kparts-devel libpodofo-devel

From fabbb1c3a2344c510aefb355fd24ae3b508b38b1 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 12/23] libextractor: revbump for exiv2-0.28.1.

---
 srcpkgs/libextractor/patches/exiv2-0.28.patch | 286 ++++++++++++++++++
 srcpkgs/libextractor/patches/fix-tests.diff   |  24 ++
 2 files changed, 310 insertions(+)
 create mode 100644 srcpkgs/libextractor/patches/exiv2-0.28.patch
 create mode 100644 srcpkgs/libextractor/patches/fix-tests.diff

diff --git a/srcpkgs/libextractor/patches/exiv2-0.28.patch b/srcpkgs/libextractor/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..270a626d8ab06
--- /dev/null
+++ b/srcpkgs/libextractor/patches/exiv2-0.28.patch
@@ -0,0 +1,286 @@
+Patch-Source: https://gitlab.archlinux.org/archlinux/packaging/packages/libextractor/-/blob/main/exiv2-0.28.patch
+diff --git a/src/plugins/exiv2_extractor.cc b/src/plugins/exiv2_extractor.cc
+index 78f9bda..d32ed6a 100644
+--- a/src/plugins/exiv2_extractor.cc
++++ b/src/plugins/exiv2_extractor.cc
+@@ -90,7 +90,11 @@ virtual int close ();
+  * @param rcount number of bytes to read
+  * @return buffer with data read, empty buffer (!) on failure (!)
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++virtual Exiv2::DataBuf read (size_t rcount);
++#else
+ virtual Exiv2::DataBuf read (long rcount);
++#endif
+ 
+ /**
+  * Read up to 'rcount' bytes into 'buf'.
+@@ -99,8 +103,17 @@ virtual Exiv2::DataBuf read (long rcount);
+  * @param rcount size of 'buf'
+  * @return number of bytes read successfully, 0 on failure (!)
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++virtual size_t read (Exiv2::byte *buf,
++                   size_t rcount);
++#else
+ virtual long read (Exiv2::byte *buf,
+                    long rcount);
++#endif
++
++#if EXIV2_TEST_VERSION (0,28,0)
++virtual void populateFakeData();
++#endif
+ 
+ /**
+  * Read a single character.
+@@ -117,8 +130,13 @@ virtual int getb ();
+  * @param wcount how many bytes to write
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual size_t write (const Exiv2::byte *data,
++                    size_t wcount);
++#else
+ virtual long write (const Exiv2::byte *data,
+                     long wcount);
++#endif
+ 
+ /**
+  * Write to stream.
+@@ -126,7 +144,11 @@ virtual long write (const Exiv2::byte *data,
+  * @param src stream to copy
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual size_t write (Exiv2::BasicIo &src);
++#else
+ virtual long write (Exiv2::BasicIo &src);
++#endif
+ 
+ /**
+  * Write a single byte.
+@@ -172,7 +194,11 @@ virtual int munmap ();
+  *
+  * @return -1 on error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual size_t tell (void) const;
++#else
+ virtual long int tell (void) const;
++#endif
+ 
+ /**
+  * Return overall size of the file.
+@@ -213,7 +239,11 @@ virtual bool eof () const;
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual const std::string& path () const noexcept;
++#else
+ virtual std::string path () const;
++#endif
+ 
+ #ifdef EXV_UNICODE_PATH
+ /**
+@@ -230,7 +260,11 @@ virtual std::wstring wpath () const;
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual Exiv2::BasicIo::UniquePtr temporary () const;
++#else
+ virtual Exiv2::BasicIo::AutoPtr temporary () const;
++#endif
+ 
+ };
+ 
+@@ -266,7 +300,11 @@ ExtractorIO::close ()
+  * @return buffer with data read, empty buffer (!) on failure (!)
+  */
+ Exiv2::DataBuf
++#if EXIV2_TEST_VERSION (0,28,0)
++ExtractorIO::read (size_t rcount)
++#else
+ ExtractorIO::read (long rcount)
++#endif
+ {
+   void *data;
+   ssize_t ret;
+@@ -284,9 +322,15 @@ ExtractorIO::read (long rcount)
+  * @param rcount size of 'buf'
+  * @return number of bytes read successfully, 0 on failure (!)
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++size_t
++ExtractorIO::read (Exiv2::byte *buf,
++                   size_t rcount)
++#else
+ long
+ ExtractorIO::read (Exiv2::byte *buf,
+                    long rcount)
++#endif
+ {
+   void *data;
+   ssize_t ret;
+@@ -305,6 +349,12 @@ ExtractorIO::read (Exiv2::byte *buf,
+   return got;
+ }
+ 
++#if EXIV2_TEST_VERSION (0,28,0)
++void ExtractorIO::populateFakeData()
++{
++  return;
++}
++#endif
+ 
+ /**
+  * Read a single character.
+@@ -319,7 +369,9 @@ ExtractorIO::getb ()
+   const unsigned char *r;
+ 
+   if (1 != ec->read (ec->cls, &data, 1))
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION(0,28,0)
++    throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+     throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+     throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -336,9 +388,15 @@ ExtractorIO::getb ()
+  * @param wcount how many bytes to write
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++size_t
++ExtractorIO::write (const Exiv2::byte *data,
++                    size_t wcount)
++#else
+ long
+ ExtractorIO::write (const Exiv2::byte *data,
+                     long wcount)
++#endif
+ {
+   return -1;
+ }
+@@ -350,7 +408,11 @@ ExtractorIO::write (const Exiv2::byte *data,
+  * @param src stream to copy
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++size_t
++#else
+ long
++#endif
+ ExtractorIO::write (Exiv2::BasicIo &src)
+ {
+   return -1;
+@@ -378,7 +440,9 @@ ExtractorIO::putb (Exiv2::byte data)
+ void
+ ExtractorIO::transfer (Exiv2::BasicIo& src)
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION(0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -427,7 +491,9 @@ ExtractorIO::seek (long offset,
+ Exiv2::byte *
+ ExtractorIO::mmap (bool isWritable)
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION (0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -452,7 +518,11 @@ ExtractorIO::munmap ()
+  *
+  * @return -1 on error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++size_t
++#else
+ long int
++#endif
+ ExtractorIO::tell (void) const
+ {
+   return (long) ec->seek (ec->cls, 0, SEEK_CUR);
+@@ -516,10 +586,17 @@ ExtractorIO::eof () const
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++const std::string&
++ExtractorIO::path () const noexcept
++#else
+ std::string
+ ExtractorIO::path () const
++#endif
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION (0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -536,7 +613,9 @@ ExtractorIO::path () const
+ std::wstring
+ ExtractorIO::wpath () const
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION (0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -552,11 +631,17 @@ ExtractorIO::wpath () const
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++Exiv2::BasicIo::UniquePtr
++#else
+ Exiv2::BasicIo::AutoPtr
++#endif
+ ExtractorIO::temporary () const
+ {
+   fprintf (stderr, "throwing temporary error\n");
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION(0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -737,8 +822,13 @@ EXTRACTOR_exiv2_extract_method (struct EXTRACTOR_ExtractContext *ec)
+ #if ! EXIV2_TEST_VERSION (0,24,0)
+     Exiv2::LogMsg::setLevel (Exiv2::LogMsg::mute);
+ #endif
++#if EXIV2_TEST_VERSION(0,28,0)
++    std::unique_ptr<Exiv2::BasicIo> eio (new ExtractorIO (ec));
++    Exiv2::Image::UniquePtr image = Exiv2::ImageFactory::open (std::move(eio));
++#else
+     std::auto_ptr<Exiv2::BasicIo> eio (new ExtractorIO (ec));
+     Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open (eio);
++#endif
+     if (0 == image.get ())
+       return;
+     image->readMetadata ();
+@@ -822,7 +912,11 @@ EXTRACTOR_exiv2_extract_method (struct EXTRACTOR_ExtractContext *ec)
+       ADDXMP ("Xmp.lr.hierarchicalSubject", EXTRACTOR_METATYPE_SUBJECT);
+     }
+   }
++#if EXIV2_TEST_VERSION (0,28,0)
++  catch (const Exiv2::Error& e)
++#else
+   catch (const Exiv2::AnyError& e)
++#endif
+   {
+ #if DEBUG
+     std::cerr << "Caught Exiv2 exception '" << e << "'\n";
diff --git a/srcpkgs/libextractor/patches/fix-tests.diff b/srcpkgs/libextractor/patches/fix-tests.diff
new file mode 100644
index 0000000000000..3b4ee7cbeea33
--- /dev/null
+++ b/srcpkgs/libextractor/patches/fix-tests.diff
@@ -0,0 +1,24 @@
+--- a/src/plugins/test_exiv2.c	2021-01-30 13:20:23.000000000 +0000
++++ b/src/plugins/test_exiv2.c	2023-11-03 19:39:43.115274492 +0000
+@@ -49,8 +49,8 @@
+       EXTRACTOR_METATYPE_GPS_LATITUDE,
+       EXTRACTOR_METAFORMAT_UTF8,
+       "text/plain",
+-      "28deg 8' (18|17.585)\" ?",
+-      strlen ("28deg 8' (18|17.585)\" ?") + 1,
++      "28 deg 8' (18|17.58)\" ?",
++      strlen ("28 deg 8' (18|17.58)\" ?") + 1,
+       0,
+       .regex = 1
+     },
+@@ -66,8 +66,8 @@
+       EXTRACTOR_METATYPE_GPS_LONGITUDE,
+       EXTRACTOR_METAFORMAT_UTF8,
+       "text/plain",
+-      "14deg 14' (22|21.713)\" ?",
+-      strlen ("14deg 14' (22|21.713)\" ?"),
++      "14 deg 14' (22|21.71)\" ?",
++      strlen ("14 deg 14' (22|21.71)\" ?"),
+       0,
+       .regex = 1
+     },

From 055984b429ab1614cc50c86c7bf4b698018fa782 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 13/23] libgexiv2: update to 0.14.2.

---
 srcpkgs/libgexiv2/template | 14 +++++++-------
 1 file changed, 7 insertions(+), 7 deletions(-)

diff --git a/srcpkgs/libgexiv2/template b/srcpkgs/libgexiv2/template
index 23780e5397dc4..91dbcaa9aca52 100644
--- a/srcpkgs/libgexiv2/template
+++ b/srcpkgs/libgexiv2/template
@@ -1,19 +1,19 @@
 # Template file for 'libgexiv2'
 pkgname=libgexiv2
-version=0.14.0
-revision=3
+version=0.14.2
+revision=1
 build_style=meson
 build_helper="gir"
-configure_args="-Dintrospection=$(vopt_if gir true false)
- -Dvapi=$(vopt_if vala true false)"
+configure_args="$(vopt_bool gir introspection) $(vopt_bool vala vapi)"
 hostmakedepends="pkg-config glib-devel $(vopt_if vala 'vala') python3-gobject"
 makedepends="libglib-devel exiv2-devel"
 short_desc="GObject-based wrapper around the Exiv2 library"
 maintainer="Enno Boland <gottox@voidlinux.org>"
 license="GPL-2.0-or-later"
 homepage="https://wiki.gnome.org/Projects/gexiv2"
-distfiles="${GNOME_SITE}/gexiv2/${version%.*}/${pkgname/lib/}-${version}.tar.xz"
-checksum=e58279a6ff20b6f64fa499615da5e9b57cf65ba7850b72fafdf17221a9d6d69e
+changelog="https://gitlab.gnome.org/GNOME/gexiv2/-/raw/master/NEWS"
+distfiles="${GNOME_SITE}/gexiv2/${version%.*}/gexiv2-${version}.tar.xz"
+checksum=2a0c9cf48fbe8b3435008866ffd40b8eddb0667d2212b42396fdf688e93ce0be
 
 build_options="gir vala"
 build_options_default="gir vala"
@@ -23,7 +23,7 @@ libgexiv2-devel_package() {
 	short_desc+=" - development files"
 	pkg_install() {
 		vmove usr/include
-		vmove usr/lib/*.so
+		vmove "usr/lib/*.so"
 		vmove usr/lib/pkgconfig
 		if [ "$build_option_vala" ]; then
 			vmove usr/share/vala

From a0ec0c5401be085a04dcae0a05ae12ccfba99b89 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 14/23] libkexiv25: update to 23.08.3.

---
 srcpkgs/libkexiv25/template | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/srcpkgs/libkexiv25/template b/srcpkgs/libkexiv25/template
index b439a42ef2b97..6d43090f3f8ec 100644
--- a/srcpkgs/libkexiv25/template
+++ b/srcpkgs/libkexiv25/template
@@ -1,6 +1,6 @@
 # Template file for 'libkexiv25'
 pkgname=libkexiv25
-version=23.04.0
+version=23.08.3
 revision=1
 build_style=cmake
 configure_args="-DBUILD_TESTING=OFF"
@@ -11,7 +11,7 @@ maintainer="Orphaned <orphan@voidlinux.org>"
 license="GPL-2.0-or-later"
 homepage="https://invent.kde.org/graphics/libkexiv2"
 distfiles="${KDE_SITE}/release-service/${version}/src/libkexiv2-${version}.tar.xz"
-checksum=18d3eed06df9d1e31d8434ed9887e305aba176d0856e19a8cd3bdb555b80d391
+checksum=07f03d40a89cb5bad2deec80784ea7d4cea702d201f06b97f3888c433df638dd
 
 libkexiv25-devel_package() {
 	short_desc+=" - development files"

From 22d818c7bdfbcf017406ec9d535de8e57519baa9 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 15/23] nomacs: update to 3.17.2287.

---
 srcpkgs/nomacs/template | 17 +++++++++++++----
 1 file changed, 13 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/nomacs/template b/srcpkgs/nomacs/template
index c52cd54e294db..956bd21ebb129 100644
--- a/srcpkgs/nomacs/template
+++ b/srcpkgs/nomacs/template
@@ -1,7 +1,8 @@
 # Template file for 'nomacs'
 pkgname=nomacs
-version=3.16.224
-revision=5
+version=3.17.2287
+revision=1
+_plugins_ver=3.17.2285
 build_wrksrc=ImageLounge
 build_style=cmake
 configure_args="-DCMAKE_BUILD_TYPE=None -DENABLE_TRANSLATIONS=1
@@ -13,5 +14,13 @@ short_desc="Simple yet powerful Qt imageviewer"
 maintainer="Orphaned <orphan@voidlinux.org>"
 license="GPL-3.0-or-later"
 homepage="https://github.com/nomacs/nomacs"
-distfiles="https://github.com/nomacs/nomacs/archive/${version}.tar.gz"
-checksum=bbc7e9048026ef9e0d2b64902c88050f17a679ef3d3c009de2c3b7de5d1d217c
+distfiles="https://github.com/nomacs/nomacs/archive/${version}.tar.gz
+ https://github.com/novomesk/nomacs-plugins/archive/refs/tags/${_plugins_ver}.tar.gz>plugins.tar.gz"
+checksum="6905ea615358f84a0c83d5b1b7077871dea0526ec667500a1951448cb845a92c
+ 946b2d754be9ecca5cb155f7ecc5dcafb164f6c3dcc7bf5c3c0610d3b47774aa"
+skip_extraction="plugins.tar.gz"
+
+post_extract() {
+ cd ${build_wrksrc}
+ vsrcextract -C plugins "plugins.tar.gz"
+}

From 4e941e02320f9e497de65af05cb431336f63c5bb Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 16/23] pdf2djvu: revbump for exiv2-0.28.1.

---
 srcpkgs/pdf2djvu/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/pdf2djvu/template b/srcpkgs/pdf2djvu/template
index ef7433c0c98ae..5a6f3ddf4ed35 100644
--- a/srcpkgs/pdf2djvu/template
+++ b/srcpkgs/pdf2djvu/template
@@ -1,7 +1,7 @@
 # Template file for 'pdf2djvu'
 pkgname=pdf2djvu
 version=0.9.19
-revision=4
+revision=5
 build_style=gnu-configure
 hostmakedepends="pkg-config djvulibre gettext"
 makedepends="djvulibre-devel poppler-devel libgraphicsmagick-devel exiv2-devel libuuid-devel"

From 145949fd8d094717f48673990465e9fb9b010ff9 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 17/23] phototonic: revbump for exiv2-0.28.1.

---
 srcpkgs/phototonic/patches/exiv2-0.28.patch | 135 ++++++++++++++++++++
 srcpkgs/phototonic/template                 |   2 +-
 2 files changed, 136 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/phototonic/patches/exiv2-0.28.patch

diff --git a/srcpkgs/phototonic/patches/exiv2-0.28.patch b/srcpkgs/phototonic/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..1c75b628dab33
--- /dev/null
+++ b/srcpkgs/phototonic/patches/exiv2-0.28.patch
@@ -0,0 +1,135 @@
+From 923a3fc14de0b779a45696c5f0aef34c74d84f13 Mon Sep 17 00:00:00 2001
+From: Andreas Sturmlechner <asturm@gentoo.org>
+Date: Sun, 28 May 2023 18:54:10 +0200
+Subject: [PATCH] Fix build with exiv2-0.28
+
+Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>
+---
+ ImageViewer.cpp   | 9 +++++++++
+ MetadataCache.cpp | 8 ++++++++
+ Phototonic.cpp    | 4 ++++
+ Tags.cpp          | 8 ++++++++
+ ThumbsViewer.cpp  | 4 ++++
+ 5 files changed, 33 insertions(+)
+
+diff --git a/ImageViewer.cpp b/ImageViewer.cpp
+index 357d223..df3ac43 100644
+--- a/ImageViewer.cpp
++++ b/ImageViewer.cpp
+@@ -945,7 +945,11 @@ void ImageViewer::keyMoveEvent(int direction) {
+ }
+ 
+ void ImageViewer::saveImage() {
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr image;
++#else
+     Exiv2::Image::AutoPtr image;
++#endif
+     bool exifError = false;
+ 
+     if (newImage) {
+@@ -985,8 +989,13 @@ void ImageViewer::saveImage() {
+ }
+ 
+ void ImageViewer::saveImageAs() {
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++    Exiv2::Image::UniquePtr newExifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
+     Exiv2::Image::AutoPtr newExifImage;
++#endif
+     bool exifError = false;
+ 
+     setCursorHiding(false);
+diff --git a/MetadataCache.cpp b/MetadataCache.cpp
+index 524ae74..5ddd4c8 100644
+--- a/MetadataCache.cpp
++++ b/MetadataCache.cpp
+@@ -64,7 +64,11 @@ void MetadataCache::clear() {
+ }
+ 
+ bool MetadataCache::loadImageMetadata(const QString &imageFullPath) {
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
++#endif
+     QSet<QString> tags;
+     long orientation = 0;
+ 
+@@ -78,7 +82,11 @@ bool MetadataCache::loadImageMetadata(const QString &imageFullPath) {
+     try {
+         Exiv2::ExifData &exifData = exifImage->exifData();
+         if (!exifData.empty()) {
++#if EXIV2_TEST_VERSION(0,28,0)
++            orientation = exifData["Exif.Image.Orientation"].value().toUint32();
++#else
+             orientation = exifData["Exif.Image.Orientation"].value().toLong();
++#endif
+         }
+     } catch (Exiv2::Error &error) {
+         qWarning() << "Failed to read Exif metadata";
+diff --git a/Phototonic.cpp b/Phototonic.cpp
+index 6cc95b3..bd5497d 100644
+--- a/Phototonic.cpp
++++ b/Phototonic.cpp
+@@ -3151,7 +3151,11 @@ void Phototonic::removeMetadata() {
+ 
+     if (ret == MessageBox::Yes) {
+         for (int file = 0; file < fileList.size(); ++file) {
++#if EXIV2_TEST_VERSION(0,28,0)
++            Exiv2::Image::UniquePtr image;
++#else
+             Exiv2::Image::AutoPtr image;
++#endif
+             try {
+                 image = Exiv2::ImageFactory::open(fileList[file].toStdString());
+                 image->clearMetadata();
+diff --git a/Tags.cpp b/Tags.cpp
+index 84eea16..a62da9d 100644
+--- a/Tags.cpp
++++ b/Tags.cpp
+@@ -136,7 +136,11 @@ void ImageTags::addTag(QString tagName, bool tagChecked) {
+ 
+ bool ImageTags::writeTagsToImage(QString &imageFileName, QSet<QString> &newTags) {
+     QSet<QString> imageTags;
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
++#endif
+ 
+     try {
+         exifImage = Exiv2::ImageFactory::open(imageFileName.toStdString());
+@@ -160,7 +164,11 @@ bool ImageTags::writeTagsToImage(QString &imageFileName, QSet<QString> &newTags)
+         QSetIterator<QString> newTagsIt(newTags);
+         while (newTagsIt.hasNext()) {
+             QString tag = newTagsIt.next();
++#if EXIV2_TEST_VERSION(0,28,0)
++            Exiv2::Value::UniquePtr value = Exiv2::Value::create(Exiv2::string);
++#else
+             Exiv2::Value::AutoPtr value = Exiv2::Value::create(Exiv2::string);
++#endif
+             value->read(tag.toStdString());
+             Exiv2::IptcKey key("Iptc.Application2.Keywords");
+             newIptcData.add(key, value.get());
+diff --git a/ThumbsViewer.cpp b/ThumbsViewer.cpp
+index 77a6189..4a11475 100644
+--- a/ThumbsViewer.cpp
++++ b/ThumbsViewer.cpp
+@@ -210,7 +210,11 @@ void ThumbsViewer::updateImageInfoViewer(QString imageFullPath) {
+         infoView->addEntry(key, val);
+     }
+ 
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
++#endif
+     try {
+         exifImage = Exiv2::ImageFactory::open(imageFullPath.toStdString());
+         exifImage->readMetadata();
+-- 
+2.40.1
+
diff --git a/srcpkgs/phototonic/template b/srcpkgs/phototonic/template
index 77ae8bf6a4406..4af006cb7da41 100644
--- a/srcpkgs/phototonic/template
+++ b/srcpkgs/phototonic/template
@@ -1,7 +1,7 @@
 # Template file for 'phototonic'
 pkgname=phototonic
 version=2.1
-revision=3
+revision=4
 build_style=qmake
 hostmakedepends="pkg-config qt5-qmake qt5-host-tools"
 makedepends="qt5-svg-devel exiv2-devel"

From 7374e851e9dd5587caad1d72b82e410c5b3f24a4 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 18/23] qimgv: revbump for exiv2-0.28.1.

---
 srcpkgs/qimgv/patches/exiv2-0.28.patch | 16 ++++++++++++++++
 srcpkgs/qimgv/template                 |  2 +-
 2 files changed, 17 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/qimgv/patches/exiv2-0.28.patch

diff --git a/srcpkgs/qimgv/patches/exiv2-0.28.patch b/srcpkgs/qimgv/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..11f37b5ae2be3
--- /dev/null
+++ b/srcpkgs/qimgv/patches/exiv2-0.28.patch
@@ -0,0 +1,16 @@
+Patch-Source: https://git.alpinelinux.org/aports/tree/community/qimgv/exiv2-0.28.patch
+diff --git a/qimgv/sourcecontainers/documentinfo.cpp b/qimgv/sourcecontainers/documentinfo.cpp
+index 98a68f7..c062474 100644
+--- a/qimgv/sourcecontainers/documentinfo.cpp
++++ b/qimgv/sourcecontainers/documentinfo.cpp
+@@ -271,10 +271,6 @@ void DocumentInfo::loadExifTags() {
+         //std::cout << "Caught Exiv2 exception '" << e.what() << "'\n";
+         return;
+     }
+-    catch (Exiv2::BasicError<CharType> e) {
+-        //std::cout << "Caught BasicError Exiv2 exception '" << e.what() << "'\n";
+-        return;
+-    }
+ #endif
+ }
+ 
diff --git a/srcpkgs/qimgv/template b/srcpkgs/qimgv/template
index 7eb30db33992c..dd341dfe1bfce 100644
--- a/srcpkgs/qimgv/template
+++ b/srcpkgs/qimgv/template
@@ -1,7 +1,7 @@
 # Template file for 'qimgv'
 pkgname=qimgv
 version=1.0.2
-revision=2
+revision=3
 build_style=cmake
 configure_args="$(vopt_if video -DVIDEO_SUPPORT=ON -DVIDEO_SUPPORT=OFF)
  $(vopt_if scale -DOPENCV_SUPPORT=ON -DOPENCV_SUPPORT=OFF)

From ac25f9423acc41f598c78a6b6ac6a73ab161ad9b Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 19/23] SIR: revbump for exiv2-0.28.1.

---
 srcpkgs/SIR/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/SIR/template b/srcpkgs/SIR/template
index 113077acad354..c6da4c26b6c71 100644
--- a/srcpkgs/SIR/template
+++ b/srcpkgs/SIR/template
@@ -1,7 +1,7 @@
 # Template file for 'SIR'
 pkgname=SIR
 version=3.2.2
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="pkg-config"
 makedepends="exiv2-devel qt5-svg-devel qt5-tools-devel"

From 2c70eaf5f3427b62977eb424e4b8facf07e09091 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 20/23] viewnior: revbump for exiv2-0.28.1.

---
 srcpkgs/viewnior/patches/exiv2-0.28.patch | 147 ++++++++++++++++++++++
 srcpkgs/viewnior/template                 |   2 +-
 2 files changed, 148 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/viewnior/patches/exiv2-0.28.patch

diff --git a/srcpkgs/viewnior/patches/exiv2-0.28.patch b/srcpkgs/viewnior/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..71459dee15768
--- /dev/null
+++ b/srcpkgs/viewnior/patches/exiv2-0.28.patch
@@ -0,0 +1,147 @@
+Patch-Source: https://gitlab.archlinux.org/archlinux/packaging/packages/viewnior/-/blob/f206ce6c22a3ec5f1f9ea1bde4077584f80458dd/exiv2-0.28.patch
+--
+From b6bb81a1b46e911d15bbf9a730972523de177705 Mon Sep 17 00:00:00 2001
+From: tastytea <tastytea@tastytea.de>
+Date: Tue, 16 May 2023 10:54:40 +0200
+Subject: [PATCH 1/2] change exiv2 AutoPtr to unique_ptr
+
+exiv2-0.28.0 removed Exiv2::Image::AutoPtr and added
+Exiv2::Image::UniquePtr instead. since it's a typedef for
+std::unique_ptr<Image>, i'm using that directly instead of adding a
+condition on the exiv2 version.
+---
+ src/uni-exiv2.cpp | 21 +++++++++++----------
+ 1 file changed, 11 insertions(+), 10 deletions(-)
+
+diff --git a/src/uni-exiv2.cpp b/src/uni-exiv2.cpp
+index 0d14b9f..77064c2 100644
+--- a/src/uni-exiv2.cpp
++++ b/src/uni-exiv2.cpp
+@@ -22,12 +22,13 @@
+ 
+ #include <exiv2/exiv2.hpp>
+ #include <iostream>
++#include <memory>
+ 
+ #include "uni-exiv2.hpp"
+ 
+ #define ARRAY_SIZE(array) (sizeof array/sizeof(array[0]))
+ 
+-static Exiv2::Image::AutoPtr cached_image;
++static std::unique_ptr<Exiv2::Image> cached_image;
+ 
+ extern "C"
+ void
+@@ -35,8 +36,8 @@ uni_read_exiv2_map(const char *uri, void (*callback)(const char*, const char*, v
+ {
+     Exiv2::LogMsg::setLevel(Exiv2::LogMsg::mute);
+     try {
+-        Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open(uri);
+-        if ( image.get() == 0 ) {
++        std::unique_ptr<Exiv2::Image> image = Exiv2::ImageFactory::open(uri);
++        if (image == nullptr) {
+             return;
+         }
+ 
+@@ -91,14 +92,14 @@ uni_read_exiv2_to_cache(const char *uri)
+ {
+     Exiv2::LogMsg::setLevel(Exiv2::LogMsg::mute);
+ 
+-    if ( cached_image.get() != NULL ) {
++    if (cached_image != nullptr) {
+         cached_image->clearMetadata();
+-        cached_image.reset(NULL);
++        cached_image.reset(nullptr);
+     }
+ 
+     try {
+         cached_image = Exiv2::ImageFactory::open(uri);
+-        if ( cached_image.get() == 0 ) {
++        if (cached_image == nullptr) {
+             return 1;
+         }
+ 
+@@ -116,13 +117,13 @@ uni_write_exiv2_from_cache(const char *uri)
+ {
+     Exiv2::LogMsg::setLevel(Exiv2::LogMsg::mute);
+ 
+-    if ( cached_image.get() == NULL ) {
++    if (cached_image == nullptr) {
+         return 1;
+     }
+ 
+     try {
+-        Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open(uri);
+-        if ( image.get() == 0 ) {
++        std::unique_ptr<Exiv2::Image> image = Exiv2::ImageFactory::open(uri);
++        if (image == nullptr) {
+             return 2;
+         }
+ 
+@@ -130,7 +131,7 @@ uni_write_exiv2_from_cache(const char *uri)
+         image->writeMetadata();
+ 
+         cached_image->clearMetadata();
+-        cached_image.reset(NULL);
++        cached_image.reset(nullptr);
+ 
+         return 0;
+     } catch (Exiv2::AnyError& e) {
+
+From 47d0b98cb46526aa8aa035bebcabc14a11fa57ee Mon Sep 17 00:00:00 2001
+From: tastytea <tastytea@tastytea.de>
+Date: Tue, 16 May 2023 11:17:00 +0200
+Subject: [PATCH 2/2] add support for exiv-0.28.0 errors
+
+exiv2-0.28.0 changed Exiv2::AnyError to Exiv2::Error.
+---
+ src/uni-exiv2.cpp | 15 ++++++++++++---
+ 1 file changed, 12 insertions(+), 3 deletions(-)
+
+diff --git a/src/uni-exiv2.cpp b/src/uni-exiv2.cpp
+index 77064c2..567a50f 100644
+--- a/src/uni-exiv2.cpp
++++ b/src/uni-exiv2.cpp
+@@ -28,6 +28,15 @@
+ 
+ #define ARRAY_SIZE(array) (sizeof array/sizeof(array[0]))
+ 
++#define EXIV_ERROR Exiv2::AnyError
++#ifdef EXIV2_VERSION
++    #ifdef EXIV2_TEST_VERSION
++        #if EXIV2_TEST_VERSION(0,28,0)
++            #define EXIV_ERROR Exiv2::Error
++        #endif
++    #endif
++#endif
++
+ static std::unique_ptr<Exiv2::Image> cached_image;
+ 
+ extern "C"
+@@ -81,7 +90,7 @@ uni_read_exiv2_map(const char *uri, void (*callback)(const char*, const char*, v
+                 }
+             }
+         }
+-    } catch (Exiv2::AnyError& e) {
++    } catch (EXIV_ERROR& e) {
+         std::cerr << "Exiv2: '" << e << "'\n";
+     }
+ }
+@@ -104,7 +113,7 @@ uni_read_exiv2_to_cache(const char *uri)
+         }
+ 
+         cached_image->readMetadata();
+-    } catch (Exiv2::AnyError& e) {
++    } catch (EXIV_ERROR& e) {
+         std::cerr << "Exiv2: '" << e << "'\n";
+     }
+ 
+@@ -134,7 +143,7 @@ uni_write_exiv2_from_cache(const char *uri)
+         cached_image.reset(nullptr);
+ 
+         return 0;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (EXIV_ERROR& e) {
+         std::cerr << "Exiv2: '" << e << "'\n";
+     }
+ 
diff --git a/srcpkgs/viewnior/template b/srcpkgs/viewnior/template
index ea1e528a8651f..4c73226662ca0 100644
--- a/srcpkgs/viewnior/template
+++ b/srcpkgs/viewnior/template
@@ -1,7 +1,7 @@
 # Template file for 'viewnior'
 pkgname=viewnior
 version=1.8
-revision=1
+revision=2
 build_style=meson
 hostmakedepends="pkg-config intltool glib-devel gettext-devel"
 makedepends="gtk+-devel exiv2-devel"

From 059f74f43f40da1e4da2b77367ed9f989b688690 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Mon, 23 Oct 2023 19:06:34 +0200
Subject: [PATCH 21/23] New package: nufraw-0.43.3

Co-authored-by: triallax <triallax@tutanota.com>
---
 srcpkgs/nufraw-gimp                           |  1 +
 .../patches/0001-nufraw-glib-2.70.patch       | 20 +++++++
 srcpkgs/nufraw/patches/exiv-0.28.x.diff       | 59 +++++++++++++++++++
 srcpkgs/nufraw/template                       | 56 ++++++++++++++++++
 srcpkgs/ufraw                                 |  1 +
 srcpkgs/ufraw-gimp                            |  2 +-
 .../ufraw/patches/001-no-gimp-remote.patch    | 12 ----
 srcpkgs/ufraw/patches/002-fix_abs_int.patch   | 11 ----
 .../ufraw/patches/03_fix-unsigned-char.patch  | 14 -----
 srcpkgs/ufraw/patches/exiv-0.27.patch         | 25 --------
 srcpkgs/ufraw/patches/glib-2.68.patch         | 30 ----------
 srcpkgs/ufraw/patches/iostream.patch          | 13 ----
 srcpkgs/ufraw/template                        | 38 ------------
 13 files changed, 138 insertions(+), 144 deletions(-)
 create mode 120000 srcpkgs/nufraw-gimp
 create mode 100644 srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch
 create mode 100644 srcpkgs/nufraw/patches/exiv-0.28.x.diff
 create mode 100644 srcpkgs/nufraw/template
 create mode 120000 srcpkgs/ufraw
 delete mode 100644 srcpkgs/ufraw/patches/001-no-gimp-remote.patch
 delete mode 100644 srcpkgs/ufraw/patches/002-fix_abs_int.patch
 delete mode 100644 srcpkgs/ufraw/patches/03_fix-unsigned-char.patch
 delete mode 100644 srcpkgs/ufraw/patches/exiv-0.27.patch
 delete mode 100644 srcpkgs/ufraw/patches/glib-2.68.patch
 delete mode 100644 srcpkgs/ufraw/patches/iostream.patch
 delete mode 100644 srcpkgs/ufraw/template

diff --git a/srcpkgs/nufraw-gimp b/srcpkgs/nufraw-gimp
new file mode 120000
index 0000000000000..0bd1459b2a16f
--- /dev/null
+++ b/srcpkgs/nufraw-gimp
@@ -0,0 +1 @@
+nufraw
\ No newline at end of file
diff --git a/srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch b/srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch
new file mode 100644
index 0000000000000..41f10bfbafa1f
--- /dev/null
+++ b/srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch
@@ -0,0 +1,20 @@
+diff -ru nufraw/uf_glib.h nufraw/uf_glib.h
+--- nufraw/uf_glib.h	2022-02-23 09:03:44.700472919 +0100
++++ nufraw/uf_glib.h	2022-02-23 09:04:50.260308805 +0100
+@@ -13,13 +13,13 @@
+ #ifndef _UF_GLIB_H
+ #define _UF_GLIB_H
+ 
++#include <glib.h>
++#include <glib/gstdio.h>
++
+ #ifdef __cplusplus
+ extern "C" {
+ #endif
+ 
+-#include <glib.h>
+-#include <glib/gstdio.h>
+-
+ // g_win32_locale_filename_from_utf8 is needed only on win32
+ #ifdef _WIN32
+ #define uf_win32_locale_filename_from_utf8(__some_string__) \
diff --git a/srcpkgs/nufraw/patches/exiv-0.28.x.diff b/srcpkgs/nufraw/patches/exiv-0.28.x.diff
new file mode 100644
index 0000000000000..6c23359bf706c
--- /dev/null
+++ b/srcpkgs/nufraw/patches/exiv-0.28.x.diff
@@ -0,0 +1,59 @@
+Patch taken from AUR package: https://aur.archlinux.org/cgit/aur.git/tree/exiv2-error.patch?h=nufraw&id=29e467f2c297fcd0f36548642d6d2cab6428d08f
+diff --git a/nufraw_exiv2.cc b/nufraw_exiv2.cc
+index 2de4cc3..45aea87 100644
+--- a/nufraw_exiv2.cc
++++ b/nufraw_exiv2.cc
+@@ -54,7 +54,7 @@ extern "C" int nufraw_exif_read_input(nufraw_data *uf)
+         uf->inputExifBuf = NULL;
+         uf->inputExifBufLen = 0;
+ 
+-        Exiv2::Image::AutoPtr image;
++        Exiv2::Image::UniquePtr image;
+         if (uf->unzippedBuf != NULL) {
+             image = Exiv2::ImageFactory::open(
+                         (const Exiv2::byte*)uf->unzippedBuf, uf->unzippedBufLen);
+@@ -135,7 +135,7 @@ extern "C" int nufraw_exif_read_input(nufraw_data *uf)
+         nufraw_message(NUFRAW_SET_LOG, "%s\n", stderror.str().c_str());
+ 
+         return NUFRAW_SUCCESS;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (Exiv2::Error& e) {
+         std::cerr.rdbuf(savecerr);
+         std::string s(e.what());
+         nufraw_message(NUFRAW_SET_WARNING, "%s\n", s.c_str());
+@@ -156,7 +156,7 @@ static Exiv2::ExifData nufraw_prepare_exifdata(nufraw_data *uf)
+         if ((pos = exifData.findKey(Exiv2::ExifKey("Exif.Image.Orientation")))
+                 != exifData.end()) {
+             nufraw_message(NUFRAW_SET_LOG, "Resetting %s from '%d' to '1'\n",
+-                          pos->key().c_str(), pos->value().toLong());
++                          pos->key().c_str(), pos->value().toInt64());
+             pos->setValue("1"); /* 1 = Normal orientation */
+         }
+     }
+@@ -327,7 +327,7 @@ extern "C" int nufraw_exif_prepare_output(nufraw_data *uf)
+         nufraw_message(NUFRAW_SET_LOG, "%s\n", stderror.str().c_str());
+ 
+         return NUFRAW_SUCCESS;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (Exiv2::Error& e) {
+         std::cerr.rdbuf(savecerr);
+         std::string s(e.what());
+         nufraw_message(NUFRAW_SET_WARNING, "%s\n", s.c_str());
+@@ -347,7 +347,7 @@ extern "C" int nufraw_exif_write(nufraw_data *uf)
+ 
+         char *filename =
+             uf_win32_locale_filename_from_utf8(uf->conf->outputFilename);
+-        Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open(filename);
++        Exiv2::Image::UniquePtr image = Exiv2::ImageFactory::open(filename);
+         uf_win32_locale_filename_free(filename);
+         assert(image.get() != 0);
+ 
+@@ -367,7 +367,7 @@ extern "C" int nufraw_exif_write(nufraw_data *uf)
+         nufraw_message(NUFRAW_SET_LOG, "%s\n", stderror.str().c_str());
+ 
+         return NUFRAW_SUCCESS;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (Exiv2::Error& e) {
+         std::cerr.rdbuf(savecerr);
+         std::string s(e.what());
+         nufraw_message(NUFRAW_SET_WARNING, "%s\n", s.c_str());
diff --git a/srcpkgs/nufraw/template b/srcpkgs/nufraw/template
new file mode 100644
index 0000000000000..7d75a4d372555
--- /dev/null
+++ b/srcpkgs/nufraw/template
@@ -0,0 +1,56 @@
+# Template file for 'nufraw'
+pkgname=nufraw
+version=0.43.3
+revision=1
+_ver="${version%.*}-${version##*.}"
+build_style=gnu-configure
+configure_args="--enable-contrast --enable-mime --enable-openmp --with-gimp
+ --enable-extras"
+hostmakedepends="pkg-config automake libtool glib-devel"
+# libgexiv2-devel is only here to fix build order, remove on next template
+# change
+makedepends="exiv2-devel gimp-devel glib-devel gtkimageview-devel lcms2-devel
+ lensfun-devel jasper-devel libgexiv2-devel"
+depends="desktop-file-utils"
+short_desc="Utility to read and manipulate raw images from digital cameras"
+maintainer="John <me@johnnynator.dev>"
+license="GPL-2.0-or-later"
+homepage="https://sourceforge.net/projects/nufraw/"
+distfiles="${SOURCEFORGE_SITE}/nufraw/nufraw-${_ver}.tar.gz"
+checksum=2c7dcc1590993ec267b3112562b2433010d6f94f6acc6506c76aa29cf8c6c32c
+
+case "$XBPS_TARGET_MACHINE" in
+	armv[67]l* | aarch64*)
+		makedepends+=" libgomp-devel"
+		make_build_args="CXXFLAGS+=-fsigned-char LDFLAGS+=-fopenmp"
+		;;
+esac
+
+pre_configure() {
+	autoreconf -fi
+}
+
+pre_build() {
+	mv nufraw.desktop{.desktop,}
+	chmod +x generate_schemas.sh
+}
+
+nufraw-gimp_package() {
+	depends="${sourcepkg}>=${version}_${revision}"
+	short_desc+=" - gimp plugin"
+	pkg_install() {
+		vmove usr/lib/gimp
+	}
+}
+
+ufraw_package() {
+	depends="${sourcepkg}>=${version}_${revision}"
+	build_style=meta
+	short_desc+=" (transitional dummy package)"
+}
+
+ufraw-gimp_package() {
+	depends="nufraw-gimp>=${version}_${revision}"
+	build_style=meta
+	short_desc+=" - gimp plugin (transitional dummy package)"
+}
diff --git a/srcpkgs/ufraw b/srcpkgs/ufraw
new file mode 120000
index 0000000000000..0bd1459b2a16f
--- /dev/null
+++ b/srcpkgs/ufraw
@@ -0,0 +1 @@
+nufraw
\ No newline at end of file
diff --git a/srcpkgs/ufraw-gimp b/srcpkgs/ufraw-gimp
index 967dc902dd02b..0bd1459b2a16f 120000
--- a/srcpkgs/ufraw-gimp
+++ b/srcpkgs/ufraw-gimp
@@ -1 +1 @@
-ufraw
\ No newline at end of file
+nufraw
\ No newline at end of file
diff --git a/srcpkgs/ufraw/patches/001-no-gimp-remote.patch b/srcpkgs/ufraw/patches/001-no-gimp-remote.patch
deleted file mode 100644
index ca4f4beb6240f..0000000000000
--- a/srcpkgs/ufraw/patches/001-no-gimp-remote.patch
+++ /dev/null
@@ -1,12 +0,0 @@
-Don't use gimp-remote since gimp 2.4 already includes gimp-remote functionality
---- a/ufraw_conf.c
-+++ b/ufraw_conf.c
-@@ -137,7 +137,7 @@
- #elif HAVE_GIMP_2_4
-     "gimp", /* remoteGimpCommand */
- #else
--    "gimp-remote", /* remoteGimpCommand */
-+    "gimp", /* remoteGimpCommand */
- #endif
- 
-     /* EXIF data */
diff --git a/srcpkgs/ufraw/patches/002-fix_abs_int.patch b/srcpkgs/ufraw/patches/002-fix_abs_int.patch
deleted file mode 100644
index 6fc552769c9f8..0000000000000
--- a/srcpkgs/ufraw/patches/002-fix_abs_int.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- a/dcraw.cc	2015-06-16 05:58:38.000000000 +0200
-+++ b/dcraw.cc	2018-02-04 14:46:54.489951076 +0100
-@@ -9242,7 +9242,7 @@
-     if (make[0] == 'O') {
-       i = find_green (12, 32, 1188864, 3576832);
-       c = find_green (12, 32, 2383920, 2387016);
--      if (abs(i) < abs(c)) {
-+      if (abs((int)i) < abs((int)c)) {
- 	SWAP(i,c);
- 	load_flags = 24;
-       }
diff --git a/srcpkgs/ufraw/patches/03_fix-unsigned-char.patch b/srcpkgs/ufraw/patches/03_fix-unsigned-char.patch
deleted file mode 100644
index 8690f87ca7d59..0000000000000
--- a/srcpkgs/ufraw/patches/03_fix-unsigned-char.patch
+++ /dev/null
@@ -1,14 +0,0 @@
-Source: written by John Paul Adrian Glaubitz for Debian
-Upstream: https://sourceforge.net/p/ufraw/bugs/417
-Reason: fixes a compilation failure on arm architectures
---- a/dcraw.cc
-+++ b/dcraw.cc
-@@ -2285,7 +2285,7 @@ void CLASS quicktake_100_load_raw()
- 
- void CLASS kodak_radc_load_raw()
- {
--  static const char src[] = {
-+  static const signed char src[] = {
-     1,1, 2,3, 3,4, 4,2, 5,7, 6,5, 7,6, 7,8,
-     1,0, 2,1, 3,3, 4,4, 5,2, 6,7, 7,6, 8,5, 8,8,
-     2,1, 2,3, 3,0, 3,2, 3,4, 4,6, 5,5, 6,7, 6,8,
diff --git a/srcpkgs/ufraw/patches/exiv-0.27.patch b/srcpkgs/ufraw/patches/exiv-0.27.patch
deleted file mode 100644
index b5b4140fff8ed..0000000000000
--- a/srcpkgs/ufraw/patches/exiv-0.27.patch
+++ /dev/null
@@ -1,25 +0,0 @@
---- a/ufraw_exiv2.cc	2015-06-16 05:58:38.000000000 +0200
-+++ b/ufraw_exiv2.cc	2018-12-29 22:51:23.291894430 +0100
-@@ -15,9 +15,7 @@
- #include "ufraw.h"
- 
- #ifdef HAVE_EXIV2
--#include <exiv2/image.hpp>
--#include <exiv2/easyaccess.hpp>
--#include <exiv2/exif.hpp>
-+#include <exiv2/exiv2.hpp>
- #include <sstream>
- #include <cassert>
- 
-@@ -67,7 +65,11 @@
-         if (exifData.empty()) {
-             std::string error(uf->filename);
-             error += ": No Exif data found in the file";
-+#if EXIV2_TEST_VERSION(0,27,0)
-+            throw Exiv2::Error(Exiv2::kerErrorMessage, error);
-+#else
-             throw Exiv2::Error(1, error);
-+#endif
-         }
- 
-         /* List of tag names taken from exiv2's printSummary() in actions.cpp */
diff --git a/srcpkgs/ufraw/patches/glib-2.68.patch b/srcpkgs/ufraw/patches/glib-2.68.patch
deleted file mode 100644
index 5b61468f118aa..0000000000000
--- a/srcpkgs/ufraw/patches/glib-2.68.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-From c56f8be3caf1cf3d9a5c80597bdbaf1325faacc0 Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?S=C3=A9rgio=20M=2E=20Basto?= <sergio@serjux.com>
-Date: Tue, 13 Apr 2021 23:45:39 +0100
-Subject: [PATCH] Fix build against glib-2.68 fixes #10
-
----
- uf_glib.h | 6 +++---
- 1 file changed, 3 insertions(+), 3 deletions(-)
-
-diff --git a/uf_glib.h b/uf_glib.h
-index 21c10b19..56cd6971 100644
---- a/uf_glib.h
-+++ b/uf_glib.h
-@@ -13,13 +13,13 @@
- #ifndef _UF_GLIB_H
- #define _UF_GLIB_H
- 
-+#include <glib.h>
-+#include <glib/gstdio.h>
-+
- #ifdef __cplusplus
- extern "C" {
- #endif
- 
--#include <glib.h>
--#include <glib/gstdio.h>
--
- // g_win32_locale_filename_from_utf8 is needed only on win32
- #ifdef _WIN32
- #define uf_win32_locale_filename_from_utf8(__some_string__) \
diff --git a/srcpkgs/ufraw/patches/iostream.patch b/srcpkgs/ufraw/patches/iostream.patch
deleted file mode 100644
index 6d15869f63db8..0000000000000
--- a/srcpkgs/ufraw/patches/iostream.patch
+++ /dev/null
@@ -1,13 +0,0 @@
-ufraw_exiv2.cc:343:10: note: 'std::cerr' is defined in header '<iostream>'
-ufraw_exiv2.cc:365:14: error: 'cerr' is not a member of 'std'
-
---- a/ufraw_exiv2.cc
-+++ b/ufraw_exiv2.cc
-@@ -17,6 +17,7 @@
- #ifdef HAVE_EXIV2
- #include <exiv2/exiv2.hpp>
- #include <sstream>
-+#include <iostream>
- #include <cassert>
- 
- /*
diff --git a/srcpkgs/ufraw/template b/srcpkgs/ufraw/template
deleted file mode 100644
index ceddcacacefb2..0000000000000
--- a/srcpkgs/ufraw/template
+++ /dev/null
@@ -1,38 +0,0 @@
-# Template file for 'ufraw'
-pkgname=ufraw
-version=0.22
-revision=5
-build_style=gnu-configure
-configure_args="--enable-contrast --enable-mime --enable-openmp --with-gimp
- $(vopt_enable extras)"
-hostmakedepends="pkg-config dcraw gettext"
-makedepends="exiv2-devel gimp-devel glib-devel gtkimageview-devel lcms2-devel lensfun-devel
- jasper-devel"
-depends="desktop-file-utils"
-short_desc="Utility to read and manipulate raw images from digital cameras"
-maintainer="John <me@johnnynator.dev>"
-license="GPL-2.0-or-later"
-homepage="http://ufraw.sourceforge.net/"
-distfiles="${SOURCEFORGE_SITE}/ufraw/ufraw/ufraw-${version}/ufraw-${version}.tar.gz"
-checksum=f7abd28ce587db2a74b4c54149bd8a2523a7ddc09bedf4f923246ff0ae09a25e
-
-build_options="extras"
-
-post_patch() {
-	vsed -e 's/default(none)//g' \
-		-i dcraw_indi.c \
-		-i dcraw_api.cc \
-		-i ufraw_ufraw.c \
-		-i ufraw_developer.c
-	vsed -i -e '/DATADIRNAME=/s/=.*/=share/' configure
-	vsed -i -e "s,^localedir =.*,localedir = /usr/share/locale," \
-		po/Makefile.in.in
-}
-
-ufraw-gimp_package() {
-	depends="${sourcepkg}>=${version}_${revision}"
-	short_desc+=" - gimp plugin"
-	pkg_install() {
-		vmove usr/lib/gimp
-	}
-}

From 0fae20d6bee56038c4c25d0c3075a19fdb127742 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 8 Nov 2023 12:53:45 +0000
Subject: [PATCH 22/23] krita: revbump for exiv2-0.28.1.

---
 srcpkgs/krita/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/krita/template b/srcpkgs/krita/template
index f4d665daf7c31..d804b581a8689 100644
--- a/srcpkgs/krita/template
+++ b/srcpkgs/krita/template
@@ -1,7 +1,7 @@
 # Template file for 'krita'
 pkgname=krita
 version=5.2.1
-revision=2
+revision=3
 build_style=cmake
 configure_args="-Wno-dev -DBUILD_TESTING=OFF"
 hostmakedepends="extra-cmake-modules gettext pkg-config python3

From fb2d66ec9942e9845f8a53a2887b71a9ac333f31 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 8 Nov 2023 18:25:01 +0000
Subject: [PATCH 23/23] darktable: revbump for exiv2-0.28.1.

---
 srcpkgs/darktable/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/darktable/template b/srcpkgs/darktable/template
index f76936a1692e8..97dfae3471e7c 100644
--- a/srcpkgs/darktable/template
+++ b/srcpkgs/darktable/template
@@ -1,7 +1,7 @@
 # Template file for 'darktable'
 pkgname=darktable
 version=4.4.2
-revision=4
+revision=5
 # upstream only supports these archs:
 archs="x86_64* aarch64* ppc64le*"
 build_style=cmake

^ permalink raw reply	[flat|nested] 27+ messages in thread

* Re: [PR REVIEW] exiv2: update to 0.28.1.
  2023-10-23  0:10 [PR PATCH] exiv2: update to 0.28.0 mhmdanas
                   ` (18 preceding siblings ...)
  2023-11-15 17:57 ` mhmdanas
@ 2023-11-16 15:12 ` sh1r4s3
  2023-11-16 15:56 ` mhmdanas
                   ` (5 subsequent siblings)
  25 siblings, 0 replies; 27+ messages in thread
From: sh1r4s3 @ 2023-11-16 15:12 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 264 bytes --]

New review comment by sh1r4s3 on void-packages repository

https://github.com/void-linux/void-packages/pull/46838#discussion_r1395874417

Comment:
Not sure, but wouldn't we need to bump a revision in the `hugin`'s template so that it will rebuild with this patch?

^ permalink raw reply	[flat|nested] 27+ messages in thread

* Re: [PR REVIEW] exiv2: update to 0.28.1.
  2023-10-23  0:10 [PR PATCH] exiv2: update to 0.28.0 mhmdanas
                   ` (19 preceding siblings ...)
  2023-11-16 15:12 ` [PR REVIEW] " sh1r4s3
@ 2023-11-16 15:56 ` mhmdanas
  2023-11-16 16:43 ` sh1r4s3
                   ` (4 subsequent siblings)
  25 siblings, 0 replies; 27+ messages in thread
From: mhmdanas @ 2023-11-16 15:56 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 244 bytes --]

New review comment by mhmdanas on void-packages repository

https://github.com/void-linux/void-packages/pull/46838#discussion_r1395949704

Comment:
Right, I think I did bump it, but Git has a habit of getting rid of revision bumps sometimes...

^ permalink raw reply	[flat|nested] 27+ messages in thread

* Re: [PR REVIEW] exiv2: update to 0.28.1.
  2023-10-23  0:10 [PR PATCH] exiv2: update to 0.28.0 mhmdanas
                   ` (20 preceding siblings ...)
  2023-11-16 15:56 ` mhmdanas
@ 2023-11-16 16:43 ` sh1r4s3
  2023-11-16 21:50 ` [PR PATCH] [Updated] " mhmdanas
                   ` (3 subsequent siblings)
  25 siblings, 0 replies; 27+ messages in thread
From: sh1r4s3 @ 2023-11-16 16:43 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 210 bytes --]

New review comment by sh1r4s3 on void-packages repository

https://github.com/void-linux/void-packages/pull/46838#discussion_r1396027610

Comment:
and I think `libextractor` should have bumped revision as well

^ permalink raw reply	[flat|nested] 27+ messages in thread

* Re: [PR PATCH] [Updated] exiv2: update to 0.28.1.
  2023-10-23  0:10 [PR PATCH] exiv2: update to 0.28.0 mhmdanas
                   ` (21 preceding siblings ...)
  2023-11-16 16:43 ` sh1r4s3
@ 2023-11-16 21:50 ` mhmdanas
  2023-11-16 21:51 ` [PR REVIEW] " mhmdanas
                   ` (2 subsequent siblings)
  25 siblings, 0 replies; 27+ messages in thread
From: mhmdanas @ 2023-11-16 21:50 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 2086 bytes --]

There is an updated pull request by mhmdanas against master on the void-packages repository

https://github.com/mhmdanas/void-packages exiv2-0.28.0
https://github.com/void-linux/void-packages/pull/46838

exiv2: update to 0.28.1.
<!-- Uncomment relevant sections and delete options which are not applicable -->

#### Testing the changes
- I tested the changes in this PR: **briefly**

TODO:
- [x] Fix `gwenview`'s failed checks (not really fixed but the exact same tests fail on master as well)
- [x] `test_exiv2` fails for `libextractor`
- [x] `kfilemetadata5` tests fail (same tests fail on master)
- [x] Fix `nufraw` cross-build
- [x] `digikam` fails to build

@Johnnynator ufraw has been [unmaintained since December 2016](https://sourceforge.net/p/ufraw/discussion/434060/thread/30b4249b/), and it doesn't build with this PR; here are the options:
- remove the package entirely
- replace it with the newer [nufraw](https://sourceforge.net/projects/nufraw/), which already has [an exiv 0.28.x patch floating around](https://aur.archlinux.org/cgit/aur.git/tree/exiv2-error.patch?h=nufraw)
- patch it to build with this PR

What do you think? (edit: `nufraw` now replaces `ufraw` in this PR)

<!--
#### New package
- This new package conforms to the [package requirements](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTItest_exiv2NG.md#package-requirements): **YES**|**NO**
-->

<!-- Note: If the build is likely to take more than 2 hours, please add ci skip tag as described in
https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration
and test at least one native build and, if supported, at least one cross build.
Ignore this section if this PR is not skipping CI.
-->
<!--
#### Local build testing
- I built this PR locally for my native architecture, (ARCH-LIBC)
- I built this PR locally for these architectures (if supported. mark crossbuilds):
  - aarch64-musl
  - armv7l
  - armv6l-musl
-->


A patch file from https://github.com/void-linux/void-packages/pull/46838.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-exiv2-0.28.0-46838.patch --]
[-- Type: text/x-diff, Size: 76297 bytes --]

From f8a8255cfcb56f80ed2ed375436eeb0e7291219f Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 15 Nov 2023 17:19:46 +0000
Subject: [PATCH 01/23] Revert "xsimd: update to 11.2.0."

This reverts commit de75fb145239a14517310ec0e516491e9e2feae7.

Breaks 32-bit krita build:
https://github.com/void-linux/void-packages/issues/47243
---
 srcpkgs/xsimd/template | 13 ++++++-------
 1 file changed, 6 insertions(+), 7 deletions(-)

diff --git a/srcpkgs/xsimd/template b/srcpkgs/xsimd/template
index ffc806bd7d111..7ab79e3a6de09 100644
--- a/srcpkgs/xsimd/template
+++ b/srcpkgs/xsimd/template
@@ -1,20 +1,19 @@
 # Template file for 'xsimd'
 pkgname=xsimd
-version=11.2.0
-revision=1
+reverts="11.2.0_1"
+version=11.1.0
+revision=2
 build_style=cmake
-checkdepends="doctest-devel"
 short_desc="C++ wrappers for SIMD intrinsics and parallelized, optimized mathematical functions"
 maintainer="John <me@johnnynator.dev>"
 license="BSD-3-Clause"
 homepage="https://github.com/xtensor-stack/xsimd"
 distfiles="https://github.com/xtensor-stack/xsimd/archive/refs/tags/${version}.tar.gz"
-checksum=509bbfe12e78ee1a0e81711019e7c7a372dabcff566dbf15b95cc94339443242
+checksum=aa54dba8daade472656eba0d27154f072fec06ee3831aefcac69a5f6c7dbbae7
 
-if [ "$XBPS_CHECK_PKGS" ]; then
+if [ -z "$CROSS_BUILD" ]; then
 	configure_args="-DBUILD_TESTS=ON"
-else
-	configure_args="-DBUILD_TESTS=OFF"
+	makedepends="doctest-devel"
 fi
 
 post_install() {

From 9bb6ab103c68600a71a1a60061eefff732ec581c Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Mon, 23 Oct 2023 01:20:09 +0100
Subject: [PATCH 02/23] inih: add `libINIReader.so.0` common/shlibs entry.

---
 common/shlibs | 1 +
 1 file changed, 1 insertion(+)

diff --git a/common/shlibs b/common/shlibs
index c4a090b04798f..5f831757c3000 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -3902,6 +3902,7 @@ libnotcurses++.so.3 notcurses-3.0.5_1
 libnotcurses-ffi.so.3 notcurses-3.0.5_1
 libevemu.so.3 evemu-2.7.0_1
 libinih.so.0 inih-52_1
+libINIReader.so.0 inih-57_1
 libpcaudio.so.0 pcaudiolib-1.1_1
 libdcerpc-samr.so.0 samba-4.13.2_1
 libdcerpc-server-core.so.0 samba-4.13.2_1

From 89930b2f9762d3d80d2ea640045156297ee17f6b Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:12 +0100
Subject: [PATCH 03/23] exiv2: update to 0.28.1.

---
 common/shlibs          |  2 +-
 srcpkgs/exiv2/template | 18 +++++++++++-------
 2 files changed, 12 insertions(+), 8 deletions(-)

diff --git a/common/shlibs b/common/shlibs
index 5f831757c3000..e27dcf4cd794c 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -555,7 +555,7 @@ libgimpcolor-2.0.so.0 libgimp-2.10.0_1
 libgimpmodule-2.0.so.0 libgimp-2.10.0_1
 libgmic.so.3 gmic-3.1.6_1
 libcgmic.so.3 gmic-3.1.6_1
-libexiv2.so.27 exiv2-0.27_1
+libexiv2.so.28 exiv2-0.28.1_1
 libKF5Holidays.so.5 kholidays-5.47.0_1
 libPhabricatorHelpers.so.5 purpose-5.48.0_1
 libKF5PurposeWidgets.so.5 purpose-5.48.0_1
diff --git a/srcpkgs/exiv2/template b/srcpkgs/exiv2/template
index 49985fe82cc14..b068757bcf201 100644
--- a/srcpkgs/exiv2/template
+++ b/srcpkgs/exiv2/template
@@ -1,17 +1,17 @@
 # Template file for 'exiv2'
 pkgname=exiv2
-version=0.27.6
+version=0.28.1
 revision=1
 build_style=cmake
 configure_args="-DEXIV2_BUILD_SAMPLES=OFF -DEXIV2_ENABLE_BMFF=ON"
-makedepends="zlib-devel expat-devel"
-checkdepends="gtest-devel"
+makedepends="zlib-devel brotli-devel expat-devel inih-devel"
+checkdepends="gtest-devel python3"
 short_desc="Image metadata manipulation"
 maintainer="Enno Boland <gottox@voidlinux.org>"
 license="GPL-2.0-or-later"
 homepage="https://www.exiv2.org"
-distfiles="https://github.com/Exiv2/exiv2/releases/download/v${version}/exiv2-${version}-Source.tar.gz"
-checksum=4c192483a1125dc59a3d70b30d30d32edace9e14adf52802d2f853abf72db8a6
+distfiles="https://github.com/Exiv2/exiv2/archive/refs/tags/v${version}.tar.gz"
+checksum=3078651f995cb6313b1041f07f4dd1bf0e9e4d394d6e2adc6e92ad0b621291fa
 
 if [ -n "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DEXIV2_BUILD_UNIT_TESTS=ON"
@@ -21,14 +21,18 @@ if [ -n "$XBPS_CCACHE" ]; then
 	configure_args+=" -DBUILD_WITH_CCACHE=ON"
 fi
 
+pre_check() {
+	# https://github.com/Exiv2/exiv2/issues/2762
+	rm -f tests/bugfixes/github/test_issue_2427.py
+}
+
 exiv2-devel_package() {
 	depends="${makedepends} ${sourcepkg}-${version}_${revision}"
 	short_desc+=" - development files"
 	pkg_install() {
 		vmove usr/include
-		vmove usr/lib/cmake
 		vmove usr/lib/pkgconfig
-		vmove "usr/lib/*.a"
+		vmove usr/share/cmake
 		vmove "usr/lib/*.so"
 	}
 }

From 96432ef723021a8709ffd2fee4fe82f82efec1b6 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:37 +0100
Subject: [PATCH 04/23] ART: revbump for exiv2-0.28.1.

---
 srcpkgs/ART/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/ART/template b/srcpkgs/ART/template
index b6c47fc6c4cdf..94c7aa0378061 100644
--- a/srcpkgs/ART/template
+++ b/srcpkgs/ART/template
@@ -1,7 +1,7 @@
 # Template file for 'ART'
 pkgname=ART
 version=1.20.2
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="pkg-config"
 makedepends="fftw-devel gtkmm-devel lensfun-devel

From a873f4af1971fdef28c6ca8a0f05ed239b86a094 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 05/23] digikam: revbump for exiv2-0.28.1.

---
 .../patches/fix-build-with-exiv2-0.28.1.patch | 422 ++++++++++++++++++
 srcpkgs/digikam/template                      |   2 +-
 2 files changed, 423 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/digikam/patches/fix-build-with-exiv2-0.28.1.patch

diff --git a/srcpkgs/digikam/patches/fix-build-with-exiv2-0.28.1.patch b/srcpkgs/digikam/patches/fix-build-with-exiv2-0.28.1.patch
new file mode 100644
index 0000000000000..2a01b4545e76d
--- /dev/null
+++ b/srcpkgs/digikam/patches/fix-build-with-exiv2-0.28.1.patch
@@ -0,0 +1,422 @@
+From a76a561b20e7300510b29edc97afab01e381c0ec Mon Sep 17 00:00:00 2001
+From: Maik Qualmann <metzpinguin@gmail.com>
+Date: Wed, 8 Nov 2023 23:13:26 +0100
+Subject: [PATCH 1/5] fix compile with Exiv2-0.28.1 It should still compile
+ even with smaller Exiv2 versions.
+
+---
+ core/CMakeLists.txt                     | 4 ++--
+ core/app/DigikamCoreTarget.cmake        | 2 +-
+ core/cmake/rules/RulesLibExiv2.cmake    | 8 ++++----
+ core/libs/metadataengine/CMakeLists.txt | 4 ++--
+ 4 files changed, 9 insertions(+), 9 deletions(-)
+
+diff --git a/core/CMakeLists.txt b/core/CMakeLists.txt
+index c694c4b176..d5dc2f0dd8 100644
+--- a/core/CMakeLists.txt
++++ b/core/CMakeLists.txt
+@@ -255,7 +255,7 @@ PRINT_COMPONENT_COMPILE_STATUS("Media Player Support"                       ENAB
+ # ==============================================================================
+ 
+ PRINT_LIBRARY_STATUS("libboostgraph" "https://github.com/boostorg/boost"                 "(version >= 1.43.0)"                Boost_FOUND)
+-PRINT_LIBRARY_STATUS("libexiv2"      "https://github.com/Exiv2/exiv2"                    "(version >= ${EXIV2_MIN_VERSION}"   exiv2_FOUND)
++PRINT_LIBRARY_STATUS("libexiv2"      "https://github.com/Exiv2/exiv2"                    "(version >= ${EXIV2_MIN_VERSION}"   LibExiv2_FOUND)
+ PRINT_LIBRARY_STATUS("libexpat"      "https://libexpat.github.io"                        "(version >= 2.0.0)"                 EXPAT_FOUND)
+ PRINT_LIBRARY_STATUS("libjpeg"       "https://github.com/libjpeg-turbo/libjpeg-turbo"    "(version >= 6b)"                    JPEG_FOUND)
+ PRINT_LIBRARY_STATUS("libkde"        "https://invent.kde.org/frameworks/"                "(version >= ${KF5_MIN_VERSION})"    KF5_FOUND)
+@@ -306,7 +306,7 @@ endif()
+ # ==============================================================================
+ 
+ if(Boost_FOUND                          AND
+-   exiv2_FOUND                          AND
++   LibExiv2_FOUND                       AND
+    EXPAT_FOUND                          AND
+    JPEG_FOUND                           AND
+    KF5_FOUND                            AND
+diff --git a/core/app/DigikamCoreTarget.cmake b/core/app/DigikamCoreTarget.cmake
+index 83fda1b35f..8221a2d632 100644
+--- a/core/app/DigikamCoreTarget.cmake
++++ b/core/app/DigikamCoreTarget.cmake
+@@ -151,7 +151,7 @@ target_link_libraries(digikamcore
+                       ${TIFF_LIBRARIES}
+                       PNG::PNG
+                       ${JPEG_LIBRARIES}
+-                      exiv2lib
++                      ${LibExiv2_LIBRARIES}
+ 
+                       ${OPENMP_LDFLAGS}
+ 
+diff --git a/core/cmake/rules/RulesLibExiv2.cmake b/core/cmake/rules/RulesLibExiv2.cmake
+index c8b37d307c..a8ca259432 100644
+--- a/core/cmake/rules/RulesLibExiv2.cmake
++++ b/core/cmake/rules/RulesLibExiv2.cmake
+@@ -4,7 +4,7 @@
+ # SPDX-License-Identifier: BSD-3-Clause
+ #
+ 
+-find_package(exiv2 REQUIRED)
++find_package(LibExiv2 REQUIRED)
+ 
+ set_package_properties("exiv2"     PROPERTIES
+                        DESCRIPTION "Required to build digiKam"
+@@ -13,13 +13,13 @@ set_package_properties("exiv2"     PROPERTIES
+                        PURPOSE     "Library to manage image metadata"
+ )
+ 
+-if("${exiv2_VERSION}" VERSION_LESS ${EXIV2_MIN_VERSION})
++if("${LibExiv2_VERSION}" VERSION_LESS ${EXIV2_MIN_VERSION})
+ 
+-    message(FATAL_ERROR "Exiv2 version is too old (${exiv2_VERSION})! Minimal version required:${EXIV2_MIN_VERSION}.")
++    message(FATAL_ERROR "Exiv2 version is too old (${LibExiv2_VERSION})! Minimal version required:${EXIV2_MIN_VERSION}.")
+ 
+ endif()
+ 
+-if("${exiv2_VERSION}" VERSION_LESS "0.27.99")
++if("${LibExiv2_VERSION}" VERSION_LESS "0.27.99")
+ 
+     set(EXIV2_CXX_STANDARD 11)
+ 
+diff --git a/core/libs/metadataengine/CMakeLists.txt b/core/libs/metadataengine/CMakeLists.txt
+index 47aa889d5e..bd4dba0bbd 100644
+--- a/core/libs/metadataengine/CMakeLists.txt
++++ b/core/libs/metadataengine/CMakeLists.txt
+@@ -18,7 +18,7 @@ endif()
+ 
+ # Exiv2 version < 0.28 use auto_ptr instead unique_ptr which is deprecated.
+ 
+-if("${exiv2_VERSION}" VERSION_LESS "0.27.99")
++if("${LibExiv2_VERSION}" VERSION_LESS "0.27.99")
+ 
+     DISABLE_GCC_COMPILER_WARNINGS("5.99.99" "-Wno-deprecated")
+ 
+@@ -112,7 +112,7 @@ include_directories(
+     $<TARGET_PROPERTY:KF5::ConfigCore,INTERFACE_INCLUDE_DIRECTORIES>
+     $<TARGET_PROPERTY:KF5::I18n,INTERFACE_INCLUDE_DIRECTORIES>
+ 
+-    $<TARGET_PROPERTY:exiv2lib,INTERFACE_INCLUDE_DIRECTORIES>
++    $<TARGET_PROPERTY:LibExiv2_INCLUDE_DIRS>
+ )
+ 
+ # Used by digikamcore
+-- 
+2.42.0
+
+
+From ee487a753a652c588b88fa18aeb885105c17368d Mon Sep 17 00:00:00 2001
+From: Maik Qualmann <metzpinguin@gmail.com>
+Date: Thu, 9 Nov 2023 18:49:18 +0100
+Subject: [PATCH 2/5] recognize both Exiv2 CMake variants
+
+---
+ core/CMakeLists.txt                     | 14 ++++++--
+ core/app/DigikamCoreTarget.cmake        | 17 ++++++++-
+ core/cmake/rules/RulesLibExiv2.cmake    | 46 +++++++++++++++++++++----
+ core/libs/metadataengine/CMakeLists.txt | 12 +++++--
+ 4 files changed, 77 insertions(+), 12 deletions(-)
+
+diff --git a/core/CMakeLists.txt b/core/CMakeLists.txt
+index d5dc2f0dd8..855fdcf185 100644
+--- a/core/CMakeLists.txt
++++ b/core/CMakeLists.txt
+@@ -255,7 +255,17 @@ PRINT_COMPONENT_COMPILE_STATUS("Media Player Support"                       ENAB
+ # ==============================================================================
+ 
+ PRINT_LIBRARY_STATUS("libboostgraph" "https://github.com/boostorg/boost"                 "(version >= 1.43.0)"                Boost_FOUND)
+-PRINT_LIBRARY_STATUS("libexiv2"      "https://github.com/Exiv2/exiv2"                    "(version >= ${EXIV2_MIN_VERSION}"   LibExiv2_FOUND)
++
++if(LibExiv2_FOUND)
++
++    PRINT_LIBRARY_STATUS("libexiv2"  "https://github.com/Exiv2/exiv2"                    "(version >= ${EXIV2_MIN_VERSION}"   LibExiv2_FOUND)
++
++else()
++
++    PRINT_LIBRARY_STATUS("libexiv2"  "https://github.com/Exiv2/exiv2"                    "(version >= ${EXIV2_MIN_VERSION}"   exiv2_FOUND)
++
++endif()
++
+ PRINT_LIBRARY_STATUS("libexpat"      "https://libexpat.github.io"                        "(version >= 2.0.0)"                 EXPAT_FOUND)
+ PRINT_LIBRARY_STATUS("libjpeg"       "https://github.com/libjpeg-turbo/libjpeg-turbo"    "(version >= 6b)"                    JPEG_FOUND)
+ PRINT_LIBRARY_STATUS("libkde"        "https://invent.kde.org/frameworks/"                "(version >= ${KF5_MIN_VERSION})"    KF5_FOUND)
+@@ -306,7 +316,7 @@ endif()
+ # ==============================================================================
+ 
+ if(Boost_FOUND                          AND
+-   LibExiv2_FOUND                       AND
++   (LibExiv2_FOUND OR exiv2_FOUND)      AND
+    EXPAT_FOUND                          AND
+    JPEG_FOUND                           AND
+    KF5_FOUND                            AND
+diff --git a/core/app/DigikamCoreTarget.cmake b/core/app/DigikamCoreTarget.cmake
+index 8221a2d632..80bd153caa 100644
+--- a/core/app/DigikamCoreTarget.cmake
++++ b/core/app/DigikamCoreTarget.cmake
+@@ -151,7 +151,6 @@ target_link_libraries(digikamcore
+                       ${TIFF_LIBRARIES}
+                       PNG::PNG
+                       ${JPEG_LIBRARIES}
+-                      ${LibExiv2_LIBRARIES}
+ 
+                       ${OPENMP_LDFLAGS}
+ 
+@@ -164,6 +163,22 @@ target_link_libraries(digikamcore
+                       opencv_flann
+ )
+ 
++if(LibExiv2_FOUND)
++
++    target_link_libraries(digikamcore
++                          PRIVATE
++                          ${LibExiv2_LIBRARIES}
++    )
++
++else()
++
++    target_link_libraries(digikamcore
++                          PRIVATE
++                          exiv2lib
++    )
++
++endif()
++
+ if(Qt6_FOUND)
+     target_link_libraries(digikamcore
+                           PRIVATE
+diff --git a/core/cmake/rules/RulesLibExiv2.cmake b/core/cmake/rules/RulesLibExiv2.cmake
+index a8ca259432..e568644ca4 100644
+--- a/core/cmake/rules/RulesLibExiv2.cmake
++++ b/core/cmake/rules/RulesLibExiv2.cmake
+@@ -4,7 +4,17 @@
+ # SPDX-License-Identifier: BSD-3-Clause
+ #
+ 
+-find_package(LibExiv2 REQUIRED)
++find_package(LibExiv2 OPTIONAL_COMPONENTS)
++
++if(LibExiv2_FOUND)
++
++    find_package(LibExiv2 REQUIRED)
++
++else()
++
++    find_package(exiv2 REQUIRED)
++
++endif()
+ 
+ set_package_properties("exiv2"     PROPERTIES
+                        DESCRIPTION "Required to build digiKam"
+@@ -13,18 +23,40 @@ set_package_properties("exiv2"     PROPERTIES
+                        PURPOSE     "Library to manage image metadata"
+ )
+ 
+-if("${LibExiv2_VERSION}" VERSION_LESS ${EXIV2_MIN_VERSION})
++if(LibExiv2_FOUND)
+ 
+-    message(FATAL_ERROR "Exiv2 version is too old (${LibExiv2_VERSION})! Minimal version required:${EXIV2_MIN_VERSION}.")
++    if("${LibExiv2_VERSION}" VERSION_LESS ${EXIV2_MIN_VERSION})
+ 
+-endif()
++        message(FATAL_ERROR "Exiv2 version is too old (${LibExiv2_VERSION})! Minimal version required:${EXIV2_MIN_VERSION}.")
++
++    endif()
++
++    if("${LibExiv2_VERSION}" VERSION_LESS "0.27.99")
+ 
+-if("${LibExiv2_VERSION}" VERSION_LESS "0.27.99")
++        set(EXIV2_CXX_STANDARD 11)
+ 
+-    set(EXIV2_CXX_STANDARD 11)
++    else()
++
++        set(EXIV2_CXX_STANDARD 17)
++
++    endif()
+ 
+ else()
+ 
+-    set(EXIV2_CXX_STANDARD 17)
++    if("${exiv2_VERSION}" VERSION_LESS ${EXIV2_MIN_VERSION})
++
++        message(FATAL_ERROR "Exiv2 version is too old (${exiv2_VERSION})! Minimal version required:${EXIV2_MIN_VERSION}.")
++
++    endif()
++
++    if("${exiv2_VERSION}" VERSION_LESS "0.27.99")
++
++        set(EXIV2_CXX_STANDARD 11)
++
++    else()
++
++        set(EXIV2_CXX_STANDARD 17)
++
++    endif()
+ 
+ endif()
+diff --git a/core/libs/metadataengine/CMakeLists.txt b/core/libs/metadataengine/CMakeLists.txt
+index bd4dba0bbd..a4124d17e0 100644
+--- a/core/libs/metadataengine/CMakeLists.txt
++++ b/core/libs/metadataengine/CMakeLists.txt
+@@ -111,10 +111,18 @@ include_directories(
+ 
+     $<TARGET_PROPERTY:KF5::ConfigCore,INTERFACE_INCLUDE_DIRECTORIES>
+     $<TARGET_PROPERTY:KF5::I18n,INTERFACE_INCLUDE_DIRECTORIES>
+-
+-    $<TARGET_PROPERTY:LibExiv2_INCLUDE_DIRS>
+ )
+ 
++if(LibExiv2_FOUND)
++
++    include_directories($<TARGET_PROPERTY:LibExiv2_INCLUDE_DIRS>)
++
++else()
++
++    include_directories($<TARGET_PROPERTY:exiv2lib,INTERFACE_INCLUDE_DIRECTORIES>)
++
++endif()
++
+ # Used by digikamcore
+ add_library(core_dmetadata_obj OBJECT ${libdmetadata_SRCS})
+ 
+-- 
+2.42.0
+
+
+From af221dd7700fbf1e6e3b5245184381d2b74ec781 Mon Sep 17 00:00:00 2001
+From: Maik Qualmann <metzpinguin@gmail.com>
+Date: Thu, 9 Nov 2023 19:12:44 +0100
+Subject: [PATCH 3/5] check version und clear LibExiv2_FOUND
+
+---
+ core/cmake/rules/RulesLibExiv2.cmake | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+diff --git a/core/cmake/rules/RulesLibExiv2.cmake b/core/cmake/rules/RulesLibExiv2.cmake
+index e568644ca4..de5ea80ec6 100644
+--- a/core/cmake/rules/RulesLibExiv2.cmake
++++ b/core/cmake/rules/RulesLibExiv2.cmake
+@@ -6,12 +6,13 @@
+ 
+ find_package(LibExiv2 OPTIONAL_COMPONENTS)
+ 
+-if(LibExiv2_FOUND)
++if(LibExiv2_FOUND AND ("${LibExiv2_VERSION}" VERSION_GREATER "0.28.0"))
+ 
+     find_package(LibExiv2 REQUIRED)
+ 
+ else()
+ 
++    set (LibExiv2_FOUND FALSE)
+     find_package(exiv2 REQUIRED)
+ 
+ endif()
+-- 
+2.42.0
+
+
+From fda83a6f7e03e4088f3a5903d036c1425d6303b9 Mon Sep 17 00:00:00 2001
+From: Maik Qualmann <metzpinguin@gmail.com>
+Date: Thu, 9 Nov 2023 19:15:41 +0100
+Subject: [PATCH 4/5] adjust Exiv2 version
+
+---
+ core/cmake/rules/RulesLibExiv2.cmake | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/core/cmake/rules/RulesLibExiv2.cmake b/core/cmake/rules/RulesLibExiv2.cmake
+index de5ea80ec6..3db233cad2 100644
+--- a/core/cmake/rules/RulesLibExiv2.cmake
++++ b/core/cmake/rules/RulesLibExiv2.cmake
+@@ -6,7 +6,7 @@
+ 
+ find_package(LibExiv2 OPTIONAL_COMPONENTS)
+ 
+-if(LibExiv2_FOUND AND ("${LibExiv2_VERSION}" VERSION_GREATER "0.28.0"))
++if(LibExiv2_FOUND AND ("${LibExiv2_VERSION}" VERSION_GREATER "0.27.99"))
+ 
+     find_package(LibExiv2 REQUIRED)
+ 
+-- 
+2.42.0
+
+
+From 921ee9945f8c438f23b83add58d5737b539cd312 Mon Sep 17 00:00:00 2001
+From: Maik Qualmann <metzpinguin@gmail.com>
+Date: Thu, 9 Nov 2023 21:35:09 +0100
+Subject: [PATCH 5/5] set correct exiv2 package name and less duplicate CMake
+ code
+
+---
+ core/cmake/rules/RulesLibExiv2.cmake | 34 +++++++++++-----------------
+ 1 file changed, 13 insertions(+), 21 deletions(-)
+
+diff --git a/core/cmake/rules/RulesLibExiv2.cmake b/core/cmake/rules/RulesLibExiv2.cmake
+index 3db233cad2..e3e667d946 100644
+--- a/core/cmake/rules/RulesLibExiv2.cmake
++++ b/core/cmake/rules/RulesLibExiv2.cmake
+@@ -9,19 +9,21 @@ find_package(LibExiv2 OPTIONAL_COMPONENTS)
+ if(LibExiv2_FOUND AND ("${LibExiv2_VERSION}" VERSION_GREATER "0.27.99"))
+ 
+     find_package(LibExiv2 REQUIRED)
++    set(EXIV2_PACKAGE_NAME "LibExiv2")
+ 
+ else()
+ 
+-    set (LibExiv2_FOUND FALSE)
++    set(LibExiv2_FOUND FALSE)
+     find_package(exiv2 REQUIRED)
++    set(EXIV2_PACKAGE_NAME "exiv2")
+ 
+ endif()
+ 
+-set_package_properties("exiv2"     PROPERTIES
+-                       DESCRIPTION "Required to build digiKam"
+-                       URL         "https://www.exiv2.org"
+-                       TYPE        RECOMMENDED
+-                       PURPOSE     "Library to manage image metadata"
++set_package_properties(${EXIV2_PACKAGE_NAME} PROPERTIES
++                       DESCRIPTION           "Required to build digiKam"
++                       URL                   "https://www.exiv2.org"
++                       TYPE                  RECOMMENDED
++                       PURPOSE               "Library to manage image metadata"
+ )
+ 
+ if(LibExiv2_FOUND)
+@@ -32,16 +34,6 @@ if(LibExiv2_FOUND)
+ 
+     endif()
+ 
+-    if("${LibExiv2_VERSION}" VERSION_LESS "0.27.99")
+-
+-        set(EXIV2_CXX_STANDARD 11)
+-
+-    else()
+-
+-        set(EXIV2_CXX_STANDARD 17)
+-
+-    endif()
+-
+ else()
+ 
+     if("${exiv2_VERSION}" VERSION_LESS ${EXIV2_MIN_VERSION})
+@@ -50,14 +42,14 @@ else()
+ 
+     endif()
+ 
+-    if("${exiv2_VERSION}" VERSION_LESS "0.27.99")
++endif()
+ 
+-        set(EXIV2_CXX_STANDARD 11)
++if(("${exiv2_VERSION}" VERSION_GREATER "0.27.99") OR ("${LibExiv2_VERSION}" VERSION_GREATER "0.27.99"))
+ 
+-    else()
++    set(EXIV2_CXX_STANDARD 17)
+ 
+-        set(EXIV2_CXX_STANDARD 17)
++else()
+ 
+-    endif()
++    set(EXIV2_CXX_STANDARD 11)
+ 
+ endif()
+-- 
+2.42.0
+
diff --git a/srcpkgs/digikam/template b/srcpkgs/digikam/template
index 206185f565488..4784bf7d62a8e 100644
--- a/srcpkgs/digikam/template
+++ b/srcpkgs/digikam/template
@@ -1,7 +1,7 @@
 # Template file for 'digikam'
 pkgname=digikam
 version=8.1.0
-revision=1
+revision=2
 build_style=cmake
 configure_args="-DBUILD_TESTING=OFF"
 hostmakedepends="extra-cmake-modules gettext pkg-config bison flex qt5-qmake

From 0a85c48f569a15a56ec9894a25fe84ac684330af Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 06/23] geeqie: revbump for exiv2-0.28.1.

---
 srcpkgs/geeqie/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/geeqie/template b/srcpkgs/geeqie/template
index b5f958f854c1b..b494bc149e957 100644
--- a/srcpkgs/geeqie/template
+++ b/srcpkgs/geeqie/template
@@ -1,7 +1,7 @@
 # Template file for 'geeqie'
 pkgname=geeqie
 version=2.1
-revision=1
+revision=2
 build_style=meson
 hostmakedepends="pkg-config gettext xxd gdk-pixbuf-devel glib-devel"
 makedepends="gtk+3-devel glib-devel lcms2-devel exiv2-devel libheif-devel

From bf7295a537aa3d7e815064278027d90031a789c2 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 07/23] gthumb: revbump for exiv2-0.28.1.

---
 srcpkgs/gthumb/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/gthumb/template b/srcpkgs/gthumb/template
index 02d2bc2ed04d6..50c1778f39435 100644
--- a/srcpkgs/gthumb/template
+++ b/srcpkgs/gthumb/template
@@ -1,7 +1,7 @@
 # Template file for 'gthumb'
 pkgname=gthumb
 version=3.12.4
-revision=1
+revision=2
 build_style=meson
 hostmakedepends="gettext pkg-config itstool glib-devel"
 makedepends="webkit2gtk-devel json-glib-devel libsecret-devel librsvg-devel

From 5fa3a99a342c00a0399b2ad6cde4ca345916f76d Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 08/23] gwenview: revbump for exiv2-0.28.1.

---
 srcpkgs/gwenview/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/gwenview/template b/srcpkgs/gwenview/template
index 1a9978f384084..c6ec9494eb067 100644
--- a/srcpkgs/gwenview/template
+++ b/srcpkgs/gwenview/template
@@ -1,7 +1,7 @@
 # Template file for 'gwenview'
 pkgname=gwenview
 version=23.08.3
-revision=1
+revision=2
 build_style=cmake
 build_helper=qemu
 hostmakedepends="extra-cmake-modules pkg-config qt5-qmake qt5-host-tools

From 8ba7a0925f7d70abe733a29d326d0e9e9439f6c9 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 09/23] hugin: revbump for exiv2-0.28.1.

---
 srcpkgs/hugin/patches/exiv2-0.28.patch | 77 ++++++++++++++++++++++++++
 srcpkgs/hugin/template                 |  2 +-
 2 files changed, 78 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/hugin/patches/exiv2-0.28.patch

diff --git a/srcpkgs/hugin/patches/exiv2-0.28.patch b/srcpkgs/hugin/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..49f0518117020
--- /dev/null
+++ b/srcpkgs/hugin/patches/exiv2-0.28.patch
@@ -0,0 +1,77 @@
+Patch-Source: https://gitlab.archlinux.org/archlinux/packaging/packages/hugin/-/blob/main/exiv2-0.28.patch
+diff -r 79cd11a7a66f src/hugin_base/panodata/Exiv2Helper.cpp
+--- a/src/hugin_base/panodata/Exiv2Helper.cpp	Wed May 24 19:13:20 2023 +0200
++++ b/src/hugin_base/panodata/Exiv2Helper.cpp	Mon Jun 05 00:31:19 2023 +0200
+@@ -40,7 +40,7 @@
+             Exiv2::ExifData::iterator itr = exifData.findKey(Exiv2::ExifKey(keyName));
+             if (itr != exifData.end() && itr->count())
+             {
+-                value = itr->toLong();
++                value = itr->toUint32();
+                 return true;
+             }
+             else
+@@ -165,7 +165,7 @@
+         {
+             if(it!=exifData.end() && it->count())
+             {
+-                return it->toLong();
++                return it->toUint32();
+             }
+             return 0;
+         };
+@@ -600,4 +600,4 @@
+         };
+ 
+     }; //namespace Exiv2Helper
+-}; //namespace HuginBase
+\ No newline at end of file
++}; //namespace HuginBase
+diff -r 79cd11a7a66f src/hugin_base/panodata/SrcPanoImage.cpp
+--- a/src/hugin_base/panodata/SrcPanoImage.cpp	Wed May 24 19:13:20 2023 +0200
++++ b/src/hugin_base/panodata/SrcPanoImage.cpp	Mon Jun 05 00:31:19 2023 +0200
+@@ -384,7 +384,7 @@
+                     pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaImageWidthPixels"));
+                     if (pos != xmpData.end())
+                     {
+-                        croppedWidth = pos->toLong();
++                        croppedWidth = pos->toUint32();
+                     }
+                     else
+                     {
+@@ -394,7 +394,7 @@
+                     pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaImageHeightPixels"));
+                     if (pos != xmpData.end())
+                     {
+-                        croppedHeight = pos->toLong();
++                        croppedHeight = pos->toUint32();
+                     }
+                     else
+                     {
+@@ -408,7 +408,7 @@
+                         double hfov = 0;
+                         if (pos != xmpData.end())
+                         {
+-                            hfov = 360 * croppedWidth / (double)pos->toLong();
++                            hfov = 360 * croppedWidth / (double)pos->toUint32();
+                         }
+                         else
+                         {
+@@ -419,7 +419,7 @@
+                         pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.FullPanoHeightPixels"));
+                         if (pos != xmpData.end())
+                         {
+-                            fullHeight = pos->toLong();
++                            fullHeight = pos->toUint32();
+                         }
+                         else
+                         {
+@@ -430,7 +430,7 @@
+                         pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaTopPixels"));
+                         if (pos != xmpData.end())
+                         {
+-                            cropTop = pos->toLong();
++                            cropTop = pos->toUint32();
+                         }
+                         else
+                         {
diff --git a/srcpkgs/hugin/template b/srcpkgs/hugin/template
index ce71f6e4cbb2d..894876470ebde 100644
--- a/srcpkgs/hugin/template
+++ b/srcpkgs/hugin/template
@@ -1,7 +1,7 @@
 # Template file for 'hugin'
 pkgname=hugin
 version=2022.0.0
-revision=11
+revision=12
 build_style=cmake
 build_helper=cmake-wxWidgets-gtk3
 pycompile_dirs="usr/share/hugin/data/plugins usr/share/hugin/data/plugins-templates"

From 1cca0b57f0204089484b245385a29a701b512691 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 10/23] kfilemetadata5: revbump for exiv2-0.28.1.

---
 srcpkgs/kfilemetadata5/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/kfilemetadata5/template b/srcpkgs/kfilemetadata5/template
index 00f7a98cf6399..e294ae5af947c 100644
--- a/srcpkgs/kfilemetadata5/template
+++ b/srcpkgs/kfilemetadata5/template
@@ -1,7 +1,7 @@
 # Template file for 'kfilemetadata5'
 pkgname=kfilemetadata5
 version=5.111.0
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="kcoreaddons extra-cmake-modules pkg-config qt5-host-tools qt5-qmake
  gettext kcoreaddons python3"

From 5ccbaf86d41b069feb8609dc6616f7fb76dd56c0 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 11/23] krename: revbump for exiv2-0.28.1.

---
 srcpkgs/krename/patches/e7dd767a.patch | 90 ++++++++++++++++++++++++++
 srcpkgs/krename/template               |  2 +-
 2 files changed, 91 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/krename/patches/e7dd767a.patch

diff --git a/srcpkgs/krename/patches/e7dd767a.patch b/srcpkgs/krename/patches/e7dd767a.patch
new file mode 100644
index 0000000000000..a0ef428ce46b1
--- /dev/null
+++ b/srcpkgs/krename/patches/e7dd767a.patch
@@ -0,0 +1,90 @@
+Patch-Source: https://invent.kde.org/utilities/krename/-/commit/e7dd767a
+From e7dd767a9a1068ee1fe1502c4d619b57d3b12add Mon Sep 17 00:00:00 2001
+From: Andreas Sturmlechner <asturm@gentoo.org>
+Date: Fri, 26 May 2023 23:23:10 +0200
+Subject: [PATCH] Fix build with >=exiv2-0.28, raise minimum to 0.27
+
+- enables use of EXIV2_TEST_VERSION macro
+- exiv2 headers cleanup
+
+Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>
+---
+ CMakeLists.txt         |  6 +-----
+ config-krename.h.cmake |  3 ---
+ src/exiv2plugin.cpp    | 17 +++++------------
+ 3 files changed, 6 insertions(+), 20 deletions(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 0bda8ac..72e7297 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -56,13 +56,9 @@ set_package_properties(Taglib PROPERTIES
+     TYPE OPTIONAL)
+ 
+ # Find exiv2
+-find_package(LibExiv2 0.13) # AccessMode was added in 0.13
++find_package(LibExiv2 0.27) # EXIV2_TEST_VERSION was added in 0.27
+ set_package_properties(LibExiv2 PROPERTIES TYPE OPTIONAL)
+ 
+-if (LibExiv2_VERSION VERSION_GREATER_EQUAL "0.27")
+-    set(HAVE_LIBEXIV2_0_27 TRUE)
+-endif()
+-
+ # Find podofo
+ find_package(PoDoFo)
+ set_package_properties(PoDoFo PROPERTIES
+diff --git a/config-krename.h.cmake b/config-krename.h.cmake
+index 76c3d30..862e40b 100644
+--- a/config-krename.h.cmake
++++ b/config-krename.h.cmake
+@@ -6,9 +6,6 @@
+ /* have Exiv2 */
+ #cmakedefine01 HAVE_EXIV2
+ 
+-/* Defined if we have libexiv2 >= 0.27 */
+-#cmakedefine HAVE_LIBEXIV2_0_27
+-
+ /* have PoDoFo */
+ #cmakedefine01 HAVE_PODOFO
+ 
+diff --git a/src/exiv2plugin.cpp b/src/exiv2plugin.cpp
+index 5694d8c..25e8869 100644
+--- a/src/exiv2plugin.cpp
++++ b/src/exiv2plugin.cpp
+@@ -3,20 +3,9 @@
+ 
+ #include "exiv2plugin.h"
+ 
+-#include "../config-krename.h"
+-
+ #include <KLocalizedString>
+ 
+-#include <exiv2/error.hpp>
+-#include <exiv2/exif.hpp>
+-#include <exiv2/image.hpp>
+-#include <exiv2/iptc.hpp>
+-#ifdef HAVE_LIBEXIV2_0_27
+-    #include <exiv2/xmp_exiv2.hpp>
+-#else
+-    #include <exiv2/xmp.hpp>
+-#endif
+-#include <exiv2/tags.hpp>
++#include <exiv2/exiv2.hpp>
+ 
+ #include "batchrenamer.h"
+ #include "tokenhelpdialog.h"
+@@ -381,7 +370,11 @@ QString Exiv2Plugin::processFile(BatchRenamer *b, int index, const QString &file
+     std::string strFilename(asc.constData(), asc.length());
+ 
+     try {
++#if EXIV2_TEST_VERSION(0,28,0)
++        Image::UniquePtr image = Exiv2::ImageFactory::open(strFilename);
++#else
+         Image::AutoPtr image = Exiv2::ImageFactory::open(strFilename);
++#endif
+         if (image.get() != nullptr && image->good()) {
+             image->readMetadata();
+ 
+-- 
+GitLab
+
diff --git a/srcpkgs/krename/template b/srcpkgs/krename/template
index 66023163e3293..df5535007714a 100644
--- a/srcpkgs/krename/template
+++ b/srcpkgs/krename/template
@@ -1,7 +1,7 @@
 # Template file for 'krename'
 pkgname=krename
 version=5.0.2
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="extra-cmake-modules gettext kcoreaddons pkg-config qt5-host-tools qt5-qmake"
 makedepends="exiv2-devel freetype-devel kjs-devel kparts-devel libpodofo-devel

From f79a85d03e65cce015fa1f1da09e4619019fcbbd Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 12/23] libextractor: revbump for exiv2-0.28.1.

---
 srcpkgs/libextractor/patches/exiv2-0.28.patch | 286 ++++++++++++++++++
 srcpkgs/libextractor/patches/fix-tests.diff   |  24 ++
 srcpkgs/libextractor/template                 |   2 +-
 3 files changed, 311 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/libextractor/patches/exiv2-0.28.patch
 create mode 100644 srcpkgs/libextractor/patches/fix-tests.diff

diff --git a/srcpkgs/libextractor/patches/exiv2-0.28.patch b/srcpkgs/libextractor/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..270a626d8ab06
--- /dev/null
+++ b/srcpkgs/libextractor/patches/exiv2-0.28.patch
@@ -0,0 +1,286 @@
+Patch-Source: https://gitlab.archlinux.org/archlinux/packaging/packages/libextractor/-/blob/main/exiv2-0.28.patch
+diff --git a/src/plugins/exiv2_extractor.cc b/src/plugins/exiv2_extractor.cc
+index 78f9bda..d32ed6a 100644
+--- a/src/plugins/exiv2_extractor.cc
++++ b/src/plugins/exiv2_extractor.cc
+@@ -90,7 +90,11 @@ virtual int close ();
+  * @param rcount number of bytes to read
+  * @return buffer with data read, empty buffer (!) on failure (!)
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++virtual Exiv2::DataBuf read (size_t rcount);
++#else
+ virtual Exiv2::DataBuf read (long rcount);
++#endif
+ 
+ /**
+  * Read up to 'rcount' bytes into 'buf'.
+@@ -99,8 +103,17 @@ virtual Exiv2::DataBuf read (long rcount);
+  * @param rcount size of 'buf'
+  * @return number of bytes read successfully, 0 on failure (!)
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++virtual size_t read (Exiv2::byte *buf,
++                   size_t rcount);
++#else
+ virtual long read (Exiv2::byte *buf,
+                    long rcount);
++#endif
++
++#if EXIV2_TEST_VERSION (0,28,0)
++virtual void populateFakeData();
++#endif
+ 
+ /**
+  * Read a single character.
+@@ -117,8 +130,13 @@ virtual int getb ();
+  * @param wcount how many bytes to write
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual size_t write (const Exiv2::byte *data,
++                    size_t wcount);
++#else
+ virtual long write (const Exiv2::byte *data,
+                     long wcount);
++#endif
+ 
+ /**
+  * Write to stream.
+@@ -126,7 +144,11 @@ virtual long write (const Exiv2::byte *data,
+  * @param src stream to copy
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual size_t write (Exiv2::BasicIo &src);
++#else
+ virtual long write (Exiv2::BasicIo &src);
++#endif
+ 
+ /**
+  * Write a single byte.
+@@ -172,7 +194,11 @@ virtual int munmap ();
+  *
+  * @return -1 on error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual size_t tell (void) const;
++#else
+ virtual long int tell (void) const;
++#endif
+ 
+ /**
+  * Return overall size of the file.
+@@ -213,7 +239,11 @@ virtual bool eof () const;
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual const std::string& path () const noexcept;
++#else
+ virtual std::string path () const;
++#endif
+ 
+ #ifdef EXV_UNICODE_PATH
+ /**
+@@ -230,7 +260,11 @@ virtual std::wstring wpath () const;
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual Exiv2::BasicIo::UniquePtr temporary () const;
++#else
+ virtual Exiv2::BasicIo::AutoPtr temporary () const;
++#endif
+ 
+ };
+ 
+@@ -266,7 +300,11 @@ ExtractorIO::close ()
+  * @return buffer with data read, empty buffer (!) on failure (!)
+  */
+ Exiv2::DataBuf
++#if EXIV2_TEST_VERSION (0,28,0)
++ExtractorIO::read (size_t rcount)
++#else
+ ExtractorIO::read (long rcount)
++#endif
+ {
+   void *data;
+   ssize_t ret;
+@@ -284,9 +322,15 @@ ExtractorIO::read (long rcount)
+  * @param rcount size of 'buf'
+  * @return number of bytes read successfully, 0 on failure (!)
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++size_t
++ExtractorIO::read (Exiv2::byte *buf,
++                   size_t rcount)
++#else
+ long
+ ExtractorIO::read (Exiv2::byte *buf,
+                    long rcount)
++#endif
+ {
+   void *data;
+   ssize_t ret;
+@@ -305,6 +349,12 @@ ExtractorIO::read (Exiv2::byte *buf,
+   return got;
+ }
+ 
++#if EXIV2_TEST_VERSION (0,28,0)
++void ExtractorIO::populateFakeData()
++{
++  return;
++}
++#endif
+ 
+ /**
+  * Read a single character.
+@@ -319,7 +369,9 @@ ExtractorIO::getb ()
+   const unsigned char *r;
+ 
+   if (1 != ec->read (ec->cls, &data, 1))
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION(0,28,0)
++    throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+     throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+     throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -336,9 +388,15 @@ ExtractorIO::getb ()
+  * @param wcount how many bytes to write
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++size_t
++ExtractorIO::write (const Exiv2::byte *data,
++                    size_t wcount)
++#else
+ long
+ ExtractorIO::write (const Exiv2::byte *data,
+                     long wcount)
++#endif
+ {
+   return -1;
+ }
+@@ -350,7 +408,11 @@ ExtractorIO::write (const Exiv2::byte *data,
+  * @param src stream to copy
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++size_t
++#else
+ long
++#endif
+ ExtractorIO::write (Exiv2::BasicIo &src)
+ {
+   return -1;
+@@ -378,7 +440,9 @@ ExtractorIO::putb (Exiv2::byte data)
+ void
+ ExtractorIO::transfer (Exiv2::BasicIo& src)
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION(0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -427,7 +491,9 @@ ExtractorIO::seek (long offset,
+ Exiv2::byte *
+ ExtractorIO::mmap (bool isWritable)
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION (0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -452,7 +518,11 @@ ExtractorIO::munmap ()
+  *
+  * @return -1 on error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++size_t
++#else
+ long int
++#endif
+ ExtractorIO::tell (void) const
+ {
+   return (long) ec->seek (ec->cls, 0, SEEK_CUR);
+@@ -516,10 +586,17 @@ ExtractorIO::eof () const
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++const std::string&
++ExtractorIO::path () const noexcept
++#else
+ std::string
+ ExtractorIO::path () const
++#endif
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION (0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -536,7 +613,9 @@ ExtractorIO::path () const
+ std::wstring
+ ExtractorIO::wpath () const
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION (0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -552,11 +631,17 @@ ExtractorIO::wpath () const
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++Exiv2::BasicIo::UniquePtr
++#else
+ Exiv2::BasicIo::AutoPtr
++#endif
+ ExtractorIO::temporary () const
+ {
+   fprintf (stderr, "throwing temporary error\n");
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION(0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -737,8 +822,13 @@ EXTRACTOR_exiv2_extract_method (struct EXTRACTOR_ExtractContext *ec)
+ #if ! EXIV2_TEST_VERSION (0,24,0)
+     Exiv2::LogMsg::setLevel (Exiv2::LogMsg::mute);
+ #endif
++#if EXIV2_TEST_VERSION(0,28,0)
++    std::unique_ptr<Exiv2::BasicIo> eio (new ExtractorIO (ec));
++    Exiv2::Image::UniquePtr image = Exiv2::ImageFactory::open (std::move(eio));
++#else
+     std::auto_ptr<Exiv2::BasicIo> eio (new ExtractorIO (ec));
+     Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open (eio);
++#endif
+     if (0 == image.get ())
+       return;
+     image->readMetadata ();
+@@ -822,7 +912,11 @@ EXTRACTOR_exiv2_extract_method (struct EXTRACTOR_ExtractContext *ec)
+       ADDXMP ("Xmp.lr.hierarchicalSubject", EXTRACTOR_METATYPE_SUBJECT);
+     }
+   }
++#if EXIV2_TEST_VERSION (0,28,0)
++  catch (const Exiv2::Error& e)
++#else
+   catch (const Exiv2::AnyError& e)
++#endif
+   {
+ #if DEBUG
+     std::cerr << "Caught Exiv2 exception '" << e << "'\n";
diff --git a/srcpkgs/libextractor/patches/fix-tests.diff b/srcpkgs/libextractor/patches/fix-tests.diff
new file mode 100644
index 0000000000000..3b4ee7cbeea33
--- /dev/null
+++ b/srcpkgs/libextractor/patches/fix-tests.diff
@@ -0,0 +1,24 @@
+--- a/src/plugins/test_exiv2.c	2021-01-30 13:20:23.000000000 +0000
++++ b/src/plugins/test_exiv2.c	2023-11-03 19:39:43.115274492 +0000
+@@ -49,8 +49,8 @@
+       EXTRACTOR_METATYPE_GPS_LATITUDE,
+       EXTRACTOR_METAFORMAT_UTF8,
+       "text/plain",
+-      "28deg 8' (18|17.585)\" ?",
+-      strlen ("28deg 8' (18|17.585)\" ?") + 1,
++      "28 deg 8' (18|17.58)\" ?",
++      strlen ("28 deg 8' (18|17.58)\" ?") + 1,
+       0,
+       .regex = 1
+     },
+@@ -66,8 +66,8 @@
+       EXTRACTOR_METATYPE_GPS_LONGITUDE,
+       EXTRACTOR_METAFORMAT_UTF8,
+       "text/plain",
+-      "14deg 14' (22|21.713)\" ?",
+-      strlen ("14deg 14' (22|21.713)\" ?"),
++      "14 deg 14' (22|21.71)\" ?",
++      strlen ("14 deg 14' (22|21.71)\" ?"),
+       0,
+       .regex = 1
+     },
diff --git a/srcpkgs/libextractor/template b/srcpkgs/libextractor/template
index bfcea979a308c..044c663a3a0b9 100644
--- a/srcpkgs/libextractor/template
+++ b/srcpkgs/libextractor/template
@@ -1,7 +1,7 @@
 # Template file for 'libextractor'
 pkgname=libextractor
 version=1.11
-revision=3
+revision=4
 build_style=gnu-configure
 configure_args="--disable-static"
 hostmakedepends="pkg-config"

From 58aea11e674c128d2b2e2608159217aa8b6d8c63 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 13/23] libgexiv2: update to 0.14.2.

---
 srcpkgs/libgexiv2/template | 14 +++++++-------
 1 file changed, 7 insertions(+), 7 deletions(-)

diff --git a/srcpkgs/libgexiv2/template b/srcpkgs/libgexiv2/template
index 23780e5397dc4..91dbcaa9aca52 100644
--- a/srcpkgs/libgexiv2/template
+++ b/srcpkgs/libgexiv2/template
@@ -1,19 +1,19 @@
 # Template file for 'libgexiv2'
 pkgname=libgexiv2
-version=0.14.0
-revision=3
+version=0.14.2
+revision=1
 build_style=meson
 build_helper="gir"
-configure_args="-Dintrospection=$(vopt_if gir true false)
- -Dvapi=$(vopt_if vala true false)"
+configure_args="$(vopt_bool gir introspection) $(vopt_bool vala vapi)"
 hostmakedepends="pkg-config glib-devel $(vopt_if vala 'vala') python3-gobject"
 makedepends="libglib-devel exiv2-devel"
 short_desc="GObject-based wrapper around the Exiv2 library"
 maintainer="Enno Boland <gottox@voidlinux.org>"
 license="GPL-2.0-or-later"
 homepage="https://wiki.gnome.org/Projects/gexiv2"
-distfiles="${GNOME_SITE}/gexiv2/${version%.*}/${pkgname/lib/}-${version}.tar.xz"
-checksum=e58279a6ff20b6f64fa499615da5e9b57cf65ba7850b72fafdf17221a9d6d69e
+changelog="https://gitlab.gnome.org/GNOME/gexiv2/-/raw/master/NEWS"
+distfiles="${GNOME_SITE}/gexiv2/${version%.*}/gexiv2-${version}.tar.xz"
+checksum=2a0c9cf48fbe8b3435008866ffd40b8eddb0667d2212b42396fdf688e93ce0be
 
 build_options="gir vala"
 build_options_default="gir vala"
@@ -23,7 +23,7 @@ libgexiv2-devel_package() {
 	short_desc+=" - development files"
 	pkg_install() {
 		vmove usr/include
-		vmove usr/lib/*.so
+		vmove "usr/lib/*.so"
 		vmove usr/lib/pkgconfig
 		if [ "$build_option_vala" ]; then
 			vmove usr/share/vala

From c180423a18b1d99f81d6270399906a02d9f31314 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 14/23] libkexiv25: update to 23.08.3.

---
 srcpkgs/libkexiv25/template | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/srcpkgs/libkexiv25/template b/srcpkgs/libkexiv25/template
index b439a42ef2b97..6d43090f3f8ec 100644
--- a/srcpkgs/libkexiv25/template
+++ b/srcpkgs/libkexiv25/template
@@ -1,6 +1,6 @@
 # Template file for 'libkexiv25'
 pkgname=libkexiv25
-version=23.04.0
+version=23.08.3
 revision=1
 build_style=cmake
 configure_args="-DBUILD_TESTING=OFF"
@@ -11,7 +11,7 @@ maintainer="Orphaned <orphan@voidlinux.org>"
 license="GPL-2.0-or-later"
 homepage="https://invent.kde.org/graphics/libkexiv2"
 distfiles="${KDE_SITE}/release-service/${version}/src/libkexiv2-${version}.tar.xz"
-checksum=18d3eed06df9d1e31d8434ed9887e305aba176d0856e19a8cd3bdb555b80d391
+checksum=07f03d40a89cb5bad2deec80784ea7d4cea702d201f06b97f3888c433df638dd
 
 libkexiv25-devel_package() {
 	short_desc+=" - development files"

From f286a2b73cd8a9a60448db5e6ab1d89fcd54b23e Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 15/23] nomacs: update to 3.17.2287.

---
 srcpkgs/nomacs/template | 17 +++++++++++++----
 1 file changed, 13 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/nomacs/template b/srcpkgs/nomacs/template
index c52cd54e294db..956bd21ebb129 100644
--- a/srcpkgs/nomacs/template
+++ b/srcpkgs/nomacs/template
@@ -1,7 +1,8 @@
 # Template file for 'nomacs'
 pkgname=nomacs
-version=3.16.224
-revision=5
+version=3.17.2287
+revision=1
+_plugins_ver=3.17.2285
 build_wrksrc=ImageLounge
 build_style=cmake
 configure_args="-DCMAKE_BUILD_TYPE=None -DENABLE_TRANSLATIONS=1
@@ -13,5 +14,13 @@ short_desc="Simple yet powerful Qt imageviewer"
 maintainer="Orphaned <orphan@voidlinux.org>"
 license="GPL-3.0-or-later"
 homepage="https://github.com/nomacs/nomacs"
-distfiles="https://github.com/nomacs/nomacs/archive/${version}.tar.gz"
-checksum=bbc7e9048026ef9e0d2b64902c88050f17a679ef3d3c009de2c3b7de5d1d217c
+distfiles="https://github.com/nomacs/nomacs/archive/${version}.tar.gz
+ https://github.com/novomesk/nomacs-plugins/archive/refs/tags/${_plugins_ver}.tar.gz>plugins.tar.gz"
+checksum="6905ea615358f84a0c83d5b1b7077871dea0526ec667500a1951448cb845a92c
+ 946b2d754be9ecca5cb155f7ecc5dcafb164f6c3dcc7bf5c3c0610d3b47774aa"
+skip_extraction="plugins.tar.gz"
+
+post_extract() {
+ cd ${build_wrksrc}
+ vsrcextract -C plugins "plugins.tar.gz"
+}

From 4a54065876d0394ebe1ae3dc1b2e20e41bb73b24 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 16/23] pdf2djvu: revbump for exiv2-0.28.1.

---
 srcpkgs/pdf2djvu/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/pdf2djvu/template b/srcpkgs/pdf2djvu/template
index ef7433c0c98ae..5a6f3ddf4ed35 100644
--- a/srcpkgs/pdf2djvu/template
+++ b/srcpkgs/pdf2djvu/template
@@ -1,7 +1,7 @@
 # Template file for 'pdf2djvu'
 pkgname=pdf2djvu
 version=0.9.19
-revision=4
+revision=5
 build_style=gnu-configure
 hostmakedepends="pkg-config djvulibre gettext"
 makedepends="djvulibre-devel poppler-devel libgraphicsmagick-devel exiv2-devel libuuid-devel"

From 8be85e809fe168442cadee2dbe56235d79d25ae9 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 17/23] phototonic: revbump for exiv2-0.28.1.

---
 srcpkgs/phototonic/patches/exiv2-0.28.patch | 135 ++++++++++++++++++++
 srcpkgs/phototonic/template                 |   2 +-
 2 files changed, 136 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/phototonic/patches/exiv2-0.28.patch

diff --git a/srcpkgs/phototonic/patches/exiv2-0.28.patch b/srcpkgs/phototonic/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..1c75b628dab33
--- /dev/null
+++ b/srcpkgs/phototonic/patches/exiv2-0.28.patch
@@ -0,0 +1,135 @@
+From 923a3fc14de0b779a45696c5f0aef34c74d84f13 Mon Sep 17 00:00:00 2001
+From: Andreas Sturmlechner <asturm@gentoo.org>
+Date: Sun, 28 May 2023 18:54:10 +0200
+Subject: [PATCH] Fix build with exiv2-0.28
+
+Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>
+---
+ ImageViewer.cpp   | 9 +++++++++
+ MetadataCache.cpp | 8 ++++++++
+ Phototonic.cpp    | 4 ++++
+ Tags.cpp          | 8 ++++++++
+ ThumbsViewer.cpp  | 4 ++++
+ 5 files changed, 33 insertions(+)
+
+diff --git a/ImageViewer.cpp b/ImageViewer.cpp
+index 357d223..df3ac43 100644
+--- a/ImageViewer.cpp
++++ b/ImageViewer.cpp
+@@ -945,7 +945,11 @@ void ImageViewer::keyMoveEvent(int direction) {
+ }
+ 
+ void ImageViewer::saveImage() {
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr image;
++#else
+     Exiv2::Image::AutoPtr image;
++#endif
+     bool exifError = false;
+ 
+     if (newImage) {
+@@ -985,8 +989,13 @@ void ImageViewer::saveImage() {
+ }
+ 
+ void ImageViewer::saveImageAs() {
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++    Exiv2::Image::UniquePtr newExifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
+     Exiv2::Image::AutoPtr newExifImage;
++#endif
+     bool exifError = false;
+ 
+     setCursorHiding(false);
+diff --git a/MetadataCache.cpp b/MetadataCache.cpp
+index 524ae74..5ddd4c8 100644
+--- a/MetadataCache.cpp
++++ b/MetadataCache.cpp
+@@ -64,7 +64,11 @@ void MetadataCache::clear() {
+ }
+ 
+ bool MetadataCache::loadImageMetadata(const QString &imageFullPath) {
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
++#endif
+     QSet<QString> tags;
+     long orientation = 0;
+ 
+@@ -78,7 +82,11 @@ bool MetadataCache::loadImageMetadata(const QString &imageFullPath) {
+     try {
+         Exiv2::ExifData &exifData = exifImage->exifData();
+         if (!exifData.empty()) {
++#if EXIV2_TEST_VERSION(0,28,0)
++            orientation = exifData["Exif.Image.Orientation"].value().toUint32();
++#else
+             orientation = exifData["Exif.Image.Orientation"].value().toLong();
++#endif
+         }
+     } catch (Exiv2::Error &error) {
+         qWarning() << "Failed to read Exif metadata";
+diff --git a/Phototonic.cpp b/Phototonic.cpp
+index 6cc95b3..bd5497d 100644
+--- a/Phototonic.cpp
++++ b/Phototonic.cpp
+@@ -3151,7 +3151,11 @@ void Phototonic::removeMetadata() {
+ 
+     if (ret == MessageBox::Yes) {
+         for (int file = 0; file < fileList.size(); ++file) {
++#if EXIV2_TEST_VERSION(0,28,0)
++            Exiv2::Image::UniquePtr image;
++#else
+             Exiv2::Image::AutoPtr image;
++#endif
+             try {
+                 image = Exiv2::ImageFactory::open(fileList[file].toStdString());
+                 image->clearMetadata();
+diff --git a/Tags.cpp b/Tags.cpp
+index 84eea16..a62da9d 100644
+--- a/Tags.cpp
++++ b/Tags.cpp
+@@ -136,7 +136,11 @@ void ImageTags::addTag(QString tagName, bool tagChecked) {
+ 
+ bool ImageTags::writeTagsToImage(QString &imageFileName, QSet<QString> &newTags) {
+     QSet<QString> imageTags;
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
++#endif
+ 
+     try {
+         exifImage = Exiv2::ImageFactory::open(imageFileName.toStdString());
+@@ -160,7 +164,11 @@ bool ImageTags::writeTagsToImage(QString &imageFileName, QSet<QString> &newTags)
+         QSetIterator<QString> newTagsIt(newTags);
+         while (newTagsIt.hasNext()) {
+             QString tag = newTagsIt.next();
++#if EXIV2_TEST_VERSION(0,28,0)
++            Exiv2::Value::UniquePtr value = Exiv2::Value::create(Exiv2::string);
++#else
+             Exiv2::Value::AutoPtr value = Exiv2::Value::create(Exiv2::string);
++#endif
+             value->read(tag.toStdString());
+             Exiv2::IptcKey key("Iptc.Application2.Keywords");
+             newIptcData.add(key, value.get());
+diff --git a/ThumbsViewer.cpp b/ThumbsViewer.cpp
+index 77a6189..4a11475 100644
+--- a/ThumbsViewer.cpp
++++ b/ThumbsViewer.cpp
+@@ -210,7 +210,11 @@ void ThumbsViewer::updateImageInfoViewer(QString imageFullPath) {
+         infoView->addEntry(key, val);
+     }
+ 
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
++#endif
+     try {
+         exifImage = Exiv2::ImageFactory::open(imageFullPath.toStdString());
+         exifImage->readMetadata();
+-- 
+2.40.1
+
diff --git a/srcpkgs/phototonic/template b/srcpkgs/phototonic/template
index 77ae8bf6a4406..4af006cb7da41 100644
--- a/srcpkgs/phototonic/template
+++ b/srcpkgs/phototonic/template
@@ -1,7 +1,7 @@
 # Template file for 'phototonic'
 pkgname=phototonic
 version=2.1
-revision=3
+revision=4
 build_style=qmake
 hostmakedepends="pkg-config qt5-qmake qt5-host-tools"
 makedepends="qt5-svg-devel exiv2-devel"

From b58fb3502000e1a15fbb1304377a745488303732 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 18/23] qimgv: revbump for exiv2-0.28.1.

---
 srcpkgs/qimgv/patches/exiv2-0.28.patch | 16 ++++++++++++++++
 srcpkgs/qimgv/template                 |  2 +-
 2 files changed, 17 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/qimgv/patches/exiv2-0.28.patch

diff --git a/srcpkgs/qimgv/patches/exiv2-0.28.patch b/srcpkgs/qimgv/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..11f37b5ae2be3
--- /dev/null
+++ b/srcpkgs/qimgv/patches/exiv2-0.28.patch
@@ -0,0 +1,16 @@
+Patch-Source: https://git.alpinelinux.org/aports/tree/community/qimgv/exiv2-0.28.patch
+diff --git a/qimgv/sourcecontainers/documentinfo.cpp b/qimgv/sourcecontainers/documentinfo.cpp
+index 98a68f7..c062474 100644
+--- a/qimgv/sourcecontainers/documentinfo.cpp
++++ b/qimgv/sourcecontainers/documentinfo.cpp
+@@ -271,10 +271,6 @@ void DocumentInfo::loadExifTags() {
+         //std::cout << "Caught Exiv2 exception '" << e.what() << "'\n";
+         return;
+     }
+-    catch (Exiv2::BasicError<CharType> e) {
+-        //std::cout << "Caught BasicError Exiv2 exception '" << e.what() << "'\n";
+-        return;
+-    }
+ #endif
+ }
+ 
diff --git a/srcpkgs/qimgv/template b/srcpkgs/qimgv/template
index 7eb30db33992c..dd341dfe1bfce 100644
--- a/srcpkgs/qimgv/template
+++ b/srcpkgs/qimgv/template
@@ -1,7 +1,7 @@
 # Template file for 'qimgv'
 pkgname=qimgv
 version=1.0.2
-revision=2
+revision=3
 build_style=cmake
 configure_args="$(vopt_if video -DVIDEO_SUPPORT=ON -DVIDEO_SUPPORT=OFF)
  $(vopt_if scale -DOPENCV_SUPPORT=ON -DOPENCV_SUPPORT=OFF)

From b3c19d88e20e7f2a23e10e9be2b77ecc776427a9 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 19/23] SIR: revbump for exiv2-0.28.1.

---
 srcpkgs/SIR/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/SIR/template b/srcpkgs/SIR/template
index 113077acad354..c6da4c26b6c71 100644
--- a/srcpkgs/SIR/template
+++ b/srcpkgs/SIR/template
@@ -1,7 +1,7 @@
 # Template file for 'SIR'
 pkgname=SIR
 version=3.2.2
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="pkg-config"
 makedepends="exiv2-devel qt5-svg-devel qt5-tools-devel"

From 8373c5cbd8957c374528c1823edc0b08051bfed7 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 20/23] viewnior: revbump for exiv2-0.28.1.

---
 srcpkgs/viewnior/patches/exiv2-0.28.patch | 147 ++++++++++++++++++++++
 srcpkgs/viewnior/template                 |   2 +-
 2 files changed, 148 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/viewnior/patches/exiv2-0.28.patch

diff --git a/srcpkgs/viewnior/patches/exiv2-0.28.patch b/srcpkgs/viewnior/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..71459dee15768
--- /dev/null
+++ b/srcpkgs/viewnior/patches/exiv2-0.28.patch
@@ -0,0 +1,147 @@
+Patch-Source: https://gitlab.archlinux.org/archlinux/packaging/packages/viewnior/-/blob/f206ce6c22a3ec5f1f9ea1bde4077584f80458dd/exiv2-0.28.patch
+--
+From b6bb81a1b46e911d15bbf9a730972523de177705 Mon Sep 17 00:00:00 2001
+From: tastytea <tastytea@tastytea.de>
+Date: Tue, 16 May 2023 10:54:40 +0200
+Subject: [PATCH 1/2] change exiv2 AutoPtr to unique_ptr
+
+exiv2-0.28.0 removed Exiv2::Image::AutoPtr and added
+Exiv2::Image::UniquePtr instead. since it's a typedef for
+std::unique_ptr<Image>, i'm using that directly instead of adding a
+condition on the exiv2 version.
+---
+ src/uni-exiv2.cpp | 21 +++++++++++----------
+ 1 file changed, 11 insertions(+), 10 deletions(-)
+
+diff --git a/src/uni-exiv2.cpp b/src/uni-exiv2.cpp
+index 0d14b9f..77064c2 100644
+--- a/src/uni-exiv2.cpp
++++ b/src/uni-exiv2.cpp
+@@ -22,12 +22,13 @@
+ 
+ #include <exiv2/exiv2.hpp>
+ #include <iostream>
++#include <memory>
+ 
+ #include "uni-exiv2.hpp"
+ 
+ #define ARRAY_SIZE(array) (sizeof array/sizeof(array[0]))
+ 
+-static Exiv2::Image::AutoPtr cached_image;
++static std::unique_ptr<Exiv2::Image> cached_image;
+ 
+ extern "C"
+ void
+@@ -35,8 +36,8 @@ uni_read_exiv2_map(const char *uri, void (*callback)(const char*, const char*, v
+ {
+     Exiv2::LogMsg::setLevel(Exiv2::LogMsg::mute);
+     try {
+-        Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open(uri);
+-        if ( image.get() == 0 ) {
++        std::unique_ptr<Exiv2::Image> image = Exiv2::ImageFactory::open(uri);
++        if (image == nullptr) {
+             return;
+         }
+ 
+@@ -91,14 +92,14 @@ uni_read_exiv2_to_cache(const char *uri)
+ {
+     Exiv2::LogMsg::setLevel(Exiv2::LogMsg::mute);
+ 
+-    if ( cached_image.get() != NULL ) {
++    if (cached_image != nullptr) {
+         cached_image->clearMetadata();
+-        cached_image.reset(NULL);
++        cached_image.reset(nullptr);
+     }
+ 
+     try {
+         cached_image = Exiv2::ImageFactory::open(uri);
+-        if ( cached_image.get() == 0 ) {
++        if (cached_image == nullptr) {
+             return 1;
+         }
+ 
+@@ -116,13 +117,13 @@ uni_write_exiv2_from_cache(const char *uri)
+ {
+     Exiv2::LogMsg::setLevel(Exiv2::LogMsg::mute);
+ 
+-    if ( cached_image.get() == NULL ) {
++    if (cached_image == nullptr) {
+         return 1;
+     }
+ 
+     try {
+-        Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open(uri);
+-        if ( image.get() == 0 ) {
++        std::unique_ptr<Exiv2::Image> image = Exiv2::ImageFactory::open(uri);
++        if (image == nullptr) {
+             return 2;
+         }
+ 
+@@ -130,7 +131,7 @@ uni_write_exiv2_from_cache(const char *uri)
+         image->writeMetadata();
+ 
+         cached_image->clearMetadata();
+-        cached_image.reset(NULL);
++        cached_image.reset(nullptr);
+ 
+         return 0;
+     } catch (Exiv2::AnyError& e) {
+
+From 47d0b98cb46526aa8aa035bebcabc14a11fa57ee Mon Sep 17 00:00:00 2001
+From: tastytea <tastytea@tastytea.de>
+Date: Tue, 16 May 2023 11:17:00 +0200
+Subject: [PATCH 2/2] add support for exiv-0.28.0 errors
+
+exiv2-0.28.0 changed Exiv2::AnyError to Exiv2::Error.
+---
+ src/uni-exiv2.cpp | 15 ++++++++++++---
+ 1 file changed, 12 insertions(+), 3 deletions(-)
+
+diff --git a/src/uni-exiv2.cpp b/src/uni-exiv2.cpp
+index 77064c2..567a50f 100644
+--- a/src/uni-exiv2.cpp
++++ b/src/uni-exiv2.cpp
+@@ -28,6 +28,15 @@
+ 
+ #define ARRAY_SIZE(array) (sizeof array/sizeof(array[0]))
+ 
++#define EXIV_ERROR Exiv2::AnyError
++#ifdef EXIV2_VERSION
++    #ifdef EXIV2_TEST_VERSION
++        #if EXIV2_TEST_VERSION(0,28,0)
++            #define EXIV_ERROR Exiv2::Error
++        #endif
++    #endif
++#endif
++
+ static std::unique_ptr<Exiv2::Image> cached_image;
+ 
+ extern "C"
+@@ -81,7 +90,7 @@ uni_read_exiv2_map(const char *uri, void (*callback)(const char*, const char*, v
+                 }
+             }
+         }
+-    } catch (Exiv2::AnyError& e) {
++    } catch (EXIV_ERROR& e) {
+         std::cerr << "Exiv2: '" << e << "'\n";
+     }
+ }
+@@ -104,7 +113,7 @@ uni_read_exiv2_to_cache(const char *uri)
+         }
+ 
+         cached_image->readMetadata();
+-    } catch (Exiv2::AnyError& e) {
++    } catch (EXIV_ERROR& e) {
+         std::cerr << "Exiv2: '" << e << "'\n";
+     }
+ 
+@@ -134,7 +143,7 @@ uni_write_exiv2_from_cache(const char *uri)
+         cached_image.reset(nullptr);
+ 
+         return 0;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (EXIV_ERROR& e) {
+         std::cerr << "Exiv2: '" << e << "'\n";
+     }
+ 
diff --git a/srcpkgs/viewnior/template b/srcpkgs/viewnior/template
index ea1e528a8651f..4c73226662ca0 100644
--- a/srcpkgs/viewnior/template
+++ b/srcpkgs/viewnior/template
@@ -1,7 +1,7 @@
 # Template file for 'viewnior'
 pkgname=viewnior
 version=1.8
-revision=1
+revision=2
 build_style=meson
 hostmakedepends="pkg-config intltool glib-devel gettext-devel"
 makedepends="gtk+-devel exiv2-devel"

From cac920b7d375cda6f11b10721262803668cb52a0 Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Mon, 23 Oct 2023 19:06:34 +0200
Subject: [PATCH 21/23] New package: nufraw-0.43.3

Co-authored-by: triallax <triallax@tutanota.com>
---
 srcpkgs/nufraw-gimp                           |  1 +
 .../patches/0001-nufraw-glib-2.70.patch       | 20 +++++++
 srcpkgs/nufraw/patches/exiv-0.28.x.diff       | 59 +++++++++++++++++++
 srcpkgs/nufraw/template                       | 56 ++++++++++++++++++
 srcpkgs/ufraw                                 |  1 +
 srcpkgs/ufraw-gimp                            |  2 +-
 .../ufraw/patches/001-no-gimp-remote.patch    | 12 ----
 srcpkgs/ufraw/patches/002-fix_abs_int.patch   | 11 ----
 .../ufraw/patches/03_fix-unsigned-char.patch  | 14 -----
 srcpkgs/ufraw/patches/exiv-0.27.patch         | 25 --------
 srcpkgs/ufraw/patches/glib-2.68.patch         | 30 ----------
 srcpkgs/ufraw/patches/iostream.patch          | 13 ----
 srcpkgs/ufraw/template                        | 38 ------------
 13 files changed, 138 insertions(+), 144 deletions(-)
 create mode 120000 srcpkgs/nufraw-gimp
 create mode 100644 srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch
 create mode 100644 srcpkgs/nufraw/patches/exiv-0.28.x.diff
 create mode 100644 srcpkgs/nufraw/template
 create mode 120000 srcpkgs/ufraw
 delete mode 100644 srcpkgs/ufraw/patches/001-no-gimp-remote.patch
 delete mode 100644 srcpkgs/ufraw/patches/002-fix_abs_int.patch
 delete mode 100644 srcpkgs/ufraw/patches/03_fix-unsigned-char.patch
 delete mode 100644 srcpkgs/ufraw/patches/exiv-0.27.patch
 delete mode 100644 srcpkgs/ufraw/patches/glib-2.68.patch
 delete mode 100644 srcpkgs/ufraw/patches/iostream.patch
 delete mode 100644 srcpkgs/ufraw/template

diff --git a/srcpkgs/nufraw-gimp b/srcpkgs/nufraw-gimp
new file mode 120000
index 0000000000000..0bd1459b2a16f
--- /dev/null
+++ b/srcpkgs/nufraw-gimp
@@ -0,0 +1 @@
+nufraw
\ No newline at end of file
diff --git a/srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch b/srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch
new file mode 100644
index 0000000000000..41f10bfbafa1f
--- /dev/null
+++ b/srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch
@@ -0,0 +1,20 @@
+diff -ru nufraw/uf_glib.h nufraw/uf_glib.h
+--- nufraw/uf_glib.h	2022-02-23 09:03:44.700472919 +0100
++++ nufraw/uf_glib.h	2022-02-23 09:04:50.260308805 +0100
+@@ -13,13 +13,13 @@
+ #ifndef _UF_GLIB_H
+ #define _UF_GLIB_H
+ 
++#include <glib.h>
++#include <glib/gstdio.h>
++
+ #ifdef __cplusplus
+ extern "C" {
+ #endif
+ 
+-#include <glib.h>
+-#include <glib/gstdio.h>
+-
+ // g_win32_locale_filename_from_utf8 is needed only on win32
+ #ifdef _WIN32
+ #define uf_win32_locale_filename_from_utf8(__some_string__) \
diff --git a/srcpkgs/nufraw/patches/exiv-0.28.x.diff b/srcpkgs/nufraw/patches/exiv-0.28.x.diff
new file mode 100644
index 0000000000000..6c23359bf706c
--- /dev/null
+++ b/srcpkgs/nufraw/patches/exiv-0.28.x.diff
@@ -0,0 +1,59 @@
+Patch taken from AUR package: https://aur.archlinux.org/cgit/aur.git/tree/exiv2-error.patch?h=nufraw&id=29e467f2c297fcd0f36548642d6d2cab6428d08f
+diff --git a/nufraw_exiv2.cc b/nufraw_exiv2.cc
+index 2de4cc3..45aea87 100644
+--- a/nufraw_exiv2.cc
++++ b/nufraw_exiv2.cc
+@@ -54,7 +54,7 @@ extern "C" int nufraw_exif_read_input(nufraw_data *uf)
+         uf->inputExifBuf = NULL;
+         uf->inputExifBufLen = 0;
+ 
+-        Exiv2::Image::AutoPtr image;
++        Exiv2::Image::UniquePtr image;
+         if (uf->unzippedBuf != NULL) {
+             image = Exiv2::ImageFactory::open(
+                         (const Exiv2::byte*)uf->unzippedBuf, uf->unzippedBufLen);
+@@ -135,7 +135,7 @@ extern "C" int nufraw_exif_read_input(nufraw_data *uf)
+         nufraw_message(NUFRAW_SET_LOG, "%s\n", stderror.str().c_str());
+ 
+         return NUFRAW_SUCCESS;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (Exiv2::Error& e) {
+         std::cerr.rdbuf(savecerr);
+         std::string s(e.what());
+         nufraw_message(NUFRAW_SET_WARNING, "%s\n", s.c_str());
+@@ -156,7 +156,7 @@ static Exiv2::ExifData nufraw_prepare_exifdata(nufraw_data *uf)
+         if ((pos = exifData.findKey(Exiv2::ExifKey("Exif.Image.Orientation")))
+                 != exifData.end()) {
+             nufraw_message(NUFRAW_SET_LOG, "Resetting %s from '%d' to '1'\n",
+-                          pos->key().c_str(), pos->value().toLong());
++                          pos->key().c_str(), pos->value().toInt64());
+             pos->setValue("1"); /* 1 = Normal orientation */
+         }
+     }
+@@ -327,7 +327,7 @@ extern "C" int nufraw_exif_prepare_output(nufraw_data *uf)
+         nufraw_message(NUFRAW_SET_LOG, "%s\n", stderror.str().c_str());
+ 
+         return NUFRAW_SUCCESS;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (Exiv2::Error& e) {
+         std::cerr.rdbuf(savecerr);
+         std::string s(e.what());
+         nufraw_message(NUFRAW_SET_WARNING, "%s\n", s.c_str());
+@@ -347,7 +347,7 @@ extern "C" int nufraw_exif_write(nufraw_data *uf)
+ 
+         char *filename =
+             uf_win32_locale_filename_from_utf8(uf->conf->outputFilename);
+-        Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open(filename);
++        Exiv2::Image::UniquePtr image = Exiv2::ImageFactory::open(filename);
+         uf_win32_locale_filename_free(filename);
+         assert(image.get() != 0);
+ 
+@@ -367,7 +367,7 @@ extern "C" int nufraw_exif_write(nufraw_data *uf)
+         nufraw_message(NUFRAW_SET_LOG, "%s\n", stderror.str().c_str());
+ 
+         return NUFRAW_SUCCESS;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (Exiv2::Error& e) {
+         std::cerr.rdbuf(savecerr);
+         std::string s(e.what());
+         nufraw_message(NUFRAW_SET_WARNING, "%s\n", s.c_str());
diff --git a/srcpkgs/nufraw/template b/srcpkgs/nufraw/template
new file mode 100644
index 0000000000000..7d75a4d372555
--- /dev/null
+++ b/srcpkgs/nufraw/template
@@ -0,0 +1,56 @@
+# Template file for 'nufraw'
+pkgname=nufraw
+version=0.43.3
+revision=1
+_ver="${version%.*}-${version##*.}"
+build_style=gnu-configure
+configure_args="--enable-contrast --enable-mime --enable-openmp --with-gimp
+ --enable-extras"
+hostmakedepends="pkg-config automake libtool glib-devel"
+# libgexiv2-devel is only here to fix build order, remove on next template
+# change
+makedepends="exiv2-devel gimp-devel glib-devel gtkimageview-devel lcms2-devel
+ lensfun-devel jasper-devel libgexiv2-devel"
+depends="desktop-file-utils"
+short_desc="Utility to read and manipulate raw images from digital cameras"
+maintainer="John <me@johnnynator.dev>"
+license="GPL-2.0-or-later"
+homepage="https://sourceforge.net/projects/nufraw/"
+distfiles="${SOURCEFORGE_SITE}/nufraw/nufraw-${_ver}.tar.gz"
+checksum=2c7dcc1590993ec267b3112562b2433010d6f94f6acc6506c76aa29cf8c6c32c
+
+case "$XBPS_TARGET_MACHINE" in
+	armv[67]l* | aarch64*)
+		makedepends+=" libgomp-devel"
+		make_build_args="CXXFLAGS+=-fsigned-char LDFLAGS+=-fopenmp"
+		;;
+esac
+
+pre_configure() {
+	autoreconf -fi
+}
+
+pre_build() {
+	mv nufraw.desktop{.desktop,}
+	chmod +x generate_schemas.sh
+}
+
+nufraw-gimp_package() {
+	depends="${sourcepkg}>=${version}_${revision}"
+	short_desc+=" - gimp plugin"
+	pkg_install() {
+		vmove usr/lib/gimp
+	}
+}
+
+ufraw_package() {
+	depends="${sourcepkg}>=${version}_${revision}"
+	build_style=meta
+	short_desc+=" (transitional dummy package)"
+}
+
+ufraw-gimp_package() {
+	depends="nufraw-gimp>=${version}_${revision}"
+	build_style=meta
+	short_desc+=" - gimp plugin (transitional dummy package)"
+}
diff --git a/srcpkgs/ufraw b/srcpkgs/ufraw
new file mode 120000
index 0000000000000..0bd1459b2a16f
--- /dev/null
+++ b/srcpkgs/ufraw
@@ -0,0 +1 @@
+nufraw
\ No newline at end of file
diff --git a/srcpkgs/ufraw-gimp b/srcpkgs/ufraw-gimp
index 967dc902dd02b..0bd1459b2a16f 120000
--- a/srcpkgs/ufraw-gimp
+++ b/srcpkgs/ufraw-gimp
@@ -1 +1 @@
-ufraw
\ No newline at end of file
+nufraw
\ No newline at end of file
diff --git a/srcpkgs/ufraw/patches/001-no-gimp-remote.patch b/srcpkgs/ufraw/patches/001-no-gimp-remote.patch
deleted file mode 100644
index ca4f4beb6240f..0000000000000
--- a/srcpkgs/ufraw/patches/001-no-gimp-remote.patch
+++ /dev/null
@@ -1,12 +0,0 @@
-Don't use gimp-remote since gimp 2.4 already includes gimp-remote functionality
---- a/ufraw_conf.c
-+++ b/ufraw_conf.c
-@@ -137,7 +137,7 @@
- #elif HAVE_GIMP_2_4
-     "gimp", /* remoteGimpCommand */
- #else
--    "gimp-remote", /* remoteGimpCommand */
-+    "gimp", /* remoteGimpCommand */
- #endif
- 
-     /* EXIF data */
diff --git a/srcpkgs/ufraw/patches/002-fix_abs_int.patch b/srcpkgs/ufraw/patches/002-fix_abs_int.patch
deleted file mode 100644
index 6fc552769c9f8..0000000000000
--- a/srcpkgs/ufraw/patches/002-fix_abs_int.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- a/dcraw.cc	2015-06-16 05:58:38.000000000 +0200
-+++ b/dcraw.cc	2018-02-04 14:46:54.489951076 +0100
-@@ -9242,7 +9242,7 @@
-     if (make[0] == 'O') {
-       i = find_green (12, 32, 1188864, 3576832);
-       c = find_green (12, 32, 2383920, 2387016);
--      if (abs(i) < abs(c)) {
-+      if (abs((int)i) < abs((int)c)) {
- 	SWAP(i,c);
- 	load_flags = 24;
-       }
diff --git a/srcpkgs/ufraw/patches/03_fix-unsigned-char.patch b/srcpkgs/ufraw/patches/03_fix-unsigned-char.patch
deleted file mode 100644
index 8690f87ca7d59..0000000000000
--- a/srcpkgs/ufraw/patches/03_fix-unsigned-char.patch
+++ /dev/null
@@ -1,14 +0,0 @@
-Source: written by John Paul Adrian Glaubitz for Debian
-Upstream: https://sourceforge.net/p/ufraw/bugs/417
-Reason: fixes a compilation failure on arm architectures
---- a/dcraw.cc
-+++ b/dcraw.cc
-@@ -2285,7 +2285,7 @@ void CLASS quicktake_100_load_raw()
- 
- void CLASS kodak_radc_load_raw()
- {
--  static const char src[] = {
-+  static const signed char src[] = {
-     1,1, 2,3, 3,4, 4,2, 5,7, 6,5, 7,6, 7,8,
-     1,0, 2,1, 3,3, 4,4, 5,2, 6,7, 7,6, 8,5, 8,8,
-     2,1, 2,3, 3,0, 3,2, 3,4, 4,6, 5,5, 6,7, 6,8,
diff --git a/srcpkgs/ufraw/patches/exiv-0.27.patch b/srcpkgs/ufraw/patches/exiv-0.27.patch
deleted file mode 100644
index b5b4140fff8ed..0000000000000
--- a/srcpkgs/ufraw/patches/exiv-0.27.patch
+++ /dev/null
@@ -1,25 +0,0 @@
---- a/ufraw_exiv2.cc	2015-06-16 05:58:38.000000000 +0200
-+++ b/ufraw_exiv2.cc	2018-12-29 22:51:23.291894430 +0100
-@@ -15,9 +15,7 @@
- #include "ufraw.h"
- 
- #ifdef HAVE_EXIV2
--#include <exiv2/image.hpp>
--#include <exiv2/easyaccess.hpp>
--#include <exiv2/exif.hpp>
-+#include <exiv2/exiv2.hpp>
- #include <sstream>
- #include <cassert>
- 
-@@ -67,7 +65,11 @@
-         if (exifData.empty()) {
-             std::string error(uf->filename);
-             error += ": No Exif data found in the file";
-+#if EXIV2_TEST_VERSION(0,27,0)
-+            throw Exiv2::Error(Exiv2::kerErrorMessage, error);
-+#else
-             throw Exiv2::Error(1, error);
-+#endif
-         }
- 
-         /* List of tag names taken from exiv2's printSummary() in actions.cpp */
diff --git a/srcpkgs/ufraw/patches/glib-2.68.patch b/srcpkgs/ufraw/patches/glib-2.68.patch
deleted file mode 100644
index 5b61468f118aa..0000000000000
--- a/srcpkgs/ufraw/patches/glib-2.68.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-From c56f8be3caf1cf3d9a5c80597bdbaf1325faacc0 Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?S=C3=A9rgio=20M=2E=20Basto?= <sergio@serjux.com>
-Date: Tue, 13 Apr 2021 23:45:39 +0100
-Subject: [PATCH] Fix build against glib-2.68 fixes #10
-
----
- uf_glib.h | 6 +++---
- 1 file changed, 3 insertions(+), 3 deletions(-)
-
-diff --git a/uf_glib.h b/uf_glib.h
-index 21c10b19..56cd6971 100644
---- a/uf_glib.h
-+++ b/uf_glib.h
-@@ -13,13 +13,13 @@
- #ifndef _UF_GLIB_H
- #define _UF_GLIB_H
- 
-+#include <glib.h>
-+#include <glib/gstdio.h>
-+
- #ifdef __cplusplus
- extern "C" {
- #endif
- 
--#include <glib.h>
--#include <glib/gstdio.h>
--
- // g_win32_locale_filename_from_utf8 is needed only on win32
- #ifdef _WIN32
- #define uf_win32_locale_filename_from_utf8(__some_string__) \
diff --git a/srcpkgs/ufraw/patches/iostream.patch b/srcpkgs/ufraw/patches/iostream.patch
deleted file mode 100644
index 6d15869f63db8..0000000000000
--- a/srcpkgs/ufraw/patches/iostream.patch
+++ /dev/null
@@ -1,13 +0,0 @@
-ufraw_exiv2.cc:343:10: note: 'std::cerr' is defined in header '<iostream>'
-ufraw_exiv2.cc:365:14: error: 'cerr' is not a member of 'std'
-
---- a/ufraw_exiv2.cc
-+++ b/ufraw_exiv2.cc
-@@ -17,6 +17,7 @@
- #ifdef HAVE_EXIV2
- #include <exiv2/exiv2.hpp>
- #include <sstream>
-+#include <iostream>
- #include <cassert>
- 
- /*
diff --git a/srcpkgs/ufraw/template b/srcpkgs/ufraw/template
deleted file mode 100644
index ceddcacacefb2..0000000000000
--- a/srcpkgs/ufraw/template
+++ /dev/null
@@ -1,38 +0,0 @@
-# Template file for 'ufraw'
-pkgname=ufraw
-version=0.22
-revision=5
-build_style=gnu-configure
-configure_args="--enable-contrast --enable-mime --enable-openmp --with-gimp
- $(vopt_enable extras)"
-hostmakedepends="pkg-config dcraw gettext"
-makedepends="exiv2-devel gimp-devel glib-devel gtkimageview-devel lcms2-devel lensfun-devel
- jasper-devel"
-depends="desktop-file-utils"
-short_desc="Utility to read and manipulate raw images from digital cameras"
-maintainer="John <me@johnnynator.dev>"
-license="GPL-2.0-or-later"
-homepage="http://ufraw.sourceforge.net/"
-distfiles="${SOURCEFORGE_SITE}/ufraw/ufraw/ufraw-${version}/ufraw-${version}.tar.gz"
-checksum=f7abd28ce587db2a74b4c54149bd8a2523a7ddc09bedf4f923246ff0ae09a25e
-
-build_options="extras"
-
-post_patch() {
-	vsed -e 's/default(none)//g' \
-		-i dcraw_indi.c \
-		-i dcraw_api.cc \
-		-i ufraw_ufraw.c \
-		-i ufraw_developer.c
-	vsed -i -e '/DATADIRNAME=/s/=.*/=share/' configure
-	vsed -i -e "s,^localedir =.*,localedir = /usr/share/locale," \
-		po/Makefile.in.in
-}
-
-ufraw-gimp_package() {
-	depends="${sourcepkg}>=${version}_${revision}"
-	short_desc+=" - gimp plugin"
-	pkg_install() {
-		vmove usr/lib/gimp
-	}
-}

From d268fd6079758beba5c90e38c2d08bdb27fab3b1 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 8 Nov 2023 12:53:45 +0000
Subject: [PATCH 22/23] krita: revbump for exiv2-0.28.1.

---
 srcpkgs/krita/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/krita/template b/srcpkgs/krita/template
index f4d665daf7c31..d804b581a8689 100644
--- a/srcpkgs/krita/template
+++ b/srcpkgs/krita/template
@@ -1,7 +1,7 @@
 # Template file for 'krita'
 pkgname=krita
 version=5.2.1
-revision=2
+revision=3
 build_style=cmake
 configure_args="-Wno-dev -DBUILD_TESTING=OFF"
 hostmakedepends="extra-cmake-modules gettext pkg-config python3

From e104b269279fefe22b8b2895ca2bbfcee0ff10fa Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 8 Nov 2023 18:25:01 +0000
Subject: [PATCH 23/23] darktable: revbump for exiv2-0.28.1.

---
 srcpkgs/darktable/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/darktable/template b/srcpkgs/darktable/template
index f76936a1692e8..97dfae3471e7c 100644
--- a/srcpkgs/darktable/template
+++ b/srcpkgs/darktable/template
@@ -1,7 +1,7 @@
 # Template file for 'darktable'
 pkgname=darktable
 version=4.4.2
-revision=4
+revision=5
 # upstream only supports these archs:
 archs="x86_64* aarch64* ppc64le*"
 build_style=cmake

^ permalink raw reply	[flat|nested] 27+ messages in thread

* Re: [PR REVIEW] exiv2: update to 0.28.1.
  2023-10-23  0:10 [PR PATCH] exiv2: update to 0.28.0 mhmdanas
                   ` (22 preceding siblings ...)
  2023-11-16 21:50 ` [PR PATCH] [Updated] " mhmdanas
@ 2023-11-16 21:51 ` mhmdanas
  2023-11-18 15:57 ` [PR PATCH] [Updated] " mhmdanas
  2023-11-18 21:41 ` [PR PATCH] [Merged]: " classabbyamp
  25 siblings, 0 replies; 27+ messages in thread
From: mhmdanas @ 2023-11-16 21:51 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 162 bytes --]

New review comment by mhmdanas on void-packages repository

https://github.com/void-linux/void-packages/pull/46838#discussion_r1396393257

Comment:
Done, thanks!

^ permalink raw reply	[flat|nested] 27+ messages in thread

* Re: [PR PATCH] [Updated] exiv2: update to 0.28.1.
  2023-10-23  0:10 [PR PATCH] exiv2: update to 0.28.0 mhmdanas
                   ` (23 preceding siblings ...)
  2023-11-16 21:51 ` [PR REVIEW] " mhmdanas
@ 2023-11-18 15:57 ` mhmdanas
  2023-11-18 21:41 ` [PR PATCH] [Merged]: " classabbyamp
  25 siblings, 0 replies; 27+ messages in thread
From: mhmdanas @ 2023-11-18 15:57 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 2086 bytes --]

There is an updated pull request by mhmdanas against master on the void-packages repository

https://github.com/mhmdanas/void-packages exiv2-0.28.0
https://github.com/void-linux/void-packages/pull/46838

exiv2: update to 0.28.1.
<!-- Uncomment relevant sections and delete options which are not applicable -->

#### Testing the changes
- I tested the changes in this PR: **briefly**

TODO:
- [x] Fix `gwenview`'s failed checks (not really fixed but the exact same tests fail on master as well)
- [x] `test_exiv2` fails for `libextractor`
- [x] `kfilemetadata5` tests fail (same tests fail on master)
- [x] Fix `nufraw` cross-build
- [x] `digikam` fails to build

@Johnnynator ufraw has been [unmaintained since December 2016](https://sourceforge.net/p/ufraw/discussion/434060/thread/30b4249b/), and it doesn't build with this PR; here are the options:
- remove the package entirely
- replace it with the newer [nufraw](https://sourceforge.net/projects/nufraw/), which already has [an exiv 0.28.x patch floating around](https://aur.archlinux.org/cgit/aur.git/tree/exiv2-error.patch?h=nufraw)
- patch it to build with this PR

What do you think? (edit: `nufraw` now replaces `ufraw` in this PR)

<!--
#### New package
- This new package conforms to the [package requirements](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTItest_exiv2NG.md#package-requirements): **YES**|**NO**
-->

<!-- Note: If the build is likely to take more than 2 hours, please add ci skip tag as described in
https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration
and test at least one native build and, if supported, at least one cross build.
Ignore this section if this PR is not skipping CI.
-->
<!--
#### Local build testing
- I built this PR locally for my native architecture, (ARCH-LIBC)
- I built this PR locally for these architectures (if supported. mark crossbuilds):
  - aarch64-musl
  - armv7l
  - armv6l-musl
-->


A patch file from https://github.com/void-linux/void-packages/pull/46838.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-exiv2-0.28.0-46838.patch --]
[-- Type: text/x-diff, Size: 76763 bytes --]

From a07a4a5e459ffbc5bc9b6cfd014381aedd63edb1 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 15 Nov 2023 17:19:46 +0000
Subject: [PATCH 01/24] Revert "xsimd: update to 11.2.0."

This reverts commit de75fb145239a14517310ec0e516491e9e2feae7.

Breaks 32-bit krita build:
https://github.com/void-linux/void-packages/issues/47243
---
 srcpkgs/xsimd/template | 13 ++++++-------
 1 file changed, 6 insertions(+), 7 deletions(-)

diff --git a/srcpkgs/xsimd/template b/srcpkgs/xsimd/template
index ffc806bd7d111..7ab79e3a6de09 100644
--- a/srcpkgs/xsimd/template
+++ b/srcpkgs/xsimd/template
@@ -1,20 +1,19 @@
 # Template file for 'xsimd'
 pkgname=xsimd
-version=11.2.0
-revision=1
+reverts="11.2.0_1"
+version=11.1.0
+revision=2
 build_style=cmake
-checkdepends="doctest-devel"
 short_desc="C++ wrappers for SIMD intrinsics and parallelized, optimized mathematical functions"
 maintainer="John <me@johnnynator.dev>"
 license="BSD-3-Clause"
 homepage="https://github.com/xtensor-stack/xsimd"
 distfiles="https://github.com/xtensor-stack/xsimd/archive/refs/tags/${version}.tar.gz"
-checksum=509bbfe12e78ee1a0e81711019e7c7a372dabcff566dbf15b95cc94339443242
+checksum=aa54dba8daade472656eba0d27154f072fec06ee3831aefcac69a5f6c7dbbae7
 
-if [ "$XBPS_CHECK_PKGS" ]; then
+if [ -z "$CROSS_BUILD" ]; then
 	configure_args="-DBUILD_TESTS=ON"
-else
-	configure_args="-DBUILD_TESTS=OFF"
+	makedepends="doctest-devel"
 fi
 
 post_install() {

From 7423e05af508b6e62cb9b41a556e716655d73818 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Mon, 23 Oct 2023 01:20:09 +0100
Subject: [PATCH 02/24] inih: add `libINIReader.so.0` common/shlibs entry.

---
 common/shlibs | 1 +
 1 file changed, 1 insertion(+)

diff --git a/common/shlibs b/common/shlibs
index c4a090b04798f..5f831757c3000 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -3902,6 +3902,7 @@ libnotcurses++.so.3 notcurses-3.0.5_1
 libnotcurses-ffi.so.3 notcurses-3.0.5_1
 libevemu.so.3 evemu-2.7.0_1
 libinih.so.0 inih-52_1
+libINIReader.so.0 inih-57_1
 libpcaudio.so.0 pcaudiolib-1.1_1
 libdcerpc-samr.so.0 samba-4.13.2_1
 libdcerpc-server-core.so.0 samba-4.13.2_1

From 7d069127d17f3974f4ef61597a9f4088ca345955 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:12 +0100
Subject: [PATCH 03/24] exiv2: update to 0.28.1.

---
 common/shlibs          |  2 +-
 srcpkgs/exiv2/template | 18 +++++++++++-------
 2 files changed, 12 insertions(+), 8 deletions(-)

diff --git a/common/shlibs b/common/shlibs
index 5f831757c3000..e27dcf4cd794c 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -555,7 +555,7 @@ libgimpcolor-2.0.so.0 libgimp-2.10.0_1
 libgimpmodule-2.0.so.0 libgimp-2.10.0_1
 libgmic.so.3 gmic-3.1.6_1
 libcgmic.so.3 gmic-3.1.6_1
-libexiv2.so.27 exiv2-0.27_1
+libexiv2.so.28 exiv2-0.28.1_1
 libKF5Holidays.so.5 kholidays-5.47.0_1
 libPhabricatorHelpers.so.5 purpose-5.48.0_1
 libKF5PurposeWidgets.so.5 purpose-5.48.0_1
diff --git a/srcpkgs/exiv2/template b/srcpkgs/exiv2/template
index 49985fe82cc14..b068757bcf201 100644
--- a/srcpkgs/exiv2/template
+++ b/srcpkgs/exiv2/template
@@ -1,17 +1,17 @@
 # Template file for 'exiv2'
 pkgname=exiv2
-version=0.27.6
+version=0.28.1
 revision=1
 build_style=cmake
 configure_args="-DEXIV2_BUILD_SAMPLES=OFF -DEXIV2_ENABLE_BMFF=ON"
-makedepends="zlib-devel expat-devel"
-checkdepends="gtest-devel"
+makedepends="zlib-devel brotli-devel expat-devel inih-devel"
+checkdepends="gtest-devel python3"
 short_desc="Image metadata manipulation"
 maintainer="Enno Boland <gottox@voidlinux.org>"
 license="GPL-2.0-or-later"
 homepage="https://www.exiv2.org"
-distfiles="https://github.com/Exiv2/exiv2/releases/download/v${version}/exiv2-${version}-Source.tar.gz"
-checksum=4c192483a1125dc59a3d70b30d30d32edace9e14adf52802d2f853abf72db8a6
+distfiles="https://github.com/Exiv2/exiv2/archive/refs/tags/v${version}.tar.gz"
+checksum=3078651f995cb6313b1041f07f4dd1bf0e9e4d394d6e2adc6e92ad0b621291fa
 
 if [ -n "$XBPS_CHECK_PKGS" ]; then
 	configure_args+=" -DEXIV2_BUILD_UNIT_TESTS=ON"
@@ -21,14 +21,18 @@ if [ -n "$XBPS_CCACHE" ]; then
 	configure_args+=" -DBUILD_WITH_CCACHE=ON"
 fi
 
+pre_check() {
+	# https://github.com/Exiv2/exiv2/issues/2762
+	rm -f tests/bugfixes/github/test_issue_2427.py
+}
+
 exiv2-devel_package() {
 	depends="${makedepends} ${sourcepkg}-${version}_${revision}"
 	short_desc+=" - development files"
 	pkg_install() {
 		vmove usr/include
-		vmove usr/lib/cmake
 		vmove usr/lib/pkgconfig
-		vmove "usr/lib/*.a"
+		vmove usr/share/cmake
 		vmove "usr/lib/*.so"
 	}
 }

From d2712cece45a82447cfcdd5775d310c8a311afd9 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:37 +0100
Subject: [PATCH 04/24] ART: revbump for exiv2-0.28.1.

---
 srcpkgs/ART/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/ART/template b/srcpkgs/ART/template
index b6c47fc6c4cdf..94c7aa0378061 100644
--- a/srcpkgs/ART/template
+++ b/srcpkgs/ART/template
@@ -1,7 +1,7 @@
 # Template file for 'ART'
 pkgname=ART
 version=1.20.2
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="pkg-config"
 makedepends="fftw-devel gtkmm-devel lensfun-devel

From f883b09f8f5b06db141553ff9a0ae44315462b2f Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 05/24] digikam: revbump for exiv2-0.28.1.

---
 .../patches/fix-build-with-exiv2-0.28.1.patch | 422 ++++++++++++++++++
 srcpkgs/digikam/template                      |   2 +-
 2 files changed, 423 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/digikam/patches/fix-build-with-exiv2-0.28.1.patch

diff --git a/srcpkgs/digikam/patches/fix-build-with-exiv2-0.28.1.patch b/srcpkgs/digikam/patches/fix-build-with-exiv2-0.28.1.patch
new file mode 100644
index 0000000000000..2a01b4545e76d
--- /dev/null
+++ b/srcpkgs/digikam/patches/fix-build-with-exiv2-0.28.1.patch
@@ -0,0 +1,422 @@
+From a76a561b20e7300510b29edc97afab01e381c0ec Mon Sep 17 00:00:00 2001
+From: Maik Qualmann <metzpinguin@gmail.com>
+Date: Wed, 8 Nov 2023 23:13:26 +0100
+Subject: [PATCH 1/5] fix compile with Exiv2-0.28.1 It should still compile
+ even with smaller Exiv2 versions.
+
+---
+ core/CMakeLists.txt                     | 4 ++--
+ core/app/DigikamCoreTarget.cmake        | 2 +-
+ core/cmake/rules/RulesLibExiv2.cmake    | 8 ++++----
+ core/libs/metadataengine/CMakeLists.txt | 4 ++--
+ 4 files changed, 9 insertions(+), 9 deletions(-)
+
+diff --git a/core/CMakeLists.txt b/core/CMakeLists.txt
+index c694c4b176..d5dc2f0dd8 100644
+--- a/core/CMakeLists.txt
++++ b/core/CMakeLists.txt
+@@ -255,7 +255,7 @@ PRINT_COMPONENT_COMPILE_STATUS("Media Player Support"                       ENAB
+ # ==============================================================================
+ 
+ PRINT_LIBRARY_STATUS("libboostgraph" "https://github.com/boostorg/boost"                 "(version >= 1.43.0)"                Boost_FOUND)
+-PRINT_LIBRARY_STATUS("libexiv2"      "https://github.com/Exiv2/exiv2"                    "(version >= ${EXIV2_MIN_VERSION}"   exiv2_FOUND)
++PRINT_LIBRARY_STATUS("libexiv2"      "https://github.com/Exiv2/exiv2"                    "(version >= ${EXIV2_MIN_VERSION}"   LibExiv2_FOUND)
+ PRINT_LIBRARY_STATUS("libexpat"      "https://libexpat.github.io"                        "(version >= 2.0.0)"                 EXPAT_FOUND)
+ PRINT_LIBRARY_STATUS("libjpeg"       "https://github.com/libjpeg-turbo/libjpeg-turbo"    "(version >= 6b)"                    JPEG_FOUND)
+ PRINT_LIBRARY_STATUS("libkde"        "https://invent.kde.org/frameworks/"                "(version >= ${KF5_MIN_VERSION})"    KF5_FOUND)
+@@ -306,7 +306,7 @@ endif()
+ # ==============================================================================
+ 
+ if(Boost_FOUND                          AND
+-   exiv2_FOUND                          AND
++   LibExiv2_FOUND                       AND
+    EXPAT_FOUND                          AND
+    JPEG_FOUND                           AND
+    KF5_FOUND                            AND
+diff --git a/core/app/DigikamCoreTarget.cmake b/core/app/DigikamCoreTarget.cmake
+index 83fda1b35f..8221a2d632 100644
+--- a/core/app/DigikamCoreTarget.cmake
++++ b/core/app/DigikamCoreTarget.cmake
+@@ -151,7 +151,7 @@ target_link_libraries(digikamcore
+                       ${TIFF_LIBRARIES}
+                       PNG::PNG
+                       ${JPEG_LIBRARIES}
+-                      exiv2lib
++                      ${LibExiv2_LIBRARIES}
+ 
+                       ${OPENMP_LDFLAGS}
+ 
+diff --git a/core/cmake/rules/RulesLibExiv2.cmake b/core/cmake/rules/RulesLibExiv2.cmake
+index c8b37d307c..a8ca259432 100644
+--- a/core/cmake/rules/RulesLibExiv2.cmake
++++ b/core/cmake/rules/RulesLibExiv2.cmake
+@@ -4,7 +4,7 @@
+ # SPDX-License-Identifier: BSD-3-Clause
+ #
+ 
+-find_package(exiv2 REQUIRED)
++find_package(LibExiv2 REQUIRED)
+ 
+ set_package_properties("exiv2"     PROPERTIES
+                        DESCRIPTION "Required to build digiKam"
+@@ -13,13 +13,13 @@ set_package_properties("exiv2"     PROPERTIES
+                        PURPOSE     "Library to manage image metadata"
+ )
+ 
+-if("${exiv2_VERSION}" VERSION_LESS ${EXIV2_MIN_VERSION})
++if("${LibExiv2_VERSION}" VERSION_LESS ${EXIV2_MIN_VERSION})
+ 
+-    message(FATAL_ERROR "Exiv2 version is too old (${exiv2_VERSION})! Minimal version required:${EXIV2_MIN_VERSION}.")
++    message(FATAL_ERROR "Exiv2 version is too old (${LibExiv2_VERSION})! Minimal version required:${EXIV2_MIN_VERSION}.")
+ 
+ endif()
+ 
+-if("${exiv2_VERSION}" VERSION_LESS "0.27.99")
++if("${LibExiv2_VERSION}" VERSION_LESS "0.27.99")
+ 
+     set(EXIV2_CXX_STANDARD 11)
+ 
+diff --git a/core/libs/metadataengine/CMakeLists.txt b/core/libs/metadataengine/CMakeLists.txt
+index 47aa889d5e..bd4dba0bbd 100644
+--- a/core/libs/metadataengine/CMakeLists.txt
++++ b/core/libs/metadataengine/CMakeLists.txt
+@@ -18,7 +18,7 @@ endif()
+ 
+ # Exiv2 version < 0.28 use auto_ptr instead unique_ptr which is deprecated.
+ 
+-if("${exiv2_VERSION}" VERSION_LESS "0.27.99")
++if("${LibExiv2_VERSION}" VERSION_LESS "0.27.99")
+ 
+     DISABLE_GCC_COMPILER_WARNINGS("5.99.99" "-Wno-deprecated")
+ 
+@@ -112,7 +112,7 @@ include_directories(
+     $<TARGET_PROPERTY:KF5::ConfigCore,INTERFACE_INCLUDE_DIRECTORIES>
+     $<TARGET_PROPERTY:KF5::I18n,INTERFACE_INCLUDE_DIRECTORIES>
+ 
+-    $<TARGET_PROPERTY:exiv2lib,INTERFACE_INCLUDE_DIRECTORIES>
++    $<TARGET_PROPERTY:LibExiv2_INCLUDE_DIRS>
+ )
+ 
+ # Used by digikamcore
+-- 
+2.42.0
+
+
+From ee487a753a652c588b88fa18aeb885105c17368d Mon Sep 17 00:00:00 2001
+From: Maik Qualmann <metzpinguin@gmail.com>
+Date: Thu, 9 Nov 2023 18:49:18 +0100
+Subject: [PATCH 2/5] recognize both Exiv2 CMake variants
+
+---
+ core/CMakeLists.txt                     | 14 ++++++--
+ core/app/DigikamCoreTarget.cmake        | 17 ++++++++-
+ core/cmake/rules/RulesLibExiv2.cmake    | 46 +++++++++++++++++++++----
+ core/libs/metadataengine/CMakeLists.txt | 12 +++++--
+ 4 files changed, 77 insertions(+), 12 deletions(-)
+
+diff --git a/core/CMakeLists.txt b/core/CMakeLists.txt
+index d5dc2f0dd8..855fdcf185 100644
+--- a/core/CMakeLists.txt
++++ b/core/CMakeLists.txt
+@@ -255,7 +255,17 @@ PRINT_COMPONENT_COMPILE_STATUS("Media Player Support"                       ENAB
+ # ==============================================================================
+ 
+ PRINT_LIBRARY_STATUS("libboostgraph" "https://github.com/boostorg/boost"                 "(version >= 1.43.0)"                Boost_FOUND)
+-PRINT_LIBRARY_STATUS("libexiv2"      "https://github.com/Exiv2/exiv2"                    "(version >= ${EXIV2_MIN_VERSION}"   LibExiv2_FOUND)
++
++if(LibExiv2_FOUND)
++
++    PRINT_LIBRARY_STATUS("libexiv2"  "https://github.com/Exiv2/exiv2"                    "(version >= ${EXIV2_MIN_VERSION}"   LibExiv2_FOUND)
++
++else()
++
++    PRINT_LIBRARY_STATUS("libexiv2"  "https://github.com/Exiv2/exiv2"                    "(version >= ${EXIV2_MIN_VERSION}"   exiv2_FOUND)
++
++endif()
++
+ PRINT_LIBRARY_STATUS("libexpat"      "https://libexpat.github.io"                        "(version >= 2.0.0)"                 EXPAT_FOUND)
+ PRINT_LIBRARY_STATUS("libjpeg"       "https://github.com/libjpeg-turbo/libjpeg-turbo"    "(version >= 6b)"                    JPEG_FOUND)
+ PRINT_LIBRARY_STATUS("libkde"        "https://invent.kde.org/frameworks/"                "(version >= ${KF5_MIN_VERSION})"    KF5_FOUND)
+@@ -306,7 +316,7 @@ endif()
+ # ==============================================================================
+ 
+ if(Boost_FOUND                          AND
+-   LibExiv2_FOUND                       AND
++   (LibExiv2_FOUND OR exiv2_FOUND)      AND
+    EXPAT_FOUND                          AND
+    JPEG_FOUND                           AND
+    KF5_FOUND                            AND
+diff --git a/core/app/DigikamCoreTarget.cmake b/core/app/DigikamCoreTarget.cmake
+index 8221a2d632..80bd153caa 100644
+--- a/core/app/DigikamCoreTarget.cmake
++++ b/core/app/DigikamCoreTarget.cmake
+@@ -151,7 +151,6 @@ target_link_libraries(digikamcore
+                       ${TIFF_LIBRARIES}
+                       PNG::PNG
+                       ${JPEG_LIBRARIES}
+-                      ${LibExiv2_LIBRARIES}
+ 
+                       ${OPENMP_LDFLAGS}
+ 
+@@ -164,6 +163,22 @@ target_link_libraries(digikamcore
+                       opencv_flann
+ )
+ 
++if(LibExiv2_FOUND)
++
++    target_link_libraries(digikamcore
++                          PRIVATE
++                          ${LibExiv2_LIBRARIES}
++    )
++
++else()
++
++    target_link_libraries(digikamcore
++                          PRIVATE
++                          exiv2lib
++    )
++
++endif()
++
+ if(Qt6_FOUND)
+     target_link_libraries(digikamcore
+                           PRIVATE
+diff --git a/core/cmake/rules/RulesLibExiv2.cmake b/core/cmake/rules/RulesLibExiv2.cmake
+index a8ca259432..e568644ca4 100644
+--- a/core/cmake/rules/RulesLibExiv2.cmake
++++ b/core/cmake/rules/RulesLibExiv2.cmake
+@@ -4,7 +4,17 @@
+ # SPDX-License-Identifier: BSD-3-Clause
+ #
+ 
+-find_package(LibExiv2 REQUIRED)
++find_package(LibExiv2 OPTIONAL_COMPONENTS)
++
++if(LibExiv2_FOUND)
++
++    find_package(LibExiv2 REQUIRED)
++
++else()
++
++    find_package(exiv2 REQUIRED)
++
++endif()
+ 
+ set_package_properties("exiv2"     PROPERTIES
+                        DESCRIPTION "Required to build digiKam"
+@@ -13,18 +23,40 @@ set_package_properties("exiv2"     PROPERTIES
+                        PURPOSE     "Library to manage image metadata"
+ )
+ 
+-if("${LibExiv2_VERSION}" VERSION_LESS ${EXIV2_MIN_VERSION})
++if(LibExiv2_FOUND)
+ 
+-    message(FATAL_ERROR "Exiv2 version is too old (${LibExiv2_VERSION})! Minimal version required:${EXIV2_MIN_VERSION}.")
++    if("${LibExiv2_VERSION}" VERSION_LESS ${EXIV2_MIN_VERSION})
+ 
+-endif()
++        message(FATAL_ERROR "Exiv2 version is too old (${LibExiv2_VERSION})! Minimal version required:${EXIV2_MIN_VERSION}.")
++
++    endif()
++
++    if("${LibExiv2_VERSION}" VERSION_LESS "0.27.99")
+ 
+-if("${LibExiv2_VERSION}" VERSION_LESS "0.27.99")
++        set(EXIV2_CXX_STANDARD 11)
+ 
+-    set(EXIV2_CXX_STANDARD 11)
++    else()
++
++        set(EXIV2_CXX_STANDARD 17)
++
++    endif()
+ 
+ else()
+ 
+-    set(EXIV2_CXX_STANDARD 17)
++    if("${exiv2_VERSION}" VERSION_LESS ${EXIV2_MIN_VERSION})
++
++        message(FATAL_ERROR "Exiv2 version is too old (${exiv2_VERSION})! Minimal version required:${EXIV2_MIN_VERSION}.")
++
++    endif()
++
++    if("${exiv2_VERSION}" VERSION_LESS "0.27.99")
++
++        set(EXIV2_CXX_STANDARD 11)
++
++    else()
++
++        set(EXIV2_CXX_STANDARD 17)
++
++    endif()
+ 
+ endif()
+diff --git a/core/libs/metadataengine/CMakeLists.txt b/core/libs/metadataengine/CMakeLists.txt
+index bd4dba0bbd..a4124d17e0 100644
+--- a/core/libs/metadataengine/CMakeLists.txt
++++ b/core/libs/metadataengine/CMakeLists.txt
+@@ -111,10 +111,18 @@ include_directories(
+ 
+     $<TARGET_PROPERTY:KF5::ConfigCore,INTERFACE_INCLUDE_DIRECTORIES>
+     $<TARGET_PROPERTY:KF5::I18n,INTERFACE_INCLUDE_DIRECTORIES>
+-
+-    $<TARGET_PROPERTY:LibExiv2_INCLUDE_DIRS>
+ )
+ 
++if(LibExiv2_FOUND)
++
++    include_directories($<TARGET_PROPERTY:LibExiv2_INCLUDE_DIRS>)
++
++else()
++
++    include_directories($<TARGET_PROPERTY:exiv2lib,INTERFACE_INCLUDE_DIRECTORIES>)
++
++endif()
++
+ # Used by digikamcore
+ add_library(core_dmetadata_obj OBJECT ${libdmetadata_SRCS})
+ 
+-- 
+2.42.0
+
+
+From af221dd7700fbf1e6e3b5245184381d2b74ec781 Mon Sep 17 00:00:00 2001
+From: Maik Qualmann <metzpinguin@gmail.com>
+Date: Thu, 9 Nov 2023 19:12:44 +0100
+Subject: [PATCH 3/5] check version und clear LibExiv2_FOUND
+
+---
+ core/cmake/rules/RulesLibExiv2.cmake | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+diff --git a/core/cmake/rules/RulesLibExiv2.cmake b/core/cmake/rules/RulesLibExiv2.cmake
+index e568644ca4..de5ea80ec6 100644
+--- a/core/cmake/rules/RulesLibExiv2.cmake
++++ b/core/cmake/rules/RulesLibExiv2.cmake
+@@ -6,12 +6,13 @@
+ 
+ find_package(LibExiv2 OPTIONAL_COMPONENTS)
+ 
+-if(LibExiv2_FOUND)
++if(LibExiv2_FOUND AND ("${LibExiv2_VERSION}" VERSION_GREATER "0.28.0"))
+ 
+     find_package(LibExiv2 REQUIRED)
+ 
+ else()
+ 
++    set (LibExiv2_FOUND FALSE)
+     find_package(exiv2 REQUIRED)
+ 
+ endif()
+-- 
+2.42.0
+
+
+From fda83a6f7e03e4088f3a5903d036c1425d6303b9 Mon Sep 17 00:00:00 2001
+From: Maik Qualmann <metzpinguin@gmail.com>
+Date: Thu, 9 Nov 2023 19:15:41 +0100
+Subject: [PATCH 4/5] adjust Exiv2 version
+
+---
+ core/cmake/rules/RulesLibExiv2.cmake | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/core/cmake/rules/RulesLibExiv2.cmake b/core/cmake/rules/RulesLibExiv2.cmake
+index de5ea80ec6..3db233cad2 100644
+--- a/core/cmake/rules/RulesLibExiv2.cmake
++++ b/core/cmake/rules/RulesLibExiv2.cmake
+@@ -6,7 +6,7 @@
+ 
+ find_package(LibExiv2 OPTIONAL_COMPONENTS)
+ 
+-if(LibExiv2_FOUND AND ("${LibExiv2_VERSION}" VERSION_GREATER "0.28.0"))
++if(LibExiv2_FOUND AND ("${LibExiv2_VERSION}" VERSION_GREATER "0.27.99"))
+ 
+     find_package(LibExiv2 REQUIRED)
+ 
+-- 
+2.42.0
+
+
+From 921ee9945f8c438f23b83add58d5737b539cd312 Mon Sep 17 00:00:00 2001
+From: Maik Qualmann <metzpinguin@gmail.com>
+Date: Thu, 9 Nov 2023 21:35:09 +0100
+Subject: [PATCH 5/5] set correct exiv2 package name and less duplicate CMake
+ code
+
+---
+ core/cmake/rules/RulesLibExiv2.cmake | 34 +++++++++++-----------------
+ 1 file changed, 13 insertions(+), 21 deletions(-)
+
+diff --git a/core/cmake/rules/RulesLibExiv2.cmake b/core/cmake/rules/RulesLibExiv2.cmake
+index 3db233cad2..e3e667d946 100644
+--- a/core/cmake/rules/RulesLibExiv2.cmake
++++ b/core/cmake/rules/RulesLibExiv2.cmake
+@@ -9,19 +9,21 @@ find_package(LibExiv2 OPTIONAL_COMPONENTS)
+ if(LibExiv2_FOUND AND ("${LibExiv2_VERSION}" VERSION_GREATER "0.27.99"))
+ 
+     find_package(LibExiv2 REQUIRED)
++    set(EXIV2_PACKAGE_NAME "LibExiv2")
+ 
+ else()
+ 
+-    set (LibExiv2_FOUND FALSE)
++    set(LibExiv2_FOUND FALSE)
+     find_package(exiv2 REQUIRED)
++    set(EXIV2_PACKAGE_NAME "exiv2")
+ 
+ endif()
+ 
+-set_package_properties("exiv2"     PROPERTIES
+-                       DESCRIPTION "Required to build digiKam"
+-                       URL         "https://www.exiv2.org"
+-                       TYPE        RECOMMENDED
+-                       PURPOSE     "Library to manage image metadata"
++set_package_properties(${EXIV2_PACKAGE_NAME} PROPERTIES
++                       DESCRIPTION           "Required to build digiKam"
++                       URL                   "https://www.exiv2.org"
++                       TYPE                  RECOMMENDED
++                       PURPOSE               "Library to manage image metadata"
+ )
+ 
+ if(LibExiv2_FOUND)
+@@ -32,16 +34,6 @@ if(LibExiv2_FOUND)
+ 
+     endif()
+ 
+-    if("${LibExiv2_VERSION}" VERSION_LESS "0.27.99")
+-
+-        set(EXIV2_CXX_STANDARD 11)
+-
+-    else()
+-
+-        set(EXIV2_CXX_STANDARD 17)
+-
+-    endif()
+-
+ else()
+ 
+     if("${exiv2_VERSION}" VERSION_LESS ${EXIV2_MIN_VERSION})
+@@ -50,14 +42,14 @@ else()
+ 
+     endif()
+ 
+-    if("${exiv2_VERSION}" VERSION_LESS "0.27.99")
++endif()
+ 
+-        set(EXIV2_CXX_STANDARD 11)
++if(("${exiv2_VERSION}" VERSION_GREATER "0.27.99") OR ("${LibExiv2_VERSION}" VERSION_GREATER "0.27.99"))
+ 
+-    else()
++    set(EXIV2_CXX_STANDARD 17)
+ 
+-        set(EXIV2_CXX_STANDARD 17)
++else()
+ 
+-    endif()
++    set(EXIV2_CXX_STANDARD 11)
+ 
+ endif()
+-- 
+2.42.0
+
diff --git a/srcpkgs/digikam/template b/srcpkgs/digikam/template
index 206185f565488..4784bf7d62a8e 100644
--- a/srcpkgs/digikam/template
+++ b/srcpkgs/digikam/template
@@ -1,7 +1,7 @@
 # Template file for 'digikam'
 pkgname=digikam
 version=8.1.0
-revision=1
+revision=2
 build_style=cmake
 configure_args="-DBUILD_TESTING=OFF"
 hostmakedepends="extra-cmake-modules gettext pkg-config bison flex qt5-qmake

From 8eef27f866ac76e34dc132885dc63b81cb5145e8 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 06/24] geeqie: revbump for exiv2-0.28.1.

---
 srcpkgs/geeqie/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/geeqie/template b/srcpkgs/geeqie/template
index b5f958f854c1b..b494bc149e957 100644
--- a/srcpkgs/geeqie/template
+++ b/srcpkgs/geeqie/template
@@ -1,7 +1,7 @@
 # Template file for 'geeqie'
 pkgname=geeqie
 version=2.1
-revision=1
+revision=2
 build_style=meson
 hostmakedepends="pkg-config gettext xxd gdk-pixbuf-devel glib-devel"
 makedepends="gtk+3-devel glib-devel lcms2-devel exiv2-devel libheif-devel

From 6a11fa797099256924fe429c0d23340048160d80 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 07/24] gthumb: revbump for exiv2-0.28.1.

---
 srcpkgs/gthumb/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/gthumb/template b/srcpkgs/gthumb/template
index 02d2bc2ed04d6..50c1778f39435 100644
--- a/srcpkgs/gthumb/template
+++ b/srcpkgs/gthumb/template
@@ -1,7 +1,7 @@
 # Template file for 'gthumb'
 pkgname=gthumb
 version=3.12.4
-revision=1
+revision=2
 build_style=meson
 hostmakedepends="gettext pkg-config itstool glib-devel"
 makedepends="webkit2gtk-devel json-glib-devel libsecret-devel librsvg-devel

From 9f7cc39586b2a95c0e11993e2d0cc10052f8410f Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 08/24] gwenview: revbump for exiv2-0.28.1.

---
 srcpkgs/gwenview/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/gwenview/template b/srcpkgs/gwenview/template
index 1a9978f384084..c6ec9494eb067 100644
--- a/srcpkgs/gwenview/template
+++ b/srcpkgs/gwenview/template
@@ -1,7 +1,7 @@
 # Template file for 'gwenview'
 pkgname=gwenview
 version=23.08.3
-revision=1
+revision=2
 build_style=cmake
 build_helper=qemu
 hostmakedepends="extra-cmake-modules pkg-config qt5-qmake qt5-host-tools

From e0fa83ddbafb761e4d4c53ae3a705a675e35df36 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 09/24] hugin: revbump for exiv2-0.28.1.

---
 srcpkgs/hugin/patches/exiv2-0.28.patch | 77 ++++++++++++++++++++++++++
 srcpkgs/hugin/template                 |  2 +-
 2 files changed, 78 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/hugin/patches/exiv2-0.28.patch

diff --git a/srcpkgs/hugin/patches/exiv2-0.28.patch b/srcpkgs/hugin/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..49f0518117020
--- /dev/null
+++ b/srcpkgs/hugin/patches/exiv2-0.28.patch
@@ -0,0 +1,77 @@
+Patch-Source: https://gitlab.archlinux.org/archlinux/packaging/packages/hugin/-/blob/main/exiv2-0.28.patch
+diff -r 79cd11a7a66f src/hugin_base/panodata/Exiv2Helper.cpp
+--- a/src/hugin_base/panodata/Exiv2Helper.cpp	Wed May 24 19:13:20 2023 +0200
++++ b/src/hugin_base/panodata/Exiv2Helper.cpp	Mon Jun 05 00:31:19 2023 +0200
+@@ -40,7 +40,7 @@
+             Exiv2::ExifData::iterator itr = exifData.findKey(Exiv2::ExifKey(keyName));
+             if (itr != exifData.end() && itr->count())
+             {
+-                value = itr->toLong();
++                value = itr->toUint32();
+                 return true;
+             }
+             else
+@@ -165,7 +165,7 @@
+         {
+             if(it!=exifData.end() && it->count())
+             {
+-                return it->toLong();
++                return it->toUint32();
+             }
+             return 0;
+         };
+@@ -600,4 +600,4 @@
+         };
+ 
+     }; //namespace Exiv2Helper
+-}; //namespace HuginBase
+\ No newline at end of file
++}; //namespace HuginBase
+diff -r 79cd11a7a66f src/hugin_base/panodata/SrcPanoImage.cpp
+--- a/src/hugin_base/panodata/SrcPanoImage.cpp	Wed May 24 19:13:20 2023 +0200
++++ b/src/hugin_base/panodata/SrcPanoImage.cpp	Mon Jun 05 00:31:19 2023 +0200
+@@ -384,7 +384,7 @@
+                     pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaImageWidthPixels"));
+                     if (pos != xmpData.end())
+                     {
+-                        croppedWidth = pos->toLong();
++                        croppedWidth = pos->toUint32();
+                     }
+                     else
+                     {
+@@ -394,7 +394,7 @@
+                     pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaImageHeightPixels"));
+                     if (pos != xmpData.end())
+                     {
+-                        croppedHeight = pos->toLong();
++                        croppedHeight = pos->toUint32();
+                     }
+                     else
+                     {
+@@ -408,7 +408,7 @@
+                         double hfov = 0;
+                         if (pos != xmpData.end())
+                         {
+-                            hfov = 360 * croppedWidth / (double)pos->toLong();
++                            hfov = 360 * croppedWidth / (double)pos->toUint32();
+                         }
+                         else
+                         {
+@@ -419,7 +419,7 @@
+                         pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.FullPanoHeightPixels"));
+                         if (pos != xmpData.end())
+                         {
+-                            fullHeight = pos->toLong();
++                            fullHeight = pos->toUint32();
+                         }
+                         else
+                         {
+@@ -430,7 +430,7 @@
+                         pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaTopPixels"));
+                         if (pos != xmpData.end())
+                         {
+-                            cropTop = pos->toLong();
++                            cropTop = pos->toUint32();
+                         }
+                         else
+                         {
diff --git a/srcpkgs/hugin/template b/srcpkgs/hugin/template
index ce71f6e4cbb2d..894876470ebde 100644
--- a/srcpkgs/hugin/template
+++ b/srcpkgs/hugin/template
@@ -1,7 +1,7 @@
 # Template file for 'hugin'
 pkgname=hugin
 version=2022.0.0
-revision=11
+revision=12
 build_style=cmake
 build_helper=cmake-wxWidgets-gtk3
 pycompile_dirs="usr/share/hugin/data/plugins usr/share/hugin/data/plugins-templates"

From 4b64bc78c538c4691b9c960037ed1dce1adf8ccf Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:38 +0100
Subject: [PATCH 10/24] kfilemetadata5: revbump for exiv2-0.28.1.

---
 srcpkgs/kfilemetadata5/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/kfilemetadata5/template b/srcpkgs/kfilemetadata5/template
index 00f7a98cf6399..e294ae5af947c 100644
--- a/srcpkgs/kfilemetadata5/template
+++ b/srcpkgs/kfilemetadata5/template
@@ -1,7 +1,7 @@
 # Template file for 'kfilemetadata5'
 pkgname=kfilemetadata5
 version=5.111.0
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="kcoreaddons extra-cmake-modules pkg-config qt5-host-tools qt5-qmake
  gettext kcoreaddons python3"

From 71a8ff096fd876d3ba91c9cd8352f986744a0ef0 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 11/24] krename: revbump for exiv2-0.28.1.

---
 srcpkgs/krename/patches/e7dd767a.patch | 90 ++++++++++++++++++++++++++
 srcpkgs/krename/template               |  2 +-
 2 files changed, 91 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/krename/patches/e7dd767a.patch

diff --git a/srcpkgs/krename/patches/e7dd767a.patch b/srcpkgs/krename/patches/e7dd767a.patch
new file mode 100644
index 0000000000000..a0ef428ce46b1
--- /dev/null
+++ b/srcpkgs/krename/patches/e7dd767a.patch
@@ -0,0 +1,90 @@
+Patch-Source: https://invent.kde.org/utilities/krename/-/commit/e7dd767a
+From e7dd767a9a1068ee1fe1502c4d619b57d3b12add Mon Sep 17 00:00:00 2001
+From: Andreas Sturmlechner <asturm@gentoo.org>
+Date: Fri, 26 May 2023 23:23:10 +0200
+Subject: [PATCH] Fix build with >=exiv2-0.28, raise minimum to 0.27
+
+- enables use of EXIV2_TEST_VERSION macro
+- exiv2 headers cleanup
+
+Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>
+---
+ CMakeLists.txt         |  6 +-----
+ config-krename.h.cmake |  3 ---
+ src/exiv2plugin.cpp    | 17 +++++------------
+ 3 files changed, 6 insertions(+), 20 deletions(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 0bda8ac..72e7297 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -56,13 +56,9 @@ set_package_properties(Taglib PROPERTIES
+     TYPE OPTIONAL)
+ 
+ # Find exiv2
+-find_package(LibExiv2 0.13) # AccessMode was added in 0.13
++find_package(LibExiv2 0.27) # EXIV2_TEST_VERSION was added in 0.27
+ set_package_properties(LibExiv2 PROPERTIES TYPE OPTIONAL)
+ 
+-if (LibExiv2_VERSION VERSION_GREATER_EQUAL "0.27")
+-    set(HAVE_LIBEXIV2_0_27 TRUE)
+-endif()
+-
+ # Find podofo
+ find_package(PoDoFo)
+ set_package_properties(PoDoFo PROPERTIES
+diff --git a/config-krename.h.cmake b/config-krename.h.cmake
+index 76c3d30..862e40b 100644
+--- a/config-krename.h.cmake
++++ b/config-krename.h.cmake
+@@ -6,9 +6,6 @@
+ /* have Exiv2 */
+ #cmakedefine01 HAVE_EXIV2
+ 
+-/* Defined if we have libexiv2 >= 0.27 */
+-#cmakedefine HAVE_LIBEXIV2_0_27
+-
+ /* have PoDoFo */
+ #cmakedefine01 HAVE_PODOFO
+ 
+diff --git a/src/exiv2plugin.cpp b/src/exiv2plugin.cpp
+index 5694d8c..25e8869 100644
+--- a/src/exiv2plugin.cpp
++++ b/src/exiv2plugin.cpp
+@@ -3,20 +3,9 @@
+ 
+ #include "exiv2plugin.h"
+ 
+-#include "../config-krename.h"
+-
+ #include <KLocalizedString>
+ 
+-#include <exiv2/error.hpp>
+-#include <exiv2/exif.hpp>
+-#include <exiv2/image.hpp>
+-#include <exiv2/iptc.hpp>
+-#ifdef HAVE_LIBEXIV2_0_27
+-    #include <exiv2/xmp_exiv2.hpp>
+-#else
+-    #include <exiv2/xmp.hpp>
+-#endif
+-#include <exiv2/tags.hpp>
++#include <exiv2/exiv2.hpp>
+ 
+ #include "batchrenamer.h"
+ #include "tokenhelpdialog.h"
+@@ -381,7 +370,11 @@ QString Exiv2Plugin::processFile(BatchRenamer *b, int index, const QString &file
+     std::string strFilename(asc.constData(), asc.length());
+ 
+     try {
++#if EXIV2_TEST_VERSION(0,28,0)
++        Image::UniquePtr image = Exiv2::ImageFactory::open(strFilename);
++#else
+         Image::AutoPtr image = Exiv2::ImageFactory::open(strFilename);
++#endif
+         if (image.get() != nullptr && image->good()) {
+             image->readMetadata();
+ 
+-- 
+GitLab
+
diff --git a/srcpkgs/krename/template b/srcpkgs/krename/template
index 66023163e3293..df5535007714a 100644
--- a/srcpkgs/krename/template
+++ b/srcpkgs/krename/template
@@ -1,7 +1,7 @@
 # Template file for 'krename'
 pkgname=krename
 version=5.0.2
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="extra-cmake-modules gettext kcoreaddons pkg-config qt5-host-tools qt5-qmake"
 makedepends="exiv2-devel freetype-devel kjs-devel kparts-devel libpodofo-devel

From 31b942b3bf30cbb27c3562724676bca0ccdc0687 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 12/24] libextractor: revbump for exiv2-0.28.1.

---
 srcpkgs/libextractor/patches/exiv2-0.28.patch | 303 ++++++++++++++++++
 srcpkgs/libextractor/patches/fix-tests.diff   |  24 ++
 srcpkgs/libextractor/template                 |   2 +-
 3 files changed, 328 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/libextractor/patches/exiv2-0.28.patch
 create mode 100644 srcpkgs/libextractor/patches/fix-tests.diff

diff --git a/srcpkgs/libextractor/patches/exiv2-0.28.patch b/srcpkgs/libextractor/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..de1b3cee5de50
--- /dev/null
+++ b/srcpkgs/libextractor/patches/exiv2-0.28.patch
@@ -0,0 +1,303 @@
+Patch based on https://gitlab.archlinux.org/archlinux/packaging/packages/libextractor/-/blob/main/exiv2-0.28.patch,
+with an additional minor change to fix build on 32-bit platforms.
+--- a/src/plugins/exiv2_extractor.cc	2023-11-18 14:03:36.454439185 +0000
++++ b/src/plugins/exiv2_extractor.cc	2023-11-18 14:03:40.462453936 +0000
+@@ -90,7 +90,11 @@
+  * @param rcount number of bytes to read
+  * @return buffer with data read, empty buffer (!) on failure (!)
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++virtual Exiv2::DataBuf read (size_t rcount);
++#else
+ virtual Exiv2::DataBuf read (long rcount);
++#endif
+ 
+ /**
+  * Read up to 'rcount' bytes into 'buf'.
+@@ -99,8 +103,17 @@
+  * @param rcount size of 'buf'
+  * @return number of bytes read successfully, 0 on failure (!)
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++virtual size_t read (Exiv2::byte *buf,
++                   size_t rcount);
++#else
+ virtual long read (Exiv2::byte *buf,
+                    long rcount);
++#endif
++
++#if EXIV2_TEST_VERSION (0,28,0)
++virtual void populateFakeData();
++#endif
+ 
+ /**
+  * Read a single character.
+@@ -117,8 +130,13 @@
+  * @param wcount how many bytes to write
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual size_t write (const Exiv2::byte *data,
++                    size_t wcount);
++#else
+ virtual long write (const Exiv2::byte *data,
+                     long wcount);
++#endif
+ 
+ /**
+  * Write to stream.
+@@ -126,7 +144,11 @@
+  * @param src stream to copy
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual size_t write (Exiv2::BasicIo &src);
++#else
+ virtual long write (Exiv2::BasicIo &src);
++#endif
+ 
+ /**
+  * Write a single byte.
+@@ -150,7 +172,7 @@
+  * @parma pos offset is relative to where?
+  * @return -1 on failure, 0 on success
+  */
+-virtual int seek (long offset,
++virtual int seek (int64_t offset,
+                   Exiv2::BasicIo::Position pos);
+ 
+ /**
+@@ -172,7 +194,11 @@
+  *
+  * @return -1 on error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual size_t tell (void) const;
++#else
+ virtual long int tell (void) const;
++#endif
+ 
+ /**
+  * Return overall size of the file.
+@@ -213,7 +239,11 @@
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual const std::string& path () const noexcept;
++#else
+ virtual std::string path () const;
++#endif
+ 
+ #ifdef EXV_UNICODE_PATH
+ /**
+@@ -230,7 +260,11 @@
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++virtual Exiv2::BasicIo::UniquePtr temporary () const;
++#else
+ virtual Exiv2::BasicIo::AutoPtr temporary () const;
++#endif
+ 
+ };
+ 
+@@ -266,7 +300,11 @@
+  * @return buffer with data read, empty buffer (!) on failure (!)
+  */
+ Exiv2::DataBuf
++#if EXIV2_TEST_VERSION (0,28,0)
++ExtractorIO::read (size_t rcount)
++#else
+ ExtractorIO::read (long rcount)
++#endif
+ {
+   void *data;
+   ssize_t ret;
+@@ -284,9 +322,15 @@
+  * @param rcount size of 'buf'
+  * @return number of bytes read successfully, 0 on failure (!)
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++size_t
++ExtractorIO::read (Exiv2::byte *buf,
++                   size_t rcount)
++#else
+ long
+ ExtractorIO::read (Exiv2::byte *buf,
+                    long rcount)
++#endif
+ {
+   void *data;
+   ssize_t ret;
+@@ -305,6 +349,12 @@
+   return got;
+ }
+ 
++#if EXIV2_TEST_VERSION (0,28,0)
++void ExtractorIO::populateFakeData()
++{
++  return;
++}
++#endif
+ 
+ /**
+  * Read a single character.
+@@ -319,7 +369,9 @@
+   const unsigned char *r;
+ 
+   if (1 != ec->read (ec->cls, &data, 1))
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION(0,28,0)
++    throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+     throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+     throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -336,9 +388,15 @@
+  * @param wcount how many bytes to write
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++size_t
++ExtractorIO::write (const Exiv2::byte *data,
++                    size_t wcount)
++#else
+ long
+ ExtractorIO::write (const Exiv2::byte *data,
+                     long wcount)
++#endif
+ {
+   return -1;
+ }
+@@ -350,7 +408,11 @@
+  * @param src stream to copy
+  * @return -1 (always fails)
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++size_t
++#else
+ long
++#endif
+ ExtractorIO::write (Exiv2::BasicIo &src)
+ {
+   return -1;
+@@ -378,7 +440,9 @@
+ void
+ ExtractorIO::transfer (Exiv2::BasicIo& src)
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION(0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -394,7 +458,7 @@
+  * @return -1 on failure, 0 on success
+  */
+ int
+-ExtractorIO::seek (long offset,
++ExtractorIO::seek (int64_t offset,
+                    Exiv2::BasicIo::Position pos)
+ {
+   int rel;
+@@ -427,7 +491,9 @@
+ Exiv2::byte *
+ ExtractorIO::mmap (bool isWritable)
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION (0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -452,7 +518,11 @@
+  *
+  * @return -1 on error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++size_t
++#else
+ long int
++#endif
+ ExtractorIO::tell (void) const
+ {
+   return (long) ec->seek (ec->cls, 0, SEEK_CUR);
+@@ -516,10 +586,17 @@
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION (0,28,0)
++const std::string&
++ExtractorIO::path () const noexcept
++#else
+ std::string
+ ExtractorIO::path () const
++#endif
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION (0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -536,7 +613,9 @@
+ std::wstring
+ ExtractorIO::wpath () const
+ {
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION (0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -552,11 +631,17 @@
+  *
+  * @throws error
+  */
++#if EXIV2_TEST_VERSION(0,28,0)
++Exiv2::BasicIo::UniquePtr
++#else
+ Exiv2::BasicIo::AutoPtr
++#endif
+ ExtractorIO::temporary () const
+ {
+   fprintf (stderr, "throwing temporary error\n");
+-#if EXIV2_TEST_VERSION (0,27,0)
++#if EXIV2_TEST_VERSION(0,28,0)
++  throw Exiv2::Error (Exiv2::ErrorCode::kerDecodeLangAltQualifierFailed);
++#elif EXIV2_TEST_VERSION (0,27,0)
+   throw Exiv2::BasicError<char> (Exiv2::kerDecodeLangAltQualifierFailed);
+ #else
+   throw Exiv2::BasicError<char> (42 /* error code */);
+@@ -737,8 +822,13 @@
+ #if ! EXIV2_TEST_VERSION (0,24,0)
+     Exiv2::LogMsg::setLevel (Exiv2::LogMsg::mute);
+ #endif
++#if EXIV2_TEST_VERSION(0,28,0)
++    std::unique_ptr<Exiv2::BasicIo> eio (new ExtractorIO (ec));
++    Exiv2::Image::UniquePtr image = Exiv2::ImageFactory::open (std::move(eio));
++#else
+     std::auto_ptr<Exiv2::BasicIo> eio (new ExtractorIO (ec));
+     Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open (eio);
++#endif
+     if (0 == image.get ())
+       return;
+     image->readMetadata ();
+@@ -822,7 +912,11 @@
+       ADDXMP ("Xmp.lr.hierarchicalSubject", EXTRACTOR_METATYPE_SUBJECT);
+     }
+   }
++#if EXIV2_TEST_VERSION (0,28,0)
++  catch (const Exiv2::Error& e)
++#else
+   catch (const Exiv2::AnyError& e)
++#endif
+   {
+ #if DEBUG
+     std::cerr << "Caught Exiv2 exception '" << e << "'\n";
diff --git a/srcpkgs/libextractor/patches/fix-tests.diff b/srcpkgs/libextractor/patches/fix-tests.diff
new file mode 100644
index 0000000000000..3b4ee7cbeea33
--- /dev/null
+++ b/srcpkgs/libextractor/patches/fix-tests.diff
@@ -0,0 +1,24 @@
+--- a/src/plugins/test_exiv2.c	2021-01-30 13:20:23.000000000 +0000
++++ b/src/plugins/test_exiv2.c	2023-11-03 19:39:43.115274492 +0000
+@@ -49,8 +49,8 @@
+       EXTRACTOR_METATYPE_GPS_LATITUDE,
+       EXTRACTOR_METAFORMAT_UTF8,
+       "text/plain",
+-      "28deg 8' (18|17.585)\" ?",
+-      strlen ("28deg 8' (18|17.585)\" ?") + 1,
++      "28 deg 8' (18|17.58)\" ?",
++      strlen ("28 deg 8' (18|17.58)\" ?") + 1,
+       0,
+       .regex = 1
+     },
+@@ -66,8 +66,8 @@
+       EXTRACTOR_METATYPE_GPS_LONGITUDE,
+       EXTRACTOR_METAFORMAT_UTF8,
+       "text/plain",
+-      "14deg 14' (22|21.713)\" ?",
+-      strlen ("14deg 14' (22|21.713)\" ?"),
++      "14 deg 14' (22|21.71)\" ?",
++      strlen ("14 deg 14' (22|21.71)\" ?"),
+       0,
+       .regex = 1
+     },
diff --git a/srcpkgs/libextractor/template b/srcpkgs/libextractor/template
index bfcea979a308c..044c663a3a0b9 100644
--- a/srcpkgs/libextractor/template
+++ b/srcpkgs/libextractor/template
@@ -1,7 +1,7 @@
 # Template file for 'libextractor'
 pkgname=libextractor
 version=1.11
-revision=3
+revision=4
 build_style=gnu-configure
 configure_args="--disable-static"
 hostmakedepends="pkg-config"

From 133f3744f85bb200597b72716efce9050f187274 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 13/24] libgexiv2: update to 0.14.2.

---
 srcpkgs/libgexiv2/template | 14 +++++++-------
 1 file changed, 7 insertions(+), 7 deletions(-)

diff --git a/srcpkgs/libgexiv2/template b/srcpkgs/libgexiv2/template
index 23780e5397dc4..91dbcaa9aca52 100644
--- a/srcpkgs/libgexiv2/template
+++ b/srcpkgs/libgexiv2/template
@@ -1,19 +1,19 @@
 # Template file for 'libgexiv2'
 pkgname=libgexiv2
-version=0.14.0
-revision=3
+version=0.14.2
+revision=1
 build_style=meson
 build_helper="gir"
-configure_args="-Dintrospection=$(vopt_if gir true false)
- -Dvapi=$(vopt_if vala true false)"
+configure_args="$(vopt_bool gir introspection) $(vopt_bool vala vapi)"
 hostmakedepends="pkg-config glib-devel $(vopt_if vala 'vala') python3-gobject"
 makedepends="libglib-devel exiv2-devel"
 short_desc="GObject-based wrapper around the Exiv2 library"
 maintainer="Enno Boland <gottox@voidlinux.org>"
 license="GPL-2.0-or-later"
 homepage="https://wiki.gnome.org/Projects/gexiv2"
-distfiles="${GNOME_SITE}/gexiv2/${version%.*}/${pkgname/lib/}-${version}.tar.xz"
-checksum=e58279a6ff20b6f64fa499615da5e9b57cf65ba7850b72fafdf17221a9d6d69e
+changelog="https://gitlab.gnome.org/GNOME/gexiv2/-/raw/master/NEWS"
+distfiles="${GNOME_SITE}/gexiv2/${version%.*}/gexiv2-${version}.tar.xz"
+checksum=2a0c9cf48fbe8b3435008866ffd40b8eddb0667d2212b42396fdf688e93ce0be
 
 build_options="gir vala"
 build_options_default="gir vala"
@@ -23,7 +23,7 @@ libgexiv2-devel_package() {
 	short_desc+=" - development files"
 	pkg_install() {
 		vmove usr/include
-		vmove usr/lib/*.so
+		vmove "usr/lib/*.so"
 		vmove usr/lib/pkgconfig
 		if [ "$build_option_vala" ]; then
 			vmove usr/share/vala

From f969623844188ade22ef01fdfdd4ed63fcafc5ac Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 14/24] libkexiv25: update to 23.08.3.

---
 srcpkgs/libkexiv25/template | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/srcpkgs/libkexiv25/template b/srcpkgs/libkexiv25/template
index b439a42ef2b97..6d43090f3f8ec 100644
--- a/srcpkgs/libkexiv25/template
+++ b/srcpkgs/libkexiv25/template
@@ -1,6 +1,6 @@
 # Template file for 'libkexiv25'
 pkgname=libkexiv25
-version=23.04.0
+version=23.08.3
 revision=1
 build_style=cmake
 configure_args="-DBUILD_TESTING=OFF"
@@ -11,7 +11,7 @@ maintainer="Orphaned <orphan@voidlinux.org>"
 license="GPL-2.0-or-later"
 homepage="https://invent.kde.org/graphics/libkexiv2"
 distfiles="${KDE_SITE}/release-service/${version}/src/libkexiv2-${version}.tar.xz"
-checksum=18d3eed06df9d1e31d8434ed9887e305aba176d0856e19a8cd3bdb555b80d391
+checksum=07f03d40a89cb5bad2deec80784ea7d4cea702d201f06b97f3888c433df638dd
 
 libkexiv25-devel_package() {
 	short_desc+=" - development files"

From 9844acd5730da1dde37450dbb0dd6d964a7b5045 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:39 +0100
Subject: [PATCH 15/24] nomacs: update to 3.17.2287.

---
 srcpkgs/nomacs/template | 17 +++++++++++++----
 1 file changed, 13 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/nomacs/template b/srcpkgs/nomacs/template
index c52cd54e294db..956bd21ebb129 100644
--- a/srcpkgs/nomacs/template
+++ b/srcpkgs/nomacs/template
@@ -1,7 +1,8 @@
 # Template file for 'nomacs'
 pkgname=nomacs
-version=3.16.224
-revision=5
+version=3.17.2287
+revision=1
+_plugins_ver=3.17.2285
 build_wrksrc=ImageLounge
 build_style=cmake
 configure_args="-DCMAKE_BUILD_TYPE=None -DENABLE_TRANSLATIONS=1
@@ -13,5 +14,13 @@ short_desc="Simple yet powerful Qt imageviewer"
 maintainer="Orphaned <orphan@voidlinux.org>"
 license="GPL-3.0-or-later"
 homepage="https://github.com/nomacs/nomacs"
-distfiles="https://github.com/nomacs/nomacs/archive/${version}.tar.gz"
-checksum=bbc7e9048026ef9e0d2b64902c88050f17a679ef3d3c009de2c3b7de5d1d217c
+distfiles="https://github.com/nomacs/nomacs/archive/${version}.tar.gz
+ https://github.com/novomesk/nomacs-plugins/archive/refs/tags/${_plugins_ver}.tar.gz>plugins.tar.gz"
+checksum="6905ea615358f84a0c83d5b1b7077871dea0526ec667500a1951448cb845a92c
+ 946b2d754be9ecca5cb155f7ecc5dcafb164f6c3dcc7bf5c3c0610d3b47774aa"
+skip_extraction="plugins.tar.gz"
+
+post_extract() {
+ cd ${build_wrksrc}
+ vsrcextract -C plugins "plugins.tar.gz"
+}

From da185980e2f174a99f355f00649d1e2bdd6947ee Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 16/24] pdf2djvu: revbump for exiv2-0.28.1.

---
 srcpkgs/pdf2djvu/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/pdf2djvu/template b/srcpkgs/pdf2djvu/template
index ef7433c0c98ae..5a6f3ddf4ed35 100644
--- a/srcpkgs/pdf2djvu/template
+++ b/srcpkgs/pdf2djvu/template
@@ -1,7 +1,7 @@
 # Template file for 'pdf2djvu'
 pkgname=pdf2djvu
 version=0.9.19
-revision=4
+revision=5
 build_style=gnu-configure
 hostmakedepends="pkg-config djvulibre gettext"
 makedepends="djvulibre-devel poppler-devel libgraphicsmagick-devel exiv2-devel libuuid-devel"

From 829341eaf4c06791e1e9bed0174c4d54b9c3824d Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 17/24] phototonic: revbump for exiv2-0.28.1.

---
 srcpkgs/phototonic/patches/exiv2-0.28.patch | 135 ++++++++++++++++++++
 srcpkgs/phototonic/template                 |   2 +-
 2 files changed, 136 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/phototonic/patches/exiv2-0.28.patch

diff --git a/srcpkgs/phototonic/patches/exiv2-0.28.patch b/srcpkgs/phototonic/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..1c75b628dab33
--- /dev/null
+++ b/srcpkgs/phototonic/patches/exiv2-0.28.patch
@@ -0,0 +1,135 @@
+From 923a3fc14de0b779a45696c5f0aef34c74d84f13 Mon Sep 17 00:00:00 2001
+From: Andreas Sturmlechner <asturm@gentoo.org>
+Date: Sun, 28 May 2023 18:54:10 +0200
+Subject: [PATCH] Fix build with exiv2-0.28
+
+Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>
+---
+ ImageViewer.cpp   | 9 +++++++++
+ MetadataCache.cpp | 8 ++++++++
+ Phototonic.cpp    | 4 ++++
+ Tags.cpp          | 8 ++++++++
+ ThumbsViewer.cpp  | 4 ++++
+ 5 files changed, 33 insertions(+)
+
+diff --git a/ImageViewer.cpp b/ImageViewer.cpp
+index 357d223..df3ac43 100644
+--- a/ImageViewer.cpp
++++ b/ImageViewer.cpp
+@@ -945,7 +945,11 @@ void ImageViewer::keyMoveEvent(int direction) {
+ }
+ 
+ void ImageViewer::saveImage() {
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr image;
++#else
+     Exiv2::Image::AutoPtr image;
++#endif
+     bool exifError = false;
+ 
+     if (newImage) {
+@@ -985,8 +989,13 @@ void ImageViewer::saveImage() {
+ }
+ 
+ void ImageViewer::saveImageAs() {
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++    Exiv2::Image::UniquePtr newExifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
+     Exiv2::Image::AutoPtr newExifImage;
++#endif
+     bool exifError = false;
+ 
+     setCursorHiding(false);
+diff --git a/MetadataCache.cpp b/MetadataCache.cpp
+index 524ae74..5ddd4c8 100644
+--- a/MetadataCache.cpp
++++ b/MetadataCache.cpp
+@@ -64,7 +64,11 @@ void MetadataCache::clear() {
+ }
+ 
+ bool MetadataCache::loadImageMetadata(const QString &imageFullPath) {
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
++#endif
+     QSet<QString> tags;
+     long orientation = 0;
+ 
+@@ -78,7 +82,11 @@ bool MetadataCache::loadImageMetadata(const QString &imageFullPath) {
+     try {
+         Exiv2::ExifData &exifData = exifImage->exifData();
+         if (!exifData.empty()) {
++#if EXIV2_TEST_VERSION(0,28,0)
++            orientation = exifData["Exif.Image.Orientation"].value().toUint32();
++#else
+             orientation = exifData["Exif.Image.Orientation"].value().toLong();
++#endif
+         }
+     } catch (Exiv2::Error &error) {
+         qWarning() << "Failed to read Exif metadata";
+diff --git a/Phototonic.cpp b/Phototonic.cpp
+index 6cc95b3..bd5497d 100644
+--- a/Phototonic.cpp
++++ b/Phototonic.cpp
+@@ -3151,7 +3151,11 @@ void Phototonic::removeMetadata() {
+ 
+     if (ret == MessageBox::Yes) {
+         for (int file = 0; file < fileList.size(); ++file) {
++#if EXIV2_TEST_VERSION(0,28,0)
++            Exiv2::Image::UniquePtr image;
++#else
+             Exiv2::Image::AutoPtr image;
++#endif
+             try {
+                 image = Exiv2::ImageFactory::open(fileList[file].toStdString());
+                 image->clearMetadata();
+diff --git a/Tags.cpp b/Tags.cpp
+index 84eea16..a62da9d 100644
+--- a/Tags.cpp
++++ b/Tags.cpp
+@@ -136,7 +136,11 @@ void ImageTags::addTag(QString tagName, bool tagChecked) {
+ 
+ bool ImageTags::writeTagsToImage(QString &imageFileName, QSet<QString> &newTags) {
+     QSet<QString> imageTags;
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
++#endif
+ 
+     try {
+         exifImage = Exiv2::ImageFactory::open(imageFileName.toStdString());
+@@ -160,7 +164,11 @@ bool ImageTags::writeTagsToImage(QString &imageFileName, QSet<QString> &newTags)
+         QSetIterator<QString> newTagsIt(newTags);
+         while (newTagsIt.hasNext()) {
+             QString tag = newTagsIt.next();
++#if EXIV2_TEST_VERSION(0,28,0)
++            Exiv2::Value::UniquePtr value = Exiv2::Value::create(Exiv2::string);
++#else
+             Exiv2::Value::AutoPtr value = Exiv2::Value::create(Exiv2::string);
++#endif
+             value->read(tag.toStdString());
+             Exiv2::IptcKey key("Iptc.Application2.Keywords");
+             newIptcData.add(key, value.get());
+diff --git a/ThumbsViewer.cpp b/ThumbsViewer.cpp
+index 77a6189..4a11475 100644
+--- a/ThumbsViewer.cpp
++++ b/ThumbsViewer.cpp
+@@ -210,7 +210,11 @@ void ThumbsViewer::updateImageInfoViewer(QString imageFullPath) {
+         infoView->addEntry(key, val);
+     }
+ 
++#if EXIV2_TEST_VERSION(0,28,0)
++    Exiv2::Image::UniquePtr exifImage;
++#else
+     Exiv2::Image::AutoPtr exifImage;
++#endif
+     try {
+         exifImage = Exiv2::ImageFactory::open(imageFullPath.toStdString());
+         exifImage->readMetadata();
+-- 
+2.40.1
+
diff --git a/srcpkgs/phototonic/template b/srcpkgs/phototonic/template
index 77ae8bf6a4406..4af006cb7da41 100644
--- a/srcpkgs/phototonic/template
+++ b/srcpkgs/phototonic/template
@@ -1,7 +1,7 @@
 # Template file for 'phototonic'
 pkgname=phototonic
 version=2.1
-revision=3
+revision=4
 build_style=qmake
 hostmakedepends="pkg-config qt5-qmake qt5-host-tools"
 makedepends="qt5-svg-devel exiv2-devel"

From cb66ea49338f8bc3cb3a085cf4e3150e4dc9bef4 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 18/24] qimgv: revbump for exiv2-0.28.1.

---
 srcpkgs/qimgv/patches/exiv2-0.28.patch | 16 ++++++++++++++++
 srcpkgs/qimgv/template                 |  2 +-
 2 files changed, 17 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/qimgv/patches/exiv2-0.28.patch

diff --git a/srcpkgs/qimgv/patches/exiv2-0.28.patch b/srcpkgs/qimgv/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..11f37b5ae2be3
--- /dev/null
+++ b/srcpkgs/qimgv/patches/exiv2-0.28.patch
@@ -0,0 +1,16 @@
+Patch-Source: https://git.alpinelinux.org/aports/tree/community/qimgv/exiv2-0.28.patch
+diff --git a/qimgv/sourcecontainers/documentinfo.cpp b/qimgv/sourcecontainers/documentinfo.cpp
+index 98a68f7..c062474 100644
+--- a/qimgv/sourcecontainers/documentinfo.cpp
++++ b/qimgv/sourcecontainers/documentinfo.cpp
+@@ -271,10 +271,6 @@ void DocumentInfo::loadExifTags() {
+         //std::cout << "Caught Exiv2 exception '" << e.what() << "'\n";
+         return;
+     }
+-    catch (Exiv2::BasicError<CharType> e) {
+-        //std::cout << "Caught BasicError Exiv2 exception '" << e.what() << "'\n";
+-        return;
+-    }
+ #endif
+ }
+ 
diff --git a/srcpkgs/qimgv/template b/srcpkgs/qimgv/template
index 7eb30db33992c..dd341dfe1bfce 100644
--- a/srcpkgs/qimgv/template
+++ b/srcpkgs/qimgv/template
@@ -1,7 +1,7 @@
 # Template file for 'qimgv'
 pkgname=qimgv
 version=1.0.2
-revision=2
+revision=3
 build_style=cmake
 configure_args="$(vopt_if video -DVIDEO_SUPPORT=ON -DVIDEO_SUPPORT=OFF)
  $(vopt_if scale -DOPENCV_SUPPORT=ON -DOPENCV_SUPPORT=OFF)

From ecce8eba56c822b789e6e28e2dab1e42e49ae65f Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 19/24] SIR: revbump for exiv2-0.28.1.

---
 srcpkgs/SIR/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/SIR/template b/srcpkgs/SIR/template
index 113077acad354..c6da4c26b6c71 100644
--- a/srcpkgs/SIR/template
+++ b/srcpkgs/SIR/template
@@ -1,7 +1,7 @@
 # Template file for 'SIR'
 pkgname=SIR
 version=3.2.2
-revision=1
+revision=2
 build_style=cmake
 hostmakedepends="pkg-config"
 makedepends="exiv2-devel qt5-svg-devel qt5-tools-devel"

From 49cfcfb22fbc985cd0cc51b7239aff3ea1fd7a5d Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 18 Oct 2023 19:18:40 +0100
Subject: [PATCH 20/24] viewnior: revbump for exiv2-0.28.1.

---
 srcpkgs/viewnior/patches/exiv2-0.28.patch | 147 ++++++++++++++++++++++
 srcpkgs/viewnior/template                 |   2 +-
 2 files changed, 148 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/viewnior/patches/exiv2-0.28.patch

diff --git a/srcpkgs/viewnior/patches/exiv2-0.28.patch b/srcpkgs/viewnior/patches/exiv2-0.28.patch
new file mode 100644
index 0000000000000..71459dee15768
--- /dev/null
+++ b/srcpkgs/viewnior/patches/exiv2-0.28.patch
@@ -0,0 +1,147 @@
+Patch-Source: https://gitlab.archlinux.org/archlinux/packaging/packages/viewnior/-/blob/f206ce6c22a3ec5f1f9ea1bde4077584f80458dd/exiv2-0.28.patch
+--
+From b6bb81a1b46e911d15bbf9a730972523de177705 Mon Sep 17 00:00:00 2001
+From: tastytea <tastytea@tastytea.de>
+Date: Tue, 16 May 2023 10:54:40 +0200
+Subject: [PATCH 1/2] change exiv2 AutoPtr to unique_ptr
+
+exiv2-0.28.0 removed Exiv2::Image::AutoPtr and added
+Exiv2::Image::UniquePtr instead. since it's a typedef for
+std::unique_ptr<Image>, i'm using that directly instead of adding a
+condition on the exiv2 version.
+---
+ src/uni-exiv2.cpp | 21 +++++++++++----------
+ 1 file changed, 11 insertions(+), 10 deletions(-)
+
+diff --git a/src/uni-exiv2.cpp b/src/uni-exiv2.cpp
+index 0d14b9f..77064c2 100644
+--- a/src/uni-exiv2.cpp
++++ b/src/uni-exiv2.cpp
+@@ -22,12 +22,13 @@
+ 
+ #include <exiv2/exiv2.hpp>
+ #include <iostream>
++#include <memory>
+ 
+ #include "uni-exiv2.hpp"
+ 
+ #define ARRAY_SIZE(array) (sizeof array/sizeof(array[0]))
+ 
+-static Exiv2::Image::AutoPtr cached_image;
++static std::unique_ptr<Exiv2::Image> cached_image;
+ 
+ extern "C"
+ void
+@@ -35,8 +36,8 @@ uni_read_exiv2_map(const char *uri, void (*callback)(const char*, const char*, v
+ {
+     Exiv2::LogMsg::setLevel(Exiv2::LogMsg::mute);
+     try {
+-        Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open(uri);
+-        if ( image.get() == 0 ) {
++        std::unique_ptr<Exiv2::Image> image = Exiv2::ImageFactory::open(uri);
++        if (image == nullptr) {
+             return;
+         }
+ 
+@@ -91,14 +92,14 @@ uni_read_exiv2_to_cache(const char *uri)
+ {
+     Exiv2::LogMsg::setLevel(Exiv2::LogMsg::mute);
+ 
+-    if ( cached_image.get() != NULL ) {
++    if (cached_image != nullptr) {
+         cached_image->clearMetadata();
+-        cached_image.reset(NULL);
++        cached_image.reset(nullptr);
+     }
+ 
+     try {
+         cached_image = Exiv2::ImageFactory::open(uri);
+-        if ( cached_image.get() == 0 ) {
++        if (cached_image == nullptr) {
+             return 1;
+         }
+ 
+@@ -116,13 +117,13 @@ uni_write_exiv2_from_cache(const char *uri)
+ {
+     Exiv2::LogMsg::setLevel(Exiv2::LogMsg::mute);
+ 
+-    if ( cached_image.get() == NULL ) {
++    if (cached_image == nullptr) {
+         return 1;
+     }
+ 
+     try {
+-        Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open(uri);
+-        if ( image.get() == 0 ) {
++        std::unique_ptr<Exiv2::Image> image = Exiv2::ImageFactory::open(uri);
++        if (image == nullptr) {
+             return 2;
+         }
+ 
+@@ -130,7 +131,7 @@ uni_write_exiv2_from_cache(const char *uri)
+         image->writeMetadata();
+ 
+         cached_image->clearMetadata();
+-        cached_image.reset(NULL);
++        cached_image.reset(nullptr);
+ 
+         return 0;
+     } catch (Exiv2::AnyError& e) {
+
+From 47d0b98cb46526aa8aa035bebcabc14a11fa57ee Mon Sep 17 00:00:00 2001
+From: tastytea <tastytea@tastytea.de>
+Date: Tue, 16 May 2023 11:17:00 +0200
+Subject: [PATCH 2/2] add support for exiv-0.28.0 errors
+
+exiv2-0.28.0 changed Exiv2::AnyError to Exiv2::Error.
+---
+ src/uni-exiv2.cpp | 15 ++++++++++++---
+ 1 file changed, 12 insertions(+), 3 deletions(-)
+
+diff --git a/src/uni-exiv2.cpp b/src/uni-exiv2.cpp
+index 77064c2..567a50f 100644
+--- a/src/uni-exiv2.cpp
++++ b/src/uni-exiv2.cpp
+@@ -28,6 +28,15 @@
+ 
+ #define ARRAY_SIZE(array) (sizeof array/sizeof(array[0]))
+ 
++#define EXIV_ERROR Exiv2::AnyError
++#ifdef EXIV2_VERSION
++    #ifdef EXIV2_TEST_VERSION
++        #if EXIV2_TEST_VERSION(0,28,0)
++            #define EXIV_ERROR Exiv2::Error
++        #endif
++    #endif
++#endif
++
+ static std::unique_ptr<Exiv2::Image> cached_image;
+ 
+ extern "C"
+@@ -81,7 +90,7 @@ uni_read_exiv2_map(const char *uri, void (*callback)(const char*, const char*, v
+                 }
+             }
+         }
+-    } catch (Exiv2::AnyError& e) {
++    } catch (EXIV_ERROR& e) {
+         std::cerr << "Exiv2: '" << e << "'\n";
+     }
+ }
+@@ -104,7 +113,7 @@ uni_read_exiv2_to_cache(const char *uri)
+         }
+ 
+         cached_image->readMetadata();
+-    } catch (Exiv2::AnyError& e) {
++    } catch (EXIV_ERROR& e) {
+         std::cerr << "Exiv2: '" << e << "'\n";
+     }
+ 
+@@ -134,7 +143,7 @@ uni_write_exiv2_from_cache(const char *uri)
+         cached_image.reset(nullptr);
+ 
+         return 0;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (EXIV_ERROR& e) {
+         std::cerr << "Exiv2: '" << e << "'\n";
+     }
+ 
diff --git a/srcpkgs/viewnior/template b/srcpkgs/viewnior/template
index ea1e528a8651f..4c73226662ca0 100644
--- a/srcpkgs/viewnior/template
+++ b/srcpkgs/viewnior/template
@@ -1,7 +1,7 @@
 # Template file for 'viewnior'
 pkgname=viewnior
 version=1.8
-revision=1
+revision=2
 build_style=meson
 hostmakedepends="pkg-config intltool glib-devel gettext-devel"
 makedepends="gtk+-devel exiv2-devel"

From 63df981be7eafc84b7313cc3e33713b8538ef97f Mon Sep 17 00:00:00 2001
From: John <me@johnnynator.dev>
Date: Mon, 23 Oct 2023 19:06:34 +0200
Subject: [PATCH 21/24] New package: nufraw-0.43.3

Co-authored-by: triallax <triallax@tutanota.com>
---
 srcpkgs/nufraw-gimp                           |  1 +
 .../patches/0001-nufraw-glib-2.70.patch       | 20 +++++++
 srcpkgs/nufraw/patches/exiv-0.28.x.diff       | 59 +++++++++++++++++++
 srcpkgs/nufraw/template                       | 56 ++++++++++++++++++
 srcpkgs/ufraw                                 |  1 +
 srcpkgs/ufraw-gimp                            |  2 +-
 .../ufraw/patches/001-no-gimp-remote.patch    | 12 ----
 srcpkgs/ufraw/patches/002-fix_abs_int.patch   | 11 ----
 .../ufraw/patches/03_fix-unsigned-char.patch  | 14 -----
 srcpkgs/ufraw/patches/exiv-0.27.patch         | 25 --------
 srcpkgs/ufraw/patches/glib-2.68.patch         | 30 ----------
 srcpkgs/ufraw/patches/iostream.patch          | 13 ----
 srcpkgs/ufraw/template                        | 38 ------------
 13 files changed, 138 insertions(+), 144 deletions(-)
 create mode 120000 srcpkgs/nufraw-gimp
 create mode 100644 srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch
 create mode 100644 srcpkgs/nufraw/patches/exiv-0.28.x.diff
 create mode 100644 srcpkgs/nufraw/template
 create mode 120000 srcpkgs/ufraw
 delete mode 100644 srcpkgs/ufraw/patches/001-no-gimp-remote.patch
 delete mode 100644 srcpkgs/ufraw/patches/002-fix_abs_int.patch
 delete mode 100644 srcpkgs/ufraw/patches/03_fix-unsigned-char.patch
 delete mode 100644 srcpkgs/ufraw/patches/exiv-0.27.patch
 delete mode 100644 srcpkgs/ufraw/patches/glib-2.68.patch
 delete mode 100644 srcpkgs/ufraw/patches/iostream.patch
 delete mode 100644 srcpkgs/ufraw/template

diff --git a/srcpkgs/nufraw-gimp b/srcpkgs/nufraw-gimp
new file mode 120000
index 0000000000000..0bd1459b2a16f
--- /dev/null
+++ b/srcpkgs/nufraw-gimp
@@ -0,0 +1 @@
+nufraw
\ No newline at end of file
diff --git a/srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch b/srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch
new file mode 100644
index 0000000000000..41f10bfbafa1f
--- /dev/null
+++ b/srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch
@@ -0,0 +1,20 @@
+diff -ru nufraw/uf_glib.h nufraw/uf_glib.h
+--- nufraw/uf_glib.h	2022-02-23 09:03:44.700472919 +0100
++++ nufraw/uf_glib.h	2022-02-23 09:04:50.260308805 +0100
+@@ -13,13 +13,13 @@
+ #ifndef _UF_GLIB_H
+ #define _UF_GLIB_H
+ 
++#include <glib.h>
++#include <glib/gstdio.h>
++
+ #ifdef __cplusplus
+ extern "C" {
+ #endif
+ 
+-#include <glib.h>
+-#include <glib/gstdio.h>
+-
+ // g_win32_locale_filename_from_utf8 is needed only on win32
+ #ifdef _WIN32
+ #define uf_win32_locale_filename_from_utf8(__some_string__) \
diff --git a/srcpkgs/nufraw/patches/exiv-0.28.x.diff b/srcpkgs/nufraw/patches/exiv-0.28.x.diff
new file mode 100644
index 0000000000000..6c23359bf706c
--- /dev/null
+++ b/srcpkgs/nufraw/patches/exiv-0.28.x.diff
@@ -0,0 +1,59 @@
+Patch taken from AUR package: https://aur.archlinux.org/cgit/aur.git/tree/exiv2-error.patch?h=nufraw&id=29e467f2c297fcd0f36548642d6d2cab6428d08f
+diff --git a/nufraw_exiv2.cc b/nufraw_exiv2.cc
+index 2de4cc3..45aea87 100644
+--- a/nufraw_exiv2.cc
++++ b/nufraw_exiv2.cc
+@@ -54,7 +54,7 @@ extern "C" int nufraw_exif_read_input(nufraw_data *uf)
+         uf->inputExifBuf = NULL;
+         uf->inputExifBufLen = 0;
+ 
+-        Exiv2::Image::AutoPtr image;
++        Exiv2::Image::UniquePtr image;
+         if (uf->unzippedBuf != NULL) {
+             image = Exiv2::ImageFactory::open(
+                         (const Exiv2::byte*)uf->unzippedBuf, uf->unzippedBufLen);
+@@ -135,7 +135,7 @@ extern "C" int nufraw_exif_read_input(nufraw_data *uf)
+         nufraw_message(NUFRAW_SET_LOG, "%s\n", stderror.str().c_str());
+ 
+         return NUFRAW_SUCCESS;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (Exiv2::Error& e) {
+         std::cerr.rdbuf(savecerr);
+         std::string s(e.what());
+         nufraw_message(NUFRAW_SET_WARNING, "%s\n", s.c_str());
+@@ -156,7 +156,7 @@ static Exiv2::ExifData nufraw_prepare_exifdata(nufraw_data *uf)
+         if ((pos = exifData.findKey(Exiv2::ExifKey("Exif.Image.Orientation")))
+                 != exifData.end()) {
+             nufraw_message(NUFRAW_SET_LOG, "Resetting %s from '%d' to '1'\n",
+-                          pos->key().c_str(), pos->value().toLong());
++                          pos->key().c_str(), pos->value().toInt64());
+             pos->setValue("1"); /* 1 = Normal orientation */
+         }
+     }
+@@ -327,7 +327,7 @@ extern "C" int nufraw_exif_prepare_output(nufraw_data *uf)
+         nufraw_message(NUFRAW_SET_LOG, "%s\n", stderror.str().c_str());
+ 
+         return NUFRAW_SUCCESS;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (Exiv2::Error& e) {
+         std::cerr.rdbuf(savecerr);
+         std::string s(e.what());
+         nufraw_message(NUFRAW_SET_WARNING, "%s\n", s.c_str());
+@@ -347,7 +347,7 @@ extern "C" int nufraw_exif_write(nufraw_data *uf)
+ 
+         char *filename =
+             uf_win32_locale_filename_from_utf8(uf->conf->outputFilename);
+-        Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open(filename);
++        Exiv2::Image::UniquePtr image = Exiv2::ImageFactory::open(filename);
+         uf_win32_locale_filename_free(filename);
+         assert(image.get() != 0);
+ 
+@@ -367,7 +367,7 @@ extern "C" int nufraw_exif_write(nufraw_data *uf)
+         nufraw_message(NUFRAW_SET_LOG, "%s\n", stderror.str().c_str());
+ 
+         return NUFRAW_SUCCESS;
+-    } catch (Exiv2::AnyError& e) {
++    } catch (Exiv2::Error& e) {
+         std::cerr.rdbuf(savecerr);
+         std::string s(e.what());
+         nufraw_message(NUFRAW_SET_WARNING, "%s\n", s.c_str());
diff --git a/srcpkgs/nufraw/template b/srcpkgs/nufraw/template
new file mode 100644
index 0000000000000..7d75a4d372555
--- /dev/null
+++ b/srcpkgs/nufraw/template
@@ -0,0 +1,56 @@
+# Template file for 'nufraw'
+pkgname=nufraw
+version=0.43.3
+revision=1
+_ver="${version%.*}-${version##*.}"
+build_style=gnu-configure
+configure_args="--enable-contrast --enable-mime --enable-openmp --with-gimp
+ --enable-extras"
+hostmakedepends="pkg-config automake libtool glib-devel"
+# libgexiv2-devel is only here to fix build order, remove on next template
+# change
+makedepends="exiv2-devel gimp-devel glib-devel gtkimageview-devel lcms2-devel
+ lensfun-devel jasper-devel libgexiv2-devel"
+depends="desktop-file-utils"
+short_desc="Utility to read and manipulate raw images from digital cameras"
+maintainer="John <me@johnnynator.dev>"
+license="GPL-2.0-or-later"
+homepage="https://sourceforge.net/projects/nufraw/"
+distfiles="${SOURCEFORGE_SITE}/nufraw/nufraw-${_ver}.tar.gz"
+checksum=2c7dcc1590993ec267b3112562b2433010d6f94f6acc6506c76aa29cf8c6c32c
+
+case "$XBPS_TARGET_MACHINE" in
+	armv[67]l* | aarch64*)
+		makedepends+=" libgomp-devel"
+		make_build_args="CXXFLAGS+=-fsigned-char LDFLAGS+=-fopenmp"
+		;;
+esac
+
+pre_configure() {
+	autoreconf -fi
+}
+
+pre_build() {
+	mv nufraw.desktop{.desktop,}
+	chmod +x generate_schemas.sh
+}
+
+nufraw-gimp_package() {
+	depends="${sourcepkg}>=${version}_${revision}"
+	short_desc+=" - gimp plugin"
+	pkg_install() {
+		vmove usr/lib/gimp
+	}
+}
+
+ufraw_package() {
+	depends="${sourcepkg}>=${version}_${revision}"
+	build_style=meta
+	short_desc+=" (transitional dummy package)"
+}
+
+ufraw-gimp_package() {
+	depends="nufraw-gimp>=${version}_${revision}"
+	build_style=meta
+	short_desc+=" - gimp plugin (transitional dummy package)"
+}
diff --git a/srcpkgs/ufraw b/srcpkgs/ufraw
new file mode 120000
index 0000000000000..0bd1459b2a16f
--- /dev/null
+++ b/srcpkgs/ufraw
@@ -0,0 +1 @@
+nufraw
\ No newline at end of file
diff --git a/srcpkgs/ufraw-gimp b/srcpkgs/ufraw-gimp
index 967dc902dd02b..0bd1459b2a16f 120000
--- a/srcpkgs/ufraw-gimp
+++ b/srcpkgs/ufraw-gimp
@@ -1 +1 @@
-ufraw
\ No newline at end of file
+nufraw
\ No newline at end of file
diff --git a/srcpkgs/ufraw/patches/001-no-gimp-remote.patch b/srcpkgs/ufraw/patches/001-no-gimp-remote.patch
deleted file mode 100644
index ca4f4beb6240f..0000000000000
--- a/srcpkgs/ufraw/patches/001-no-gimp-remote.patch
+++ /dev/null
@@ -1,12 +0,0 @@
-Don't use gimp-remote since gimp 2.4 already includes gimp-remote functionality
---- a/ufraw_conf.c
-+++ b/ufraw_conf.c
-@@ -137,7 +137,7 @@
- #elif HAVE_GIMP_2_4
-     "gimp", /* remoteGimpCommand */
- #else
--    "gimp-remote", /* remoteGimpCommand */
-+    "gimp", /* remoteGimpCommand */
- #endif
- 
-     /* EXIF data */
diff --git a/srcpkgs/ufraw/patches/002-fix_abs_int.patch b/srcpkgs/ufraw/patches/002-fix_abs_int.patch
deleted file mode 100644
index 6fc552769c9f8..0000000000000
--- a/srcpkgs/ufraw/patches/002-fix_abs_int.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- a/dcraw.cc	2015-06-16 05:58:38.000000000 +0200
-+++ b/dcraw.cc	2018-02-04 14:46:54.489951076 +0100
-@@ -9242,7 +9242,7 @@
-     if (make[0] == 'O') {
-       i = find_green (12, 32, 1188864, 3576832);
-       c = find_green (12, 32, 2383920, 2387016);
--      if (abs(i) < abs(c)) {
-+      if (abs((int)i) < abs((int)c)) {
- 	SWAP(i,c);
- 	load_flags = 24;
-       }
diff --git a/srcpkgs/ufraw/patches/03_fix-unsigned-char.patch b/srcpkgs/ufraw/patches/03_fix-unsigned-char.patch
deleted file mode 100644
index 8690f87ca7d59..0000000000000
--- a/srcpkgs/ufraw/patches/03_fix-unsigned-char.patch
+++ /dev/null
@@ -1,14 +0,0 @@
-Source: written by John Paul Adrian Glaubitz for Debian
-Upstream: https://sourceforge.net/p/ufraw/bugs/417
-Reason: fixes a compilation failure on arm architectures
---- a/dcraw.cc
-+++ b/dcraw.cc
-@@ -2285,7 +2285,7 @@ void CLASS quicktake_100_load_raw()
- 
- void CLASS kodak_radc_load_raw()
- {
--  static const char src[] = {
-+  static const signed char src[] = {
-     1,1, 2,3, 3,4, 4,2, 5,7, 6,5, 7,6, 7,8,
-     1,0, 2,1, 3,3, 4,4, 5,2, 6,7, 7,6, 8,5, 8,8,
-     2,1, 2,3, 3,0, 3,2, 3,4, 4,6, 5,5, 6,7, 6,8,
diff --git a/srcpkgs/ufraw/patches/exiv-0.27.patch b/srcpkgs/ufraw/patches/exiv-0.27.patch
deleted file mode 100644
index b5b4140fff8ed..0000000000000
--- a/srcpkgs/ufraw/patches/exiv-0.27.patch
+++ /dev/null
@@ -1,25 +0,0 @@
---- a/ufraw_exiv2.cc	2015-06-16 05:58:38.000000000 +0200
-+++ b/ufraw_exiv2.cc	2018-12-29 22:51:23.291894430 +0100
-@@ -15,9 +15,7 @@
- #include "ufraw.h"
- 
- #ifdef HAVE_EXIV2
--#include <exiv2/image.hpp>
--#include <exiv2/easyaccess.hpp>
--#include <exiv2/exif.hpp>
-+#include <exiv2/exiv2.hpp>
- #include <sstream>
- #include <cassert>
- 
-@@ -67,7 +65,11 @@
-         if (exifData.empty()) {
-             std::string error(uf->filename);
-             error += ": No Exif data found in the file";
-+#if EXIV2_TEST_VERSION(0,27,0)
-+            throw Exiv2::Error(Exiv2::kerErrorMessage, error);
-+#else
-             throw Exiv2::Error(1, error);
-+#endif
-         }
- 
-         /* List of tag names taken from exiv2's printSummary() in actions.cpp */
diff --git a/srcpkgs/ufraw/patches/glib-2.68.patch b/srcpkgs/ufraw/patches/glib-2.68.patch
deleted file mode 100644
index 5b61468f118aa..0000000000000
--- a/srcpkgs/ufraw/patches/glib-2.68.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-From c56f8be3caf1cf3d9a5c80597bdbaf1325faacc0 Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?S=C3=A9rgio=20M=2E=20Basto?= <sergio@serjux.com>
-Date: Tue, 13 Apr 2021 23:45:39 +0100
-Subject: [PATCH] Fix build against glib-2.68 fixes #10
-
----
- uf_glib.h | 6 +++---
- 1 file changed, 3 insertions(+), 3 deletions(-)
-
-diff --git a/uf_glib.h b/uf_glib.h
-index 21c10b19..56cd6971 100644
---- a/uf_glib.h
-+++ b/uf_glib.h
-@@ -13,13 +13,13 @@
- #ifndef _UF_GLIB_H
- #define _UF_GLIB_H
- 
-+#include <glib.h>
-+#include <glib/gstdio.h>
-+
- #ifdef __cplusplus
- extern "C" {
- #endif
- 
--#include <glib.h>
--#include <glib/gstdio.h>
--
- // g_win32_locale_filename_from_utf8 is needed only on win32
- #ifdef _WIN32
- #define uf_win32_locale_filename_from_utf8(__some_string__) \
diff --git a/srcpkgs/ufraw/patches/iostream.patch b/srcpkgs/ufraw/patches/iostream.patch
deleted file mode 100644
index 6d15869f63db8..0000000000000
--- a/srcpkgs/ufraw/patches/iostream.patch
+++ /dev/null
@@ -1,13 +0,0 @@
-ufraw_exiv2.cc:343:10: note: 'std::cerr' is defined in header '<iostream>'
-ufraw_exiv2.cc:365:14: error: 'cerr' is not a member of 'std'
-
---- a/ufraw_exiv2.cc
-+++ b/ufraw_exiv2.cc
-@@ -17,6 +17,7 @@
- #ifdef HAVE_EXIV2
- #include <exiv2/exiv2.hpp>
- #include <sstream>
-+#include <iostream>
- #include <cassert>
- 
- /*
diff --git a/srcpkgs/ufraw/template b/srcpkgs/ufraw/template
deleted file mode 100644
index ceddcacacefb2..0000000000000
--- a/srcpkgs/ufraw/template
+++ /dev/null
@@ -1,38 +0,0 @@
-# Template file for 'ufraw'
-pkgname=ufraw
-version=0.22
-revision=5
-build_style=gnu-configure
-configure_args="--enable-contrast --enable-mime --enable-openmp --with-gimp
- $(vopt_enable extras)"
-hostmakedepends="pkg-config dcraw gettext"
-makedepends="exiv2-devel gimp-devel glib-devel gtkimageview-devel lcms2-devel lensfun-devel
- jasper-devel"
-depends="desktop-file-utils"
-short_desc="Utility to read and manipulate raw images from digital cameras"
-maintainer="John <me@johnnynator.dev>"
-license="GPL-2.0-or-later"
-homepage="http://ufraw.sourceforge.net/"
-distfiles="${SOURCEFORGE_SITE}/ufraw/ufraw/ufraw-${version}/ufraw-${version}.tar.gz"
-checksum=f7abd28ce587db2a74b4c54149bd8a2523a7ddc09bedf4f923246ff0ae09a25e
-
-build_options="extras"
-
-post_patch() {
-	vsed -e 's/default(none)//g' \
-		-i dcraw_indi.c \
-		-i dcraw_api.cc \
-		-i ufraw_ufraw.c \
-		-i ufraw_developer.c
-	vsed -i -e '/DATADIRNAME=/s/=.*/=share/' configure
-	vsed -i -e "s,^localedir =.*,localedir = /usr/share/locale," \
-		po/Makefile.in.in
-}
-
-ufraw-gimp_package() {
-	depends="${sourcepkg}>=${version}_${revision}"
-	short_desc+=" - gimp plugin"
-	pkg_install() {
-		vmove usr/lib/gimp
-	}
-}

From 2f67f4fef7a4ffe3e44d76ba8b956af8e7f222bc Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 8 Nov 2023 12:53:45 +0000
Subject: [PATCH 22/24] krita: revbump for exiv2-0.28.1.

---
 srcpkgs/krita/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/krita/template b/srcpkgs/krita/template
index f4d665daf7c31..d804b581a8689 100644
--- a/srcpkgs/krita/template
+++ b/srcpkgs/krita/template
@@ -1,7 +1,7 @@
 # Template file for 'krita'
 pkgname=krita
 version=5.2.1
-revision=2
+revision=3
 build_style=cmake
 configure_args="-Wno-dev -DBUILD_TESTING=OFF"
 hostmakedepends="extra-cmake-modules gettext pkg-config python3

From ee9779ce2a4d6ddfc910915e5248a2f374010fed Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Wed, 8 Nov 2023 18:25:01 +0000
Subject: [PATCH 23/24] darktable: revbump for exiv2-0.28.1.

---
 srcpkgs/darktable/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/darktable/template b/srcpkgs/darktable/template
index f76936a1692e8..97dfae3471e7c 100644
--- a/srcpkgs/darktable/template
+++ b/srcpkgs/darktable/template
@@ -1,7 +1,7 @@
 # Template file for 'darktable'
 pkgname=darktable
 version=4.4.2
-revision=4
+revision=5
 # upstream only supports these archs:
 archs="x86_64* aarch64* ppc64le*"
 build_style=cmake

From 08086a52165fe6131b52dcbc63b10b9a12c80522 Mon Sep 17 00:00:00 2001
From: Mohammed Anas <triallax@tutanota.com>
Date: Sat, 18 Nov 2023 14:12:48 +0000
Subject: [PATCH 24/24] qgis: revbump for exiv2-0.28.1.

---
 srcpkgs/qgis/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/qgis/template b/srcpkgs/qgis/template
index d12cf9b841f1f..0ea9f5233a042 100644
--- a/srcpkgs/qgis/template
+++ b/srcpkgs/qgis/template
@@ -1,7 +1,7 @@
 # Template file for 'qgis'
 pkgname=qgis
 version=3.34.0
-revision=1
+revision=2
 build_style=cmake
 configure_args="-DENABLE_TESTS=OFF -DWITH_3D=True -DWITH_PDAL=True
  -DGRASS_PREFIX8=${XBPS_CROSS_BASE}/usr/lib/grass"

^ permalink raw reply	[flat|nested] 27+ messages in thread

* Re: [PR PATCH] [Merged]: exiv2: update to 0.28.1.
  2023-10-23  0:10 [PR PATCH] exiv2: update to 0.28.0 mhmdanas
                   ` (24 preceding siblings ...)
  2023-11-18 15:57 ` [PR PATCH] [Updated] " mhmdanas
@ 2023-11-18 21:41 ` classabbyamp
  25 siblings, 0 replies; 27+ messages in thread
From: classabbyamp @ 2023-11-18 21:41 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 1923 bytes --]

There's a merged pull request on the void-packages repository

exiv2: update to 0.28.1.
https://github.com/void-linux/void-packages/pull/46838

Description:
<!-- Uncomment relevant sections and delete options which are not applicable -->

#### Testing the changes
- I tested the changes in this PR: **briefly**

TODO:
- [x] Fix `gwenview`'s failed checks (not really fixed but the exact same tests fail on master as well)
- [x] `test_exiv2` fails for `libextractor`
- [x] `kfilemetadata5` tests fail (same tests fail on master)
- [x] Fix `nufraw` cross-build
- [x] `digikam` fails to build

@Johnnynator ufraw has been [unmaintained since December 2016](https://sourceforge.net/p/ufraw/discussion/434060/thread/30b4249b/), and it doesn't build with this PR; here are the options:
- remove the package entirely
- replace it with the newer [nufraw](https://sourceforge.net/projects/nufraw/), which already has [an exiv 0.28.x patch floating around](https://aur.archlinux.org/cgit/aur.git/tree/exiv2-error.patch?h=nufraw)
- patch it to build with this PR

What do you think? (edit: `nufraw` now replaces `ufraw` in this PR)

<!--
#### New package
- This new package conforms to the [package requirements](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTItest_exiv2NG.md#package-requirements): **YES**|**NO**
-->

<!-- Note: If the build is likely to take more than 2 hours, please add ci skip tag as described in
https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration
and test at least one native build and, if supported, at least one cross build.
Ignore this section if this PR is not skipping CI.
-->
<!--
#### Local build testing
- I built this PR locally for my native architecture, (ARCH-LIBC)
- I built this PR locally for these architectures (if supported. mark crossbuilds):
  - aarch64-musl
  - armv7l
  - armv6l-musl
-->


^ permalink raw reply	[flat|nested] 27+ messages in thread

end of thread, other threads:[~2023-11-18 21:41 UTC | newest]

Thread overview: 27+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-10-23  0:10 [PR PATCH] exiv2: update to 0.28.0 mhmdanas
2023-10-23  0:20 ` [PR PATCH] [Updated] " mhmdanas
2023-11-01 17:23 ` mhmdanas
2023-11-01 17:26 ` mhmdanas
2023-11-01 18:11 ` mhmdanas
2023-11-02 19:42 ` biopsin
2023-11-03 20:00 ` [PR PATCH] [Updated] " mhmdanas
2023-11-03 20:18 ` mhmdanas
2023-11-04 21:57 ` [PR PATCH] [Updated] " mhmdanas
2023-11-06 20:17 ` mhmdanas
2023-11-06 20:18 ` mhmdanas
2023-11-06 20:19 ` mhmdanas
2023-11-06 20:20 ` mhmdanas
2023-11-12 13:04 ` biopsin
2023-11-12 15:01 ` mhmdanas
2023-11-12 22:54 ` [PR PATCH] [Updated] " mhmdanas
2023-11-12 22:55 ` exiv2: update to 0.28.1 mhmdanas
2023-11-13  0:00 ` [PR PATCH] [Updated] " mhmdanas
2023-11-15 17:40 ` mhmdanas
2023-11-15 17:57 ` mhmdanas
2023-11-16 15:12 ` [PR REVIEW] " sh1r4s3
2023-11-16 15:56 ` mhmdanas
2023-11-16 16:43 ` sh1r4s3
2023-11-16 21:50 ` [PR PATCH] [Updated] " mhmdanas
2023-11-16 21:51 ` [PR REVIEW] " mhmdanas
2023-11-18 15:57 ` [PR PATCH] [Updated] " mhmdanas
2023-11-18 21:41 ` [PR PATCH] [Merged]: " classabbyamp

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).