From 43271f54e88222325d7e8d698ff24c35e11541c3 Mon Sep 17 00:00:00 2001 From: CentOS Buildsys Date: Mar 01 2014 00:17:27 +0000 Subject: import tracker-0.16.2-8.el7.src.rpm --- diff --git a/SOURCES/0001-Bump-the-minimum-memory-requirement-to-768M.patch b/SOURCES/0001-Bump-the-minimum-memory-requirement-to-768M.patch new file mode 100644 index 0000000..9ee871c --- /dev/null +++ b/SOURCES/0001-Bump-the-minimum-memory-requirement-to-768M.patch @@ -0,0 +1,26 @@ +From 5d841e9bdf3dc2a8e39e67d52c0b547fd6a26c88 Mon Sep 17 00:00:00 2001 +From: Debarshi Ray +Date: Tue, 12 Nov 2013 16:09:57 +0100 +Subject: [PATCH] Bump the minimum memory requirement to 768M + +http://bugzilla.gnome.org/show_bug.cgi?id=712142 +--- + src/libtracker-common/tracker-os-dependant-unix.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/src/libtracker-common/tracker-os-dependant-unix.c b/src/libtracker-common/tracker-os-dependant-unix.c +index 24108f4..2fa7c93 100644 +--- a/src/libtracker-common/tracker-os-dependant-unix.c ++++ b/src/libtracker-common/tracker-os-dependant-unix.c +@@ -39,7 +39,7 @@ + /* Maximum here is a G_MAXLONG, so if you want to use > 2GB, you have + * to set MEM_LIMIT to RLIM_INFINITY + */ +-#define MEM_LIMIT_MIN 256 * 1024 * 1024 ++#define MEM_LIMIT_MIN 768 * 1024 * 1024 + + #if defined(__OpenBSD__) && !defined(RLIMIT_AS) + #define RLIMIT_AS RLIMIT_DATA +-- +1.8.4.2 + diff --git a/SOURCES/0001-fts-Strengthen-against-sqlite-failures-in-FTS-functi.patch b/SOURCES/0001-fts-Strengthen-against-sqlite-failures-in-FTS-functi.patch new file mode 100644 index 0000000..7c6977d --- /dev/null +++ b/SOURCES/0001-fts-Strengthen-against-sqlite-failures-in-FTS-functi.patch @@ -0,0 +1,136 @@ +From 00b71d0f9ae3f4d2b7bc8fa2afe08cd89c5c9c35 Mon Sep 17 00:00:00 2001 +From: Carlos Garnacho +Date: Tue, 3 Dec 2013 16:17:54 +0100 +Subject: [PATCH] fts: Strengthen against sqlite failures in FTS functions + +function_weights() and function_property_names() (used respectively by +SPARQL fts:rank and fts:offsets functions), initialize all data at first +from the database, so it's available in memory for posterior runs, +although currently those are being quite optimistic about the database +return values in several ways, so: + +- Ensure no infinite loops happen on sqlite3_step() if the stmt trips + into some unexpected state. SQLITE_BUSY still does keep looping though. + +- As initialization here is a failable task, stop using g_once_init_* + and use an static GMutex so initialization can be tried later again + if it failed previously. + +- For the cases where initialization failed, propagate the error code + on the sqlite3_context. + +Based on work by Tim Waugh and Michael Catanzaro. +https://bugzilla.redhat.com/show_bug.cgi?id=1026283 +--- + src/libtracker-fts/tracker-fts.c | 52 +++++++++++++++++++++++++++------------- + 1 file changed, 36 insertions(+), 16 deletions(-) + +diff --git a/src/libtracker-fts/tracker-fts.c b/src/libtracker-fts/tracker-fts.c +index 530d831..446a4a6 100644 +--- a/src/libtracker-fts/tracker-fts.c ++++ b/src/libtracker-fts/tracker-fts.c +@@ -127,13 +127,15 @@ function_weights (sqlite3_context *context, + sqlite3_value *argv[]) + { + static guint *weights = NULL; +- static gsize weights_initialized = 0; ++ static GMutex mutex; ++ int rc = SQLITE_DONE; + +- if (g_once_init_enter (&weights_initialized)) { ++ g_mutex_lock (&mutex); ++ ++ if (G_UNLIKELY (weights == NULL)) { + GArray *weight_array; + sqlite3_stmt *stmt; + sqlite3 *db; +- int rc; + + weight_array = g_array_new (FALSE, FALSE, sizeof (guint)); + db = sqlite3_context_db_handle (context); +@@ -149,18 +151,26 @@ function_weights (sqlite3_context *context, + guint weight; + weight = sqlite3_column_int (stmt, 0); + g_array_append_val (weight_array, weight); ++ } else if (rc != SQLITE_BUSY) { ++ break; + } + } + ++ sqlite3_finalize (stmt); ++ + if (rc == SQLITE_DONE) { +- rc = sqlite3_finalize (stmt); ++ weights = (guint *) g_array_free (weight_array, FALSE); ++ } else { ++ g_array_free (weight_array, TRUE); + } +- +- weights = (guint *) g_array_free (weight_array, FALSE); +- g_once_init_leave (&weights_initialized, (rc == SQLITE_OK)); + } + +- sqlite3_result_blob (context, weights, sizeof (weights), NULL); ++ g_mutex_unlock (&mutex); ++ ++ if (rc == SQLITE_DONE) ++ sqlite3_result_blob (context, weights, sizeof (weights), NULL); ++ else ++ sqlite3_result_error_code (context, rc); + } + + static void +@@ -169,13 +179,15 @@ function_property_names (sqlite3_context *context, + sqlite3_value *argv[]) + { + static gchar **names = NULL; +- static gsize names_initialized = 0; ++ static GMutex mutex; ++ int rc = SQLITE_DONE; + +- if (g_once_init_enter (&names_initialized)) { ++ g_mutex_lock (&mutex); ++ ++ if (G_UNLIKELY (names == NULL)) { + GPtrArray *names_array; + sqlite3_stmt *stmt; + sqlite3 *db; +- int rc; + + names_array = g_ptr_array_new (); + db = sqlite3_context_db_handle (context); +@@ -194,18 +206,26 @@ function_property_names (sqlite3_context *context, + + name = sqlite3_column_text (stmt, 0); + g_ptr_array_add (names_array, g_strdup (name)); ++ } else if (rc != SQLITE_BUSY) { ++ break; + } + } + ++ sqlite3_finalize (stmt); ++ + if (rc == SQLITE_DONE) { +- rc = sqlite3_finalize (stmt); ++ names = (gchar **) g_ptr_array_free (names_array, FALSE); ++ } else { ++ g_ptr_array_free (names_array, TRUE); + } +- +- names = (gchar **) g_ptr_array_free (names_array, FALSE); +- g_once_init_leave (&names_initialized, (rc == SQLITE_OK)); + } + +- sqlite3_result_blob (context, names, sizeof (names), NULL); ++ g_mutex_unlock (&mutex); ++ ++ if (rc == SQLITE_DONE) ++ sqlite3_result_blob (context, names, sizeof (names), NULL); ++ else ++ sqlite3_result_error_code (context, rc); + } + + static void +-- +1.8.4.2 + diff --git a/SPECS/tracker.spec b/SPECS/tracker.spec index bd3ac6f..494afb6 100644 --- a/SPECS/tracker.spec +++ b/SPECS/tracker.spec @@ -15,7 +15,7 @@ Summary: Desktop-neutral search tool and indexer Name: tracker Version: 0.16.2 -Release: 3%{?dist} +Release: 8%{?dist} License: GPLv2+ Group: Applications/System URL: http://projects.gnome.org/tracker/ @@ -33,6 +33,12 @@ Patch3: 0001-Add-a-newline-at-the-end-of-file.patch Patch4: 0002-libtracker-extract-tracker-extract-Remove-modulesdir.patch Patch5: 0003-tracker-extract-Rename-.rules.in-to-.rules.patch +# https://bugzilla.redhat.com/show_bug.cgi?id=1051470 +Patch6: 0001-fts-Strengthen-against-sqlite-failures-in-FTS-functi.patch + +# https://bugzilla.redhat.com/show_bug.cgi?id=1028194 +Patch7: 0001-Bump-the-minimum-memory-requirement-to-768M.patch + BuildRequires: poppler-glib-devel libxml2-devel libgsf-devel libgxps-devel BuildRequires: libuuid-devel dbus-glib-devel BuildRequires: nautilus-devel @@ -57,8 +63,6 @@ BuildRequires: gtk-doc graphviz BuildRequires: gobject-introspection BuildRequires: autoconf BuildRequires: automake -#BuildRequires: libtool -#BuildRequires: evolution-devel %if 0%{?with_thunderbird} BuildRequires: thunderbird @@ -102,14 +106,6 @@ Obsoletes: tracker-search-tool <= 0.12.0 Graphical frontend to tracker search (tracker-needle) and configuration (tracker-preferences) facilities. -#%package evolution-plugin -#Summary: Tracker's evolution plugin -#Group: User Interface/Desktops -#Requires: %{name}%{?_isa} = %{version}-%{release} - -#%description evolution-plugin -#Tracker's evolution plugin - %package firefox-plugin Summary: A simple bookmark exporter for Tracker Group: User Interface/Desktops @@ -154,11 +150,11 @@ This package contains the documentation for tracker %patch3 -p1 -b .newline %patch4 -p1 -b .modulesdir %patch5 -p1 -b .rename +%patch6 -p1 -b .fts +%patch7 -p1 -b .memory autoreconf -#%global evo_plugins_dir %(pkg-config evolution-plugin-3.0 --variable=plugindir) - ## nuke unwanted rpaths, see also ## https://fedoraproject.org/wiki/Packaging/Guidelines#Beware_of_Rpath sed -i -e 's|"/lib /usr/lib|"/%{_lib} %{_libdir}|' configure @@ -166,6 +162,7 @@ sed -i -e 's|"/lib /usr/lib|"/%{_lib} %{_libdir}|' configure %build %configure --disable-static \ --enable-gtk-doc \ + --enable-miner-evolution=no \ --with-firefox-plugin-dir=%{_libdir}/firefox/extensions \ %if 0%{?with_thunderbird} --with-thunderbird-plugin-dir=%{_libdir}/thunderbird/extensions \ @@ -262,10 +259,6 @@ fi %{_mandir}/man1/tracker-needle.1.gz %exclude %{_datadir}/applications/trackerbird-launcher.desktop -#%files evolution-plugin -#%{evo_plugins_dir}/liborg-freedesktop-Tracker-evolution-plugin.so -#%{evo_plugins_dir}/org-freedesktop-Tracker-evolution-plugin.eplug - %files firefox-plugin %{_datadir}/xul-ext/trackerfox/ %{_libdir}/firefox/extensions/trackerfox@bustany.org @@ -288,6 +281,23 @@ fi %{_datadir}/gtk-doc/html/ontology/ %changelog +* Fri Feb 28 2014 Matthias Clasen 0 16.2-8 +- Rebuild +Resolves: #1070803 + +* Fri Jan 24 2014 Daniel Mach - 0.16.2-7 +- Mass rebuild 2014-01-24 + +* Fri Jan 10 2014 Debarshi Ray - 0.16.2-6 +- Strengthen against sqlite failures in FTS functions +- Resolves: #1026283 + +* Fri Dec 27 2013 Daniel Mach - 0.16.2-5 +- Mass rebuild 2013-12-27 + +* Tue Nov 12 2013 Debarshi Ray - 0.16.2-4 +- Bump the minimum memory requirement to 768M (Red Hat #1028194) + * Mon Nov 04 2013 Debarshi Ray - 0.16.2-3 - The rules files should be architecture-neutral (Red Hat #884197)