[53127] trunk/dports/lang/php5

ryandesign at macports.org ryandesign at macports.org
Mon Jun 29 21:19:44 PDT 2009


Revision: 53127
          http://trac.macports.org/changeset/53127
Author:   ryandesign at macports.org
Date:     2009-06-29 21:19:44 -0700 (Mon, 29 Jun 2009)
Log Message:
-----------
php5: fix date("Y") returning "0000" on PowerPC; see
http://lists.macosforge.org/pipermail/macports-users/2009-June/015743.html

Modified Paths:
--------------
    trunk/dports/lang/php5/Portfile

Added Paths:
-----------
    trunk/dports/lang/php5/files/patch-ext-date-php_date.c.diff

Modified: trunk/dports/lang/php5/Portfile
===================================================================
--- trunk/dports/lang/php5/Portfile	2009-06-30 04:05:59 UTC (rev 53126)
+++ trunk/dports/lang/php5/Portfile	2009-06-30 04:19:44 UTC (rev 53127)
@@ -5,6 +5,7 @@
 name                    php5
 epoch                   1
 version                 5.2.10
+revision                1
 set major               [lindex [split ${version} .] 0]
 set my_name             php${major}
 dist_subdir             ${my_name}
@@ -64,6 +65,7 @@
     port:freetype
 
 patchfiles \
+    patch-ext-date-php_date.c.diff \
     patch-bind.diff
 
 use_autoconf            yes

Added: trunk/dports/lang/php5/files/patch-ext-date-php_date.c.diff
===================================================================
--- trunk/dports/lang/php5/files/patch-ext-date-php_date.c.diff	                        (rev 0)
+++ trunk/dports/lang/php5/files/patch-ext-date-php_date.c.diff	2009-06-30 04:19:44 UTC (rev 53127)
@@ -0,0 +1,11 @@
+--- ext/date/php_date.c	2009-06-05 17:34:30.000000000 -0500
++++ ext/date/php_date.c	2009-06-29 22:39:00.000000000 -0500
+@@ -798,7 +798,7 @@
+ 			/* year */
+ 			case 'L': length = slprintf(buffer, 32, "%d", timelib_is_leap((int) t->y)); break;
+ 			case 'y': length = slprintf(buffer, 32, "%02d", (int) t->y % 100); break;
+-			case 'Y': length = slprintf(buffer, 32, "%s%04ld", t->y < 0 ? "-" : "", llabs(t->y)); break;
++			case 'Y': length = slprintf(buffer, 32, "%s%04lld", t->y < 0 ? "-" : "", llabs(t->y)); break;
+ 
+ 			/* time */
+ 			case 'a': length = slprintf(buffer, 32, "%s", t->h >= 12 ? "pm" : "am"); break;
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-changes/attachments/20090629/05cba1f1/attachment-0001.html>


More information about the macports-changes mailing list