Script 'mail_helper' called by obssrc Hello community, here is the log from the commit of package krename for openSUSE:Factory checked in at 2023-07-04 15:22:38 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/krename (Old) and /work/SRC/openSUSE:Factory/.krename.new.23466 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "krename" Tue Jul 4 15:22:38 2023 rev:42 rq:1096668 version:5.0.2 Changes: -------- --- /work/SRC/openSUSE:Factory/krename/krename.changes 2022-09-06 13:01:32.739044629 +0200 +++ /work/SRC/openSUSE:Factory/.krename.new.23466/krename.changes 2023-07-04 15:23:33.902632949 +0200 @@ -1,0 +2,6 @@ +Tue Jul 4 06:37:49 UTC 2023 - Christophe Marin <christo...@krop.fr> + +- Add patch: + * 0001-Fix-build-with-exiv2-0.28-raise-minimum-to-0.27.patch + +------------------------------------------------------------------- New: ---- 0001-Fix-build-with-exiv2-0.28-raise-minimum-to-0.27.patch ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ krename.spec ++++++ --- /var/tmp/diff_new_pack.2kBFWE/_old 2023-07-04 15:23:34.574636987 +0200 +++ /var/tmp/diff_new_pack.2kBFWE/_new 2023-07-04 15:23:34.586637059 +0200 @@ -30,6 +30,9 @@ Patch0: servicemenus-files.patch # PATCH-FIX-UPSTREAM remove-gplv2-code.diff dmuel...@suse.de -- Remove GPLv2 only code (only used for self-testing) Patch1: remove-gplv2-code.diff +%if 0%{?suse_version} > 1500 || 0%{?sle_version} > 150400 +Patch2: 0001-Fix-build-with-exiv2-0.28-raise-minimum-to-0.27.patch +%endif BuildRequires: extra-cmake-modules BuildRequires: freetype2-devel BuildRequires: libexiv2-devel ++++++ 0001-Fix-build-with-exiv2-0.28-raise-minimum-to-0.27.patch ++++++ >From 0d4127ce11c460809352dcbeeec78065f99e7a38 Mon Sep 17 00:00:00 2001 From: Andreas Sturmlechner <ast...@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 <ast...@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 cc9df14..a696009 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -54,13 +54,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 2c23d5a..258471e 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 43633c6..4d24b19 100644 --- a/src/exiv2plugin.cpp +++ b/src/exiv2plugin.cpp @@ -17,20 +17,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" @@ -395,7 +384,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(); -- 2.41.0