[php-symfony2-Translation] Fedora PEAR packaging update

Shawn Iwinski siwinski at fedoraproject.org
Tue Oct 30 00:35:00 UTC 2012


commit a22a135a9b01c558404157a9d9be60a691b34cd9
Author: Shawn Iwinski <shawn.iwinski at gmail.com>
Date:   Mon Oct 29 20:34:47 2012 -0400

    Fedora PEAR packaging update
    
    See http://lists.fedoraproject.org/pipermail/php-devel/2012-October/000192.html
    
    - Added "%global pear_metadir" and usage in %install
    - Changed RPM_BUILD_ROOT to %{buildroot}

 php-symfony2-Translation.spec |   18 ++++++++++++------
 1 files changed, 12 insertions(+), 6 deletions(-)
---
diff --git a/php-symfony2-Translation.spec b/php-symfony2-Translation.spec
index b20e526..dadde3c 100644
--- a/php-symfony2-Translation.spec
+++ b/php-symfony2-Translation.spec
@@ -1,4 +1,5 @@
 %{!?__pear: %{expand: %%global __pear %{_bindir}/pear}}
+%{!?pear_metadir: %global pear_metadir %{pear_phpdir}}
 
 %global pear_channel pear.symfony.com
 %global pear_name    %(echo %{name} | sed -e 's/^php-symfony2-//' -e 's/-/_/g')
@@ -6,7 +7,7 @@
 
 Name:             php-symfony2-Translation
 Version:          2.1.2
-Release:          1%{?dist}
+Release:          2%{?dist}
 Summary:          Symfony2 %{pear_name} Component
 
 Group:            Development/Libraries
@@ -16,6 +17,7 @@ Source0:          http://%{pear_channel}/get/%{pear_name}-%{version}.tgz
 Patch0:           %{name}-tests-bootstrap.patch
 
 BuildArch:        noarch
+
 BuildRequires:    php-pear(PEAR)
 BuildRequires:    php-channel(%{pear_channel})
 # Test requires
@@ -32,7 +34,7 @@ BuildRequires:    php-pcre
 BuildRequires:    php-simplexml
 BuildRequires:    php-spl
 
-Requires:         php-common >= 5.3.3
+Requires:         php-common >= %{php_min_ver}
 Requires:         php-pear(PEAR)
 Requires:         php-channel(%{pear_channel})
 Requires(post):   %{__pear}
@@ -84,14 +86,14 @@ mv package.xml %{pear_name}-%{version}/%{name}.xml
 
 %install
 cd %{pear_name}-%{version}
-%{__pear} install --nodeps --packagingroot $RPM_BUILD_ROOT %{name}.xml
+%{__pear} install --nodeps --packagingroot %{buildroot} %{name}.xml
 
 # Clean up unnecessary files
-rm -rf $RPM_BUILD_ROOT%{pear_phpdir}/.??*
+rm -rf %{buildroot}%{pear_metadir}/.??*
 
 # Install XML package description
-mkdir -p $RPM_BUILD_ROOT%{pear_xmldir}
-install -pm 644 %{name}.xml $RPM_BUILD_ROOT%{pear_xmldir}
+mkdir -p %{buildroot}%{pear_xmldir}
+install -pm 644 %{name}.xml %{buildroot}%{pear_xmldir}
 
 
 %check
@@ -119,6 +121,10 @@ fi
 
 
 %changelog
+* Mon Oct 29 2012 Shawn Iwinski <shawn.iwinski at gmail.com> 2.1.2-2
+- Added "%%global pear_metadir" and usage in %%install
+- Changed RPM_BUILD_ROOT to %%{buildroot}
+
 * Tue Oct 23 2012 Shawn Iwinski <shawn.iwinski at gmail.com> 2.1.2-1
 - Updated to upstream version 2.1.2
 - Updated description


More information about the scm-commits mailing list