[php-pear-PEAR-Command-Packaging] missing channel name in Provides for package from non standard channel

Remi Collet remi at fedoraproject.org
Wed Jan 25 16:32:21 UTC 2012


commit be6d7e4a542ebf9e0778b6e344be576b2be8a1a6
Author: remi <fedora at famillecollet.com>
Date:   Wed Jan 25 17:31:47 2012 +0100

    missing channel name in Provides for package from non standard channel

 ...ommand-Packaging-0.2.0-fedora-conventions.patch |   18 +++++-------------
 ...PEAR-Command-Packaging-fedora-template-specfile |    7 +------
 php-pear-PEAR-Command-Packaging.spec               |   12 ++++++------
 3 files changed, 12 insertions(+), 25 deletions(-)
---
diff --git a/php-pear-PEAR-Command-Packaging-0.2.0-fedora-conventions.patch b/php-pear-PEAR-Command-Packaging-0.2.0-fedora-conventions.patch
index 3c1749c..92baba6 100644
--- a/php-pear-PEAR-Command-Packaging-0.2.0-fedora-conventions.patch
+++ b/php-pear-PEAR-Command-Packaging-0.2.0-fedora-conventions.patch
@@ -6,13 +6,13 @@ diff -up package.xml.orig package.xml
    <dir baseinstalldir="PEAR/Command" name="/">
     <file baseinstalldir="PEAR/Command" md5sum="72a74194c78677dba2584098c3b53a2e" name="Packaging.xml" role="php" />
 -   <file baseinstalldir="PEAR/Command" md5sum="70509a4f539f3f8b219fccf38831a38b" name="Packaging.php" role="php">
-+   <file baseinstalldir="PEAR/Command" md5sum="5f97e963109b46d09427c23b64a40155" name="Packaging.php" role="php">
++   <file baseinstalldir="PEAR/Command" name="Packaging.php" role="php">
      <tasks:replace from="@DATA-DIR@" to="data_dir" type="pear-config" />
      <tasks:replace from="@package_version@" to="version" type="package-info" />
     </file>
 diff -up PEAR_Command_Packaging-0.2.0/Packaging.php.orig PEAR_Command_Packaging-0.2.0/Packaging.php
---- PEAR_Command_Packaging-0.2.0/Packaging.php.orig	2010-02-20 08:48:14.000000000 +0100
-+++ PEAR_Command_Packaging-0.2.0/Packaging.php	2010-02-20 08:48:17.000000000 +0100
+--- PEAR_Command_Packaging-0.2.0/Packaging.php.fedora	1970-01-01 10:13:24.000000000 +0100
++++ PEAR_Command_Packaging-0.2.0/Packaging.php	2012-01-25 17:18:40.000000000 +0100
 @@ -72,15 +72,14 @@ are as follows:
  %n = Channel name (full) e.g. pear.example.com
  %N = Non standard channel name followed by a "/" (e.g. "pear.example.com/")
@@ -104,24 +104,16 @@ diff -up PEAR_Command_Packaging-0.2.0/Packaging.php.orig PEAR_Command_Packaging-
      
      // ------------------------------------------------------------------------
      // --- END DISTRIBUTION CONFIG
-@@ -593,13 +592,15 @@ Wrote: /path/to/rpm-build-tree/RPMS/noar
+@@ -593,7 +592,7 @@ Wrote: /path/to/rpm-build-tree/RPMS/noar
          if ($pf->getDeps()) {
              $this->_generatePackageDeps($pf);
          }
 -    
 +        
