From ef51efc18824757a99e41737402775610faa0c6f Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Thu, 13 Dec 2018 11:06:54 +0100 Subject: update to 2.9.0 add optional dependency on psr/http-factory-implementation use range dependencies --- composer.json | 6 ++++-- php-zendframework-zend-filter.spec | 42 +++++++++++++++++++++++++++++++++----- 2 files changed, 41 insertions(+), 7 deletions(-) diff --git a/composer.json b/composer.json index 46c9b98..bf193dc 100644 --- a/composer.json +++ b/composer.json @@ -22,12 +22,14 @@ "require-dev": { "pear/archive_tar": "^1.4.3", "phpunit/phpunit": "^5.7.23 || ^6.4.3", + "psr/http-factory": "^1.0", "zendframework/zend-coding-standard": "~1.0.0", "zendframework/zend-crypt": "^3.2.1", "zendframework/zend-servicemanager": "^2.7.8 || ^3.3", "zendframework/zend-uri": "^2.6" }, "suggest": { + "psr/http-factory-implementation": "psr/http-factory-implementation, for creating file upload instances when consuming PSR-7 in file upload filters", "zendframework/zend-crypt": "Zend\\Crypt component, for encryption filters", "zendframework/zend-i18n": "Zend\\I18n component for filters depending on i18n functionality", "zendframework/zend-servicemanager": "Zend\\ServiceManager component, for using the filter chain functionality", @@ -51,8 +53,8 @@ }, "extra": { "branch-alias": { - "dev-master": "2.8.x-dev", - "dev-develop": "2.9.x-dev" + "dev-master": "2.9.x-dev", + "dev-develop": "2.10.x-dev" }, "zf": { "component": "Zend\\Filter", diff --git a/php-zendframework-zend-filter.spec b/php-zendframework-zend-filter.spec index 495ea6c..baf3c7a 100644 --- a/php-zendframework-zend-filter.spec +++ b/php-zendframework-zend-filter.spec @@ -7,7 +7,7 @@ # Please, preserve the changelog entries # %global bootstrap 0 -%global gh_commit 7b997dbe79459f1652deccc8786d7407fb66caa9 +%global gh_commit 875da9790e5cb16b9a12f41453d5f7c441452daf %global gh_short %(c=%{gh_commit}; echo ${c:0:7}) %global gh_owner zendframework %global gh_project zend-filter @@ -21,7 +21,7 @@ %global php_version %(php -r 'echo PHP_VERSION;') Name: php-%{gh_owner}-%{gh_project} -Version: 2.8.0 +Version: 2.9.0 Release: 1%{?dist} Summary: Zend Framework %{library} component @@ -34,7 +34,8 @@ Source1: makesrc.sh BuildArch: noarch # Tests %if %{with_tests} -BuildRequires: php(language) >= 5.6 +# 7.0 because of psr/http-factory +BuildRequires: php(language) >= 7.0 BuildRequires: php-date BuildRequires: php-iconv BuildRequires: php-mbstring @@ -42,10 +43,17 @@ BuildRequires: php-mcrypt BuildRequires: php-pcre BuildRequires: php-spl BuildRequires: php-zip +# remirepo:1 +%if 0%{?fedora} >= 27 || 0%{?rhel} >= 8 +BuildRequires: (php-autoloader(%{gh_owner}/zend-stdlib) >= 3.1.0 with php-autoloader(%{gh_owner}/zend-stdlib) < 4) +# remirepo:3 +%else BuildRequires: php-autoloader(%{gh_owner}/zend-stdlib) >= 3.1.0 +%endif # From composer, "require-dev": { # "pear/archive_tar": "^1.4.3", # "phpunit/phpunit": "^5.7.23 || ^6.4.3", +# "psr/http-factory": "^1.0", # "zendframework/zend-coding-standard": "~1.0.0", # "zendframework/zend-crypt": "^3.2.1", # "zendframework/zend-servicemanager": "^2.7.8 || ^3.3", @@ -54,9 +62,19 @@ BuildRequires: php-autoloader(pear/archive_tar) >= 1.4.3 %global phpunit %{_bindir}/phpunit6 BuildRequires: phpunit6 >= 6.4.3 %endif +# remirepo:1 +%if 0%{?fedora} >= 27 || 0%{?rhel} >= 8 +BuildRequires: (php-composer(psr/http-factory) >= 1.0 with php-composer(psr/http-factory) < 2) +BuildRequires: (php-autoloader(%{gh_owner}/zend-crypt) >= 3.2.1 with php-autoloader(%{gh_owner}/zend-crypt) < 4) +BuildRequires: (php-autoloader(%{gh_owner}/zend-servicemanager) >= 2.7.8 with php-autoloader(%{gh_owner}/zend-servicemanager) < 4) +BuildRequires: (php-autoloader(%{gh_owner}/zend-uri) >= 2.6 with php-autoloader(%{gh_owner}/zend-uri) < 3) +# remirepo:5 +%else +BuildRequires: php-composer(psr/http-factory) BuildRequires: php-autoloader(%{gh_owner}/zend-crypt) >= 3.2.1 BuildRequires: php-autoloader(%{gh_owner}/zend-servicemanager) >= 2.7.8 BuildRequires: php-autoloader(%{gh_owner}/zend-uri) >= 2.6 +%endif # Autoloader BuildRequires: php-fedora-autoloader-devel @@ -64,14 +82,22 @@ BuildRequires: php-fedora-autoloader-devel # "php": "^5.6 || ^7.0", # "zendframework/zend-stdlib": "^2.7.7 || ^3.1" Requires: php(language) >= 5.6 +# remirepo:1 +%if 0%{?fedora} >= 27 || 0%{?rhel} >= 8 +Requires: (php-autoloader(%{gh_owner}/zend-stdlib) >= 3.1.0 with php-autoloader(%{gh_owner}/zend-stdlib) < 4) +# remirepo:4 +%else Requires: php-autoloader(%{gh_owner}/zend-stdlib) >= 3.1.0 Requires: php-autoloader(%{gh_owner}/zend-stdlib) < 4 +%endif %if ! %{bootstrap} # From composer, "suggest": { +# "psr/http-factory-implementation": "psr/http-factory-implementation, for creating file upload instances when consuming PSR-7 in file upload filters", # "zendframework/zend-crypt": "Zend\\Crypt component", # "zendframework/zend-i18n": "Zend\\I18n component", # "zendframework/zend-servicemanager": "Zend\\ServiceManager component", # "zendframework/zend-uri": "Zend\\Uri component for UriNormalize filter" +Suggests: php-composer(psr/http-factory-implementation) Suggests: php-autoloader(%{gh_owner}/zend-crypt) Suggests: php-autoloader(%{gh_owner}/zend-i18n) Suggests: php-autoloader(%{gh_owner}/zend-servicemanager) @@ -122,6 +148,7 @@ cat << 'EOF' | tee -a src/autoload.php '%{php_home}/Zend/Stdlib/autoload.php', ]); \Fedora\Autoloader\Dependencies::optional([ + '%{php_home}/Psr/Http/Message/http-factory-autoload.php', '%{php_home}/Zend/Crypt/autoload.php', '%{php_home}/Zend/I18n/autoload.php', '%{php_home}/Zend/ServiceManager/autoload.php', @@ -149,10 +176,10 @@ EOF rm test/Compress/SnappyTest.php ret=0 -for cmd in "php %{phpunit}" "php70 %{_bindir}/phpunit6" "php71 %{_bindir}/phpunit6" "php72 %{_bindir}/phpunit6"; do +for cmd in "php %{phpunit}" php70 php71 php72 php73; do if which $cmd; then set $cmd - $1 $2 || ret=1 + $1 ${2:-%{_bindir}/phpunit6} || ret=1 fi done exit $ret @@ -170,6 +197,11 @@ exit $ret %changelog +* Thu Dec 13 2018 Remi Collet - 2.9.0-1 +- update to 2.9.0 +- add optional dependency on psr/http-factory-implementation +- use range dependencies + * Thu Apr 12 2018 Remi Collet - 2.8.0-1 - update to 2.8.0 - raise dependency on PHP 5.6 -- cgit