diff options
Diffstat (limited to 'kde-frameworks/baloo')
-rw-r--r-- | kde-frameworks/baloo/Manifest | 4 | ||||
-rw-r--r-- | kde-frameworks/baloo/baloo-5.77.0-r1.ebuild (renamed from kde-frameworks/baloo/baloo-5.77.0.ebuild) | 7 | ||||
-rw-r--r-- | kde-frameworks/baloo/files/baloo-5.77.0-no-error-w-o-index.patch | 77 | ||||
-rw-r--r-- | kde-frameworks/baloo/files/baloo-5.77.0-strip-trailing-slash.patch | 34 |
4 files changed, 120 insertions, 2 deletions
diff --git a/kde-frameworks/baloo/Manifest b/kde-frameworks/baloo/Manifest index 16532a72cb9a..d2066a96d86b 100644 --- a/kde-frameworks/baloo/Manifest +++ b/kde-frameworks/baloo/Manifest @@ -1,5 +1,7 @@ +AUX baloo-5.77.0-no-error-w-o-index.patch 2264 BLAKE2B 252ce25e00a45c431d35b082bc2e0336a7b8dd15ca3f54a14b7f192e3d439bf056c0df76eec3ee18f70e0920d3bd0bdb801b4ac68652bebb24cc1bfa4515c71b SHA512 5ca7166cbf34717f5f1d157b118574373901544c6da9386158a1fc389c81f7ca4d18c0d613442c20cba8c76dca2e5a73b97dded33cc2885e17902571647d4b41 +AUX baloo-5.77.0-strip-trailing-slash.patch 1096 BLAKE2B c3a7a30578ec903d4e83191e80927626372b6ea993e6088651cef564e1414b62e4d4d6d9e27fe27c6ec2ee72499ec7403fd64fe327efe74e8580f15e23f8eeb4 SHA512 b6b4316043ff5c4386c4c372e4b927204a6b651146b781739113b368b51e80654616efe5dd3e093269089fd0584414e82329ae55dbbaf2f03a7702c9ed1d314e DIST baloo-5.74.0.tar.xz 286000 BLAKE2B e0759f01364413e5ef232c0746ca7fa54585ecc55ac7073d3cf20bfc06227f055ad2f4a11611dc3f745fe3da736529a42fde3b30e77c761425b8eea917e88354 SHA512 e044b3d0aa924154e32d2a7a66c6de0c4a8b572d3357d5c2600e9a64ae3e32751ea5953a37bbb8a0bde939732b1298486ccceaa64a84400f6179e44cd360ec5f DIST baloo-5.77.0.tar.xz 290444 BLAKE2B decc4f6fbd785ccfe8e5f4616da6ee92fee0846aa3bbb25979ecd9cd445b0d6333ef1328221e39fb976e8ebf7c53be965b5ce58c8126a1b3cd2fa64962898083 SHA512 4d56136c3d661ad7dc11bf1f6b433b5fdc48f597bfd26ae8b5529d348750b89bcaba487c5bce874d557e76f5cee0779e2ea22c2259ce33926a1b3f26fa458929 EBUILD baloo-5.74.0.ebuild 890 BLAKE2B 6a26785fc879038d8ad960e3a65af1c5842d93b7e9e786b1dd0b78a4f2a4c537771fd39c6fa3ea5cf7f9306508a38538b02b1a370b07531749b43921ad131c8f SHA512 6c03ba199bbb6e875ec51fe421d77f091fce95413eb567d3216337533799f49af14a6272a8be624bff79e34956aa34f26f7de180a45401e4f96a86f6b67712e8 -EBUILD baloo-5.77.0.ebuild 893 BLAKE2B bfdf6067b5f047083cc11816bc0add55691c5891d3a8d35caef5c7a3ef7742556dc3e09f80c34adf9fce8afccde4632a4e77f2b8164b6ee27b6a746ce835aa0a SHA512 7bad6f81ddefe2538e185f3cdc94e293c40e68490977b1a3a634d3564b465440f6bfedd9d82f628d8d799d83273379aeabfd39fa0431bdce9d78ad9ce4b93568 +EBUILD baloo-5.77.0-r1.ebuild 998 BLAKE2B 3b80b3b5585d95d3e8b5b29763f5ab90978b86de9c108185df78e8d00632105b9433115a6290a88020a147c1c5f9c34037cddbfcb11ac0c1906b30d32054fa27 SHA512 8f859bca573fc127247bb447f25e592470a7dfe991ef1ba16769a974c8cd6e8106b2d77af54e2831eca039ee1b25090e835b6508c87a57876ce4671170800636 MISC metadata.xml 249 BLAKE2B ad415db89e5dee1627aa77f44ded9d4e1e5b8217d06c7ca25bbaa3fe92ce67c2b1090957c45a821b407d7927e5af798498aa6a5b903895ee1af8ee20a446c7f7 SHA512 76a5a340b13f0053ca3c5e94ed24380ea8d29b45ac8655419e22eaadb1e4a827c04d2e7e36b65145c4964e6526f656618fc6ac144e277ef53cb7373e6239e3c3 diff --git a/kde-frameworks/baloo/baloo-5.77.0.ebuild b/kde-frameworks/baloo/baloo-5.77.0-r1.ebuild index b4693c49c8ba..ac7ba5028324 100644 --- a/kde-frameworks/baloo/baloo-5.77.0.ebuild +++ b/kde-frameworks/baloo/baloo-5.77.0-r1.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2020 Gentoo Authors +# Copyright 1999-2021 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=7 @@ -33,3 +33,8 @@ DEPEND=" RDEPEND="${DEPEND}" RESTRICT+=" test" # bug 624250 + +PATCHES=( + "${FILESDIR}/${P}-strip-trailing-slash.patch" + "${FILESDIR}/${P}-no-error-w-o-index.patch" +) diff --git a/kde-frameworks/baloo/files/baloo-5.77.0-no-error-w-o-index.patch b/kde-frameworks/baloo/files/baloo-5.77.0-no-error-w-o-index.patch new file mode 100644 index 000000000000..d49cc8f6d9d9 --- /dev/null +++ b/kde-frameworks/baloo/files/baloo-5.77.0-no-error-w-o-index.patch @@ -0,0 +1,77 @@ +From d102b01ee59d93de3fe18c12364ea69a85ea723f Mon Sep 17 00:00:00 2001 +From: Christoph Cullmann <cullmann@kde.org> +Date: Thu, 31 Dec 2020 15:44:40 +0000 +Subject: [PATCH] avoid errors for application startup if no baloo index was + ever created + +use case: + + * a KDE application started e.g. in an non-KDE Plasma environment + * a KDE application started with baloo indexing disabled + +you normally will get: + +kf.kio.slaves.tags: tag fetch failed: "Failed to open the database" +kf.kio.slaves.tags: "tags:/" list() invalid url + +Now this is not issued if no index database exist. +--- + src/engine/database.cpp | 6 ++++++ + src/engine/database.h | 7 +++++++ + src/lib/taglistjob.cpp | 7 +++++++ + 3 files changed, 20 insertions(+) + +diff --git a/src/engine/database.cpp b/src/engine/database.cpp +index 427210d0..ac93426c 100644 +--- a/src/engine/database.cpp ++++ b/src/engine/database.cpp +@@ -247,3 +247,9 @@ QString Database::path() const + QMutexLocker locker(&m_mutex); + return m_path; + } ++ ++bool Database::isAvailable() const ++{ ++ QMutexLocker locker(&m_mutex); ++ return QFileInfo::exists(m_path + QStringLiteral("/index")); ++} +diff --git a/src/engine/database.h b/src/engine/database.h +index 0f43b623..26d21101 100644 +--- a/src/engine/database.h ++++ b/src/engine/database.h +@@ -73,6 +73,13 @@ public: + */ + QString path() const; + ++ /** ++ * Is the database available for use? ++ * For example if indexing is disabled or the indexer did never run this is false. ++ * @return database available ++ */ ++ bool isAvailable() const; ++ + private: + /** + * serialize access, as open might be called from multiple threads +diff --git a/src/lib/taglistjob.cpp b/src/lib/taglistjob.cpp +index cea57889..58945cc7 100644 +--- a/src/lib/taglistjob.cpp ++++ b/src/lib/taglistjob.cpp +@@ -33,7 +33,14 @@ TagListJob::~TagListJob() + void TagListJob::start() + { + Database *db = globalDatabaseInstance(); ++ + if (!db->open(Database::ReadOnlyDatabase)) { ++ // if we have no index, we have no tags ++ if (!db->isAvailable()) { ++ emitResult(); ++ return; ++ } ++ + setError(UserDefinedError); + setErrorText(QStringLiteral("Failed to open the database")); + emitResult(); +-- +GitLab + diff --git a/kde-frameworks/baloo/files/baloo-5.77.0-strip-trailing-slash.patch b/kde-frameworks/baloo/files/baloo-5.77.0-strip-trailing-slash.patch new file mode 100644 index 000000000000..ab9c7639799f --- /dev/null +++ b/kde-frameworks/baloo/files/baloo-5.77.0-strip-trailing-slash.patch @@ -0,0 +1,34 @@ +From 9b61371fdefbd538938f20cdc87eed03d170fa5b Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Stefan=20Br=C3=BCns?= <stefan.bruens@rwth-aachen.de> +Date: Sat, 12 Dec 2020 19:01:45 +0100 +Subject: [PATCH] [BasicIndexingJob] Strip trailing slash from folders + +If BasicIndexingJob is called with a path with a trailing slash, the +search for the last slash (separating name from parent path) goes wrong. + +This was wrong already earlier, but with commit 47ebc15844f6b8a8 +("[Document] Add parent document ID and populate it") this caused +document and parent id to be the same. + +CCBUG: 430273 +--- + src/file/basicindexingjob.cpp | 3 +++ + 1 file changed, 3 insertions(+) + +diff --git a/src/file/basicindexingjob.cpp b/src/file/basicindexingjob.cpp +index e00c6a2b..c0f18ddd 100644 +--- a/src/file/basicindexingjob.cpp ++++ b/src/file/basicindexingjob.cpp +@@ -23,6 +23,9 @@ BasicIndexingJob::BasicIndexingJob(const QString& filePath, const QString& mimet + , m_mimetype(mimetype) + , m_indexingLevel(level) + { ++ if (m_filePath.endsWith(QChar('/'))) { ++ m_filePath.chop(1); ++ } + } + + namespace { +-- +GitLab + |