diff options
Diffstat (limited to 'php-pecl-memcached.spec')
-rw-r--r-- | php-pecl-memcached.spec | 42 |
1 files changed, 30 insertions, 12 deletions
diff --git a/php-pecl-memcached.spec b/php-pecl-memcached.spec index 614c0d0..26283d7 100644 --- a/php-pecl-memcached.spec +++ b/php-pecl-memcached.spec @@ -20,10 +20,12 @@ %global _root_prefix %{_prefix} %endif -%global with_fastlz 1 -%global with_igbin 1 +%bcond_without fastlz +%bcond_without igbinary +%bcond_without msgpack +%bcond_without tests + %global with_zts 0%{!?_without_zts:%{?__ztsphp:1}} -%global with_tests 0%{!?_without_tests:1} %global pecl_name memcached # After 40-igbinary, 40-json, 40-msgpack %global ini_name 50-%{pecl_name}.ini @@ -31,7 +33,7 @@ Summary: Extension to work with the Memcached caching daemon Name: %{?sub_prefix}php-pecl-memcached Version: 3.1.5 -Release: 4%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}} +Release: 5%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}} License: PHP URL: https://pecl.php.net/package/%{pecl_name} @@ -45,21 +47,24 @@ Patch4: https://patch-diff.githubusercontent.com/raw/php-memcached-dev/php Patch5: https://patch-diff.githubusercontent.com/raw/php-memcached-dev/php-memcached/pull/469.patch Patch6: https://patch-diff.githubusercontent.com/raw/php-memcached-dev/php-memcached/pull/472.patch Patch7: https://patch-diff.githubusercontent.com/raw/php-memcached-dev/php-memcached/pull/473.patch +Patch8: https://patch-diff.githubusercontent.com/raw/php-memcached-dev/php-memcached/pull/486.patch BuildRequires: %{?dtsprefix}gcc BuildRequires: %{?scl_prefix}php-devel >= 7 BuildRequires: %{?scl_prefix}php-pear BuildRequires: %{?scl_prefix}php-json -%if %{with_igbin} +%if %{with igbinary} BuildRequires: %{?sub_prefix}php-pecl-igbinary-devel %endif +%if %{with msgpack} BuildRequires: %{?sub_prefix}php-pecl-msgpack-devel +%endif BuildRequires: zlib-devel BuildRequires: cyrus-sasl-devel -%if %{with_fastlz} +%if %{with fastlz} BuildRequires: fastlz-devel %endif -%if %{with_tests} +%if %{with tests} BuildRequires: memcached %endif @@ -78,10 +83,12 @@ BuildRequires: pkgconfig(libmemcached) >= 1.0.18 Requires: %{?scl_prefix}php(zend-abi) = %{php_zend_api} Requires: %{?scl_prefix}php(api) = %{php_core_api} Requires: %{?scl_prefix}php-json%{?_isa} -%if %{with_igbin} +%if %{with igbinary} Requires: %{?sub_prefix}php-pecl-igbinary%{?_isa} %endif +%if %{with msgpack} Requires: %{?sub_prefix}php-pecl-msgpack%{?_isa} +%endif %{?_sclreq:Requires: %{?scl_prefix}runtime%{?_sclreq}%{?_isa}} Provides: %{?scl_prefix}php-%{pecl_name} = %{version} @@ -123,6 +130,9 @@ Obsoletes: php74-pecl-%{pecl_name} <= %{version} %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 %if %{move_to_opt} @@ -163,9 +173,10 @@ cd NTS %patch5 -p1 -b .pr469 %patch6 -p1 -b .pr472 %patch7 -p1 -b .pr473 +%patch8 -p1 -b .pr486 %endif -%if %{with_fastlz} +%if %{with fastlz} rm -r fastlz sed -e '/name=.fastlz/d' -i ../package.xml %endif @@ -216,18 +227,20 @@ export PKG_CONFIG_PATH=/opt/libmemcached/%{_lib}/pkgconfig peclconf() { %configure \ -%if %{with_igbin} +%if %{with igbinary} --enable-memcached-igbinary \ %endif --enable-memcached-json \ --enable-memcached-sasl \ +%if %{with msgpack} --enable-memcached-msgpack \ +%endif %if 0 --disable-memcached-protocol \ %else --enable-memcached-protocol \ %endif -%if %{with_fastlz} +%if %{with fastlz} --with-system-fastlz \ %endif --with-php-config=$1 @@ -309,7 +322,7 @@ OPT="-n" --modules | grep %{pecl_name} %endif -%if %{with_tests} +%if %{with tests} ret=0 : Launch the Memcached service @@ -362,6 +375,11 @@ exit $ret %changelog +* Wed Jun 9 2021 Remi Collet <remi@remirepo.net> - 3.1.5-4 +- add patch got PHP 8.1 from + https://github.com/php-memcached-dev/php-memcached/pull/486 +- switch to bcond and add option to disable msgpack usage + * Thu Oct 8 2020 Remi Collet <remi@remirepo.net> - 3.1.5-3 - more patches for PHP 8 from https://github.com/php-memcached-dev/php-memcached/pull/465 |