Source: citadel
Version: 9.01-1
Severity: normal
Tags: patch

Dear Maintainer,

Initial plans has been started for transitioning to libical 2.0.0
(currently stuck in NEW).

Your package fails to build from source with the new version.
Please see attached patches which are on top of the citadel
git packaging repo. (Please replace the bug report number in the
first commit message with whatever number this bug report gets
and replace the forth/last patch with a fresh "gbp dch --auto"
run.)

(See also #797074 if you're interested in current transition planning.)

Regards,
Andreas Henriksson
>From 695d48e311e0e1463afc98537cd05f9e3684cc4a Mon Sep 17 00:00:00 2001
From: Andreas Henriksson <andr...@fatal.se>
Date: Mon, 25 Apr 2016 15:32:33 +0200
Subject: [PATCH 1/4] Add debian/patches/icalerror_errors_are_fatal.patch

- fixes building against libical 2.0.0

Git-Dch: Full
Closes: #-1
---
 debian/patches/icalerror_errors_are_fatal.patch | 22 ++++++++++++++++++++++
 debian/patches/series                           |  1 +
 2 files changed, 23 insertions(+)
 create mode 100644 debian/patches/icalerror_errors_are_fatal.patch
 create mode 100644 debian/patches/series

diff --git a/debian/patches/icalerror_errors_are_fatal.patch b/debian/patches/icalerror_errors_are_fatal.patch
new file mode 100644
index 0000000..a31ff6f
--- /dev/null
+++ b/debian/patches/icalerror_errors_are_fatal.patch
@@ -0,0 +1,22 @@
+From: Andreas Henriksson <andr...@fatal.se>
+Subject: Fix building with libical 2.0.0
+
+Use new helper function since the global variable was removed.
+
+See https://github.com/libical/libical/commit/6e5534a979b3ab4d28e5a32f5
+
+Note that this unconditionally uses the new function as the macro
+ICAL_CHECK_VERSION was not added in 2.0.0 yet. Maybe it can be
+utilized in the future....
+
+--- a/modules/calendar/serv_calendar.c
++++ b/modules/calendar/serv_calendar.c
+@@ -2586,7 +2586,7 @@
+ 	{
+ 
+ 		/* Tell libical to return errors instead of aborting if it gets bad data */
+-		icalerror_errors_are_fatal = 0;
++		icalerror_set_errors_are_fatal(0);
+ 
+ 		/* Use our own application prefix in tzid's generated from system tzdata */
+ 		icaltimezone_set_tzid_prefix("/citadel.org/");
diff --git a/debian/patches/series b/debian/patches/series
new file mode 100644
index 0000000..baceaf6
--- /dev/null
+++ b/debian/patches/series
@@ -0,0 +1 @@
+icalerror_errors_are_fatal.patch
-- 
2.8.0.rc3

>From f73ea4c74c73a2d8ee67613a5c7393ab14fa2f57 Mon Sep 17 00:00:00 2001
From: Andreas Henriksson <andr...@fatal.se>
Date: Mon, 25 Apr 2016 15:33:37 +0200
Subject: [PATCH 2/4] Bump libical-dev build-dependency to >= 2.0.0

- see previously added patch header

Git-Dch: Full
---
 debian/control | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/debian/control b/debian/control
index 6ca9737..4030dd4 100644
--- a/debian/control
+++ b/debian/control
@@ -4,7 +4,7 @@ Priority: extra
 Maintainer: Debian Citadel Team <pkg-citadel-de...@lists.alioth.debian.org>
 Uploaders: Wilfried Goesgens <w.goesg...@outgesourced.org>, Michael Meskes <mes...@debian.org>, Alexander Wirt <formo...@debian.org>
 Build-Depends: debhelper (>= 7.0.50~), po-debconf, bison, autotools-dev, 
- libdb-dev, libexpat1-dev, libical-dev (>=0.43), libldap2-dev, libncurses5-dev,
+ libdb-dev, libexpat1-dev, libical-dev (>= 2.0.0), libldap2-dev, libncurses5-dev,
  libpam0g-dev, libsieve2-dev, libssl-dev, libcitadel-dev (>= 9.01),
  libcurl4-openssl-dev (>> 7.25), zlib1g-dev, libev-dev (>= 4.0), libc-ares-dev (>= 1.7.2)
 Standards-Version: 3.9.6
-- 
2.8.0.rc3

>From c3d0ece3d0919e06956885c1d963d088c4074641 Mon Sep 17 00:00:00 2001
From: Andreas Henriksson <andr...@fatal.se>
Date: Mon, 25 Apr 2016 15:34:55 +0200
Subject: [PATCH 3/4] Add build-dependency and use quilt sequencer to apply
 debian/patches

---
 debian/control | 2 +-
 debian/rules   | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/debian/control b/debian/control
index 4030dd4..30bbb00 100644
--- a/debian/control
+++ b/debian/control
@@ -3,7 +3,7 @@ Section: mail
 Priority: extra
 Maintainer: Debian Citadel Team <pkg-citadel-de...@lists.alioth.debian.org>
 Uploaders: Wilfried Goesgens <w.goesg...@outgesourced.org>, Michael Meskes <mes...@debian.org>, Alexander Wirt <formo...@debian.org>
-Build-Depends: debhelper (>= 7.0.50~), po-debconf, bison, autotools-dev, 
+Build-Depends: debhelper (>= 7.0.50~), po-debconf, quilt, bison, autotools-dev, 
  libdb-dev, libexpat1-dev, libical-dev (>= 2.0.0), libldap2-dev, libncurses5-dev,
  libpam0g-dev, libsieve2-dev, libssl-dev, libcitadel-dev (>= 9.01),
  libcurl4-openssl-dev (>> 7.25), zlib1g-dev, libev-dev (>= 4.0), libc-ares-dev (>= 1.7.2)
diff --git a/debian/rules b/debian/rules
index d510c35..6e80075 100755
--- a/debian/rules
+++ b/debian/rules
@@ -101,5 +101,5 @@ override_dh_strip:
 	dh_strip --dbg-package=citadel-dbg
 
 %:
-	dh $@ --with autotools-dev
+	dh $@ --with autotools-dev,quilt
 
-- 
2.8.0.rc3

>From 9548a8c1756cc647e7dac27cb4cef9141fba3868 Mon Sep 17 00:00:00 2001
From: Andreas Henriksson <andr...@fatal.se>
Date: Mon, 25 Apr 2016 15:35:35 +0200
Subject: [PATCH 4/4] Update debian/changelog

---
 debian/changelog | 12 ++++++++++++
 1 file changed, 12 insertions(+)

diff --git a/debian/changelog b/debian/changelog
index 16b3549..df535c2 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,15 @@
+citadel (9.01-1.1) UNRELEASED; urgency=medium
+
+  * Non-maintainer upload.
+  * Add debian/patches/icalerror_errors_are_fatal.patch
+    - fixes building against libical 2.0.0
+    Closes: #-1
+  * Bump libical-dev build-dependency to >= 2.0.0
+    - see previously added patch header
+  * Add build-dependency and use quilt sequencer to apply debian/patches
+
+ -- Andreas Henriksson <andr...@fatal.se>  Mon, 25 Apr 2016 15:35:15 +0200
+
 citadel (9.01-1) unstable; urgency=medium
 
   * Imported Upstream version 9.01
-- 
2.8.0.rc3

Reply via email to