summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRemi Collet <remi@remirepo.net>2018-12-04 17:25:27 +0100
committerRemi Collet <remi@remirepo.net>2018-12-04 17:25:27 +0100
commit31309c918cc35e0a5ada9f7cf2af84f45193616b (patch)
treee68357e82bcecb459ffc263b560bcf7789f3da64
parentc4688a55c2c54f9c77f57ba2e54079c8e044a3e6 (diff)
cleanup for EL-8
-rw-r--r--php-phpunit-PHPUnit.spec21
-rw-r--r--phpunit-5.4.0-Autoload.php.in2
2 files changed, 17 insertions, 6 deletions
diff --git a/php-phpunit-PHPUnit.spec b/php-phpunit-PHPUnit.spec
index 30705d4..749b671 100644
--- a/php-phpunit-PHPUnit.spec
+++ b/php-phpunit-PHPUnit.spec
@@ -22,11 +22,10 @@
%global pear_channel pear.phpunit.de
%global major 5.7
%global minor 27
-%global specrel 2
Name: php-phpunit-PHPUnit
Version: %{major}.%{minor}
-Release: %{?gh_date:1%{specrel}.%{?prever}%{!?prever:%{gh_date}.%{gh_short}}}%{!?gh_date:%{specrel}}%{?dist}
+Release: 4%{?dist}
Summary: The PHP Unit Testing framework
Group: Development/Libraries
@@ -48,7 +47,8 @@ Patch0: %{gh_project}-rpm.patch
BuildArch: noarch
BuildRequires: php(language) >= 5.6
BuildRequires: %{_bindir}/phpab
-%if 0%{?fedora} >= 27
+# remirepo:1
+%if 0%{?fedora} >= 27 || 0%{?rhel} >= 8
BuildRequires: (php-composer(phpunit/php-file-iterator) >= 1.4 with php-composer(phpunit/php-file-iterator) < 2)
BuildRequires: (php-composer(phpunit/php-text-template) >= 1.2 with php-composer(phpunit/php-text-template) < 2)
BuildRequires: (php-composer(phpunit/php-code-coverage) >= 4.0.4 with php-composer(phpunit/php-code-coverage) < 5)
@@ -67,6 +67,7 @@ BuildRequires: (php-composer(myclabs/deep-copy) >= 1.3 with php-com
BuildRequires: (php-composer(phpunit/php-invoker) >= 1.1 with php-composer(phpunit/php-invoker) < 2)
BuildRequires: (php-composer(doctrine/instantiator) >= 1.0.4 with php-composer(doctrine/instantiator) < 2)
BuildRequires: (php-composer(sebastian/recursion-context) >= 2.0 with php-composer(sebastian/recursion-context) < 3)
+# remirepo:20
%else
BuildRequires: php-phpunit-File-Iterator >= 1.4
BuildRequires: php-phpunit-Text-Template >= 1.2
@@ -116,7 +117,8 @@ BuildRequires: php-composer(fedora/autoloader)
# "ext-libxml": "*"
Requires: php(language) >= 5.6
Requires: php-cli
-%if 0%{?fedora} >= 27
+# remirepo:1
+%if 0%{?fedora} >= 27 || 0%{?rhel} >= 8
Requires: (php-composer(phpunit/php-file-iterator) >= 1.4 with php-composer(phpunit/php-file-iterator) < 2)
Requires: (php-composer(phpunit/php-text-template) >= 1.2 with php-composer(phpunit/php-text-template) < 2)
Requires: (php-composer(phpunit/php-code-coverage) >= 4.0.4 with php-composer(phpunit/php-code-coverage) < 5)
@@ -132,6 +134,7 @@ Requires: (php-composer(sebastian/object-enumerator) >= 2.0 with php-com
Requires: (php-composer(sebastian/resource-operations) >= 1.0 with php-composer(sebastian/resource-operations) < 2)
Requires: (php-composer(sebastian/version) >= 2.0.1 with php-composer(sebastian/version) < 3)
Requires: (php-composer(myclabs/deep-copy) >= 1.3 with php-composer(myclabs/deep-copy) < 2)
+# remirepo:17
%else
Requires: php-phpunit-File-Iterator >= 1.4
Requires: php-phpunit-Text-Template >= 1.2
@@ -158,11 +161,13 @@ Requires: php-libxml
# From composer.json, "suggest": {
# "phpunit/php-invoker": "~1.1",
# "ext-xdebug": "*"
-%if 0%{?fedora} >= 27
+# remirepo:1
+%if 0%{?fedora} >= 27 || 0%{?rhel} >= 8
Requires: (php-composer(phpunit/php-invoker) >= 1.1 with php-composer(phpunit/php-invoker) < 2)
# For our autoload patch
Requires: (php-composer(doctrine/instantiator) >= 1.0.4 with php-composer(doctrine/instantiator) < 2)
Requires: (php-composer(sebastian/recursion-context) >= 2.0 with php-composer(sebastian/recursion-context) < 3)
+# remirepo:5
%else
Requires: php-phpunit-PHP-Invoker >= 1.1
Requires: php-doctrine-instantiator >= 1.0.4
@@ -254,6 +259,12 @@ fi
%changelog
+* Tue Dec 4 2018 Remi Collet <remi@remirepo.net> - 5.7.27-4
+- cleanup for EL-8
+
+* Tue Feb 20 2018 Remi Collet <remi@remirepo.net> - 5.7.27-3
+- fix autoloader, restrict symfony to Yaml component
+
* Fri Feb 2 2018 Remi Collet <remi@remirepo.net> - 5.7.27-2
- use package names on EL and Fedora < 27
diff --git a/phpunit-5.4.0-Autoload.php.in b/phpunit-5.4.0-Autoload.php.in
index baffe2c..00d7cb0 100644
--- a/phpunit-5.4.0-Autoload.php.in
+++ b/phpunit-5.4.0-Autoload.php.in
@@ -15,7 +15,7 @@ if (!class_exists('Fedora\\Autoloader\\Autoload', false)) {
$sym = (getenv('RPM_SYMFONY_TREE') ?: 'Symfony');
/* don't use symfony autoloader which pull some unwanted stuff (polyfill) */
$vendorDir = stream_resolve_include_path("$sym/Component/Yaml/Yaml.php");
-\Fedora\Autoloader\Autoload::addPsr4('Symfony\\Component\\', dirname(dirname($vendorDir)));
+\Fedora\Autoloader\Autoload::addPsr4('Symfony\\Component\\Yaml\\', dirname($vendorDir));
/* Required */
require_once 'File/Iterator/Autoload.php';