-+        /* Fedora: we handle this in our template spec
          // Hook to support virtual Provides, where the dependency name differs
          // from the package name
          $rpmdep = $this->_getRPMName($pf->getPackage(), $pf->getChannel(), null, 'pkgdep');
-         if (!empty($rpmdep) && $rpmdep != $this->_output['rpm_package']) {
-             $this->_output['extra_headers'] .= $this->_formatRpmHeader('Provides', "$rpmdep = %{version}") . "\n";
-         }
-+        */
-         
-         // Create the list of files in the package
-         foreach ($package_info['filelist'] as $filename => $attr) {
-@@ -657,9 +658,9 @@ Wrote: /path/to/rpm-build-tree/RPMS/noar
+@@ -657,9 +656,9 @@ Wrote: /path/to/rpm-build-tree/RPMS/noar
          
          // Handle doc files
          if (isset($file_list['doc'])) {
diff --git a/php-pear-PEAR-Command-Packaging-fedora-template-specfile b/php-pear-PEAR-Command-Packaging-fedora-template-specfile
index ebd0b9d..548a7ff 100644
--- a/php-pear-PEAR-Command-Packaging-fedora-template-specfile
+++ b/php-pear-PEAR-Command-Packaging-fedora-template-specfile
@@ -16,7 +16,6 @@ BuildArch:      noarch
 BuildRequires:  php-pear >= 1:1.4.9-1.2
 Requires(post): %{__pear}
 Requires(postun): %{__pear}
-Provides:       php-pear(%{pear_name}) = %{version}
 @extra_headers@
 
 %description
@@ -27,10 +26,6 @@ Provides:       php-pear(%{pear_name}) = %{version}
 [ -f package2.xml ] || mv package.xml package2.xml
 mv package2.xml %{pear_name}-%{version}/%{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}
 
 
@@ -42,7 +37,7 @@ cd %{pear_name}-%{version}
 %install
 cd %{pear_name}-%{version}
 rm -rf $RPM_BUILD_ROOT
-PHPRC=../php.ini %{__pear} install --nodeps --packagingroot $RPM_BUILD_ROOT %{name}.xml
+%{__pear} install --nodeps --packagingroot $RPM_BUILD_ROOT %{name}.xml
 
 # Clean up unnecessary files
 rm -rf $RPM_BUILD_ROOT%{pear_phpdir}/.??*
diff --git a/php-pear-PEAR-Command-Packaging.spec b/php-pear-PEAR-Command-Packaging.spec
index 7b78445..e5a2522 100644
--- a/php-pear-PEAR-Command-Packaging.spec
+++ b/php-pear-PEAR-Command-Packaging.spec
@@ -3,7 +3,7 @@
 
 Name:           php-pear-PEAR-Command-Packaging
 Version:        0.2.0
-Release:        7%{?dist}
+Release:        8%{?dist}
 Summary:        Create RPM spec files from PEAR modules
 
 Group:          Development/System
@@ -37,10 +37,6 @@ http://fedoraproject.org/wiki/Packaging:PHP
 # Patches for Fedora conventions
 %patch0 -p0 -b .fedora
 
-# Create a "localized" php.ini to avoid build warning
-cp /etc/php.ini .
-echo "date.timezone=UTC" >>php.ini
-
 mv package.xml %{pear_name}-%{version}/%{name}.xml
 cd %{pear_name}-%{version}
 
@@ -51,7 +47,7 @@ cd %{pear_name}-%{version}
 %install
 cd %{pear_name}-%{version}
 rm -rf $RPM_BUILD_ROOT
-PHPRC=../php.ini %{__pear} install --nodeps --packagingroot $RPM_BUILD_ROOT %{name}.xml
+%{__pear} install --nodeps --packagingroot $RPM_BUILD_ROOT %{name}.xml
 
 cp -p %{SOURCE1} $RPM_BUILD_ROOT%{pear_phpdir}/data/%{pear_name}/template.spec
 
@@ -86,6 +82,10 @@ fi
 
 
 %changelog
+* Wed Jan 25 2012 Remi Collet <remi at fedoraproject.org> - 0.2.0-8
+- clean fedora template
+- fix Provides for non standard channel (missing channel name)
+
 * Sat Jan 14 2012 Fedora Release Engineering <rel-eng at lists.fedoraproject.org> - 0.2.0-7
 - Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
 


More information about the scm-commits mailing list