remi pushed to php-phpunit-FinderFacade (f22). "- upgrade to 1.2.0 (..more)"

notifications at fedoraproject.org notifications at fedoraproject.org
Thu Jun 4 12:09:31 UTC 2015


From 59a22708daf514b021cb775bb3e19b48b553b0a1 Mon Sep 17 00:00:00 2001
From: Remi Collet <remi at fedoraproject.org>
Date: Thu, 4 Jun 2015 13:53:58 +0200
Subject: - upgrade to 1.2.0 - raise dependency on symfony/finder 2.3 -
 generate autoloader (dropped upstream) - fix license handling


diff --git a/.gitignore b/.gitignore
index bbb0231..b1e8a18 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,6 +1,3 @@
-*spec~
-package-*.xml
-/FinderFacade-1.0.5.tgz
-/FinderFacade-1.0.6.tgz
-/FinderFacade-1.1.0.tgz
+clog
 /finder-facade-1.1.0.tar.gz
+/finder-facade-1.2.0-a520dcc.tar.gz
diff --git a/autoload.php.in b/autoload.php.in
new file mode 100644
index 0000000..b3c9b67
--- /dev/null
+++ b/autoload.php.in
@@ -0,0 +1,35 @@
+<?php
+/* Inspipred from Autoload from version 1.1 */
+
+$vendorDir = '/usr/share/php';
+require_once $vendorDir . '/TheSeer/fDOMDocument/autoload.php';
+require_once $vendorDir . '/Symfony/Component/ClassLoader/UniversalClassLoader.php';
+use Symfony\Component\ClassLoader\UniversalClassLoader;
+
+$loader = new UniversalClassLoader();
+$loader->registerNamespaces(array(
+    'Symfony\\Component\\Finder'          => $vendorDir,
+    'Symfony\\Component\\ClassLoader'     => $vendorDir,
+));
+$loader->register();
+
+// @codingStandardsIgnoreFile
+// @codeCoverageIgnoreStart
+spl_autoload_register(
+  function($class) {
+    static $classes = NULL;
+
+    if ($classes === NULL) {
+      $classes = array(
+        ___CLASSLIST___
+      );
+    }
+
+    $cn = strtolower($class);
+
+    if (isset($classes[$cn])) {
+      require ___BASEDIR___$classes[$cn];
+    }
+  }
+);
+// @codeCoverageIgnoreEnd
diff --git a/php-phpunit-FinderFacade.spec b/php-phpunit-FinderFacade.spec
index 43aef9e..26d36ff 100644
--- a/php-phpunit-FinderFacade.spec
+++ b/php-phpunit-FinderFacade.spec
@@ -1,12 +1,12 @@
-# spec file for php-phpunit-FinderFacade
+# remirepo/fedora spec file for php-phpunit-FinderFacade
 #
-# Copyright (c) 2012-2014 Remi Collet
+# Copyright (c) 2012-2015 Remi Collet
 # License: CC-BY-SA
-# http://creativecommons.org/licenses/by-sa/3.0/
+# http://creativecommons.org/licenses/by-sa/4.0/
 #
 # Please, preserve the changelog entries
 #
-%global gh_commit    1e396fda3449fce9df032749fa4fa2619e0347e0
+%global gh_commit    a520dcc3dd39160eea480daa3426f4fd419a327b
 %global gh_short     %(c=%{gh_commit}; echo ${c:0:7})
 %global gh_owner     sebastianbergmann
 %global gh_project   finder-facade
@@ -16,35 +16,41 @@
 %global with_tests   %{?_without_tests:0}%{!?_without_tests:1}
 
 Name:           php-phpunit-FinderFacade
-Version:        1.1.0
-Release:        6%{?dist}
+Version:        1.2.0
+Release:        1%{?dist}
 Summary:        Wrapper for Symfony Finder component
 
 Group:          Development/Libraries
 License:        BSD
 URL:            https://github.com/%{gh_owner}/%{gh_project}
-Source0:        https://github.com/%{gh_owner}/%{gh_project}/archive/%{gh_commit}/%{gh_project}-%{version}.tar.gz
+Source0:        https://github.com/%{gh_owner}/%{gh_project}/archive/%{gh_commit}/%{gh_project}-%{version}-%{gh_short}.tar.gz
+# Autoloader template
+Source1:        autoload.php.in
 
 BuildArch:      noarch
 BuildRequires:  php(language) >= 5.3.3
