From f70654e75f4e68f485541ca0346aee7813b17314 Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Fri, 23 Sep 2022 16:42:50 +0200 Subject: update to 1.7.0 drop build dependency on clue/block-react add build dependency on react/async and react/promise-timer switch to classmap autoloader --- composer.json | 5 +++-- php-react-http.spec | 62 +++++++++++++++++++++++++++++++---------------------- 2 files changed, 39 insertions(+), 28 deletions(-) diff --git a/composer.json b/composer.json index 4c9a038..57adfc2 100644 --- a/composer.json +++ b/composer.json @@ -38,11 +38,12 @@ "ringcentral/psr7": "^1.2" }, "require-dev": { - "clue/block-react": "^1.5", "clue/http-proxy-react": "^1.7", "clue/reactphp-ssh-proxy": "^1.3", "clue/socks-react": "^1.3", - "phpunit/phpunit": "^9.3 || ^5.7 || ^4.8.35" + "phpunit/phpunit": "^9.3 || ^5.7 || ^4.8.35", + "react/async": "^4 || ^3 || ^2", + "react/promise-timer": "^1.9" }, "autoload": { "psr-4": { "React\\Http\\": "src" } diff --git a/php-react-http.spec b/php-react-http.spec index 88177ed..6f3800d 100644 --- a/php-react-http.spec +++ b/php-react-http.spec @@ -12,17 +12,14 @@ %global github_owner reactphp %global github_name http -%global github_version 1.6.0 -%global github_commit 59961cc4a5b14481728f07c591546be18fa3a5c7 +%global github_version 1.7.0 +%global github_commit 4a1e85382e8c2a9e0fdb8ac04e94585da2083bfa %global composer_vendor react %global composer_project http # "php": ">=5.3.0" %global php_min_ver 5.3.0 -# "clue/block-react": "^1.5" -%global clue_block_react_min_ver 1.5 -%global clue_block_react_max_ver 2.0 # "clue/http-proxy-react": "^1.3", ignored as only used in examples # "clue/reactphp-ssh-proxy": "^1.0", ignored as only used in examples # "clue/socks-react": "^1.0", ignored as only used in examples @@ -47,6 +44,12 @@ # "react/event-loop": "^1.2", %global react_event_loop_min_ver 1.2 %global react_event_loop_max_ver 2.0 +# "react/async": "^4 || ^3 || ^2", +%global react_async_min_ver 2.0 +%global react_async_max_ver 5 +# "react/promise-timer": "^1.9", +%global react_promise_timer_min_ver 1.9 +%global react_promise_timer_max_ver 2 # "psr/http-message": "^1.0" %global psr_http_message_min_ver 1.0 %global psr_http_message_max_ver 2.0 @@ -55,7 +58,7 @@ %global fig_http_message_util_max_ver 2 # Build using "--without tests" to disable tests -%global with_tests 0%{!?_without_tests:1} +%bcond_without tests # Range dependencies supported? %if 0%{?fedora} >= 27 || 0%{?rhel} >= 8 @@ -81,7 +84,7 @@ Source1: %{name}-get-source.sh BuildArch: noarch # Tests -%if %{with_tests} +%if %{with tests} ## composer.json BuildRequires: php(language) >= %{php_min_ver} %if 0%{?fedora} >= 32 || 0%{?rhel} >= 9 @@ -93,7 +96,6 @@ BuildRequires: phpunit9 >= 9.3 BuildRequires: php-phpunit-PHPUnit >= 4.8.35 %endif %if %{with_range_dependencies} -BuildRequires: (php-composer(clue/block-react) >= %{clue_block_react_min_ver} with php-composer(clue/block-react) < %{clue_block_react_max_ver}) BuildRequires: (php-composer(evenement/evenement) >= %{evenement_min_ver} with php-composer(evenement/evenement) < %{evenement_max_ver}) BuildRequires: (php-composer(react/event-loop) >= %{react_event_loop_min_ver} with php-composer(react/event-loop) < %{react_event_loop_max_ver}) BuildRequires: (php-composer(react/promise-stream) >= %{react_promise_stream_min_ver} with php-composer(react/promise-stream) < %{react_promise_stream_max_ver}) @@ -103,9 +105,9 @@ BuildRequires: (php-composer(react/stream) >= %{react_stream_min_ver} with php-c BuildRequires: (php-composer(ringcentral/psr7) >= %{ringcentral_psr7_min_ver} with php-composer(ringcentral/psr7) < %{ringcentral_psr7_max_ver}) BuildRequires: (php-composer(psr/http-message) >= %{psr_http_message_min_ver} with php-composer(psr/http-message) < %{psr_http_message_max_ver}) BuildRequires: (php-composer(fig/http-message-util) >= %{fig_http_message_util_min_ver} with php-composer(fig/http-message-util) < %{fig_http_message_util_max_ver}) +BuildRequires: (php-composer(react/async) >= %{react_async_min_ver} with php-composer(react/async) < %{react_async_max_ver}) +BuildRequires: (php-composer(react/promise-timer) >= %{react_promise_timer_min_ver} with php-composer(react/promise-timer) < %{react_promise_timer_max_ver}) %else -BuildRequires: php-clue-block-react < %{clue_block_react_max_ver} -BuildRequires: php-clue-block-react >= %{clue_block_react_min_ver} BuildRequires: php-evenement < %{evenement_max_ver} BuildRequires: php-evenement >= %{evenement_min_ver} BuildRequires: php-react-event-loop < %{react_event_loop_max_ver} @@ -118,6 +120,10 @@ BuildRequires: php-react-socket < %{react_socket_max_ver} BuildRequires: php-react-socket >= %{react_socket_min_ver} BuildRequires: php-react-stream < %{react_stream_max_ver} BuildRequires: php-react-stream >= %{react_stream_min_ver} +BuildRequires: php-composer(react/async) < %{react_async_max_ver} +BuildRequires: php-composer(react/async) >= %{react_async_min_ver} +BuildRequires: php-composer(react/promise-timer) < %{react_promise_timer_max_ver} +BuildRequires: php-composer(react/promise-timer) >= %{react_promise_timer_min_ver} BuildRequires: php-ringcentral-psr7 < %{ringcentral_psr7_max_ver} BuildRequires: php-ringcentral-psr7 >= %{ringcentral_psr7_min_ver} BuildRequires: php-psr-http-message < %{psr_http_message_max_ver} @@ -133,9 +139,9 @@ BuildRequires: php-json BuildRequires: php-pcre BuildRequires: php-sockets BuildRequires: php-spl -## Autoloader -BuildRequires: php-composer(fedora/autoloader) %endif +## Autoloader +BuildRequires: php-fedora-autoloader-devel # composer.json Requires: php(language) >= %{php_min_ver} @@ -202,17 +208,14 @@ Autoloader: %{phpdir}/React/Http/autoload.php %build : Create autoloader -cat <<'AUTOLOAD' | tee src/autoload.php - - 1.7.0-1 +- update to 1.7.0 +- drop build dependency on clue/block-react +- add build dependency on react/async and react/promise-timer +- switch to classmap autoloader + * Thu Feb 3 2022 Remi Collet - 1.6.0-1 - update to 1.6.0 - raise dependency on clue/block-react 1.5 -- cgit