libical >= 2.0.0 support (patch)

Ondřej Surý ondrej at
Tue May 24 04:40:44 EDT 2016


Debian has recently switched to libical >= 2.0.0 that hides some
previously exported symbols.

I rewrote custom icalrecur_add_rule to reconstruct RRULE from XML or
JSON to be reparsed again with icalrecurrencetype_from_string(char *).

I understand this is not optimal, but I believe that simplicity of the
code outweights the speed.

And I suggest to drop support for libical << 2.0.0 for simplicity. And
in that case I will weed out the HAVE_ICAL_<foo> macros and send another
patch with that (0018-* is just basic to get it compiled).

Please review (and apply) attached patch. I used buf_* functions to
reconstruct the cstring, but it desperately needs a review if I am using
those correctly and if it doesn't leak memory (it probably does? But in
that case json_x_value leaks it as well).

But hey it compiles! :)

Ondřej Surý <ondrej at>
Knot DNS ( – a high-performance DNS server
Knot Resolver ( – secure, privacy-aware,
fast DNS(SEC) resolver
Vše pro chleba ( – Potřeby pro pečení chleba
všeho druhu
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0019-Replace-the-custom-icalrecur_add_rule-with-reconstru.patch
Type: text/x-patch
Size: 5992 bytes
Desc: not available
URL: <>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0018-Require-libical-2.0-and-define-the-libical-feature-m.patch
Type: text/x-patch
Size: 2102 bytes
Desc: not available
URL: <>

More information about the Cyrus-devel mailing list