+BuildRequires:  %{_bindir}/phpab
 %if %{with_tests}
-BuildRequires:  php-pear-PHPUnit >= 3.7.0
-BuildRequires:  php-theseer-fDOMDocument >= 1.3.1
-BuildRequires:  php-symfony-finder >= 2.2.0
+BuildRequires:  %{_bindir}/phpunit
+BuildRequires:  php-composer(theseer/fdomdocument) >= 1.3
+BuildRequires:  php-composer(symfony/finder) >=  2.3
+BuildRequires:  php-composer(symfony/class-loader)
 %endif
 
-# From composer.json
-#      "theseer/fdomdocument": ">=1.3.1",
-#      "symfony/finder": ">=2.2.0"
+# From composer.json "require": {
+#        "theseer/fdomdocument": "~1.3",
+#        "symfony/finder": "~2.3"
 Requires:       php(language) >= 5.3.3
-Requires:       php-theseer-fDOMDocument >= 1.3.1
-Requires:       php-symfony-finder >= 2.2.0
-# From phpcompatinfo report
+Requires:       php-composer(theseer/fdomdocument) >= 1.3
+Requires:       php-composer(theseer/fdomdocument) <  2
+Requires:       php-composer(symfony/finder) >=  2.3
+Requires:       php-composer(symfony/finder) <   3
+# From phpcompatinfo report for version 1.2.0
 Requires:       php-ctype
-Requires:       php-spl
+# For our autoloader
+Requires:       php-composer(symfony/class-loader)
 
 Provides:       php-composer(sebastian/finder-facade) = %{version}
-
 # For compatibility with PEAR mode
 Provides:       php-pear(%{pear_channel}/%{pear_name}) = %{version}
 
@@ -56,17 +62,12 @@ Convenience wrapper for Symfony's Finder component.
 %prep
 %setup -q -n %{gh_project}-%{gh_commit}
 
-rm src/autoload.php.in
-
 
 %build
-# Empty build section, most likely nothing required.
-
-# If upstream drop Autoload.php, command to generate it.
-#phpab \
-#  --output   src/autoload.php \
-#  --template src/autoload.php.in \
-#  src
+phpab \
+  --output   src/autoload.php \
+  --template %{SOURCE1} \
+  src
 
 
 %install
@@ -77,9 +78,8 @@ cp -pr src %{buildroot}%{php_home}/SebastianBergmann/FinderFacade
 %if %{with_tests}
 %check
 phpunit \
-  -d date.timezone=UTC \
-  --bootstrap src/autoload.php \
-  tests
+  --bootstrap %{buildroot}%{php_home}/SebastianBergmann/FinderFacade/autoload.php \
+  --verbose tests
 %endif
 
 
@@ -91,12 +91,21 @@ fi
 
 
 %files
-%doc ChangeLog.md README.md LICENSE composer.json
+%{!?_licensedir:%global license %%doc}
+%license LICENSE
+%doc README.md
+%doc composer.json
 %dir %{php_home}/SebastianBergmann
      %{php_home}/SebastianBergmann/FinderFacade
 
 
 %changelog
+* Thu Jun  4 2015 Remi Collet <remi at fedoraproject.org> - 1.2.0-1
+- upgrade to 1.2.0
+- raise dependency on symfony/finder 2.3
+- generate autoloader (dropped upstream)
+- fix license handling
+
 * Wed Jun 25 2014 Remi Collet <remi at fedoraproject.org> - 1.1.0-6
 - composer dependencies
 
diff --git a/sources b/sources
index a469df2..1105fec 100644
--- a/sources
+++ b/sources
@@ -1 +1 @@
-fe25e3372512b5d3893f3069a5ec8e9c  finder-facade-1.1.0.tar.gz
+9ae6c69234eb4b7ca177639026ec169f  finder-facade-1.2.0-a520dcc.tar.gz
-- 
cgit v0.10.2


	http://pkgs.fedoraproject.org/cgit/php-phpunit-FinderFacade.git/commit/?h=f22&id=59a22708daf514b021cb775bb3e19b48b553b0a1


More information about the scm-commits mailing list