KDE Release Gear 22.08 RC

OBS-URL: https://build.opensuse.org/package/show/KDE:Applications/kitinerary?expand=0&rev=145
This commit is contained in:
Christophe Giboudeaux 2022-08-09 14:12:40 +00:00 committed by Git OBS Bridge
parent 74ff124cf3
commit 75760cd9d6
7 changed files with 37 additions and 92 deletions

View File

@ -1,68 +0,0 @@
From b08fd64711165c10bf1e88e6add4e66f68e32dc5 Mon Sep 17 00:00:00 2001
From: Volker Krause <vkrause@kde.org>
Date: Fri, 8 Jul 2022 16:04:19 +0200
Subject: [PATCH] Support ZXing 1.4.0
The previous code crashes (if it builds at all) with ZXing 1.4.0, so
distributions updating to 1.4.0 would need to apply this patch on top
of 22.04.3 as well.
(cherry picked from commit e60195421aa159462353892ed32bf46ac8c57d19)
---
src/lib/barcodedecoder.cpp | 26 ++++++++++++++++++++++++++
1 file changed, 26 insertions(+)
diff --git a/src/lib/barcodedecoder.cpp b/src/lib/barcodedecoder.cpp
index b38140a..40e0c64 100644
--- a/src/lib/barcodedecoder.cpp
+++ b/src/lib/barcodedecoder.cpp
@@ -15,6 +15,7 @@
#include <QString>
#ifdef HAVE_ZXING
+#define ZX_USE_UTF8 1
#ifdef ZXING_USE_READBARCODE
#include <ZXing/ReadBarcode.h>
#else
@@ -244,6 +245,30 @@ void BarcodeDecoder::decodeZxing(const QImage &img, BarcodeDecoder::BarcodeTypes
#endif
if (res.isValid()) {
+#if ZXING_VERSION >= QT_VERSION_CHECK(1, 4, 0)
+ // detect content type
+ std::string zxUtf8Text;
+ if (res.contentType() == ZXing::ContentType::Text) {
+ result.contentType = Result::Any;
+ zxUtf8Text = res.text();
+ // check if the text is ASCII-only (in which case we allow access as byte array as well)
+ if (std::any_of(zxUtf8Text.begin(), zxUtf8Text.end(), [](unsigned char c) { return c > 0x7F; })) {
+ result.contentType &= ~Result::ByteArray;
+ }
+ } else {
+ result.contentType = Result::ByteArray;
+ }
+
+ // decode content
+ if (result.contentType & Result::ByteArray) {
+ QByteArray b;
+ b.resize(res.bytes().size());
+ std::copy(res.bytes().begin(), res.bytes().end(), b.begin());
+ result.content = b;
+ } else {
+ result.content = QString::fromStdString(zxUtf8Text);
+ }
+#else
// detect content type
result.contentType = Result::Any;
if (std::any_of(res.text().begin(), res.text().end(), [](const auto c) { return c > 255; })) {
@@ -262,6 +287,7 @@ void BarcodeDecoder::decodeZxing(const QImage &img, BarcodeDecoder::BarcodeTypes
} else {
result.content = QString::fromStdWString(res.text());
}
+#endif
result.positive |= formatToType(res.format());
} else {
result.negative |= format;
--
2.36.1

View File

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:9fc6970e633584c88c5283dd2a5d3a4638f704439229abd9c6267d907a6ab3cb
size 1530056

View File

@ -1,16 +0,0 @@
-----BEGIN PGP SIGNATURE-----
iQIzBAABCgAdFiEE2BwMs463Je9mkcOFu0YzUNbvMe8FAmLDwVkACgkQu0YzUNbv
Me+VBxAAiO6fzhY5lwELKO7rL8LJTsFCanUaDYEtZr3kniTZDkihGfUg7nNLUYB0
0CLjOq3UhVwsfii+GxaJSPa7bULJnbdSa7vv9kQe0oYDptTLhKBvAn1yxtNB544c
a3MdiHICUDRcop33bxHaR9DBFtFCynDQnmQiDYtzfXxaV5CMPvu+PWDDuAf3oaKp
MNVBxyfIviZQ7Qq3OgHQGY5eZKeAPcvkt8FcmO3U3NGrrgyR6wzigm7qLIiqM1AR
/g45/nYZ6HRu7eClHuOlvHolVWx4K79jYMKnDmCObFLqRfXCiu1hLstFbjGwl42u
yWBLyTnYuPZrbmo6N1OPm984KiGsItwQNRXpVgBTwHP9ggZltpFX4B/6UTLhE5Y3
5CvT1AnYgjDXy5JnME+kmrCShZmS/BRpVDOv3HSmc1W/1bb/RHpJx9w7srGd400f
olmCLCt+0QCciQ8V7fPHSXudpKYCpzSKMCb7mBzbPVkSM4FTUF0ITd1jjsrCP/vZ
o3CZgpfO1nQxaX9nx5VYdmjsAKmh7KeAJVnnu1FxlcTgVzEruHa3eRG9RxhGl674
TRWbHerwi0LS6w9Eo9WufMYScDc2HAkMcjMqVfUfNnyH+6aMg5faclmmTmz4emtZ
e517USzUz/zqZY7OS+eRgKeLhZBvOIDSr+tfZdTFwnuwDxxKTyw=
=Wqvl
-----END PGP SIGNATURE-----

View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:df810bbad8131d83f1ad6dd6b191ebcf53910741eaa8a42659974481e217beb9
size 1689820

View File

@ -0,0 +1,16 @@
-----BEGIN PGP SIGNATURE-----
iQIzBAABCgAdFiEE2BwMs463Je9mkcOFu0YzUNbvMe8FAmLsYkUACgkQu0YzUNbv
Me/+fw//XbyWtmDcrTSMGgxdeCNLb98ueXsyHanzipJ/zUBZwMGt/FS5/HGBz0Nr
LrzdK9Zy74FQitpqrpunpG1cqf35ZNy8kSrlAKOSNVUJkhYxgAisCbdg6SOE6CA5
Yt5TPWaIMX3V5ciDMU6GUDa6Xch3a1wbJBjKvBFuskEoKo9LqlbYU4jQEx3O5irV
HFHKiZRFZTcQmeZ6AqrShzYwmkUDFoyd+hNDRYO5wz5EEyPGj8QCWkwtmbsSkaO+
bQ3y2R1TI/f18OH483lk/yoOut6F1XredZoA+AJf2FC3Et2E8rRJhw+/QMhSbNU2
QUHHtrWvp/uFAv2VUkOGthrMaJ4ul1BK5rs8hRbUHFM7PwHxsOMMzBBtngPCc213
1eWNiyncm6F0OCiaFZYK9kmCRmRFyw8QWjXJZOdUQ3Cbal8u7ZME+w7j8Moqrstv
R/xNizzv274wWwAGzwKx6ou4bjVpHkSROoNSJutnQbAILkkQYazl2qmLDo51tgUy
4rHJR1C8PN4A1ZXIRDMFyDg6MDfIL/4xSDrwb8B6HK8MKlGVlfhikmtJJFSE4387
XIHQlM01FXLQ1C7E1g+n7wvVGX+GZd9fynbGJit4uX7smK3UppRjYHvRYK4zacnX
6DuN3RBa96Pg+nLFF0C4BsoiMsG4Xu0B5hAfNrsvRBdUasPxkOk=
=9hUf
-----END PGP SIGNATURE-----

View File

@ -1,9 +1,24 @@
-------------------------------------------------------------------
Fri Aug 5 12:10:58 UTC 2022 - Christophe Giboudeaux <christophe@krop.fr>
- Update to 22.07.90
* New feature release
- Drop patch, now upstream:
* 0001-Support-ZXing-1.4.0.patch
------------------------------------------------------------------- -------------------------------------------------------------------
Wed Jul 20 16:24:51 UTC 2022 - Fabian Vogt <fabian@ritter-vogt.de> Wed Jul 20 16:24:51 UTC 2022 - Fabian Vogt <fabian@ritter-vogt.de>
- Add patch to fix build with ZXing 1.4.0: - Add patch to fix build with ZXing 1.4.0:
* 0001-Support-ZXing-1.4.0.patch * 0001-Support-ZXing-1.4.0.patch
-------------------------------------------------------------------
Sat Jul 16 08:28:12 UTC 2022 - Christophe Giboudeaux <christophe@krop.fr>
- Update to 22.07.80
* New feature release
------------------------------------------------------------------- -------------------------------------------------------------------
Tue Jul 5 17:03:22 UTC 2022 - Christophe Giboudeaux <christophe@krop.fr> Tue Jul 5 17:03:22 UTC 2022 - Christophe Giboudeaux <christophe@krop.fr>

View File

@ -18,19 +18,17 @@
%bcond_without released %bcond_without released
Name: kitinerary Name: kitinerary
Version: 22.04.3 Version: 22.07.90
Release: 0 Release: 0
Summary: Data model and extraction system for travel reservations Summary: Data model and extraction system for travel reservations
License: LGPL-2.1-or-later License: LGPL-2.1-or-later
Group: System/GUI/KDE Group: System/GUI/KDE
URL: https://www.kde.org URL: https://www.kde.org
Source: https://download.kde.org/stable/release-service/%{version}/src/%{name}-%{version}.tar.xz Source: https://download.kde.org/unstable/release-service/%{version}/src/%{name}-%{version}.tar.xz
%if %{with released} %if %{with released}
Source1: https://download.kde.org/stable/release-service/%{version}/src/%{name}-%{version}.tar.xz.sig Source1: https://download.kde.org/unstable/release-service/%{version}/src/%{name}-%{version}.tar.xz.sig
Source2: applications.keyring Source2: applications.keyring
%endif %endif
# PATCH-FIX-UPSTREAM
Patch1: 0001-Support-ZXing-1.4.0.patch
BuildRequires: extra-cmake-modules BuildRequires: extra-cmake-modules
BuildRequires: kf5-filesystem BuildRequires: kf5-filesystem
BuildRequires: libopenssl-devel BuildRequires: libopenssl-devel