diff options
| -rw-r--r-- | php-pecl-http-message.spec | 81 |
1 files changed, 22 insertions, 59 deletions
diff --git a/php-pecl-http-message.spec b/php-pecl-http-message.spec index 690c268..5c20493 100644 --- a/php-pecl-http-message.spec +++ b/php-pecl-http-message.spec @@ -1,8 +1,8 @@ # remirepo spec file for php-pecl-http-message # -# Copyright (c) 2019-2021 Remi Collet -# License: CC-BY-SA -# http://creativecommons.org/licenses/by-sa/4.0/ +# SPDX-FileCopyrightText: Copyright 2019-2025 Remi Collet +# SPDX-License-Identifier: CECILL-2.1 +# http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt # # Please, preserve the changelog entries # @@ -13,7 +13,12 @@ %global with_zts 0%{!?_without_zts:%{?__ztsphp:1}} %global pecl_name http_message -%global with_tests 0%{!?_without_tests:1} +%ifarch aarch64 +# strange failure, need investigation +%bcond_with tests +%else +%bcond_without tests +%endif # after 40-psr.ini %global ini_name 50-%{pecl_name}.ini #global prever RC2 @@ -21,8 +26,8 @@ Summary: PSR-7 HTTP Message implementation Name: %{?sub_prefix}php-pecl-http-message Version: 1.0.0 -Release: 1%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}} -License: BSD +Release: 3%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}} +License: MIT URL: https://pecl.php.net/package/%{pecl_name} Source0: https://pecl.php.net/get/%{pecl_name}-%{version}%{?prever}.tgz @@ -41,7 +46,6 @@ Requires: %{?scl_prefix}php-psr%{?_isa} >= 1.2 %else Requires: %{?scl_prefix}php-psr%{?_isa} >= 0.6 %endif -%{?_sclreq:Requires: %{?scl_prefix}runtime%{?_sclreq}%{?_isa}} Provides: %{?scl_prefix}php-%{pecl_name} = %{version} Provides: %{?scl_prefix}php-%{pecl_name}%{?_isa} = %{version} @@ -50,23 +54,6 @@ Provides: %{?scl_prefix}php-pecl(%{pecl_name})%{?_isa} = %{version} Provides: %{?scl_prefix}php-pecl-%{pecl_name} = %{version}-%{release} Provides: %{?scl_prefix}php-pecl-%{pecl_name}%{?_isa} = %{version}-%{release} -%if "%{?packager}" == "Remi Collet" && 0%{!?scl:1} && 0%{?rhel} -# Other third party repo stuff -Obsoletes: php72u-pecl-%{pecl_name} <= %{version} -%if "%{php_version}" > "7.3" -Obsoletes: php73-pecl-%{pecl_name} <= %{version} -%endif -%if "%{php_version}" > "7.4" -Obsoletes: php74-pecl-%{pecl_name} <= %{version} -%endif -%if "%{php_version}" > "8.0" -Obsoletes: php80-pecl-%{pecl_name} <= %{version} -%endif -%if "%{php_version}" > "8.1" -Obsoletes: php81-pecl-%{pecl_name} <= %{version} -%endif -%endif - %description PSR-7 compatible HTTP Message implementation as PHP extension. @@ -91,10 +78,10 @@ These are the files needed to compile programs using %{name}. mv %{pecl_name}-%{version}%{?prever} NTS # Don't install/register tests -%{?_licensedir:sed -e '/LICENSE/s/role="doc"/role="src"/' -i package.xml} +sed -e '/LICENSE/s/role="doc"/role="src"/' -i package.xml cd NTS -%patch1 -p1 -b .pr7 +%patch -P1 -p1 -b .pr7 # Sanity check, really often broken extver=$(sed -n '/#define PHP_HTTP_MESSAGE_VERSION/{s/.* "//;s/".*$//;p}' php_http_message.h) @@ -162,26 +149,6 @@ do install -Dpm 644 NTS/$i %{buildroot}%{pecl_testdir}/%{pecl_name}/$i done -%if 0%{?fedora} < 24 && 0%{?rhel} < 8 -# when pear installed alone, after us -%triggerin -- %{?scl_prefix}php-pear -if [ -x %{__pecl} ] ; then - %{pecl_install} %{pecl_xmldir}/%{name}.xml >/dev/null || : -fi - -# posttrans as pear can be installed after us -%posttrans -if [ -x %{__pecl} ] ; then - %{pecl_install} %{pecl_xmldir}/%{name}.xml >/dev/null || : -fi - -%postun -if [ $1 -eq 0 -a -x %{__pecl} ] ; then - %{pecl_uninstall} %{pecl_name} >/dev/null || : -fi -%endif - - %check OPT="-n -d extension=psr" @@ -191,7 +158,7 @@ cd NTS --define extension=%{buildroot}%{php_extdir}/%{pecl_name}.so \ --modules | grep %{pecl_name} -%if %{with_tests} +%if %{with tests} : Upstream test suite for NTS extension TEST_PHP_EXECUTABLE=%{__php} \ TEST_PHP_ARGS="$OPT -d extension=$PWD/modules/%{pecl_name}.so" \ @@ -205,23 +172,12 @@ cd ../ZTS %{__ztsphp} $OPT \ --define extension=%{buildroot}%{php_ztsextdir}/%{pecl_name}.so \ --modules | grep %{pecl_name} - -%if %{with_tests} -: Ignore tests using CGI -rm -r tests/Emitter - -: Upstream test suite for NTS extension -TEST_PHP_EXECUTABLE=%{__ztsphp} \ -TEST_PHP_ARGS="$OPT -d extension=$PWD/modules/%{pecl_name}.so" \ -REPORT_EXIT_STATUS=1 \ -%{__ztsphp} -n run-tests.php -q --show-diff -%endif %endif %files %doc %{pecl_docdir}/%{pecl_name} -%{?_licensedir:%license NTS/LICENSE} +%license NTS/LICENSE %{pecl_xmldir}/%{name}.xml %config(noreplace) %{php_inidir}/%{ini_name} @@ -243,6 +199,13 @@ REPORT_EXIT_STATUS=1 \ %changelog +* Tue Sep 2 2025 Remi Collet <remi@remirepo.net> - 1.0.0-3 +- re-license spec file to CECILL-2.1 +- disable test suite on aarch64 + +* Thu Aug 22 2024 Remi Collet <remi@remirepo.net> - 1.0.0-2 +- cleanup + * Mon Dec 13 2021 Remi Collet <remi@remirepo.net> - 1.0.0-1 - update to 1.0.0 - drop patches merged upstream |
