From 599ba913baf0a782908df09118e7ad90d861cd04 Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Thu, 3 May 2018 09:06:00 +0200 Subject: update to 1.2.0 use range dependencies on F27+ switch to phpunit6 or phpunit7 --- php-zendframework-zend-servicemanager-di.spec | 58 ++++++++++++++++++++------- 1 file changed, 43 insertions(+), 15 deletions(-) (limited to 'php-zendframework-zend-servicemanager-di.spec') diff --git a/php-zendframework-zend-servicemanager-di.spec b/php-zendframework-zend-servicemanager-di.spec index 97e397e..30d2cd1 100644 --- a/php-zendframework-zend-servicemanager-di.spec +++ b/php-zendframework-zend-servicemanager-di.spec @@ -1,13 +1,13 @@ # remirepo/Fedora spec file for php-zendframework-zend-servicemanager-di # -# Copyright (c) 2016-2017 Remi Collet +# Copyright (c) 2016-2018 Remi Collet # License: CC-BY-SA # http://creativecommons.org/licenses/by-sa/4.0/ # # Please, preserve the changelog entries # %global bootstrap 0 -%global gh_commit 655253928da5ca15d14ce037d8195b1fb594897d +%global gh_commit b9a62f219f9156b1f4b14e131918c7e1f468107b %global gh_short %(c=%{gh_commit}; echo ${c:0:7}) %global gh_owner zendframework %global gh_project zend-servicemanager-di @@ -20,8 +20,8 @@ %endif Name: php-%{gh_owner}-%{gh_project} -Version: 1.1.1 -Release: 2%{?dist} +Version: 1.2.0 +Release: 1%{?dist} Summary: Zend Framework ServiceManager-%{library} component Group: Development/Libraries @@ -34,14 +34,28 @@ BuildArch: noarch # Tests %if %{with_tests} BuildRequires: php(language) >= 5.6 -BuildRequires: php-composer(container-interop/container-interop) >= 1.1 -BuildRequires: php-autoloader(%{gh_owner}/zend-di) >= 2.6 -BuildRequires: php-autoloader(%{gh_owner}/zend-servicemanager) >= 3.0.3 BuildRequires: php-spl # From composer, "require-dev": { -# "phpunit/phpunit": "^4.5", +# "phpunit/phpunit": "^5.7.27 || ^6.5.8 || ^7.1.4", # "zendframework/zend-coding-standard": "~1.0.0" -BuildRequires: php-composer(phpunit/phpunit) >= 4.0 +# remirepo:1 +%if 0%{?fedora} >= 27 || 0%{?rhel} >= 8 +BuildRequires: (php-composer(container-interop/container-interop) >= 1.1 with php-composer(container-interop/container-interop) < 2) +BuildRequires: (php-autoloader(%{gh_owner}/zend-di) >= 2.6 with php-autoloader(%{gh_owner}/zend-di) < 3) +BuildRequires: (php-autoloader(%{gh_owner}/zend-servicemanager) >= 3.0.3 with php-autoloader(%{gh_owner}/zend-servicemanager) < 4) +%global phpunit %{_bindir}/phpunit7 +BuildRequires: phpunit7 >= 7.1.4 +# remirepo:10 +%else +BuildRequires: php-composer(container-interop/container-interop) < 2 +BuildRequires: php-composer(container-interop/container-interop) >= 1.1 +BuildRequires: php-autoloader(%{gh_owner}/zend-di) < 3 +BuildRequires: php-autoloader(%{gh_owner}/zend-di) >= 2.6 +BuildRequires: php-autoloader(%{gh_owner}/zend-servicemanager) < 4 +BuildRequires: php-autoloader(%{gh_owner}/zend-servicemanager) >= 3.0.3 +%global phpunit %{_bindir}/phpunit6 +BuildRequires: phpunit6 >= 6.5.8 +%endif %endif # Autoloader BuildRequires: php-fedora-autoloader-devel @@ -52,12 +66,20 @@ BuildRequires: php-fedora-autoloader-devel # "zendframework/zend-di": "^2.6", # "zendframework/zend-servicemanager": "^3.0.3" Requires: php(language) >= 5.6 -Requires: php-composer(container-interop/container-interop) >= 1.1 +# remirepo:1 +%if 0%{?fedora} >= 27 || 0%{?rhel} >= 8 +Requires: (php-composer(container-interop/container-interop) >= 1.1 with php-composer(container-interop/container-interop) < 2) +Requires: (php-autoloader(%{gh_owner}/zend-di) >= 2.6 with php-autoloader(%{gh_owner}/zend-di) < 3) +Requires: (php-autoloader(%{gh_owner}/zend-servicemanager) >= 3.0.3 with php-autoloader(%{gh_owner}/zend-servicemanager) < 4) +# remirepo:8 +%else Requires: php-composer(container-interop/container-interop) < 2 -Requires: php-autoloader(%{gh_owner}/zend-di) >= 2.6 +Requires: php-composer(container-interop/container-interop) >= 1.1 Requires: php-autoloader(%{gh_owner}/zend-di) < 3 -Requires: php-autoloader(%{gh_owner}/zend-servicemanager) >= 3.0.3 +Requires: php-autoloader(%{gh_owner}/zend-di) >= 2.6 Requires: php-autoloader(%{gh_owner}/zend-servicemanager) < 4 +Requires: php-autoloader(%{gh_owner}/zend-servicemanager) >= 3.0.3 +%endif # From phpcompatinfo report for version 1.1.0 Requires: php-spl # Autoloader @@ -113,9 +135,10 @@ require_once '%{buildroot}%{php_home}/Zend/ServiceManager/%{library}/autoload.ph EOF ret=0 -for cmd in php php56 php70 php71 php72; do - if which $cmd; then - $cmd %{_bindir}/phpunit --include-path=%{buildroot}%{php_home} --verbose || ret=1 +for cmdarg in "php %{phpunit}" "php56 %{_bindir}/phpunit" "php70 %{_bindir}/phpunit6" php71 php72; do + if which $cmdarg; then + set $cmdarg + $1 ${2:-%{_bindir}/phpunit7} --verbose || ret=1 fi done exit $ret @@ -134,6 +157,11 @@ exit $ret %changelog +* Thu May 3 2018 Remi Collet - 1.2.0-1 +- update to 1.2.0 +- use range dependencies on F27+ +- switch to phpunit6 or phpunit7 + * Wed Dec 6 2017 Remi Collet - 1.1.1-2 - switch from zend-loader to fedora/autoloader -- cgit