summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--PHPINFO9
-rw-r--r--REFLECTION236
-rw-r--r--php-zstd.spec52
3 files changed, 234 insertions, 63 deletions
diff --git a/PHPINFO b/PHPINFO
index 632bfeb..dc18cf0 100644
--- a/PHPINFO
+++ b/PHPINFO
@@ -2,6 +2,11 @@
zstd
Zstd support => enabled
-Extension Version => 0.13.3
-Interface Version => 1.5.5
+Extension Version => 0.15.2
+Interface Version => 1.5.7
APCu serializer ABI => 0
+
+Directive => Local Value => Master Value
+zstd.output_compression => Off => Off
+zstd.output_compression_level => 3 => 3
+zstd.output_compression_dict => no value => no value
diff --git a/REFLECTION b/REFLECTION
index c0a9903..b1fed13 100644
--- a/REFLECTION
+++ b/REFLECTION
@@ -1,142 +1,288 @@
-Extension [ <persistent> extension #81 zstd version 0.13.3 ] {
+Extension [ <persistent> extension #131 zstd version 0.15.2 ] {
- Dependencies {
Dependency [ apcu (Optional) ]
}
+ - INI {
+ Entry [ zstd.output_compression <ALL> ]
+ Current = '0'
+ }
+ Entry [ zstd.output_compression_level <ALL> ]
+ Current = '3'
+ }
+ Entry [ zstd.output_compression_dict <ALL> ]
+ Current = ''
+ }
+ }
+
- Constants [5] {
Constant [ int ZSTD_COMPRESS_LEVEL_MIN ] { 1 }
Constant [ int ZSTD_COMPRESS_LEVEL_MAX ] { 22 }
Constant [ int ZSTD_COMPRESS_LEVEL_DEFAULT ] { 3 }
- Constant [ int LIBZSTD_VERSION_NUMBER ] { 10505 }
- Constant [ string LIBZSTD_VERSION_STRING ] { 1.5.5 }
+ Constant [ int ZSTD_VERSION_NUMBER ] { 10507 }
+ Constant [ string ZSTD_VERSION_TEXT ] { 1.5.7 }
}
- Functions {
Function [ <internal:zstd> function zstd_compress ] {
- - Parameters [2] {
- Parameter #0 [ <required> $data ]
- Parameter #1 [ <optional> $level = <default> ]
+ - Parameters [3] {
+ Parameter #0 [ <required> string $data ]
+ Parameter #1 [ <optional> int $level = ZSTD_COMPRESS_LEVEL_DEFAULT ]
+ Parameter #2 [ <optional> ?string $dict = null ]
}
+ - Return [ string|false ]
}
Function [ <internal:zstd> function zstd_uncompress ] {
- - Parameters [1] {
- Parameter #0 [ <required> $data ]
+ - Parameters [2] {
+ Parameter #0 [ <required> string $data ]
+ Parameter #1 [ <optional> ?string $dict = null ]
}
+ - Return [ string|false ]
}
Function [ <internal:zstd> function zstd_decompress ] {
- - Parameters [1] {
- Parameter #0 [ <required> $data ]
+ - Parameters [2] {
+ Parameter #0 [ <required> string $data ]
+ Parameter #1 [ <optional> ?string $dict = null ]
}
+ - Return [ string|false ]
}
Function [ <internal:zstd> function zstd_compress_dict ] {
- Parameters [3] {
- Parameter #0 [ <required> $data ]
- Parameter #1 [ <required> $dictBuffer ]
- Parameter #2 [ <optional> $level = <default> ]
+ Parameter #0 [ <required> string $data ]
+ Parameter #1 [ <required> string $dict ]
+ Parameter #2 [ <optional> int $level = ZSTD_COMPRESS_LEVEL_DEFAULT ]
}
+ - Return [ string|false ]
}
Function [ <internal:zstd> function zstd_uncompress_dict ] {
- Parameters [2] {
- Parameter #0 [ <required> $data ]
- Parameter #1 [ <required> $dictBuffer ]
+ Parameter #0 [ <required> string $data ]
+ Parameter #1 [ <required> string $dict ]
}
+ - Return [ string|false ]
}
Function [ <internal:zstd> function zstd_compress_usingcdict ] {
- Parameters [3] {
- Parameter #0 [ <required> $data ]
- Parameter #1 [ <required> $dictBuffer ]
- Parameter #2 [ <optional> $level = <default> ]
+ Parameter #0 [ <required> string $data ]
+ Parameter #1 [ <required> string $dict ]
+ Parameter #2 [ <optional> int $level = ZSTD_COMPRESS_LEVEL_DEFAULT ]
}
+ - Return [ string|false ]
}
Function [ <internal:zstd> function zstd_decompress_dict ] {
- Parameters [2] {
- Parameter #0 [ <required> $data ]
- Parameter #1 [ <required> $dictBuffer ]
+ Parameter #0 [ <required> string $data ]
+ Parameter #1 [ <required> string $dict ]
}
+ - Return [ string|false ]
}
Function [ <internal:zstd> function zstd_uncompress_usingcdict ] {
- Parameters [2] {
- Parameter #0 [ <required> $data ]
- Parameter #1 [ <required> $dictBuffer ]
+ Parameter #0 [ <required> string $data ]
+ Parameter #1 [ <required> string $dict ]
}
+ - Return [ string|false ]
}
Function [ <internal:zstd> function zstd_decompress_usingcdict ] {
- Parameters [2] {
- Parameter #0 [ <required> $data ]
- Parameter #1 [ <required> $dictBuffer ]
+ Parameter #0 [ <required> string $data ]
+ Parameter #1 [ <required> string $dict ]
}
+ - Return [ string|false ]
}
- Function [ <internal:zstd> function Zstd\compress ] {
+ Function [ <internal:zstd> function zstd_compress_init ] {
- Parameters [2] {
- Parameter #0 [ <required> $data ]
- Parameter #1 [ <optional> $level = <default> ]
+ Parameter #0 [ <optional> int $level = ZSTD_COMPRESS_LEVEL_DEFAULT ]
+ Parameter #1 [ <optional> ?string $dict = null ]
}
+ - Return [ Zstd\Compress\Context|false ]
}
- Function [ <internal:zstd> function Zstd\uncompress ] {
+ Function [ <internal:zstd> function zstd_compress_add ] {
+
+ - Parameters [3] {
+ Parameter #0 [ <required> Zstd\Compress\Context $context ]
+ Parameter #1 [ <required> string $data ]
+ Parameter #2 [ <optional> bool $end = false ]
+ }
+ - Return [ string|false ]
+ }
+ Function [ <internal:zstd> function zstd_uncompress_init ] {
- Parameters [1] {
- Parameter #0 [ <required> $data ]
+ Parameter #0 [ <optional> ?string $dict = null ]
}
+ - Return [ Zstd\UnCompress\Context|false ]
+ }
+ Function [ <internal:zstd> function zstd_uncompress_add ] {
+
+ - Parameters [2] {
+ Parameter #0 [ <required> Zstd\UnCompress\Context $context ]
+ Parameter #1 [ <required> string $data ]
+ }
+ - Return [ string|false ]
+ }
+ Function [ <internal:zstd> function Zstd\compress ] {
+
+ - Parameters [3] {
+ Parameter #0 [ <required> string $data ]
+ Parameter #1 [ <optional> int $level = ZSTD_COMPRESS_LEVEL_DEFAULT ]
+ Parameter #2 [ <optional> ?string $dict = null ]
+ }
+ - Return [ string|false ]
+ }
+ Function [ <internal:zstd> function Zstd\uncompress ] {
+
+ - Parameters [2] {
+ Parameter #0 [ <required> string $data ]
+ Parameter #1 [ <optional> ?string $dict = null ]
+ }
+ - Return [ string|false ]
}
Function [ <internal:zstd> function Zstd\decompress ] {
- - Parameters [1] {
- Parameter #0 [ <required> $data ]
+ - Parameters [2] {
+ Parameter #0 [ <required> string $data ]
+ Parameter #1 [ <optional> ?string $dict = null ]
}
+ - Return [ string|false ]
}
Function [ <internal:zstd> function Zstd\compress_dict ] {
- Parameters [3] {
- Parameter #0 [ <required> $data ]
- Parameter #1 [ <required> $dictBuffer ]
- Parameter #2 [ <optional> $level = <default> ]
+ Parameter #0 [ <required> string $data ]
+ Parameter #1 [ <required> string $dict ]
+ Parameter #2 [ <optional> int $level = ZSTD_COMPRESS_LEVEL_DEFAULT ]
}
+ - Return [ string|false ]
}
Function [ <internal:zstd> function Zstd\compress_usingcdict ] {
- Parameters [3] {
- Parameter #0 [ <required> $data ]
- Parameter #1 [ <required> $dictBuffer ]
- Parameter #2 [ <optional> $level = <default> ]
+ Parameter #0 [ <required> string $data ]
+ Parameter #1 [ <required> string $dict ]
+ Parameter #2 [ <optional> int $level = ZSTD_COMPRESS_LEVEL_DEFAULT ]
}
+ - Return [ string|false ]
}
Function [ <internal:zstd> function Zstd\uncompress_dict ] {
- Parameters [2] {
- Parameter #0 [ <required> $data ]
- Parameter #1 [ <required> $dictBuffer ]
+ Parameter #0 [ <required> string $data ]
+ Parameter #1 [ <required> string $dict ]
}
+ - Return [ string|false ]
}
Function [ <internal:zstd> function Zstd\decompress_dict ] {
- Parameters [2] {
- Parameter #0 [ <required> $data ]
- Parameter #1 [ <required> $dictBuffer ]
+ Parameter #0 [ <required> string $data ]
+ Parameter #1 [ <required> string $dict ]
}
+ - Return [ string|false ]
}
Function [ <internal:zstd> function Zstd\uncompress_usingcdict ] {
- Parameters [2] {
- Parameter #0 [ <required> $data ]
- Parameter #1 [ <required> $dictBuffer ]
+ Parameter #0 [ <required> string $data ]
+ Parameter #1 [ <required> string $dict ]
}
+ - Return [ string|false ]
}
Function [ <internal:zstd> function Zstd\decompress_usingcdict ] {
- Parameters [2] {
- Parameter #0 [ <required> $data ]
- Parameter #1 [ <required> $dictBuffer ]
+ Parameter #0 [ <required> string $data ]
+ Parameter #1 [ <required> string $dict ]
+ }
+ - Return [ string|false ]
+ }
+ Function [ <internal:zstd> function Zstd\compress_init ] {
+
+ - Parameters [2] {
+ Parameter #0 [ <optional> int $level = ZSTD_COMPRESS_LEVEL_DEFAULT ]
+ Parameter #1 [ <optional> ?string $dict = null ]
+ }
+ - Return [ Zstd\Compress\Context|false ]
+ }
+ Function [ <internal:zstd> function Zstd\compress_add ] {
+
+ - Parameters [3] {
+ Parameter #0 [ <required> Zstd\Compress\Context $context ]
+ Parameter #1 [ <required> string $data ]
+ Parameter #2 [ <optional> bool $end = false ]
+ }
+ - Return [ string|false ]
+ }
+ Function [ <internal:zstd> function Zstd\uncompress_init ] {
+
+ - Parameters [1] {
+ Parameter #0 [ <optional> ?string $dict = null ]
+ }
+ - Return [ Zstd\UnCompress\Context|false ]
+ }
+ Function [ <internal:zstd> function Zstd\uncompress_add ] {
+
+ - Parameters [2] {
+ Parameter #0 [ <required> Zstd\UnCompress\Context $context ]
+ Parameter #1 [ <required> string $data ]
+ }
+ - Return [ string|false ]
+ }
+ Function [ <internal:zstd> function ob_zstd_handler ] {
+
+ - Parameters [2] {
+ Parameter #0 [ <required> string $data ]
+ Parameter #1 [ <required> int $flags ]
+ }
+ - Return [ string|false ]
+ }
+ }
+
+ - Classes [2] {
+ Class [ <internal:zstd> final class Zstd\Compress\Context ] {
+
+ - Constants [0] {
+ }
+
+ - Static properties [0] {
+ }
+
+ - Static methods [0] {
+ }
+
+ - Properties [0] {
+ }
+
+ - Methods [0] {
+ }
+ }
+
+ Class [ <internal:zstd> final class Zstd\UnCompress\Context ] {
+
+ - Constants [0] {
+ }
+
+ - Static properties [0] {
+ }
+
+ - Static methods [0] {
+ }
+
+ - Properties [0] {
+ }
+
+ - Methods [0] {
}
}
}
diff --git a/php-zstd.spec b/php-zstd.spec
index 4d18d72..012ef3e 100644
--- a/php-zstd.spec
+++ b/php-zstd.spec
@@ -1,8 +1,8 @@
# remirepo spec file for php-zstd
#
-# Copyright (c) 2018-2024 Remi Collet
-# License: CC-BY-SA-4.0
-# http://creativecommons.org/licenses/by-sa/4.0/
+# SPDX-FileCopyrightText: Copyright 2018-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,9 +13,11 @@
%bcond_without apcu
%bcond_without libzstd
-%global zstdver 1.5.5
+%global zstdver 1.5.6
%global pecl_name zstd
+%global pie_vend kjdev
+%global pie_proj zstd
%global with_zts 0%{!?_without_zts:%{?__ztsphp:1}}
%global ini_name 40-%{pecl_name}.ini
%global buildver %(pkg-config --silence-errors --modversion libzstd 2>/dev/null || echo 65536)
@@ -24,7 +26,7 @@
Summary: Zstandard extension
Name: %{?scl_prefix}php-%{pecl_name}
-Version: 0.13.3
+Version: 0.15.2
Release: 1%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}}
%if %{with libzstd}
License: MIT
@@ -51,10 +53,12 @@ Provides: bundled(libzstd) = %{zstdver}
Requires: %{?scl_prefix}php(zend-abi) = %{php_zend_api}
Requires: %{?scl_prefix}php(api) = %{php_core_api}
-Provides: %{?scl_prefix}php-pecl-%{pecl_name} = %{version}
-Provides: %{?scl_prefix}php-pecl-%{pecl_name}%{?_isa} = %{version}
-Provides: %{?scl_prefix}php-pecl(%{pecl_name}) = %{version}
-Provides: %{?scl_prefix}php-pecl(%{pecl_name})%{?_isa} = %{version}
+Provides: %{?scl_prefix}php-pecl-%{pecl_name} = %{version}
+Provides: %{?scl_prefix}php-pecl-%{pecl_name}%{?_isa} = %{version}
+Provides: %{?scl_prefix}php-pecl(%{pecl_name}) = %{version}
+Provides: %{?scl_prefix}php-pecl(%{pecl_name})%{?_isa} = %{version}
+Provides: %{?scl_prefix}php-pie(%{pie_vend}/%{pie_proj}) = %{version}
+Provides: %{?scl_prefix}php-%{pie_vend}-%{pie_proj} = %{version}
%description
@@ -105,6 +109,11 @@ mkdir ZTS
cat << 'EOF' | tee %{ini_name}
; Enable '%{summary}' extension module
extension = %{pecl_name}.so
+
+; Configuration
+;zstd.output_compression = Off
+;zstd.output_compression_level = 3
+;zstd.output_compression_dict =
EOF
@@ -206,13 +215,6 @@ TEST_PHP_ARGS="-n -d extension=%{buildroot}%{php_extdir}/%{pecl_name}.so" \
%{__ztsphp} --no-php-ini \
--define extension=%{buildroot}%{php_ztsextdir}/%{pecl_name}.so \
--modules | grep '^%{pecl_name}$'
-
-%if %{with tests}
-: Upstream test suite for ZTS extension
-TEST_PHP_EXECUTABLE=%{__ztsphp} \
-TEST_PHP_ARGS="-n -d extension=%{buildroot}%{php_ztsextdir}/%{pecl_name}.so" \
-%{__ztsphp} -n run-tests.php -q --offline --show-diff
-%endif
%endif
@@ -243,6 +245,24 @@ TEST_PHP_ARGS="-n -d extension=%{buildroot}%{php_ztsextdir}/%{pecl_name}.so" \
%changelog
+* Tue Sep 2 2025 Remi Collet <remi@remirepo.net> - 0.15.2-1
+- update to 0.15.2
+
+* Mon Aug 18 2025 Remi Collet <remi@remirepo.net> - 0.15.1-1
+- update to 0.15.1
+
+* Wed Aug 13 2025 Remi Collet <remi@remirepo.net> - 0.15.0-1
+- update to 0.15.0
+- drop patch merged upstream
+
+* Wed Jul 30 2025 Remi Collet <remi@remirepo.net> - 0.14.0-2
+- fix for PHP 8.5.0alpha3 using patch from
+ https://github.com/kjdev/php-ext-zstd/pull/88
+- re-license spec file to CECILL-2.1
+
+* Wed Nov 6 2024 Remi Collet <remi@remirepo.net> - 0.14.0-1
+- update to 0.14.0
+
* Mon Jan 29 2024 Remi Collet <remi@remirepo.net> - 0.13.3-1
- update to 0.13.3