summaryrefslogtreecommitdiffstats
path: root/php-pecl-memcached.spec
diff options
context:
space:
mode:
Diffstat (limited to 'php-pecl-memcached.spec')
-rw-r--r--php-pecl-memcached.spec57
1 files changed, 22 insertions, 35 deletions
diff --git a/php-pecl-memcached.spec b/php-pecl-memcached.spec
index ba83ab9..3713f27 100644
--- a/php-pecl-memcached.spec
+++ b/php-pecl-memcached.spec
@@ -30,27 +30,26 @@
# After 40-igbinary, 40-json, 40-msgpack
%global ini_name 50-%{pecl_name}.ini
+%global upstream_version 3.1.6
+%global upstream_prever dev
+# upstream use dev => alpha => beta => RC
+# make RPM happy DEV => alpha => beta => rc
+%global upstream_lower DEV
+
+
Summary: Extension to work with the Memcached caching daemon
Name: %{?sub_prefix}php-pecl-memcached
-Version: 3.1.5
-Release: 13%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}}
+Version: %{upstream_version}%{?upstream_prever:~%{upstream_lower}}
+Release: 1%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}}
License: PHP
URL: https://pecl.php.net/package/%{pecl_name}
-Source0: https://pecl.php.net/get/%{pecl_name}-%{version}.tgz
-
-Patch0: https://patch-diff.githubusercontent.com/raw/php-memcached-dev/php-memcached/pull/461.patch
-Patch1: https://patch-diff.githubusercontent.com/raw/php-memcached-dev/php-memcached/pull/463.patch
-Patch2: https://patch-diff.githubusercontent.com/raw/php-memcached-dev/php-memcached/pull/465.patch
-Patch3: https://patch-diff.githubusercontent.com/raw/php-memcached-dev/php-memcached/pull/467.patch
-Patch4: https://patch-diff.githubusercontent.com/raw/php-memcached-dev/php-memcached/pull/468.patch
-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
-Patch9: https://patch-diff.githubusercontent.com/raw/php-memcached-dev/php-memcached/pull/487.patch
+Source0: https://pecl.php.net/get/%{pecl_name}-%{upstream_version}%{?upstream_prever}.tgz
+
+# revert change store_retry_count default (keep 3.1.5 behavior)
+Patch0: https://patch-diff.githubusercontent.com/raw/php-memcached-dev/php-memcached/pull/452.patch
+# improve phpinfo
Patch10: https://patch-diff.githubusercontent.com/raw/php-memcached-dev/php-memcached/pull/488.patch
-Patch11: https://patch-diff.githubusercontent.com/raw/php-memcached-dev/php-memcached/pull/474.patch
BuildRequires: %{?dtsprefix}gcc
BuildRequires: %{?scl_prefix}php-devel >= 7.0
@@ -161,7 +160,7 @@ Package built for PHP %(%{__php} -r 'echo PHP_MAJOR_VERSION.".".PHP_MINOR_VERSIO
%prep
%setup -c -q
-mv %{pecl_name}-%{version} NTS
+mv %{pecl_name}-%{upstream_version}%{?upstream_prever} NTS
# Don't install/register tests
sed -e 's/role="test"/role="src"/' \
@@ -169,23 +168,8 @@ sed -e 's/role="test"/role="src"/' \
-i package.xml
cd NTS
-%if "%{php_version}" > "8.0"
-%patch0 -p1 -b .pr461
-%patch1 -p1 -b .pr463
-%patch2 -p1 -b .pr465
-%patch3 -p1 -b .pr467
-%patch4 -p1 -b .pr468
-%patch5 -p1 -b .pr469
-%patch6 -p1 -b .pr472
-%patch8 -p1 -b .pr486
-%patch9 -p1 -b .pr486
-%endif
+%patch0 -p1 -R -b .pr452
%patch10 -p1 -b .pr488
-%if "%{php_version}" > "8.0"
-%patch11 -p1 -b .pr474
-%else
-%patch7 -p1 -b .pr473
-%endif
%if %{with fastlz}
rm -r fastlz
@@ -194,9 +178,9 @@ sed -e '/name=.fastlz/d' -i ../package.xml
# Check version as upstream often forget to update this
extver=$(sed -n '/#define PHP_MEMCACHED_VERSION/{s/.* "//;s/".*$//;p}' php_memcached.h)
-if test "x${extver}" != "x%{version}%{?gh_date:-dev}%{?intver}"; then
- : Error: Upstream HTTP version is now ${extver}, expecting %{version}%{?prever}%{?gh_date:-dev}.
- : Update the pdover macro and rebuild.
+if test "x${extver}" != "x%{upstream_version}%{?upstream_prever:-%{upstream_prever}}"; then
+ : Error: Upstream extension version is ${extver}, expecting %{upstream_version}%{?upstream_prever:-%{upstream_prever}}.
+ : Update the macro and rebuild.
exit 1
fi
cd ..
@@ -386,6 +370,9 @@ exit $ret
%changelog
+* Thu Mar 3 2022 Remi Collet <remi@remirepo.net> - 3.1.6~DEV-1
+- update to 3.1.6-dev (2022-03-02)
+
* Fri Feb 25 2022 Remi Collet <remi@remirepo.net> - 3.1.5-13
- rebuild using remi-libmemcached-awesome