From 3f546fcf2de55b5090ea9a177dfc4d03c4daf32c Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Tue, 17 Mar 2026 11:10:11 +0100 Subject: drop pear/pecl dependency sources from github --- REFLECTION | 2 +- composer.json | 63 ++++++++++++++++++++++++++++++++++++++++++++++++ php-pecl-redis6.spec | 68 ++++++++++++++++++++++++---------------------------- 3 files changed, 95 insertions(+), 38 deletions(-) create mode 100644 composer.json diff --git a/REFLECTION b/REFLECTION index 2f90220..dccd1f1 100644 --- a/REFLECTION +++ b/REFLECTION @@ -1,4 +1,4 @@ -Extension [ extension #146 redis version 6.3.0 ] { +Extension [ extension #145 redis version 6.3.0 ] { - Dependencies { Dependency [ igbinary (Required) ] diff --git a/composer.json b/composer.json new file mode 100644 index 0000000..dd4d00a --- /dev/null +++ b/composer.json @@ -0,0 +1,63 @@ + +{ + "name": "phpredis/phpredis", + "type": "php-ext", + "license": "PHP-3.01", + "description": "A PHP extension for Redis", + "require": { + "php": ">= 7.4.0" + }, + "php-ext": { + "extension-name": "redis", + "configure-options": [ + { + "name": "enable-redis", + "description": "Enable redis support" + }, + { + "name": "disable-redis-session", + "description": "Disable session support" + }, + { + "name": "disable-redis-json", + "description": "Disable json serializer support" + }, + { + "name": "enable-redis-igbinary", + "description": "Enable igbinary serializer support" + }, + { + "name": "enable-redis-msgpack", + "description": "Enable msgpack serializer support" + }, + { + "name": "enable-redis-lzf", + "description": "Enable lzf compression support" + }, + { + "name": "with-liblzf", + "description": "Use system liblzf", + "needs-value": true + }, + { + "name": "enable-redis-zstd", + "description": "Enable Zstd compression support" + }, + { + "name": "with-libzstd", + "description": "Use system libzstd", + "needs-value": true + }, + { + "name": "enable-redis-lz4", + "description": "Enable lz4 compression support" + }, + { + "name": "with-liblz4", + "description": "Use system liblz4", + "needs-value": true + } + ], + "priority": 60 + } +} diff --git a/php-pecl-redis6.spec b/php-pecl-redis6.spec index 99b42e6..1a5af47 100644 --- a/php-pecl-redis6.spec +++ b/php-pecl-redis6.spec @@ -1,6 +1,6 @@ # remirepo spec file for php-pecl-redis6 # -# SPDX-FileCopyrightText: Copyright 2012-2025 Remi Collet +# SPDX-FileCopyrightText: Copyright 2012-2026 Remi Collet # SPDX-License-Identifier: CECILL-2.1 # http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt # @@ -22,30 +22,36 @@ # Use keydb instead of valkey for tests %bcond_with keydb -%global pie_vend phpredis -%global pie_proj phpredis -%global pecl_name redis -%global with_zts 0%{!?_without_zts:%{?__ztsphp:1}} +%global pie_vend phpredis +%global pie_proj phpredis +%global pecl_name redis +%global with_zts 0%{!?_without_zts:%{?__ztsphp:1}} # after 20-json, 40-igbinary and 40-msgpack -%global ini_name 50-%{pecl_name}.ini +%global ini_name 50-%{pecl_name}.ini %global upstream_version 6.3.0 #global upstream_prever RC1 -%global sources %{pecl_name}-%{upstream_version}%{?upstream_prever} +%global sources %{gh_proj}-%{upstream_version}%{?upstream_prever} %global _configure ../%{sources}/configure -Summary: PHP extension for interfacing with key-value stores +# Github forge +%global gh_vend %{pie_vend} +%global gh_proj %{pie_proj} +%global forgeurl https://github.com/%{gh_vend}/%{gh_proj} +%global tag %{version} + Name: %{?scl_prefix}php-pecl-redis6 -Version: %{upstream_version}%{?upstream_prever:~%{upstream_prever}} -Release: 1%{?dist} +Summary: PHP extension for interfacing with key-value stores License: PHP-3.01 -URL: https://pecl.php.net/package/redis -Source0: https://pecl.php.net/get/%{sources}.tgz +Version: %{upstream_version}%{?upstream_prever:~%{upstream_prever}} +Release: 2%{?dist} +%forgemeta +URL: %{forgeurl} +Source0: %{forgesource} BuildRequires: make BuildRequires: %{?dtsprefix}gcc BuildRequires: %{?scl_prefix}php-devel >= 7.4 -BuildRequires: %{?scl_prefix}php-pear BuildRequires: %{?scl_prefix}php-json %if %{with igbinary} BuildRequires: %{?scl_prefix}php-pecl-igbinary-devel @@ -60,14 +66,12 @@ BuildRequires: pkgconfig(liblz4) %if %{with tests} %if %{with redis} BuildRequires: redis -%else -%if %{with keydb} +%elif %{with keydb} BuildRequires: keydb %else BuildRequires: valkey %endif %endif -%endif Requires: %{?scl_prefix}php(zend-abi) = %{php_zend_api} Requires: %{?scl_prefix}php(api) = %{php_core_api} @@ -135,12 +139,6 @@ Package built for PHP %(%{__php} -r 'echo PHP_MAJOR_VERSION.".".PHP_MINOR_VERSIO %prep %setup -q -c -# Don't install/register tests, license, and bundled library -sed -e 's/role="test"/role="src"/' \ - -e '/LICENSE/s/role="doc"/role="src"/' \ - -e '/liblzf/d' \ - -i package.xml - cd %{sources} # Use system library rm -r liblzf @@ -262,15 +260,6 @@ install -D -m 644 %{ini_name} %{buildroot}%{php_inidir}/%{ini_name} install -D -m 644 %{ini_name} %{buildroot}%{php_ztsinidir}/%{ini_name} %endif -# Install the package XML file -install -D -m 644 package.xml %{buildroot}%{pecl_xmldir}/%{name}.xml - -# Documentation -cd %{sources} -for i in $(grep 'role="doc"' ../package.xml | sed -e 's/^.*name="//;s/".*$//') -do install -Dpm 644 $i %{buildroot}%{pecl_docdir}/%{pecl_name}/$i -done - %check # simple module load test @@ -293,15 +282,15 @@ done cd %{sources}/tests : Launch the server -SRV=%{_root_bindir}/valkey-server -CLI=%{_root_bindir}/valkey-cli %if %{with redis} SRV=%{_root_bindir}/redis-server CLI=%{_root_bindir}/redis-cli -%endif -%if %{with keydb} +%elif %{with keydb} SRV=%{_root_bindir}/keydb-server CLI=%{_root_bindir}/keydb-cli +%else +SRV=%{_root_bindir}/valkey-server +CLI=%{_root_bindir}/valkey-cli %endif mkdir -p data @@ -340,8 +329,9 @@ exit $ret %files %license %{sources}/LICENSE -%doc %{pecl_docdir}/%{pecl_name} -%{pecl_xmldir}/%{name}.xml +%doc %{sources}/composer.json +%doc %{sources}/CREDITS +%doc %{sources}/*.md %{php_extdir}/%{pecl_name}.so %config(noreplace) %{php_inidir}/%{ini_name} @@ -353,6 +343,10 @@ exit $ret %changelog +* Tue Mar 17 2026 Remi Collet - 6.3.0-2 +- drop pear/pecl dependency +- sources from github + * Fri Nov 7 2025 Remi Collet - 6.3.0-1 - update to 6.3.0 -- cgit