Script 'mail_helper' called by obssrc Hello community, here is the log from the commit of package kaidan for openSUSE:Factory checked in at 2023-02-09 16:23:21 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/kaidan (Old) and /work/SRC/openSUSE:Factory/.kaidan.new.4462 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "kaidan" Thu Feb 9 16:23:21 2023 rev:2 rq:1063958 version:0.8.0 Changes: -------- --- /work/SRC/openSUSE:Factory/kaidan/kaidan.changes 2022-07-28 20:58:18.747513123 +0200 +++ /work/SRC/openSUSE:Factory/.kaidan.new.4462/kaidan.changes 2023-02-09 16:23:22.198763345 +0100 @@ -1,0 +2,8 @@ +Thu Feb 9 08:09:58 UTC 2023 - Christophe Marin <[email protected]> + +- Add patches to fix build with ZXing >= 2.0: + * 0001-QrCodeDecoder-Replace-deprecated-BarcodeFormat-QR_CO.patch + * 0001-QrCodeGenerator-Replace-deprecated-BarcodeFormat-QR_.patch + * 0001-Support-ZXing-2.0.patch + +------------------------------------------------------------------- New: ---- 0001-QrCodeDecoder-Replace-deprecated-BarcodeFormat-QR_CO.patch 0001-QrCodeGenerator-Replace-deprecated-BarcodeFormat-QR_.patch 0001-Support-ZXing-2.0.patch ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ kaidan.spec ++++++ --- /var/tmp/diff_new_pack.idoAfE/_old 2023-02-09 16:23:22.658765715 +0100 +++ /var/tmp/diff_new_pack.idoAfE/_new 2023-02-09 16:23:22.662765735 +0100 @@ -1,7 +1,7 @@ # # spec file for package kaidan # -# Copyright (c) 2021 SUSE LLC +# Copyright (c) 2023 SUSE LLC # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -21,11 +21,16 @@ Release: 0 Summary: A XMPP client based on KDE Framework License: GPL-3.0-or-later AND SUSE-GPL-3.0+-with-openssl-exception AND MIT AND AML AND CC-BY-SA-4.0 -Group: Productivity/Networking/Instant Messenger URL: https://www.kaidan.im Source0: https://download.kde.org/unstable/%{name}/%{version}/%{name}-%{version}.tar.xz Source1: https://download.kde.org/unstable/%{name}/%{version}/%{name}-%{version}.tar.xz.sig Source2: kaidan.keyring +# PATCH-FIX-UPSTREAM +Patch0: 0001-QrCodeDecoder-Replace-deprecated-BarcodeFormat-QR_CO.patch +# PATCH-FIX-UPSTREAM +Patch1: 0001-QrCodeGenerator-Replace-deprecated-BarcodeFormat-QR_.patch +# PATCH-FIX-UPSTREAM +Patch2: 0001-Support-ZXing-2.0.patch BuildRequires: cmake >= 3.3 BuildRequires: extra-cmake-modules >= 5.40.0 BuildRequires: update-desktop-files ++++++ 0001-QrCodeDecoder-Replace-deprecated-BarcodeFormat-QR_CO.patch ++++++ >From 9a2f88779064b46ae097a354c97d657901f47d01 Mon Sep 17 00:00:00 2001 From: Melvin Keskin <[email protected]> Date: Fri, 18 Feb 2022 10:48:46 +0100 Subject: [PATCH] QrCodeDecoder: Replace deprecated 'BarcodeFormat::QR_CODE' with 'BarcodeFormat::QRCode' --- src/QrCodeDecoder.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/QrCodeDecoder.cpp b/src/QrCodeDecoder.cpp index a84978f..a7b0cf5 100644 --- a/src/QrCodeDecoder.cpp +++ b/src/QrCodeDecoder.cpp @@ -60,7 +60,11 @@ void QrCodeDecoder::decodeImage(const QImage &image) { // Advise the decoder to check for QR codes and to try decoding rotated versions of the image. #if ZXING_VERSION >= QT_VERSION_CHECK(1, 1, 0) +# if ZXING_VERSION >= QT_VERSION_CHECK(1, 1, 1) + const auto decodeHints = DecodeHints().setFormats(BarcodeFormat::QRCode); +# else const auto decodeHints = DecodeHints().setFormats(BarcodeFormat::QR_CODE); +# endif const auto result = ReadBarcode({image.bits(), image.width(), image.height(), ZXing::ImageFormat::Lum, image.bytesPerLine()}, decodeHints); #else const auto decodeHints = -- 2.39.1 ++++++ 0001-QrCodeGenerator-Replace-deprecated-BarcodeFormat-QR_.patch ++++++ >From dc41a3f3850308d5204134ae08e66f20a58195f9 Mon Sep 17 00:00:00 2001 From: Melvin Keskin <[email protected]> Date: Sun, 13 Mar 2022 13:03:16 +0100 Subject: [PATCH] QrCodeGenerator: Replace deprecated 'BarcodeFormat::QR_CODE' with 'BarcodeFormat::QRCode' --- src/QrCodeGenerator.cpp | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/QrCodeGenerator.cpp b/src/QrCodeGenerator.cpp index b9c8743..1338308 100644 --- a/src/QrCodeGenerator.cpp +++ b/src/QrCodeGenerator.cpp @@ -33,6 +33,10 @@ #include <QImage> #include <QRgb> +#include <ZXing/ZXVersion.h> +#define ZXING_VERSION \ + QT_VERSION_CHECK(ZXING_VERSION_MAJOR, ZXING_VERSION_MINOR, ZXING_VERSION_PATCH) + #include <ZXing/BarcodeFormat.h> #include <ZXing/MultiFormatWriter.h> @@ -74,7 +78,11 @@ QImage QrCodeGenerator::generateBareJidQrCode(int edgePixelCount, const QString QImage QrCodeGenerator::generateQrCode(int edgePixelCount, const QString &text) { try { +#if ZXING_VERSION >= QT_VERSION_CHECK(1, 1, 1) + ZXing::MultiFormatWriter writer(ZXing::BarcodeFormat::QRCode); +#else ZXing::MultiFormatWriter writer(ZXing::BarcodeFormat::QR_CODE); +#endif const ZXing::BitMatrix &bitMatrix = writer.encode(text.toStdWString(), edgePixelCount, edgePixelCount); return toImage(bitMatrix); } catch (const std::invalid_argument &e) { -- 2.39.1 ++++++ 0001-Support-ZXing-2.0.patch ++++++ >From c92fe3125c08e61b454b41f151b435a6a9e6da4b Mon Sep 17 00:00:00 2001 From: Volker Krause <[email protected]> Date: Wed, 4 Jan 2023 17:28:31 +0100 Subject: [PATCH] Support ZXing 2.0 An alternative approach going forward might be replacing the entire direct ZXing use and video stream processing by KF::Prison. Avoids duplicated maintenance, but adds a new dependency. --- src/QrCodeDecoder.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/QrCodeDecoder.cpp b/src/QrCodeDecoder.cpp index a7b0cf5..86d1e7b 100644 --- a/src/QrCodeDecoder.cpp +++ b/src/QrCodeDecoder.cpp @@ -90,7 +90,11 @@ void QrCodeDecoder::decodeImage(const QImage &image) // If a QR code could be found and decoded, emit a signal with the decoded string. // Otherwise, emit a signal for failed decoding. if (result.isValid()) +#if ZXING_VERSION < QT_VERSION_CHECK(2, 0, 0) emit decodingSucceeded(QString::fromStdString(TextUtfEncoding::ToUtf8(result.text()))); +#else + emit decodingSucceeded(QString::fromStdString(result.text())); +#endif else emit decodingFailed(); } -- 2.39.1
