summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--composer.json12
-rw-r--r--php-zendframework-zend-validator.spec56
2 files changed, 55 insertions, 13 deletions
diff --git a/composer.json b/composer.json
index 17f2915..fc08755 100644
--- a/composer.json
+++ b/composer.json
@@ -18,7 +18,10 @@
"container-interop/container-interop": "^1.1"
},
"require-dev": {
+ "phpunit/PHPUnit": "^6.0.8 || ^5.7.15",
+ "psr/http-message": "^1.0",
"zendframework/zend-cache": "^2.6.1",
+ "zendframework/zend-coding-standard": "~1.0.0",
"zendframework/zend-config": "^2.6",
"zendframework/zend-db": "^2.7",
"zendframework/zend-filter": "^2.6",
@@ -27,11 +30,10 @@
"zendframework/zend-math": "^2.6",
"zendframework/zend-servicemanager": "^2.7.5 || ^3.0.3",
"zendframework/zend-session": "^2.8",
- "zendframework/zend-uri": "^2.5",
- "phpunit/PHPUnit": "^6.0.8 || ^5.7.15",
- "zendframework/zend-coding-standard": "~1.0.0"
+ "zendframework/zend-uri": "^2.5"
},
"suggest": {
+ "psr/http-message": "psr/http-message, required when validating PSR-7 UploadedFileInterface instances via the Upload and UploadFile validators",
"zendframework/zend-db": "Zend\\Db component, required by the (No)RecordExists validator",
"zendframework/zend-filter": "Zend\\Filter component, required by the Digits validator",
"zendframework/zend-i18n": "Zend\\I18n component to allow translation of validation error messages",
@@ -45,8 +47,8 @@
"prefer-stable": true,
"extra": {
"branch-alias": {
- "dev-master": "2.10.x-dev",
- "dev-develop": "2.11.x-dev"
+ "dev-master": "2.11.x-dev",
+ "dev-develop": "2.12.x-dev"
},
"zf": {
"component": "Zend\\Validator",
diff --git a/php-zendframework-zend-validator.spec b/php-zendframework-zend-validator.spec
index 1abbd9a..1ae795c 100644
--- a/php-zendframework-zend-validator.spec
+++ b/php-zendframework-zend-validator.spec
@@ -7,7 +7,7 @@
# Please, preserve the changelog entries
#
%global bootstrap 0
-%global gh_commit 38109ed7d8e46cfa71bccbe7e6ca80cdd035f8c9
+%global gh_commit f0789b4c4c099afdd2ecc58cc209a26c64bd4f17
%global gh_short %(c=%{gh_commit}; echo ${c:0:7})
%global gh_owner zendframework
%global gh_project zend-validator
@@ -22,7 +22,7 @@
# TODO switch BR to fedora-autoloader + tests
Name: php-%{gh_owner}-%{gh_project}
-Version: 2.10.2
+Version: 2.11.0
Release: 2%{?dist}
Summary: Zend Framework %{library} component
@@ -43,10 +43,20 @@ BuildRequires: php-hash
BuildRequires: php-intl
BuildRequires: php-pcre
BuildRequires: php-spl
+# remirepo:1
+%if 0%{?fedora} >= 27 || 0%{?rhel} >= 8
+BuildRequires: (php-autoloader(%{gh_owner}/zend-stdlib) >= 2.7.6 with php-autoloader(%{gh_owner}/zend-stdlib) < 4)
+BuildRequires: (php-composer(container-interop/container-interop) >= 1.1 with php-composer(container-interop/container-interop) < 2)
+# remirepo:4
+%else
BuildRequires: php-autoloader(%{gh_owner}/zend-stdlib) >= 2.7.6
BuildRequires: php-composer(container-interop/container-interop) >= 1.1
+%endif
# From composer, "require-dev": {
+# "phpunit/PHPUnit": "^6.0.8 || ^5.7.15",
+# "psr/http-message": "^1.0",
# "zendframework/zend-cache": "^2.6.1",
+# "zendframework/zend-coding-standard": "~1.0.0",
# "zendframework/zend-config": "^2.6",
# "zendframework/zend-db": "^2.7",
# "zendframework/zend-filter": "^2.6",
@@ -55,9 +65,24 @@ BuildRequires: php-composer(container-interop/container-interop) >= 1.1
# "zendframework/zend-math": "^2.6",
# "zendframework/zend-servicemanager": "^2.7.5 || ^3.0.3",
# "zendframework/zend-session": "^2.8",
-# "zendframework/zend-uri": "^2.5",
-# "phpunit/PHPUnit": "^6.0.8 || ^5.7.15",
-# "zendframework/zend-coding-standard": "~1.0.0"
+# "zendframework/zend-uri": "^2.5"
+# remirepo:1
+%if 0%{?fedora} >= 27 || 0%{?rhel} >= 8
+BuildRequires: (php-composer(psr/http-message) >= 1.0 with php-composer(psr/http-message) < 2)
+BuildRequires: (php-composer(%{gh_owner}/zend-cache) >= 2.6.1 with php-composer(%{gh_owner}/zend-cache) < 3)
+BuildRequires: (php-composer(%{gh_owner}/zend-config) >= 2.6 with php-composer(%{gh_owner}/zend-config) < 3)
+BuildRequires: (php-composer(%{gh_owner}/zend-db) >= 2.7 with php-composer(%{gh_owner}/zend-db) < 3)
+BuildRequires: (php-composer(%{gh_owner}/zend-filter) >= 2.6 with php-composer(%{gh_owner}/zend-filter) < 3)
+BuildRequires: (php-composer(%{gh_owner}/zend-http) >= 2.5.4 with php-composer(%{gh_owner}/zend-http) < 3)
+BuildRequires: (php-composer(%{gh_owner}/zend-i18n) >= 2.6 with php-composer(%{gh_owner}/zend-i18n) < 3)
+# ignore max version
+BuildRequires: (php-composer(%{gh_owner}/zend-math) >= 2.6 with php-composer(%{gh_owner}/zend-math) < 4)
+BuildRequires: (php-composer(%{gh_owner}/zend-servicemanager) >= 2.7.5 with php-composer(%{gh_owner}/zend-servicemanager) < 4)
+BuildRequires: (php-composer(%{gh_owner}/zend-session) >= 2.8 with php-composer(%{gh_owner}/zend-session) < 3)
+BuildRequires: (php-composer(%{gh_owner}/zend-uri) >= 2.5 with php-composer(%{gh_owner}/zend-uri) < 3)
+# remirepo:13
+%else
+BuildRequires: php-composer(psr/http-message) >= 1.0
BuildRequires: php-composer(%{gh_owner}/zend-cache) >= 2.6.1
BuildRequires: php-composer(%{gh_owner}/zend-config) >= 2.6
BuildRequires: php-composer(%{gh_owner}/zend-db) >= 2.7
@@ -68,6 +93,7 @@ BuildRequires: php-composer(%{gh_owner}/zend-math) >= 2.6
BuildRequires: php-composer(%{gh_owner}/zend-servicemanager) >= 2.7.5
BuildRequires: php-composer(%{gh_owner}/zend-session) >= 2.8
BuildRequires: php-composer(%{gh_owner}/zend-uri) >= 2.5
+%endif
BuildRequires: phpunit6 >= 6.0.8
# Autoloader
BuildRequires: php-composer(%{gh_owner}/zend-loader) >= 2.5
@@ -80,11 +106,19 @@ BuildRequires: php-fedora-autoloader-devel
# "container-interop/container-interop": "^1.1"
Requires: php(language) >= 5.5
%if ! %{bootstrap}
+# remirepo:1
+%if 0%{?fedora} >= 27 || 0%{?rhel} >= 8
+Requires: (php-autoloader(%{gh_owner}/zend-stdlib) >= 2.7.6 with php-autoloader(%{gh_owner}/zend-stdlib) < 4)
+Requires: (php-composer(container-interop/container-interop) >= 1.1 with php-composer(container-interop/container-interop) < 2)
+# remirepo:6
+%else
Requires: php-autoloader(%{gh_owner}/zend-stdlib) >= 2.7.6
Requires: php-autoloader(%{gh_owner}/zend-stdlib) < 4
Requires: php-composer(container-interop/container-interop) >= 1.1
Requires: php-composer(container-interop/container-interop) < 2
+%endif
# From composer, "suggest": {
+# "psr/http-message": "psr/http-message, required when validating PSR-7 UploadedFileInterface instances via the Upload and UploadFile validators",
# "zendframework/zend-db": "Zend\\Db component, required by the (No)RecordExists validator",
# "zendframework/zend-filter": "Zend\\Filter component, required by the Digits validator",
# "zendframework/zend-i18n": "Zend\\I18n component to allow translation of validation error messages",
@@ -93,7 +127,8 @@ Requires: php-composer(container-interop/container-interop) < 2
# "zendframework/zend-servicemanager": "Zend\\ServiceManager component to allow using the ValidatorPluginManager and validator chains",
# "zendframework/zend-session": "Zend\\Session component, ^2.8; required by the Csrf validator",
# "zendframework/zend-uri": "Zend\\Uri component, required by the Uri and Sitemap\\Loc validators"
-%if 0%{?fedora} >= 21
+%if 0%{?fedora} >= 21 || 0%{?rhel} >= 8
+Recommends: php-composer(psr/http-message)
Suggests: php-composer(%{gh_owner}/zend-db)
Suggests: php-composer(%{gh_owner}/zend-filter)
Suggests: php-composer(%{gh_owner}/zend-i18n)
@@ -144,6 +179,7 @@ cat << 'EOF' | tee -a src/autoload.php
'%{php_home}/Zend/Stdlib/autoload.php',
]);
\Fedora\Autoloader\Dependencies::optional([
+ '%{php_home}/Psr/Http/Message/autoload.php',
'%{php_home}/Zend/Db/autoload.php',
'%{php_home}/Zend/Filter/autoload.php',
'%{php_home}/Zend/I18n/autoload.php',
@@ -175,9 +211,8 @@ require_once '%{buildroot}%{php_home}/Zend/%{library}/autoload.php';
\Fedora\Autoloader\Autoload::addPsr4('ZendTest\\%{library}\\', dirname(__DIR__) . '/test');
EOF
-# PHP 7.2 https://github.com/zendframework/zend-validator/issues/196
ret=0
-for cmd in php php70 php71 php72; do
+for cmd in php php70 php71 php72 php73; do
if which $cmd; then
$cmd -d memory_limit=1G %{_bindir}/phpunit6 --verbose || ret=1
fi
@@ -197,6 +232,11 @@ exit $ret
%changelog
+* Fri Dec 14 2018 Remi Collet <remi@remirepo.net> - 2.11.0-2
+- update to 2.11.0
+- add weak dependency on psr/http-message
+- use range dependencies
+
* Fri Feb 2 2018 Remi Collet <remi@remirepo.net> - 2.10.2-1
- Update to 2.10.2
- switch to phpunit6