summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexey Shvetsov <alexxy@gentoo.org>2024-02-24 14:09:58 +0300
committerAlexey Shvetsov <alexxy@gentoo.org>2024-02-24 14:13:33 +0300
commit3521346f75b35bd657d18ec59049813314752ad4 (patch)
tree7d72b00f839be2cec98dc4994da245a0e9536bc4 /media-libs
parentmedia-libs/kcolorpicker: add 0.3.0 (diff)
downloadgentoo-3521346f75b35bd657d18ec59049813314752ad4.tar.gz
gentoo-3521346f75b35bd657d18ec59049813314752ad4.tar.bz2
gentoo-3521346f75b35bd657d18ec59049813314752ad4.zip
media-libs/kimageannotator: Version bump and restrict deps
Signed-off-by: Alexey Shvetsov <alexxy@gentoo.org>
Diffstat (limited to 'media-libs')
-rw-r--r--media-libs/kimageannotator/Manifest1
-rw-r--r--media-libs/kimageannotator/files/kimageannotator-0.7.0-fix-qt6-tests.patch117
-rw-r--r--media-libs/kimageannotator/kimageannotator-0.6.0.ebuild3
-rw-r--r--media-libs/kimageannotator/kimageannotator-0.6.1.ebuild3
-rw-r--r--media-libs/kimageannotator/kimageannotator-0.7.0.ebuild53
-rw-r--r--media-libs/kimageannotator/metadata.xml7
6 files changed, 182 insertions, 2 deletions
diff --git a/media-libs/kimageannotator/Manifest b/media-libs/kimageannotator/Manifest
index 2abeecfad611..bcf546abf17a 100644
--- a/media-libs/kimageannotator/Manifest
+++ b/media-libs/kimageannotator/Manifest
@@ -1,2 +1,3 @@
DIST kImageAnnotator-0.6.0.tar.gz 257662 BLAKE2B 3736d0e862f1d3f3f9728e4d4d611c7e406d40fe022a2441b1a80355997d86a194064ecade63b7657d3cbf1f63364b8b74654d9c92d809ac056b7dc999d97415 SHA512 5782acd552af2297813164c0612810ec0d2127c174773040d99ec9d281f3575832b06667736a5521e88fa2d57ea6410e42a5d95232cb2dbdd9608917e5d6e896
DIST kImageAnnotator-0.6.1.tar.gz 264176 BLAKE2B dfbfb50d2187572b0e68f1a699e91391fbb1fbc36f9b44f3ad97cab9e4ab3329e20ae4abe7fc68f1cf8dfd1960f2b03b3d6a6c949b4a7102b0c22d35690b8e05 SHA512 92ec8ff06011856e98e5624f9c3d98227e10991385fa41e110187db9b5d7b8de075199844e886618668040b69f8910be51b8cf55a009fac8887954c5b7695b25
+DIST kImageAnnotator-0.7.0.tar.gz 266849 BLAKE2B eda6428caf37dedc24f613e513c970a94a0b25f37ea62953a9cf4b7afe3abd01b487f5a19f1c7baa34d9f31dfa0aaefed192f23ca2e3e1f06964cc6e4a951888 SHA512 e2a6d3014476fcb6e8838c0d0aa72e4bf5ccf6fbe1314ee6c1f44bb4299c6bd1b04be305e1039628f55e5e5e1626899329d9b93314c1f1fd2870bafaf0a8e2ff
diff --git a/media-libs/kimageannotator/files/kimageannotator-0.7.0-fix-qt6-tests.patch b/media-libs/kimageannotator/files/kimageannotator-0.7.0-fix-qt6-tests.patch
new file mode 100644
index 000000000000..985bf108c1a3
--- /dev/null
+++ b/media-libs/kimageannotator/files/kimageannotator-0.7.0-fix-qt6-tests.patch
@@ -0,0 +1,117 @@
+From dbcb28f4fe8deb5ce83d45907f97516eade74420 Mon Sep 17 00:00:00 2001
+From: Heiko Becker <mail@heiko-becker.de>
+Date: Tue, 6 Feb 2024 18:47:20 +0000
+Subject: [PATCH] Fix building the tests with Qt 6 (#332)
+
+* Remove usage of QTEST_ADD_GPU_BLACKLIST_SUPPORT_DEFS
+
+According to commit 641eb4a96552615d898512723e2093abcaf7fbc1 in
+qtbase.git they serve no purpose anymore and were subsequently removed
+in Qt6.
+
+Closes #331.
+
+* Replace QLatin1Literal with QStringLiteral
+
+The former is deprecated and was removed from Qt6.
+---
+ .../annotations/core/AnnotationPropertiesFactoryTest.cpp | 2 +-
+ tests/gui/annotator/tabs/AnnotationTabContextMenuTest.cpp | 6 +++---
+ tests/utils/TestRunner.h | 8 --------
+ tests/widgets/settingsPicker/StickerPickerTest.cpp | 4 ++--
+ 4 files changed, 6 insertions(+), 14 deletions(-)
+
+diff --git a/tests/annotations/core/AnnotationPropertiesFactoryTest.cpp b/tests/annotations/core/AnnotationPropertiesFactoryTest.cpp
+index 77b43057..ce5047ef 100644
+--- a/tests/annotations/core/AnnotationPropertiesFactoryTest.cpp
++++ b/tests/annotations/core/AnnotationPropertiesFactoryTest.cpp
+@@ -199,7 +199,7 @@ void AnnotationPropertiesFactoryTest::TestCreate_Should_SetToolFontBasedOnSettin
+ void AnnotationPropertiesFactoryTest::TestCreate_Should_StickerPathBasedOnSettings()
+ {
+ auto tool = Tools::Sticker;
+- auto path = QLatin1Literal("/my/path/to/sticker");
++ auto path = QStringLiteral("/my/path/to/sticker");
+ MockDefaultParameters parameters;
+ auto settingsProvider = new MockSettingsProvider();
+ settingsProvider->setSticker(path);
+diff --git a/tests/gui/annotator/tabs/AnnotationTabContextMenuTest.cpp b/tests/gui/annotator/tabs/AnnotationTabContextMenuTest.cpp
+index 0c4904de..a5c86d7f 100644
+--- a/tests/gui/annotator/tabs/AnnotationTabContextMenuTest.cpp
++++ b/tests/gui/annotator/tabs/AnnotationTabContextMenuTest.cpp
+@@ -40,8 +40,8 @@ void AnnotationTabContextMenuTest::TestCustomActionTriggered_Should_CallInnerAct
+ void AnnotationTabContextMenuTest::TestAddCustomActions_Should_SetTextIconAndToolTipInOuterAction()
+ {
+ QAction customAction;
+- customAction.setText(QLatin1Literal("LaLa"));
+- customAction.setToolTip(QLatin1Literal("Hello Hello"));
++ customAction.setText(QStringLiteral("LaLa"));
++ customAction.setToolTip(QStringLiteral("Hello Hello"));
+ customAction.setIcon(QIcon());
+ QWidget parent;
+ AnnotationTabContextMenu menu(&parent);
+@@ -68,4 +68,4 @@ void AnnotationTabContextMenuTest::TestCustomActionChanged_Should_UpdateEnabledS
+ QCOMPARE(customAction.isEnabled(), outerAction->isEnabled());
+ }
+
+-TEST_MAIN(AnnotationTabContextMenuTest);
+\ No newline at end of file
++TEST_MAIN(AnnotationTabContextMenuTest);
+diff --git a/tests/utils/TestRunner.h b/tests/utils/TestRunner.h
+index 214b8b02..ff742f02 100644
+--- a/tests/utils/TestRunner.h
++++ b/tests/utils/TestRunner.h
+@@ -69,9 +69,6 @@ class GoogleTestEventListener : public ::testing::EmptyTestEventListener {
+ #endif
+
+ #define TEST_MAIN(TestObject) \
+-QT_BEGIN_NAMESPACE \
+-QTEST_ADD_GPU_BLACKLIST_SUPPORT_DEFS \
+-QT_END_NAMESPACE \
+ int main(int argc, char *argv[]) \
+ { \
+ INIT_GOOGLE_MOCKS (argc, argv); \
+@@ -79,7 +76,6 @@ int main(int argc, char *argv[]) \
+ QApplication app(argc, argv); \
+ app.setAttribute(Qt::AA_Use96Dpi, true); \
+ QTEST_DISABLE_KEYPAD_NAVIGATION \
+- QTEST_ADD_GPU_BLACKLIST_SUPPORT \
+ TestObject tc; \
+ QTEST_SET_MAIN_SOURCE_PATH \
+ return QTest::qExec(&tc, argc, argv); \
+@@ -90,16 +86,12 @@ int main(int argc, char *argv[]) \
+ #include <QtTest/qtest_gui.h>
+
+ #define TEST_MAIN(TestObject) \
+-QT_BEGIN_NAMESPACE \
+-QTEST_ADD_GPU_BLACKLIST_SUPPORT_DEFS \
+-QT_END_NAMESPACE \
+ int main(int argc, char *argv[]) \
+ { \
+ INIT_GOOGLE_MOCKS (argc, argv); \
+ \
+ QGuiApplication app(argc, argv); \
+ app.setAttribute(Qt::AA_Use96Dpi, true); \
+- QTEST_ADD_GPU_BLACKLIST_SUPPORT \
+ TestObject tc; \
+ QTEST_SET_MAIN_SOURCE_PATH \
+ return QTest::qExec(&tc, argc, argv); \
+diff --git a/tests/widgets/settingsPicker/StickerPickerTest.cpp b/tests/widgets/settingsPicker/StickerPickerTest.cpp
+index 94c26802..7c539fcb 100644
+--- a/tests/widgets/settingsPicker/StickerPickerTest.cpp
++++ b/tests/widgets/settingsPicker/StickerPickerTest.cpp
+@@ -23,7 +23,7 @@ void StickerPickerTest::TestSelectSticker_Should_EmitSignal_When_StickerChanged(
+ {
+ StickerPicker stickerPicker(nullptr);
+ QSignalSpy spy(&stickerPicker, &StickerPicker::stickerSelected);
+- auto expectedStickerPath = QLatin1Literal(":/stickers/nerd_face.svg");
++ auto expectedStickerPath = QStringLiteral(":/stickers/nerd_face.svg");
+
+ stickerPicker.setSticker(expectedStickerPath);
+
+@@ -32,4 +32,4 @@ void StickerPickerTest::TestSelectSticker_Should_EmitSignal_When_StickerChanged(
+ QCOMPARE(resultSize, expectedStickerPath);
+ }
+
+-TEST_MAIN(StickerPickerTest);
+\ No newline at end of file
++TEST_MAIN(StickerPickerTest);
diff --git a/media-libs/kimageannotator/kimageannotator-0.6.0.ebuild b/media-libs/kimageannotator/kimageannotator-0.6.0.ebuild
index c80fd7661803..fca1139e8043 100644
--- a/media-libs/kimageannotator/kimageannotator-0.6.0.ebuild
+++ b/media-libs/kimageannotator/kimageannotator-0.6.0.ebuild
@@ -1,4 +1,4 @@
-# Copyright 2020-2023 Gentoo Authors
+# Copyright 2020-2024 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
@@ -25,6 +25,7 @@ RDEPEND="
dev-qt/qtsvg:5
dev-qt/qtwidgets:5[png]
>=media-libs/kcolorpicker-0.2.0
+ <media-libs/kcolorpicker-0.3.0
x11-libs/libX11
"
DEPEND="${RDEPEND}
diff --git a/media-libs/kimageannotator/kimageannotator-0.6.1.ebuild b/media-libs/kimageannotator/kimageannotator-0.6.1.ebuild
index d8bf925f00f3..7e184fac91b8 100644
--- a/media-libs/kimageannotator/kimageannotator-0.6.1.ebuild
+++ b/media-libs/kimageannotator/kimageannotator-0.6.1.ebuild
@@ -1,4 +1,4 @@
-# Copyright 2020-2023 Gentoo Authors
+# Copyright 2020-2024 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
@@ -25,6 +25,7 @@ RDEPEND="
dev-qt/qtsvg:5
dev-qt/qtwidgets:5[png]
>=media-libs/kcolorpicker-0.2.0
+ <media-libs/kcolorpicker-0.3.0
x11-libs/libX11
"
DEPEND="${RDEPEND}
diff --git a/media-libs/kimageannotator/kimageannotator-0.7.0.ebuild b/media-libs/kimageannotator/kimageannotator-0.7.0.ebuild
new file mode 100644
index 000000000000..c1059b0c87d8
--- /dev/null
+++ b/media-libs/kimageannotator/kimageannotator-0.7.0.ebuild
@@ -0,0 +1,53 @@
+# Copyright 2020-2024 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+VIRTUALX_REQUIRED="test"
+inherit cmake
+
+MY_PN=kImageAnnotator
+MY_P="${MY_PN}-${PV}"
+
+DESCRIPTION="Tool for annotating images"
+HOMEPAGE="https://github.com/ksnip/kImageAnnotator"
+SRC_URI="https://github.com/ksnip/${MY_PN}/archive/v${PV}.tar.gz -> ${MY_P}.tar.gz"
+
+LICENSE="LGPL-3+"
+SLOT="0"
+KEYWORDS="~amd64 ~arm64 ~loong ~ppc64 ~riscv ~x86"
+IUSE="test"
+
+RDEPEND="
+ dev-qt/qtbase:6[gui,widgets]
+ dev-qt/qtsvg:6
+ >=media-libs/kcolorpicker-0.3.0
+"
+DEPEND="${RDEPEND}
+ test? (
+ dev-qt/qtbase:6[test]
+ dev-cpp/gtest
+ )
+"
+BDEPEND="
+ dev-qt/qttools:6[linguist]
+"
+
+RESTRICT="!test? ( test )"
+
+PATCHES=( "${FILESDIR}/${P}-fix-qt6-tests.patch" )
+
+S="${WORKDIR}/${MY_P}"
+
+src_configure() {
+ local mycmakeargs=(
+ -DBUILD_TESTS=$(usex test)
+ -DBUILD_WITH_QT6=ON
+ )
+ cmake_src_configure
+}
+
+src_test() {
+ local -x QT_QPA_PLATFORM=offscreen
+ BUILD_DIR="${BUILD_DIR}/tests" cmake_src_test
+}
diff --git a/media-libs/kimageannotator/metadata.xml b/media-libs/kimageannotator/metadata.xml
index 4ddb8c1adc71..f4a2088a6f74 100644
--- a/media-libs/kimageannotator/metadata.xml
+++ b/media-libs/kimageannotator/metadata.xml
@@ -9,4 +9,11 @@
<email>proxy-maint@gentoo.org</email>
<name>Proxy Maintainers</name>
</maintainer>
+ <maintainer type="project">
+ <email>kde@gentoo.org</email>
+ <name>Gentoo KDE Project</name>
+ </maintainer>
+ <upstream>
+ <remote-id type="github">ksnip/kImageAnnotator</remote-id>
+ </upstream>
</pkgmetadata>