[php-pear-Net-URL] - rename Net_URL.xml to php-pear-Net-URL-USA.xml - set date.timezone during build

Remi Collet remi at fedoraproject.org
Sun Aug 15 17:31:44 UTC 2010


commit af43ef2aa09d53577071dc61a9689952b0f470c1
Author: remi <fedora at famillecollet.com>
Date:   Sun Aug 15 19:31:33 2010 +0200

    - rename Net_URL.xml to php-pear-Net-URL-USA.xml
    - set date.timezone during build

 .gitignore            |    1 +
 php-pear-Net-URL.spec |   24 ++++++++++++++++--------
 2 files changed, 17 insertions(+), 8 deletions(-)
---
diff --git a/.gitignore b/.gitignore
index 98a7f4b..2339036 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1 +1,2 @@
 Net_URL-1.0.15.tgz
+package.xml
diff --git a/php-pear-Net-URL.spec b/php-pear-Net-URL.spec
index dcfcf0d..6b8c26c 100644
--- a/php-pear-Net-URL.spec
+++ b/php-pear-Net-URL.spec
@@ -1,9 +1,9 @@
 %{!?__pear: %{expand: %%global __pear %{_bindir}/pear}}
-%define pear_name Net_URL
+%global pear_name Net_URL
 
 Name:           php-pear-Net-URL
 Version:        1.0.15
-Release:        3%{?dist}
+Release:        4%{?dist}
 Summary:        Easy parsing of URLs
 
 Group:          Development/Libraries
@@ -25,9 +25,13 @@ Provides easy parsing of URLs and their constituent parts.
 
 %prep
 %setup -qc
-[ -f package2.xml ] || mv package.xml package2.xml
-mv package2.xml %{pear_name}-%{version}/%{pear_name}.xml
+# Create a "localized" php.ini to avoid build warning
+cp /etc/php.ini .
+echo "date.timezone=UTC" >>php.ini
+
 cd %{pear_name}-%{version}
+# Package is V2
+mv ../package.xml %{name}.xml
 
 
 %build
@@ -38,7 +42,7 @@ cd %{pear_name}-%{version}
 %install
 cd %{pear_name}-%{version}
 rm -rf $RPM_BUILD_ROOT docdir
-%{__pear} install --nodeps --packagingroot $RPM_BUILD_ROOT %{pear_name}.xml
+PHPRC=../php.ini %{__pear} install --nodeps --packagingroot $RPM_BUILD_ROOT %{name}.xml
 
 # Move documentation
 mkdir -p docdir
@@ -49,7 +53,7 @@ rm -rf $RPM_BUILD_ROOT%{pear_phpdir}/.??*
 
 # Install XML package description
 install -d $RPM_BUILD_ROOT%{pear_xmldir}
-install -pm 644 %{pear_name}.xml $RPM_BUILD_ROOT%{pear_xmldir}
+install -pm 644 %{name}.xml $RPM_BUILD_ROOT%{pear_xmldir}
 
 
 %clean
@@ -58,7 +62,7 @@ rm -rf $RPM_BUILD_ROOT
 
 %post
 %{__pear} install --nodeps --soft --force --register-only \
-    %{pear_xmldir}/%{pear_name}.xml >/dev/null || :
+    %{pear_xmldir}/%{name}.xml >/dev/null || :
 
 %postun
 if [ $1 -eq 0 ] ; then
@@ -70,11 +74,15 @@ fi
 %files
 %defattr(-,root,root,-)
 %doc %{pear_name}-%{version}/docdir/%{pear_name}/docs/*
-%{pear_xmldir}/%{pear_name}.xml
+%{pear_xmldir}/%{name}.xml
 %{pear_phpdir}/Net
 
 
 %changelog
+* Sun Aug 15 2010 Remi Collet <Fedora at FamilleCollet.com> - 1.0.15-4
+- rename Net_URL.xml to php-pear-Net-URL-USA.xml
+- set date.timezone during build
+
 * Sun Jul 26 2009 Fedora Release Engineering <rel-eng at lists.fedoraproject.org> - 1.0.15-3
 - Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
 


More information about the scm-commits mailing list