Date: Tue, 10 Jan 2023 16:42:38 GMT From: "Tobias C. Berner" <tcberner@FreeBSD.org> To: ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org Subject: git: 49c02cde16e2 - main - deskutils/kodaskanna: prepare for textproc/zxing-cpp 2.0.0 Message-ID: <202301101642.30AGgcuf038177@gitrepo.freebsd.org>
next in thread | raw e-mail | index | archive | help
The branch main has been updated by tcberner: URL: https://cgit.FreeBSD.org/ports/commit/?id=49c02cde16e2518fafc37e7025ac1ec0bda70aad commit 49c02cde16e2518fafc37e7025ac1ec0bda70aad Author: Tobias C. Berner <tcberner@FreeBSD.org> AuthorDate: 2023-01-10 09:07:41 +0000 Commit: Tobias C. Berner <tcberner@FreeBSD.org> CommitDate: 2023-01-10 16:41:14 +0000 deskutils/kodaskanna: prepare for textproc/zxing-cpp 2.0.0 --- deskutils/kodaskanna/Makefile | 5 +++- deskutils/kodaskanna/distinfo | 4 +++- .../files/patch-src_core_scanimagerunner.cpp | 27 ++++++++++++++++++++++ 3 files changed, 34 insertions(+), 2 deletions(-) diff --git a/deskutils/kodaskanna/Makefile b/deskutils/kodaskanna/Makefile index 7ac0951748bc..11db8dff00c5 100644 --- a/deskutils/kodaskanna/Makefile +++ b/deskutils/kodaskanna/Makefile @@ -4,6 +4,9 @@ PORTREVISION= 1 CATEGORIES= deskutils MASTER_SITES= KDE/unstable/${PORTNAME}/${DISTVERSION}/src +PATCH_SITES= https://invent.kde.org/graphics/kodaskanna/-/commit/ +PATCHFILES= 1656f7e66aec20ecd4a66f041bd7fc1850721e08.diff:-p1 + MAINTAINER= adridg@FreeBSD.org COMMENT= Barcode and QR-code scanner WWW= https://invent.kde.org/graphics/kodaskanna @@ -11,7 +14,7 @@ WWW= https://invent.kde.org/graphics/kodaskanna LICENSE= LGPL21+ LICENSE_FILE= ${WRKSRC}/LICENSES/LGPL-2.1-or-later.txt -LIB_DEPENDS= libZXing.so.1:textproc/zxing-cpp +LIB_DEPENDS= libZXing.so:textproc/zxing-cpp USES= cmake compiler:c++17-lang gl kde:5 pkgconfig qt:5 tar:xz xorg USE_GL= gl diff --git a/deskutils/kodaskanna/distinfo b/deskutils/kodaskanna/distinfo index 7067c1949065..67b6e541e78d 100644 --- a/deskutils/kodaskanna/distinfo +++ b/deskutils/kodaskanna/distinfo @@ -1,3 +1,5 @@ -TIMESTAMP = 1643278462 +TIMESTAMP = 1673343046 SHA256 (kodaskanna-0.1.0.tar.xz) = 2860cfdae922a29749421f3b4e3281ef88fc5713002345bc725082fb47cd627f SIZE (kodaskanna-0.1.0.tar.xz) = 40656 +SHA256 (1656f7e66aec20ecd4a66f041bd7fc1850721e08.diff) = 198a2f22fd574bb6a9e4b02406d04847921caacf9c709f974f1e9025438940a5 +SIZE (1656f7e66aec20ecd4a66f041bd7fc1850721e08.diff) = 463 diff --git a/deskutils/kodaskanna/files/patch-src_core_scanimagerunner.cpp b/deskutils/kodaskanna/files/patch-src_core_scanimagerunner.cpp new file mode 100644 index 000000000000..8d3133a58c2d --- /dev/null +++ b/deskutils/kodaskanna/files/patch-src_core_scanimagerunner.cpp @@ -0,0 +1,27 @@ +--- src/core/scanimagerunner.cpp.orig 2022-01-24 22:35:35 UTC ++++ src/core/scanimagerunner.cpp +@@ -10,6 +10,9 @@ + #include "scanresult.hpp" + #include "scanresult_p.hpp" + // ZXing ++#include <ZXing/ZXVersion.h> ++#define ZXING_VERSION \ ++ QT_VERSION_CHECK(ZXING_VERSION_MAJOR, ZXING_VERSION_MINOR, ZXING_VERSION_PATCH) + #include <ZXing/ReadBarcode.h> + + namespace Kodaskanna +@@ -63,8 +66,13 @@ void ScanImageRunner::run() + + resultData->isSuccess = result.isValid(); + if (resultData->isSuccess) { +- resultData->text = QString::fromStdWString(result.text()); ++#if ZXING_VERSION < QT_VERSION_CHECK(2, 0, 0) ++ resultData->text = QString::fromStdWString(result.text()); + resultData->bytes = QByteArray(reinterpret_cast<const char *>(result.rawBytes().data()), result.rawBytes().size()); ++#else ++ resultData->text = QString::fromStdString(result.text()); ++ resultData->bytes = QByteArray(reinterpret_cast<const char *>(result.bytes().data()), result.bytes().size()); ++#endif + } + + Q_EMIT scanFinished(scanResult);
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202301101642.30AGgcuf038177>