diff --git a/libical-0.44.tar.bz2 b/libical-0.44.tar.bz2 deleted file mode 100644 index 90c1747..0000000 --- a/libical-0.44.tar.bz2 +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:5c26ec795a8acd86ef6a9f1923488e276ed8bc4a48361729b33ef4e2e2a1b6d4 -size 795297 diff --git a/libical-0.46-fix-endless-loop.patch b/libical-0.46-fix-endless-loop.patch new file mode 100644 index 0000000..02e8069 --- /dev/null +++ b/libical-0.46-fix-endless-loop.patch @@ -0,0 +1,13 @@ +Index: trunk/libical/src/libical/icalrecur.c +=================================================================== +--- trunk/libical/src/libical/icalrecur.c (revision 1043) ++++ trunk/libical/src/libical/icalrecur.c (revision 1044) +@@ -361,7 +361,7 @@ + char *t, *n; + int i=0; + int sign = 1; +- int weekno = 0; ++ char weekno = 0; /* note: Novell/Groupwise sends BYDAY=255SU, so we fit in a signed char to get -1 SU for last sunday. */ + icalrecurrencetype_weekday wd; + short *array = parser->rt.by_day; + char* end; diff --git a/libical-0.46-fix-fatal-error-macro-usage.patch b/libical-0.46-fix-fatal-error-macro-usage.patch new file mode 100644 index 0000000..07b3388 --- /dev/null +++ b/libical-0.46-fix-fatal-error-macro-usage.patch @@ -0,0 +1,70 @@ +Index: trunk/libical/src/libical/autogenex/ical.h +=================================================================== +--- trunk/libical/src/libical/autogenex/ical.h (revision 1041) ++++ trunk/libical/src/libical/autogenex/ical.h (revision 1042) +@@ -3272,7 +3272,7 @@ + void icalerror_set_errno(icalerrorenum x); + #endif + +-#ifdef ICAL_ERRORS_ARE_FATAL ++#if ICAL_ERRORS_ARE_FATAL == 1 + #undef NDEBUG + #endif + +@@ -3282,7 +3282,7 @@ + #define icalerror_check_component_type(value,type); + + /* Assert with a message */ +-#ifdef ICAL_ERRORS_ARE_FATAL ++#if ICAL_ERRORS_ARE_FATAL == 1 + + #ifdef __GNUC__ + #define icalerror_assert(test,message) if(!(test)){fprintf(stderr,"%s(), %s:%d: %s\n",__FUNCTION__,__FILE__,__LINE__,message);icalerror_stop_here(); abort();} +Index: trunk/libical/src/libical/icalparser.c +=================================================================== +--- trunk/libical/src/libical/icalparser.c (revision 1041) ++++ trunk/libical/src/libical/icalparser.c (revision 1042) +@@ -930,10 +930,7 @@ + + /* Change for mozilla */ + /* have the option of being flexible towards unsupported parameters */ +- #ifndef ICAL_ERRORS_ARE_FATAL +- continue; +- #endif +- ++ #if ICAL_ERRORS_ARE_FATAL == 1 + insert_error(tail, str, "Cant parse parameter name", + ICAL_XLICERRORTYPE_PARAMETERNAMEPARSEERROR); + tail = 0; +@@ -947,6 +944,9 @@ + name = 0; + } + return 0; ++ #else ++ continue; ++ #endif + } + + /* if (pvalue) { +Index: trunk/libical/src/libical/icalerror.h +=================================================================== +--- trunk/libical/src/libical/icalerror.h (revision 1041) ++++ trunk/libical/src/libical/icalerror.h (revision 1042) +@@ -121,7 +121,7 @@ + void icalerror_set_errno(icalerrorenum x); + #endif + +-#ifdef ICAL_ERRORS_ARE_FATAL ++#if ICAL_ERRORS_ARE_FATAL == 1 + #undef NDEBUG + #endif + +@@ -131,7 +131,7 @@ + #define icalerror_check_component_type(value,type); + + /* Assert with a message */ +-#ifdef ICAL_ERRORS_ARE_FATAL ++#if ICAL_ERRORS_ARE_FATAL == 1 + + #ifdef __GNUC__ + #define icalerror_assert(test,message) if(!(test)){fprintf(stderr,"%s(), %s:%d: %s\n",__FUNCTION__,__FILE__,__LINE__,message);icalerror_stop_here(); abort();} diff --git a/libical-0.46-fix-race.patch b/libical-0.46-fix-race.patch new file mode 100644 index 0000000..ed4bc07 --- /dev/null +++ b/libical-0.46-fix-race.patch @@ -0,0 +1,93 @@ +Index: trunk/libical/src/libical/icaltimezone.c +=================================================================== +--- trunk/libical/src/libical/icaltimezone.c (revision 1038) ++++ trunk/libical/src/libical/icaltimezone.c (revision 1039) +@@ -45,6 +45,11 @@ + + #include + ++#ifdef HAVE_PTHREAD ++#include ++static pthread_mutex_t builtin_mutex = PTHREAD_MUTEX_INITIALIZER; ++#endif ++ + #ifdef WIN32 + #include + #include +@@ -453,8 +458,7 @@ + + int changes_end_year; + +- if (!zone->component) +- icaltimezone_load_builtin_timezone (zone); ++ icaltimezone_load_builtin_timezone (zone); + + if (icaltimezone_minimum_expansion_year == -1) { + struct icaltimetype today = icaltime_today(); +@@ -1140,8 +1144,7 @@ + if (!zone) + return NULL; + +- if (!zone->tzid) +- icaltimezone_load_builtin_timezone (zone); ++ icaltimezone_load_builtin_timezone (zone); + + return zone->tzid; + } +@@ -1167,8 +1170,7 @@ + if (!zone) + return NULL; + +- if (!zone->component) +- icaltimezone_load_builtin_timezone (zone); ++ icaltimezone_load_builtin_timezone (zone); + + return zone->tznames; + } +@@ -1210,8 +1212,7 @@ + if (!zone) + return NULL; + +- if (!zone->component) +- icaltimezone_load_builtin_timezone (zone); ++ icaltimezone_load_builtin_timezone (zone); + + return zone->component; + } +@@ -1449,8 +1450,7 @@ + for (i=0; icomponent) +- icaltimezone_load_builtin_timezone (zone); ++ icaltimezone_load_builtin_timezone (zone); + + z_offset = get_offset(zone); + +@@ -1745,6 +1745,12 @@ + if (!zone->location || !zone->location[0]) + return; + ++#ifdef HAVE_PTHREAD ++ pthread_mutex_lock(&builtin_mutex); ++ if (zone->component) ++ goto out; ++#endif ++ + #ifdef USE_BUILTIN_TZDATA + { + char *filename; +@@ -1801,8 +1807,11 @@ + icalcomponent_remove_component(comp,subcomp); + icalcomponent_free(comp); + } +-#endif +- ++#endif ++#ifdef HAVE_PTHREAD ++ out: ++ pthread_mutex_unlock(&builtin_mutex); ++#endif + } + + diff --git a/libical-0.46.tar.bz2 b/libical-0.46.tar.bz2 new file mode 100644 index 0000000..22e6c92 --- /dev/null +++ b/libical-0.46.tar.bz2 @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:bc9c9b6dd822d294d72a730015b13784e2ae6967dba52fbf731f7653c917f959 +size 758365 diff --git a/libical.changes b/libical.changes index ff6d767..594959d 100644 --- a/libical.changes +++ b/libical.changes @@ -1,3 +1,36 @@ +------------------------------------------------------------------- +Fri Mar 11 20:04:22 UTC 2011 - gber@opensuse.org + +- update to version 0.46 + + allow control over how components, properties and parameters + with unknown names are handled + + renamed static set_zone_directory() to set_zonedir() + + added appropriate icaltime_* functions as methods to + icaltimetype + + added icaltimetype.datetime for converting a icaltimetype to a + python datetime + + added icalarray_copy for easy copying of icalarrays + + renamed icaltimetype.datetime to icaltimetype.as_datetime and + added icaltimetype.from_datetime staticmethod + + bugfixes +- correct licensing information +- run autoreconf since tarball misses autconf autgenerated files + (sf#3072673) +- added libical-0.46-fix-race.patch from upstream svn which fixes a + race in populating builtin timezone components +- added libical-0.46-fix-fatal-error-macro-usage.patch from + upstream svn in order to replace broken ICAL_ERRORS_ARE_FATAL + preprocessor conditions with the correct check for the macros + value (sf#3140405) +- added libical-0.46-fix-fatal-error-macro-usage.patch from + upstream svn which fixes endless loop in the recurrence + calculation (sf#3177380) + +------------------------------------------------------------------- +Sat Apr 24 11:38:20 UTC 2010 - coolo@novell.com + +- buildrequire pkg-config to fix provides + ------------------------------------------------------------------- Wed Jan 6 04:49:26 CET 2010 - jengelh@medozas.de diff --git a/libical.spec b/libical.spec index 54bc54d..8d32792 100644 --- a/libical.spec +++ b/libical.spec @@ -1,5 +1,5 @@ # -# spec file for package libical (Version 0.44) +# spec file for package libical (Version 0.46) # # Copyright (c) 2010 SUSE LINUX Products GmbH, Nuernberg, Germany. # @@ -15,20 +15,23 @@ # Please submit bugfixes or comments via http://bugs.opensuse.org/ # -# norootforbuild - Name: libical -BuildRequires: db-devel python-devel +BuildRequires: db-devel pkg-config python-devel Url: http://sourceforge.net/projects/freeassociation/ -License: LGPL v2.1 or later ; MPL .. +License: LGPLv2 or MPLv1.1 Group: Development/Libraries/C and C++ -AutoReqProv: on -Version: 0.44 -Release: 2 +Version: 0.46 +Release: 3 Summary: An Implementation of Basic iCAL Protocols Source: libical-%{version}.tar.bz2 Source2: baselibs.conf +# libical-0.46-fix-race.patch gber@opensuse.org -- Fixes a race in populating builtin timezone components (from upstream svn) +Patch0: libical-0.46-fix-race.patch +# libical-0.46-fix-fatal-error-macro-usage.patch sf#3140405 gber@opensuse.org -- Replace broken ICAL_ERRORS_ARE_FATAL preprocessor conditions with the correct check for the macros value +Patch1: libical-0.46-fix-fatal-error-macro-usage.patch +# libical-0.46-fix-endless-loop.patch sf#3177380 gber@opensuse.org -- Fixes endless loop in recurrence calculation +Patch2: libical-0.46-fix-endless-loop.patch BuildRoot: %{_tmppath}/%{name}-%{version}-build Requires: libical0 = %{version} @@ -38,19 +41,12 @@ calendaring and scheduling protocols (RFC 2445, 2446, and 2447). It parses iCal components and provides a C API for manipulating the component properties, parameters, and subcomponents. - - -Authors: --------- - Eric Busboom - %package -n libical0 License: MPL .. Summary: An Implementation of Basic iCAL Protocols Group: Development/Libraries/C and C++ Provides: libical = %{version} Obsoletes: libical < %{version} -AutoReqProv: on %description -n libical0 Libical is an open source implementation of the IETF's iCalendar @@ -58,18 +54,11 @@ calendaring and scheduling protocols (RFC 2445, 2446, and 2447). It parses iCal components and provides a C API for manipulating the component properties, parameters, and subcomponents. - - -Authors: --------- - Eric Busboom - %package -n libical-devel License: MPL .. Summary: An implementation of basic iCAL protocols Group: Development/Libraries/C and C++ Requires: libical = %{version} -AutoReqProv: on %description -n libical-devel Libical is an Open Source implementation of the IETF's iCalendar @@ -77,12 +66,6 @@ Calendaring and Scheduling protocols. (RFC 2445, 2446, and 2447). It parses iCal components and provides a C API for manipulating the component properties, parameters, and subcomponents. - - -Authors: --------- - Eric Busboom - %package -n libical-doc License: MPL .. Summary: An Implementation of Basic iCAL Protocols @@ -95,17 +78,15 @@ calendaring and scheduling protocols (RFC 2445, 2446, and 2447). It parses iCal components and provides a C API for manipulating the component properties, parameters, and subcomponents. - - -Authors: --------- - Eric Busboom - %prep -%setup +%setup -q +%patch0 -p2 +%patch1 -p2 +%patch2 -p2 %build -#autoreconf -f -i +# triger autoreconf since the 0.46 tarball is missing autotools bootstrap files +autoreconf -f -i %{configure} \ --with-bdb4 \ --with-bdb4-dir=%{_prefix} \