* Thu Jul 16 2009 Joe Orton <jorton@redhat.com> 5.3.0-4
- rediff systzdata patch
This commit is contained in:
parent
1890efc06e
commit
5f68886a63
@ -16,30 +16,8 @@ r1: initial revision
|
||||
|
||||
Index: ext/date/lib/timelib.m4
|
||||
===================================================================
|
||||
--- ext/date/lib/timelib.m4 (revision 284069)
|
||||
+++ ext/date/lib/timelib.m4 (working copy)
|
||||
@@ -78,3 +78,17 @@
|
||||
|
||||
dnl Check for strtoll, atoll
|
||||
AC_CHECK_FUNCS(strtoll atoll strftime)
|
||||
+
|
||||
+PHP_ARG_WITH(system-tzdata, for use of system timezone data,
|
||||
+[ --with-system-tzdata[=DIR] to specify use of system timezone data],
|
||||
+no, no)
|
||||
+
|
||||
+if test "$PHP_SYSTEM_TZDATA" != "no"; then
|
||||
+ AC_DEFINE(HAVE_SYSTEM_TZDATA, 1, [Define if system timezone data is used])
|
||||
+
|
||||
+ if test "$PHP_SYSTEM_TZDATA" != "yes"; then
|
||||
+ AC_DEFINE_UNQUOTED(HAVE_SYSTEM_TZDATA_PREFIX, "$PHP_SYSTEM_TZDATA",
|
||||
+ [Define for location of system timezone data])
|
||||
+ fi
|
||||
+fi
|
||||
+
|
||||
Index: ext/date/lib/parse_tz.c
|
||||
===================================================================
|
||||
--- ext/date/lib/parse_tz.c (revision 284069)
|
||||
+++ ext/date/lib/parse_tz.c (working copy)
|
||||
--- php-5.3.0/ext/date/lib/parse_tz.c.systzdata
|
||||
+++ php-5.3.0/ext/date/lib/parse_tz.c
|
||||
@@ -20,6 +20,16 @@
|
||||
|
||||
#include "timelib.h"
|
||||
@ -57,7 +35,7 @@ Index: ext/date/lib/parse_tz.c
|
||||
#include <stdio.h>
|
||||
|
||||
#ifdef HAVE_LOCALE_H
|
||||
@@ -31,8 +41,13 @@
|
||||
@@ -31,7 +41,12 @@
|
||||
#else
|
||||
#include <strings.h>
|
||||
#endif
|
||||
@ -65,12 +43,11 @@ Index: ext/date/lib/parse_tz.c
|
||||
+#ifndef HAVE_SYSTEM_TZDATA
|
||||
#include "timezonedb.h"
|
||||
+#endif
|
||||
|
||||
+#include <ctype.h>
|
||||
+
|
||||
+#include <ctype.h>
|
||||
|
||||
#if (defined(__APPLE__) || defined(__APPLE_CC__)) && (defined(__BIG_ENDIAN__) || defined(__LITTLE_ENDIAN__))
|
||||
# if defined(__LITTLE_ENDIAN__)
|
||||
# undef WORDS_BIGENDIAN
|
||||
@@ -51,9 +66,14 @@
|
||||
|
||||
static void read_preamble(const unsigned char **tzf, timelib_tzinfo *tz)
|
||||
@ -89,7 +66,7 @@ Index: ext/date/lib/parse_tz.c
|
||||
/* read BC flag */
|
||||
tz->bc = (**tzf == '\1');
|
||||
*tzf += 1;
|
||||
@@ -253,8 +273,391 @@
|
||||
@@ -253,7 +273,390 @@ void timelib_dump_tzinfo(timelib_tzinfo
|
||||
}
|
||||
}
|
||||
|
||||
@ -122,7 +99,7 @@ Index: ext/date/lib/parse_tz.c
|
||||
+#define LOCINFO_HASH_SIZE (1021)
|
||||
+
|
||||
+static uint32_t tz_hash(const char *str)
|
||||
{
|
||||
+{
|
||||
+ const unsigned char *p = (const unsigned char *)str;
|
||||
+ uint32_t hash = 5381;
|
||||
+ int c;
|
||||
@ -478,11 +455,10 @@ Index: ext/date/lib/parse_tz.c
|
||||
+#endif
|
||||
+
|
||||
+static int inmem_seek_to_tz_position(const unsigned char **tzf, char *timezone, const timelib_tzdb *tzdb)
|
||||
+{
|
||||
{
|
||||
int left = 0, right = tzdb->index_size - 1;
|
||||
#ifdef HAVE_SETLOCALE
|
||||
char *cur_locale = NULL, *tmp;
|
||||
@@ -292,36 +695,124 @@
|
||||
@@ -292,36 +695,124 @@ static int seek_to_tz_position(const uns
|
||||
return 0;
|
||||
}
|
||||
|
||||
@ -610,3 +586,23 @@ Index: ext/date/lib/parse_tz.c
|
||||
} else {
|
||||
tmp = NULL;
|
||||
}
|
||||
--- php-5.3.0/ext/date/lib/timelib.m4.systzdata
|
||||
+++ php-5.3.0/ext/date/lib/timelib.m4
|
||||
@@ -78,3 +78,17 @@ stdlib.h
|
||||
|
||||
dnl Check for strtoll, atoll
|
||||
AC_CHECK_FUNCS(strtoll atoll strftime)
|
||||
+
|
||||
+PHP_ARG_WITH(system-tzdata, for use of system timezone data,
|
||||
+[ --with-system-tzdata[=DIR] to specify use of system timezone data],
|
||||
+no, no)
|
||||
+
|
||||
+if test "$PHP_SYSTEM_TZDATA" != "no"; then
|
||||
+ AC_DEFINE(HAVE_SYSTEM_TZDATA, 1, [Define if system timezone data is used])
|
||||
+
|
||||
+ if test "$PHP_SYSTEM_TZDATA" != "yes"; then
|
||||
+ AC_DEFINE_UNQUOTED(HAVE_SYSTEM_TZDATA_PREFIX, "$PHP_SYSTEM_TZDATA",
|
||||
+ [Define for location of system timezone data])
|
||||
+ fi
|
||||
+fi
|
||||
+
|
||||
|
5
php.spec
5
php.spec
@ -13,7 +13,7 @@
|
||||
Summary: PHP scripting language for creating dynamic web sites
|
||||
Name: php
|
||||
Version: 5.3.0
|
||||
Release: 3%{?dist}
|
||||
Release: 4%{?dist}
|
||||
License: PHP
|
||||
Group: Development/Languages
|
||||
URL: http://www.php.net/
|
||||
@ -843,6 +843,9 @@ rm files.* macros.php
|
||||
%files enchant -f files.enchant
|
||||
|
||||
%changelog
|
||||
* Thu Jul 16 2009 Joe Orton <jorton@redhat.com> 5.3.0-4
|
||||
- rediff systzdata patch
|
||||
|
||||
* Thu Jul 16 2009 Joe Orton <jorton@redhat.com> 5.3.0-3
|
||||
- update to v6 of systzdata patch; various fixes
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user