[php-pear-Cache/f14/master] update to 1.5.6 - QA release

Remi Collet remi at fedoraproject.org
Wed Oct 27 17:22:42 UTC 2010


commit c6999006c17b09bbf4284c36593a04075d63c7d5
Author: remi <fedora at famillecollet.com>
Date:   Wed Oct 27 19:16:14 2010 +0200

    update to 1.5.6 - QA release

 .gitignore          |    2 ++
 php-pear-Cache.spec |   27 ++++++++++++++++++---------
 sources             |    2 +-
 xml2changelog       |   26 ++++++++++++++++----------
 4 files changed, 37 insertions(+), 20 deletions(-)
---
diff --git a/.gitignore b/.gitignore
index 4bf0d41..24426dc 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1 +1,3 @@
 Cache-1.5.5.tgz
+package.xml
+/Cache-1.5.6.tgz
diff --git a/php-pear-Cache.spec b/php-pear-Cache.spec
index e57dc6c..0784321 100644
--- a/php-pear-Cache.spec
+++ b/php-pear-Cache.spec
@@ -4,10 +4,10 @@
 ##define beta RC4
 
 Name:           php-pear-Cache
-Version:        1.5.5
+Version:        1.5.6
 
 %if %{?beta:0}%{!?beta:1}
-Release:        4%{?dist}
+Release:        1%{?dist}
 %else
 Release:        0.2.%{beta}%{?dist}
 %endif
@@ -18,14 +18,15 @@ License:        PHP
 URL:            http://pear.php.net/package/Cache
 Source0:        http://pear.php.net/get/%{pear_name}-%{version}%{?beta}.tgz
 Source2:        xml2changelog
-BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
 
+BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
 BuildArch:      noarch
-BuildRequires:  php-pear >= 1:1.4.9-1.2
+BuildRequires:  php-pear(PEAR) >= 1.7.0
+
 Requires(post): %{__pear}
 Requires(postun): %{__pear}
 Provides:       php-pear(%{pear_name}) = %{version}
-Requires:       php-pear(PEAR) >= 1.3.5
+Requires:       php-pear(PEAR) >= 1.7.0
 Requires(hint): php-pear(HTTP_Request)
 
 %description
@@ -36,11 +37,15 @@ between applications.
 
 %prep
 %setup -q -c
-# package.xml is V2
-%{_bindir}/php -n %{SOURCE2} package.xml >CHANGELOG
-mv package.xml %{pear_name}-%{version}%{?beta}/%{name}.xml
+%{_bindir}/php -n %{SOURCE2} package.xml | tee CHANGELOG | head -n 10
+
+# Create a "localized" php.ini to avoid build warning
+cp /etc/php.ini .
+echo "date.timezone=UTC" >>php.ini
 
 cd %{pear_name}-%{version}%{?beta}
+# package.xml is V2
+mv ../package.xml %{name}.xml
 
 
 %build
@@ -51,7 +56,7 @@ cd %{pear_name}-%{version}%{?beta}
 %install
 rm -rf $RPM_BUILD_ROOT docdir
 cd %{pear_name}-%{version}%{?beta}
-%{__pear} install --nodeps --packagingroot $RPM_BUILD_ROOT %{name}.xml
+PHPRC=../php.ini %{__pear} install --nodeps --packagingroot $RPM_BUILD_ROOT %{name}.xml
 
 
 # Clean up unnecessary files
@@ -87,6 +92,10 @@ fi
 
 
 %changelog
+* Wed Oct 27 2010 Remi Collet <Fedora at FamilleCollet.com> 1.5.6-1
+- Version 1.5.6 (stable) - API 1.5.5 (stable) - QA release
+- set timezone during build
+
 * Fri May 14 2010 Remi Collet <Fedora at FamilleCollet.com> 1.5.5-4
 - spec cleanup
 
diff --git a/sources b/sources
index ab091ec..290673c 100644
--- a/sources
+++ b/sources
@@ -1 +1 @@
-b3d5cd9953ce666884246a1942fe0f1e  Cache-1.5.5.tgz
+a8692d95365c85e1639c971ef1b55bac  Cache-1.5.6.tgz
diff --git a/xml2changelog b/xml2changelog
index c114873..eb6bd31 100644
--- a/xml2changelog
+++ b/xml2changelog
@@ -13,16 +13,22 @@ if ($xml['version'] >= "2"){ // Package.xml V 2.0
 		$xml->date, $xml->notes);
 	$new=$xml->version->release;
 
-	if (isset($xml->changelog->release) && count($xml->changelog->release)) 
-	    foreach($xml->changelog->release as $rel) {
-		$old=$rel->version->release;
-		if ("$old" != "$new") {
-		    printf("*** Version %s (%s) - API %s (%s) - %s\n\n%s\n\n",
-			$rel->version->release, $rel->stability->release, 
-			$rel->version->api, $rel->stability->api, 
-			$rel->date, $rel->notes);
-		}
-	    }
+	if (isset($xml->changelog->release) && count($xml->changelog->release)) {
+		$tab = array();
+		foreach($xml->changelog->release as $rel) {
+			$old=$rel->version->release;
+			if ("$old" != "$new") {
+				$tab[''.$rel->date] = $rel;
+			}
+		}	
+		krsort($tab);
+		foreach($tab as $rel) {
+			printf("*** Version %s (%s) - API %s (%s) - %s\n\n%s\n\n",
+				$rel->version->release, $rel->stability->release, 
+				$rel->version->api, $rel->stability->api, 
+				$rel->date, $rel->notes);
+	    	}
+	}
 } else { // Package.xml V 1.0
 	printf("* Version %s (%s) - %s\n\n%s\n\n",
 		$xml->release->version, $xml->release->state, $xml->release->date, $xml->release->notes);


More information about the scm-commits mailing list