Update to 1.0.1
This commit is contained in:
parent
488b2eaad2
commit
dca16e7578
1
.gitignore
vendored
1
.gitignore
vendored
@ -1,2 +1,3 @@
|
||||
/libical-0.48.tar.gz
|
||||
/libical-1.0.tar.gz
|
||||
/libical-1.0.1.tar.gz
|
||||
|
@ -1,6 +1,6 @@
|
||||
diff -up libical-1.0/src/libical/icaltime.c.old libical-1.0/src/libical/icaltime.c
|
||||
--- libical-1.0/src/libical/icaltime.c.old 2014-11-26 13:29:50.809112801 +0100
|
||||
+++ libical-1.0/src/libical/icaltime.c 2014-11-26 14:56:05.740893525 +0100
|
||||
diff -up libical-1.0.1/src/libical/icaltime.c.avoid-putenv libical-1.0.1/src/libical/icaltime.c
|
||||
--- libical-1.0.1/src/libical/icaltime.c.avoid-putenv 2014-10-09 17:07:05.000000000 +0200
|
||||
+++ libical-1.0.1/src/libical/icaltime.c 2015-01-26 11:56:35.153309240 +0100
|
||||
@@ -64,11 +64,6 @@
|
||||
#define gmtime_r(tp,tmp) (gmtime(tp)?(*(tmp)=*gmtime(tp),(tmp)):0)
|
||||
#endif
|
||||
@ -22,25 +22,23 @@ diff -up libical-1.0/src/libical/icaltime.c.old libical-1.0/src/libical/icaltime
|
||||
{
|
||||
time_t tim;
|
||||
|
||||
@@ -85,7 +80,7 @@ static time_t make_time(struct tm *tm, i
|
||||
|
||||
@@ -91,13 +86,13 @@ static time_t make_time(struct tm *tm, i
|
||||
#if (SIZEOF_TIME_T == 4)
|
||||
/* check that year specification within range */
|
||||
|
||||
- if (tm->tm_year < 70 || tm->tm_year > 138)
|
||||
+ if (be_strict && sizeof (time_t) == 4 && (tm->tm_year < 70 || tm->tm_year > 138))
|
||||
+ if (be_strict && (tm->tm_year < 70 || tm->tm_year > 138))
|
||||
return((time_t) -1);
|
||||
|
||||
/* check that month specification within range */
|
||||
@@ -96,7 +91,7 @@ static time_t make_time(struct tm *tm, i
|
||||
/* check for upper bound of Jan 17, 2038 (to avoid possibility of
|
||||
32-bit arithmetic overflow) */
|
||||
|
||||
- if (tm->tm_year == 138) {
|
||||
+ if (be_strict && sizeof (time_t) == 4 && tm->tm_year == 138) {
|
||||
+ if (be_strict && tm->tm_year == 138) {
|
||||
if (tm->tm_mon > 0)
|
||||
return((time_t) -1);
|
||||
else if (tm->tm_mday > 17)
|
||||
@@ -289,99 +284,12 @@ time_t icaltime_as_timet(const struct ic
|
||||
@@ -291,99 +286,12 @@ time_t icaltime_as_timet(const struct ic
|
||||
stm.tm_year = tt.year-1900;
|
||||
stm.tm_isdst = -1;
|
||||
|
||||
@ -141,7 +139,7 @@ diff -up libical-1.0/src/libical/icaltime.c.old libical-1.0/src/libical/icaltime
|
||||
/** Return the time as seconds past the UNIX epoch, using the
|
||||
* given timezone.
|
||||
*
|
||||
@@ -395,8 +303,6 @@ time_t icaltime_as_timet_with_zone(const
|
||||
@@ -397,8 +305,6 @@ time_t icaltime_as_timet_with_zone(const
|
||||
{
|
||||
icaltimezone *utc_zone;
|
||||
struct tm stm;
|
||||
@ -150,7 +148,7 @@ diff -up libical-1.0/src/libical/icaltime.c.old libical-1.0/src/libical/icaltime
|
||||
struct icaltimetype local_tt;
|
||||
|
||||
utc_zone = icaltimezone_get_utc_timezone ();
|
||||
@@ -424,25 +330,8 @@ time_t icaltime_as_timet_with_zone(const
|
||||
@@ -426,25 +332,8 @@ time_t icaltime_as_timet_with_zone(const
|
||||
stm.tm_mon = local_tt.month-1;
|
||||
stm.tm_year = local_tt.year-1900;
|
||||
stm.tm_isdst = -1;
|
||||
|
@ -1,24 +0,0 @@
|
||||
Backported upstream patch to move the time zone fix in icaltimezone_get_utc_offset over
|
||||
to icaltimezone_get_utc_offset_of_utc_time. r1141 made a fix in the first function but not
|
||||
the second. This ensures these almost identical methods behave almost identically :) See
|
||||
http://sourceforge.net/p/freeassociation/code/1150/ for the upstream patch and also Red Hat
|
||||
Bugzilla at https://bugzilla.redhat.com/show_bug.cgi?id=1021136
|
||||
|
||||
--- libical-1.0/src/libical/icaltimezone.c 2013-04-14 19:24:42.000000000 +0200
|
||||
+++ libical-1.0/src/libical/icaltimezone.c.r1150 2013-10-20 01:31:42.000000000 +0200
|
||||
@@ -1045,9 +1045,12 @@
|
||||
change_num += step;
|
||||
|
||||
/* If we go past the start of the changes array, then we have no data
|
||||
- for this time so we return a UTC offset of 0. */
|
||||
- if (change_num < 0)
|
||||
- return 0;
|
||||
+ for this time so we return the prev UTC offset. */
|
||||
+ if (change_num < 0) {
|
||||
+ if (is_daylight)
|
||||
+ *is_daylight = ! tmp_change.is_daylight;
|
||||
+ return tmp_change.prev_utc_offset;
|
||||
+ }
|
||||
|
||||
if ((unsigned int)change_num >= zone->changes->num_elements)
|
||||
break;
|
@ -1,12 +0,0 @@
|
||||
diff -up libical-1.0/scripts/mkderivedvalues.pl.sort libical-1.0/scripts/mkderivedvalues.pl
|
||||
--- libical-1.0/scripts/mkderivedvalues.pl.sort 2013-11-21 14:46:33.330067572 +0100
|
||||
+++ libical-1.0/scripts/mkderivedvalues.pl 2013-11-21 14:46:47.037211733 +0100
|
||||
@@ -63,7 +63,7 @@ if($opt_h){
|
||||
print "typedef enum icalvalue_kind {\n";
|
||||
print " ICAL_ANY_VALUE=$idx,\n";
|
||||
|
||||
- foreach $value (keys %h) {
|
||||
+ foreach $value (sort keys %h) {
|
||||
|
||||
$idx++;
|
||||
my $ucv = join("",map {uc(lc($_));} split(/-/,$value));
|
@ -1,12 +0,0 @@
|
||||
diff -up libical-1.0/src/libical/icaltime.c.ycaltime libical-1.0/src/libical/icaltime.c
|
||||
--- libical-1.0/src/libical/icaltime.c.ycaltime 2015-01-12 18:51:47.753599914 -0500
|
||||
+++ libical-1.0/src/libical/icaltime.c 2015-01-12 18:51:56.111697783 -0500
|
||||
@@ -475,7 +475,7 @@ icaltime_is_leap_year (const int year)
|
||||
|
||||
|
||||
int
|
||||
-ycaltime_days_in_year (const int year)
|
||||
+icaltime_days_in_year (const int year)
|
||||
{
|
||||
if (icaltime_is_leap_year (year))
|
||||
return 366;
|
25
libical.spec
25
libical.spec
@ -1,14 +1,11 @@
|
||||
Summary: Reference implementation of the iCalendar data type and serialization format
|
||||
Name: libical
|
||||
Version: 1.0
|
||||
Release: 9%{?dist}
|
||||
Version: 1.0.1
|
||||
Release: 1%{?dist}
|
||||
License: LGPLv2 or MPLv1.1
|
||||
URL: http://freeassociation.sourceforge.net/
|
||||
Source: http://downloads.sourceforge.net/freeassociation/%{name}-%{version}.tar.gz
|
||||
Patch0: libical-1.0-r1150.patch
|
||||
Patch1: libical-1.0-r1156.patch
|
||||
Patch2: libical-1.0-avoid-putenv.patch
|
||||
Patch3: libical-1.0-ycaltime.patch
|
||||
Source: https://github.com/%{name}/%{name}/archive/v%{version}/%{name}-%{version}.tar.gz
|
||||
Patch0: libical-1.0-avoid-putenv.patch
|
||||
|
||||
BuildRequires: bison, byacc, flex
|
||||
BuildRequires: cmake
|
||||
@ -28,10 +25,7 @@ applications that use libical.
|
||||
|
||||
%prep
|
||||
%setup -q
|
||||
%patch0 -p1 -b .r1150
|
||||
%patch1 -p1 -b .r1156
|
||||
%patch2 -p1 -b .avoid-putenv
|
||||
%patch3 -p1 -b .ycaltime
|
||||
%patch0 -p1 -b .avoid-putenv
|
||||
|
||||
%build
|
||||
mkdir -p %{_target_platform}
|
||||
@ -47,12 +41,15 @@ make install/fast DESTDIR=%{buildroot} -C %{_target_platform}
|
||||
# omit static libs
|
||||
rm -fv %{buildroot}%{_libdir}/lib*.a
|
||||
|
||||
%check
|
||||
make test ARGS="-V" -C %{_target_platform}
|
||||
|
||||
%post -p /sbin/ldconfig
|
||||
|
||||
%postun -p /sbin/ldconfig
|
||||
|
||||
%files
|
||||
%doc LICENSE README THANKS
|
||||
%doc LICENSE ReadMe.txt THANKS
|
||||
%{_libdir}/libical.so.1*
|
||||
%{_libdir}/libicalss.so.1*
|
||||
%{_libdir}/libicalvcal.so.1*
|
||||
@ -64,9 +61,13 @@ rm -fv %{buildroot}%{_libdir}/lib*.a
|
||||
%{_libdir}/libicalss.so
|
||||
%{_libdir}/libicalvcal.so
|
||||
%{_libdir}/pkgconfig/libical.pc
|
||||
%{_libdir}/cmake/LibIcal/
|
||||
%{_includedir}/libical/
|
||||
|
||||
%changelog
|
||||
* Mon Jan 26 2015 Igor Gnatenko <ignatenkobrain@fedoraproject.org> - 1.0.1-1
|
||||
- Update to 1.0.1
|
||||
|
||||
* Mon Jan 12 2015 Matthias Clasen <mclasen@redhat.com> - 1.0-9
|
||||
- Fix a stupid typo in the definition of icaltime_days_in_year
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user