Source: zeitgeist
Version: 1.0.4-6
Severity: normal
Tags: patch
Xapian 2 was released back in March and I'm working towards a transition
to it in Debian. There are packages in experimental (currently of
2.1.0).
The currently packaged version of zeitgeist isn't compatible, but the
changes required are small and I've prepared a patch (attached).
The patched version will also work with Xapian 1.4.x so the patch can be
applied now (no need to coordinate it to happen together with the
transition).
Cheers,
Olly
--- a/extensions/fts++/indexer.cpp
+++ b/extensions/fts++/indexer.cpp
@@ -60,8 +60,8 @@
{
if (zeitgeist_utils_using_in_memory_database ())
{
- this->db = new Xapian::WritableDatabase;
- this->db->add_database (Xapian::InMemory::open ());
+ this->db = new Xapian::WritableDatabase ("",
+ Xapian::DB_BACKEND_INMEMORY);
}
else
{
@@ -112,10 +112,10 @@
FILTER_PREFIX_SUBJECT_STORAGE);
this->query_parser->add_prefix ("category", FILTER_PREFIX_XDG_CATEGORY);
- this->query_parser->add_valuerangeprocessor (
- new Xapian::NumberValueRangeProcessor (VALUE_EVENT_ID, "id"));
- this->query_parser->add_valuerangeprocessor (
- new Xapian::NumberValueRangeProcessor (VALUE_TIMESTAMP, "ms", false));
+ this->query_parser->add_rangeprocessor (
+ new Xapian::NumberRangeProcessor (VALUE_EVENT_ID, "id"));
+ this->query_parser->add_rangeprocessor (
+ new Xapian::NumberRangeProcessor (VALUE_TIMESTAMP, "ms", Xapian::RP_SUFFIX));
this->query_parser->set_default_op (Xapian::Query::OP_AND);
this->query_parser->set_database (*this->db);
@@ -215,8 +215,8 @@
if (zeitgeist_utils_using_in_memory_database ())
{
- this->db = new Xapian::WritableDatabase;
- this->db->add_database (Xapian::InMemory::open ());
+ this->db = new Xapian::WritableDatabase ("",
+ Xapian::DB_BACKEND_INMEMORY);
}
else
{