diff options
-rw-r--r-- | Autoload-timezone.patch | 24 | ||||
-rw-r--r-- | php-theseer-autoload.spec | 19 |
2 files changed, 37 insertions, 6 deletions
diff --git a/Autoload-timezone.patch b/Autoload-timezone.patch new file mode 100644 index 0000000..631cbf8 --- /dev/null +++ b/Autoload-timezone.patch @@ -0,0 +1,24 @@ +From 70fb142b56fe010f1a2b52cf2a7a79059e17043c Mon Sep 17 00:00:00 2001 +From: Remi Collet <fedora@famillecollet.com> +Date: Wed, 12 Nov 2014 14:26:54 +0100 +Subject: [PATCH] define date.timezone to avoid warning (in buildystem) + +--- + phpab.php | 4 ++++ + 1 file changed, 4 insertions(+) + +diff --git a/phpab.php b/phpab.php +index 393e304..791e227 100755 +--- a/phpab.php ++++ b/phpab.php +@@ -44,6 +44,10 @@ + + define('PHPAB_VERSION', '%development%'); + ++if (!ini_get('date.timezone')) { ++ ini_set('date.timezone', 'UTC'); ++} ++ + require 'TheSeer/DirectoryScanner/autoload.php'; + require 'ezc/Base/base.php'; + diff --git a/php-theseer-autoload.spec b/php-theseer-autoload.spec index 2ab6689..96eb6f8 100644 --- a/php-theseer-autoload.spec +++ b/php-theseer-autoload.spec @@ -12,7 +12,7 @@ Name: php-theseer-autoload Version: 1.16.0 -Release: 1%{?dist} +Release: 2%{?dist} Summary: A tool and library to generate autoload code Group: Development/Libraries @@ -20,6 +20,9 @@ License: BSD URL: https://github.com/theseer/Autoload Source0: http://%{pear_channel}/get/%{pear_name}-%{version}.tgz +# https://github.com/theseer/Autoload/pull/52 +Patch0: %{pear_name}-timezone.patch + BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildArch: noarch BuildRequires: php(language) >= 5.3.1 @@ -59,7 +62,11 @@ the option of creating static require lists as well as phar archives. %setup -q -c cd %{pear_name}-%{version} -mv ../package.xml %{name}.xml +%patch0 -p1 -b .tz +# Drop checksum for patched file +sed -e '/phpab.php/s/md5sum="[^"]*"//' \ + ../package.xml >%{name}.xml +touch -r ../package.xml %{name}.xml %build @@ -89,10 +96,7 @@ require 'TheSeer/DirectoryScanner/autoload.php'; require 'TheSeer/Autoload/autoload.php'; EOF -phpunit \ - --include-path=%{buildroot}%{pear_phpdir} \ - -d date.timezone=UTC - +phpunit --include-path=%{buildroot}%{pear_phpdir} %clean @@ -121,6 +125,9 @@ fi %changelog +* Wed Nov 12 2014 Remi Collet <remi@fedoraproject.org> - 1.16.0-2 +- define date.timezone in phpab command to avoid warning + * Tue Sep 02 2014 Remi Collet <remi@fedoraproject.org> - 1.16.0-1 - Update to 1.16.0 |