From dd88fdbbed44490e389c7def9eed0ef82d5a6df782fdf46c9b745a818fc6542c Mon Sep 17 00:00:00 2001 From: Christophe Giboudeaux Date: Sun, 27 Aug 2017 07:20:28 +0000 Subject: [PATCH] Accepting request 518881 from home:wolfi323:branches:KDE:Applications - Add Fix-SQLite-DB-schema-upgrade.patch to fix Akonadi not starting when the sqlite plugin is used because the database schema upgrade fails due to unsupported syntax (kde#384024) OBS-URL: https://build.opensuse.org/request/show/518881 OBS-URL: https://build.opensuse.org/package/show/KDE:Applications/akonadi-server?expand=0&rev=122 --- Fix-SQLite-DB-schema-upgrade.patch | 33 ++++++++++++++++++++++++++++++ akonadi-server.changes | 7 +++++++ akonadi-server.spec | 3 +++ 3 files changed, 43 insertions(+) create mode 100644 Fix-SQLite-DB-schema-upgrade.patch diff --git a/Fix-SQLite-DB-schema-upgrade.patch b/Fix-SQLite-DB-schema-upgrade.patch new file mode 100644 index 0000000..b730f9a --- /dev/null +++ b/Fix-SQLite-DB-schema-upgrade.patch @@ -0,0 +1,33 @@ +From 2fcd7c4c4f6cc512de9d7778ab67d637934e7638 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Daniel=20Vr=C3=A1til?= +Date: Sat, 26 Aug 2017 12:03:40 +0200 +Subject: Fix SQLite DB schema upgrade to version 35 + +SQLite does not support DROP COLUMN and our upgrade language is not +expressive enough to handle that in another way, so for now we just +leave the 'external' column in PartTable on SQLite, it will simply +be ignored. On other backends the column is removed as expected. + +BUG: 384024 +FIXED-IN: 5.6.1 +--- + src/server/storage/dbupdate.xml | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +diff --git a/src/server/storage/dbupdate.xml b/src/server/storage/dbupdate.xml +index 80fb9d7..c5f9777 100644 +--- a/src/server/storage/dbupdate.xml ++++ b/src/server/storage/dbupdate.xml +@@ -323,7 +323,8 @@ + + + UPDATE PartTable SET storage = external; +- ALTER TABLE PartTable DROP COLUMN external; ++ ALTER TABLE PartTable DROP COLUMN external; ++ + UPDATE PartTable SET storage = cast(external as integer); + ALTER TABLE PartTable DROP COLUMN external; + +-- +cgit v0.11.2 + diff --git a/akonadi-server.changes b/akonadi-server.changes index be4bd3b..457a886 100644 --- a/akonadi-server.changes +++ b/akonadi-server.changes @@ -1,3 +1,10 @@ +------------------------------------------------------------------- +Sat Aug 26 10:25:05 UTC 2017 - wbauer@tmo.at + +- Add Fix-SQLite-DB-schema-upgrade.patch to fix Akonadi not + starting when the sqlite plugin is used because the database + schema upgrade fails due to unsupported syntax (kde#384024) + ------------------------------------------------------------------- Fri Aug 11 22:44:47 UTC 2017 - christophe@krop.fr diff --git a/akonadi-server.spec b/akonadi-server.spec index f57278b..fbc06c9 100644 --- a/akonadi-server.spec +++ b/akonadi-server.spec @@ -31,6 +31,8 @@ Group: System/GUI/KDE Url: http://akonadi-project.org Source: %{rname}-%{version}.tar.xz Source99: akonadi-server-rpmlintrc +# PATCH-FIX-UPSTREAM +Patch: Fix-SQLite-DB-schema-upgrade.patch %if 0%{?suse_version} > 1325 BuildRequires: libboost_headers-devel %else @@ -172,6 +174,7 @@ service. %prep %setup -q -n %{rname}-%{version} +%patch -p1 %build %cmake_kf5 -d build -- -DINSTALL_QSQLITE_IN_QT_PREFIX=TRUE -DQT_PLUGINS_DIR=%{_kf5_plugindir}