From 8b4ace9c50842c5b83401ea7b179dcab940387e1 Mon Sep 17 00:00:00 2001 From: V3n3RiX Date: Wed, 23 Sep 2020 10:22:15 +0100 Subject: gentoo resync : 23.09.2020 --- app-text/kjots/Manifest | 2 + .../files/kjots-5.0.2-kontactinterface-20.08.patch | 148 +++++++++++++++++++++ app-text/kjots/kjots-5.0.2-r2.ebuild | 49 +++++++ 3 files changed, 199 insertions(+) create mode 100644 app-text/kjots/files/kjots-5.0.2-kontactinterface-20.08.patch create mode 100644 app-text/kjots/kjots-5.0.2-r2.ebuild (limited to 'app-text/kjots') diff --git a/app-text/kjots/Manifest b/app-text/kjots/Manifest index 1f5102e33d12..24819237abe5 100644 --- a/app-text/kjots/Manifest +++ b/app-text/kjots/Manifest @@ -1,4 +1,6 @@ AUX kjots-5.0.2-kf5bookmarks-5.69.patch 2734 BLAKE2B 5bbad18ee50f844320a405347eb6f89535b831d42b4751c56d7227e31095dbf0767fff15ea5fe3930bb11a13155bd13db6f9b970be86aee011c0929efaa7dbfe SHA512 13aff021919d8565cce1c6e7c84cdf23e9a405394374451325f229a00ce5d36be070c0efb0726573297a615d709e0a7d1bd60cb5f1e7752aaee50d8021b64fef +AUX kjots-5.0.2-kontactinterface-20.08.patch 5563 BLAKE2B 2c754b4a31c133c4fe9409e930df855366d0276a35678466b07b4fd54736c1ec64bdac6b3064bceb5044765433f6d953239746e580f4ef150ad274e111829001 SHA512 0fd6cfaaaac12bac57043acec043ad4fabb232a2df666379860b745b6d137e18193abd6447dca60a51596cfa969f4193bafc33d811bf793b547df43efb462026 DIST kjots-5.0.2.tar.xz 230608 BLAKE2B 3194b0ef072decfa09455ca7e8d6057ea3f37f54d37641a6ddf28e17ef4662a408adc9e9b04394e6002b51e72ef740412bcdd70324d6efcb9e949f9911437559 SHA512 a652765c56cebcaeba7b879cc075555c28667abdba84d11e986e5ffb440fbc776116f363992dd84d939918ae7d80ef5c2e1093da28d114b18041e10e5209b225 EBUILD kjots-5.0.2-r1.ebuild 1469 BLAKE2B 0e66e6554360a201f1095861cc6f5a65fe5f4ac5b344f4f55ebd87b350c5e412782f5e75f5e56f64a36df1250aebf45d9d07d6afcb4b93f879df50cc1087bf06 SHA512 04e3be8661fb2eff2dd22373fea6c6fb12ce49cac076e661cbf1af9538742405bf71d84f6dcace4c07a5c451639694b6b2dd31c11af11d7a07f1a4a3a7795f90 +EBUILD kjots-5.0.2-r2.ebuild 1343 BLAKE2B ac83e67d01b3375519a0075f776b44c9cd6a4b81a7b5c28f24dd34a91613a92d89aac13b797a6f8a1fe1084389017ee38910c6d1680fb186008692c9d1c5b88e SHA512 50fc1c301a15794f5a14accb24b22f996c94fc364431d41fce024b5b7f342763b797012a058c1cb90c0ff2bff5047b872c7d01979f839234a2713d69893ce4a6 MISC metadata.xml 249 BLAKE2B ad415db89e5dee1627aa77f44ded9d4e1e5b8217d06c7ca25bbaa3fe92ce67c2b1090957c45a821b407d7927e5af798498aa6a5b903895ee1af8ee20a446c7f7 SHA512 76a5a340b13f0053ca3c5e94ed24380ea8d29b45ac8655419e22eaadb1e4a827c04d2e7e36b65145c4964e6526f656618fc6ac144e277ef53cb7373e6239e3c3 diff --git a/app-text/kjots/files/kjots-5.0.2-kontactinterface-20.08.patch b/app-text/kjots/files/kjots-5.0.2-kontactinterface-20.08.patch new file mode 100644 index 000000000000..608a50d98567 --- /dev/null +++ b/app-text/kjots/files/kjots-5.0.2-kontactinterface-20.08.patch @@ -0,0 +1,148 @@ +From bcf49fb95bee12bbc4bef0578285ad296deafcae Mon Sep 17 00:00:00 2001 +From: David Faure +Date: Fri, 24 Apr 2020 01:25:43 +0200 +Subject: [PATCH] Install the kontact plugin into kontact5, with JSON metadata. + +Summary: This will allow kontact to use KPluginLoader one day. + +It also fixes compilation with current kontactinterface API. + +Test Plan: +rm $prefix/lib64/plugins/kontact_zanshinplugin.so ; make install +kontact still finds the zanshin plugin + +The same steps (other than old-kontact-interface compatibility) were already +pushed to all other kontact plugins. + +This commit is very similar to https://phabricator.kde.org/D28847 +and its predecessor commit, in zanshin. +--- + src/kontact_plugin/CMakeLists.txt | 11 ++++++++- + src/kontact_plugin/kjots_plugin.cpp | 34 ++++++++++++++++++++------ + src/kontact_plugin/kjots_plugin.h | 5 ++++ + src/kontact_plugin/kjotsplugin.desktop | 2 +- + 4 files changed, 43 insertions(+), 9 deletions(-) + +diff --git a/src/kontact_plugin/CMakeLists.txt b/src/kontact_plugin/CMakeLists.txt +index 8a6b5e1..dec4b8b 100644 +--- a/src/kontact_plugin/CMakeLists.txt ++++ b/src/kontact_plugin/CMakeLists.txt +@@ -1,13 +1,22 @@ + include_directories(${kjots_SOURCE_DIR}/src) + ++# TODO: remove once kontactinterface 5.14.42 is required ++if(NOT CMAKE_VERSION VERSION_LESS "3.10.0") ++ # CMake 3.9+ warns about automoc on files without Q_OBJECT, and doesn't know about other macros. ++ # 3.10+ lets us provide more macro names that require automoc. ++ # KF5 >= 5.42 takes care itself of adding its macros in its cmake config files ++ list(APPEND CMAKE_AUTOMOC_MACRO_NAMES "EXPORT_KONTACT_PLUGIN_WITH_JSON") ++endif() ++ + set(kontact_kjots_PART_SRCS + kjots_plugin.cpp + ) + + add_library(kontact_kjotsplugin MODULE ${kontact_kjots_PART_SRCS}) + target_link_libraries(kontact_kjotsplugin KF5::KontactInterface) ++kcoreaddons_desktop_to_json(kontact_kjotsplugin kjotsplugin.desktop) + +-install(TARGETS kontact_kjotsplugin DESTINATION ${KDE_INSTALL_PLUGINDIR}) ++install(TARGETS kontact_kjotsplugin DESTINATION ${KDE_INSTALL_PLUGINDIR}/kontact5) + install(FILES kjotsplugin.desktop DESTINATION ${KDE_INSTALL_KSERVICES5DIR}/kontact) + install(FILES kjots.setdlg DESTINATION ${KDE_INSTALL_DATADIR}/kontact/ksettingsdialog) + +diff --git a/src/kontact_plugin/kjots_plugin.cpp b/src/kontact_plugin/kjots_plugin.cpp +index 66e7ed5..b74d601 100644 +--- a/src/kontact_plugin/kjots_plugin.cpp ++++ b/src/kontact_plugin/kjots_plugin.cpp +@@ -33,7 +33,25 @@ + #include + #include + +-EXPORT_KONTACT_PLUGIN(KJotsPlugin, kjots) ++#if KONTACTINTERFACE_VERSION < QT_VERSION_CHECK(5, 14, 42) ++/** ++ Exports Kontact plugin. ++ @param pluginclass the class to instanciate (must derive from KontactInterface::Plugin ++ @param jsonFile filename of the JSON file, generated from a .desktop file ++ */ ++#define EXPORT_KONTACT_PLUGIN_WITH_JSON( pluginclass, jsonFile ) \ ++ class Instance \ ++ { \ ++ public: \ ++ static QObject *createInstance( QWidget *, QObject *parent, const QVariantList &list ) \ ++ { return new pluginclass( static_cast( parent ), list ); } \ ++ }; \ ++ K_PLUGIN_FACTORY_WITH_JSON( KontactPluginFactory, jsonFile, registerPlugin< pluginclass > \ ++ ( QString(), Instance::createInstance ); ) \ ++ K_EXPORT_PLUGIN_VERSION(KONTACT_PLUGIN_VERSION) ++#endif ++ ++EXPORT_KONTACT_PLUGIN_WITH_JSON(KJotsPlugin, "kjotsplugin.json") + + KJotsPlugin::KJotsPlugin(KontactInterface::Core *core, const QVariantList &) + : KontactInterface::Plugin(core, core, "kjots") +@@ -63,15 +81,17 @@ QStringList KJotsPlugin::invisibleToolbarActions() const + return { QStringLiteral("new_page"), QStringLiteral("new_book") }; + } + ++#if KONTACTINTERFACE_VERSION >= QT_VERSION_CHECK(5, 14, 42) ++KParts::Part *KJotsPlugin::createPart() ++{ ++ return loadPart(); ++} ++#else + KParts::ReadOnlyPart *KJotsPlugin::createPart() + { +- KParts::ReadOnlyPart *part = loadPart(); +- if (!part) { +- return Q_NULLPTR; +- } +- +- return part; ++ return loadPart(); + } ++#endif + + QStringList KJotsPlugin::configModules() const + { +diff --git a/src/kontact_plugin/kjots_plugin.h b/src/kontact_plugin/kjots_plugin.h +index cd62373..4945d25 100644 +--- a/src/kontact_plugin/kjots_plugin.h ++++ b/src/kontact_plugin/kjots_plugin.h +@@ -24,6 +24,7 @@ + #define KJOTS_PLUGIN_H + + #include ++#include + + namespace KontactInterface + { +@@ -62,7 +63,11 @@ public: + QStringList invisibleToolbarActions() const Q_DECL_OVERRIDE; + + protected: ++#if KONTACTINTERFACE_VERSION >= QT_VERSION_CHECK(5, 14, 42) ++ KParts::Part *createPart() override; ++#else + KParts::ReadOnlyPart *createPart() Q_DECL_OVERRIDE; ++#endif + KontactInterface::UniqueAppWatcher *mUniqueAppWatcher; + + private: +diff --git a/src/kontact_plugin/kjotsplugin.desktop b/src/kontact_plugin/kjotsplugin.desktop +index 1339753..d5a198f 100644 +--- a/src/kontact_plugin/kjotsplugin.desktop ++++ b/src/kontact_plugin/kjotsplugin.desktop +@@ -3,7 +3,7 @@ Type=Service + Icon=kjots + X-KDE-ServiceTypes=Kontact/Plugin,KPluginInfo + +-X-KDE-Library=kontact_kjotsplugin ++X-KDE-Library=kontact5/kontact_kjotsplugin + X-KDE-KontactPluginVersion=10 + X-KDE-KontactPartLibraryName=kjotspart + X-KDE-KontactPartExecutableName=kjots +-- +GitLab + diff --git a/app-text/kjots/kjots-5.0.2-r2.ebuild b/app-text/kjots/kjots-5.0.2-r2.ebuild new file mode 100644 index 000000000000..07aaf94d7b1c --- /dev/null +++ b/app-text/kjots/kjots-5.0.2-r2.ebuild @@ -0,0 +1,49 @@ +# Copyright 1999-2020 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +KFMIN=5.70.0 +QTMIN=5.12.3 +inherit ecm kde.org + +DESCRIPTION="Note taking utility by KDE" +HOMEPAGE="https://userbase.kde.org/KJots https://community.kde.org/PIM/KJots" +SRC_URI="mirror://kde/stable/${PN}/${PV}/${P}.tar.xz" + +LICENSE="GPL-2" +SLOT="5" +KEYWORDS="~amd64 ~x86" +IUSE="" + +DEPEND=" + dev-libs/grantlee:5 + dev-libs/libxslt + >=dev-qt/qtdbus-${QTMIN}:5 + >=dev-qt/qtgui-${QTMIN}:5 + >=dev-qt/qtprintsupport-${QTMIN}:5 + >=dev-qt/qtwidgets-${QTMIN}:5 + >=kde-apps/akonadi-20.08.1:5 + >=kde-apps/akonadi-notes-20.08.1:5 + >=kde-apps/kmime-20.08.1:5 + >=kde-apps/kontactinterface-20.08.1:5 + >=kde-apps/kpimtextedit-20.08.1:5 + >=kde-frameworks/kbookmarks-${KFMIN}:5 + >=kde-frameworks/kcmutils-${KFMIN}:5 + >=kde-frameworks/kconfig-${KFMIN}:5 + >=kde-frameworks/kconfigwidgets-${KFMIN}:5 + >=kde-frameworks/kcoreaddons-${KFMIN}:5 + >=kde-frameworks/ki18n-${KFMIN}:5 + >=kde-frameworks/kio-${KFMIN}:5 + >=kde-frameworks/kitemmodels-${KFMIN}:5 + >=kde-frameworks/kparts-${KFMIN}:5 + >=kde-frameworks/ktextwidgets-${KFMIN}:5 + >=kde-frameworks/kwidgetsaddons-${KFMIN}:5 + >=kde-frameworks/kxmlgui-${KFMIN}:5 +" +RDEPEND="${DEPEND}" + +PATCHES+=( + "${FILESDIR}/${P}-kf5bookmarks-5.69.patch" # KDE-Bug 384000 + "${FILESDIR}/${P}-kontactinterface-20.08.patch" +) -- cgit v1.2.3