[arch-commits] Commit in tracker3/repos (3 files)

Felix Yan felixonmars at archlinux.org
Sat Dec 19 07:49:07 UTC 2020


    Date: Saturday, December 19, 2020 @ 07:49:07
  Author: felixonmars
Revision: 404562

archrelease: copy trunk to staging-x86_64

Added:
  tracker3/repos/staging-x86_64/
  tracker3/repos/staging-x86_64/353.patch
    (from rev 404561, tracker3/trunk/353.patch)
  tracker3/repos/staging-x86_64/PKGBUILD
    (from rev 404561, tracker3/trunk/PKGBUILD)

-----------+
 353.patch |   51 +++++++++++++++++++++++++++++++++++++++++++++++++++
 PKGBUILD  |   49 +++++++++++++++++++++++++++++++++++++++++++++++++
 2 files changed, 100 insertions(+)

Copied: tracker3/repos/staging-x86_64/353.patch (from rev 404561, tracker3/trunk/353.patch)
===================================================================
--- staging-x86_64/353.patch	                        (rev 0)
+++ staging-x86_64/353.patch	2020-12-19 07:49:07 UTC (rev 404562)
@@ -0,0 +1,51 @@
+From 040e22d005985a19a0dc435a7631f91700804ce4 Mon Sep 17 00:00:00 2001
+From: Carlos Garnacho <carlosg at gnome.org>
+Date: Thu, 10 Dec 2020 03:55:08 +0100
+Subject: [PATCH] libtracker-data: Avoid deletion of empty rows in FTS table
+
+Starting with SQLite 3.34.0, this turns into a consistency error. Ensure
+rows being deleted have actually some content before proceeding to deletion,
+and ensure we don't process individual properties one by one in the course
+of a whole rdfs:Resource deletion.
+
+Fixes: https://bugs.archlinux.org/task/68903
+---
+ src/libtracker-data/tracker-data-update.c         | 2 ++
+ src/libtracker-data/tracker-db-interface-sqlite.c | 5 +++--
+ 2 files changed, 5 insertions(+), 2 deletions(-)
+
+diff --git a/src/libtracker-data/tracker-data-update.c b/src/libtracker-data/tracker-data-update.c
+index e97006631..cb2f39eff 100644
+--- a/src/libtracker-data/tracker-data-update.c
++++ b/src/libtracker-data/tracker-data-update.c
+@@ -1902,6 +1902,8 @@ cache_delete_resource_type_full (TrackerData  *data,
+ 		if (strcmp (tracker_class_get_uri (class), TRACKER_PREFIX_RDFS "Resource") == 0 &&
+ 		    g_hash_table_size (data->resource_buffer->tables) == 0) {
+ 			tracker_db_interface_sqlite_fts_delete_id (iface, database, data->resource_buffer->id);
++			data->resource_buffer->fts_updated = TRUE;
++
+ 			/* skip subclass query when deleting whole resource
+ 			   to improve performance */
+ 
+diff --git a/src/libtracker-data/tracker-db-interface-sqlite.c b/src/libtracker-data/tracker-db-interface-sqlite.c
+index 260b81d87..f5e91de29 100644
+--- a/src/libtracker-data/tracker-db-interface-sqlite.c
++++ b/src/libtracker-data/tracker-db-interface-sqlite.c
+@@ -2315,11 +2315,12 @@ tracker_db_interface_sqlite_fts_create_delete_all_query (TrackerDBInterface *db_
+ 	g_string_append_printf (insert_str,
+ 	                        "INSERT INTO \"%s\".fts5 (fts5, rowid %s) "
+ 	                        "SELECT 'delete', rowid %s FROM \"%s\".fts_view "
+-	                        "WHERE rowid = ?",
++	                        "WHERE rowid = ? AND COALESCE(NULL %s) IS NOT NULL",
+ 				database,
+ 	                        db_interface->fts_properties,
+ 	                        db_interface->fts_properties,
+-	                        database);
++	                        database,
++				db_interface->fts_properties);
+ 	return g_string_free (insert_str, FALSE);
+ }
+ 
+-- 
+GitLab
+

Copied: tracker3/repos/staging-x86_64/PKGBUILD (from rev 404561, tracker3/trunk/PKGBUILD)
===================================================================
--- staging-x86_64/PKGBUILD	                        (rev 0)
+++ staging-x86_64/PKGBUILD	2020-12-19 07:49:07 UTC (rev 404562)
@@ -0,0 +1,49 @@
+# Maintainer: Jan Alexander Steffens (heftig) <heftig at archlinux.org>
+# Contributor: Sergej Pupykin <pupykin.s+arch at gmail.com>
+# Contributor: Alexander Fehr <pizzapunk gmail com>
+
+pkgname=tracker3
+pkgver=3.0.2
+pkgrel=2
+pkgdesc="Desktop-neutral user information store, search tool and indexer"
+url="https://wiki.gnome.org/Projects/Tracker"
+arch=(x86_64)
+license=(GPL)
+depends=(sqlite icu glib2 libffi util-linux libstemmer libseccomp libsoup
+         json-glib)
+makedepends=(gobject-introspection vala git gtk-doc bash-completion meson
+             asciidoc systemd)
+checkdepends=(python-gobject python-dbus)
+provides=(libtracker-sparql-3.0.so)
+groups=(gnome)
+_commit=7324a45d8f5f2c221e9cdc96f8d28ffe32598ef0  # tags/3.0.2^0
+source=("git+https://gitlab.gnome.org/GNOME/tracker.git#commit=$_commit"
+        353.patch)
+sha256sums=('SKIP'
+            '1445d235392de75c65ab28a0e358056c8ce7df9127f6e146cb3e2a4879c09f3d')
+
+pkgver() {
+  cd tracker
+  git describe --tags | sed 's/_/./g;s/-/+/g'
+}
+
+prepare() {
+  cd tracker
+
+  # https://gitlab.gnome.org/GNOME/tracker/-/merge_requests/353
+  # https://bugs.archlinux.org/task/68903
+  git apply -3 ../353.patch
+}
+
+build() {
+  arch-meson tracker build --buildtype debug
+  meson compile -C build
+}
+
+check() {
+  TRACKER_DEBUG=sqlite,sql-statements dbus-run-session meson test -C build --print-errorlogs -t 3
+}
+
+package() {
+  DESTDIR="$pkgdir" meson install -C build
+}



More information about the arch-commits mailing list