summaryrefslogtreecommitdiffstats
path: root/php-ringcentral-psr7.spec
diff options
context:
space:
mode:
Diffstat (limited to 'php-ringcentral-psr7.spec')
-rw-r--r--php-ringcentral-psr7.spec10
1 files changed, 7 insertions, 3 deletions
diff --git a/php-ringcentral-psr7.spec b/php-ringcentral-psr7.spec
index 9b328d8..c504ffc 100644
--- a/php-ringcentral-psr7.spec
+++ b/php-ringcentral-psr7.spec
@@ -39,6 +39,9 @@ License: MIT
URL: https://github.com/%{github_owner}/%{github_name}
Source0: %{url}/archive/%{github_commit}/%{name}-%{github_version}-%{github_commit}.tar.gz
+# For PHP 8
+Patch0: %{name}-php8.patch
+
BuildArch: noarch
# Tests
%if %{with_tests}
@@ -92,7 +95,7 @@ Autoloader: %{phpdir}/RingCentral/Psr7/autoload.php
%prep
%setup -qn %{github_name}-%{github_commit}
-
+%patch0 -p1
%build
: Create autoloader
@@ -127,8 +130,7 @@ ln -s %{buildroot}%{phpdir}/RingCentral/Psr7/autoload.php vendor/autoload.php
: Upstream tests
RETURN_CODE=0
PHPUNIT=$(which phpunit)
-# TODO php 8.0: "Method ReflectionParameter::isArray() is deprecated"
-for PHP_EXEC in php %{?rhel:php54 php55 php56 php70 php71} php72 php73 php74; do
+for PHP_EXEC in php %{?rhel:php54 php55 php56 php70 php71} php72 php73 php74 php80; do
if [ "php" == "$PHP_EXEC" ] || which $PHP_EXEC; then
$PHP_EXEC $PHPUNIT --verbose || RETURN_CODE=1
fi
@@ -151,6 +153,8 @@ exit $RETURN_CODE
%changelog
* Thu Nov 5 2020 Remi Collet <remi@remirepo.net> - 1.3.0-1
- update to 1.3.0
+- add patch for PHP 8 from
+ https://github.com/ringcentral/psr7/pull/8
* Sat Apr 21 2018 Shawn Iwinski <shawn@iwin.ski> - 1.2.2-1
- Update to 1.2.2