diff options
-rw-r--r-- | PHPINFO | 5 | ||||
-rw-r--r-- | REFLECTION | 6 | ||||
-rw-r--r-- | php-brotli.spec | 48 |
3 files changed, 37 insertions, 22 deletions
@@ -2,5 +2,6 @@ brotli Brotli support => enabled -Extension Version => 0.11.1 -Library Version => 1.0.7 +Extension Version => 0.12.0 +Library Version => 1.0.9 +APCu serializer ABI => 0 @@ -1,4 +1,8 @@ -Extension [ <persistent> extension #116 brotli version 0.11.1 ] { +Extension [ <persistent> extension #119 brotli version 0.12.0 ] { + + - Dependencies { + Dependency [ apcu (Optional) ] + } - INI { Entry [ brotli.output_compression <ALL> ] diff --git a/php-brotli.spec b/php-brotli.spec index 9244ea6..720d845 100644 --- a/php-brotli.spec +++ b/php-brotli.spec @@ -1,6 +1,6 @@ # remirepo spec file for php-brotli # -# Copyright (c) 2017-2020 Remi Collet +# Copyright (c) 2017-2021 Remi Collet # License: CC-BY-SA # http://creativecommons.org/licenses/by-sa/4.0/ # @@ -17,13 +17,16 @@ %global pkg_name %{name} %endif +# To build with PHP 5.x use --without apcu +%bcond_without apcu + %if 0%{?fedora} >= 30 || 0%{?rhel} >= 7 %bcond_without libbrotli %else %bcond_with libbrotli %endif -%global gh_commit c44db8db93fb3993e92a1a79264ca40ed27527c3 +%global gh_commit 267e470245bc742d99ad4b47a65a3efdb7187168 %global gh_short %(c=%{gh_commit}; echo ${c:0:7}) %global gh_owner kjdev %global gh_project php-ext-brotli @@ -34,11 +37,11 @@ Summary: Brotli Extension for PHP Name: %{?sub_prefix}php-%{pecl_name} -Version: 0.11.1 +Version: 0.12.0 %if 0%{?gh_date:1} Release: 2%{gh_date}git%{gh_short}%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}} %else -Release: 3%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}} +Release: 1%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}} %endif License: MIT URL: https://github.com/%{gh_owner}/%{gh_project} @@ -46,8 +49,14 @@ Source0: %{pkg_name}-%{version}-%{gh_short}.tgz # retrieve a recursive git snapshot with submodule Source1: makesrc.sh +BuildRequires: make BuildRequires: %{?dtsprefix}gcc +%if %{with apcu} +BuildRequires: %{?scl_prefix}php-devel > 7 +BuildRequires: %{?scl_prefix}php-pecl-apcu-devel +%else BuildRequires: %{?scl_prefix}php-devel +%endif %if %{with libbrotli} BuildRequires: brotli-devel >= 0.6.0 %else @@ -59,9 +68,6 @@ Requires: %{?scl_prefix}php(api) = %{php_core_api} %{?_sclreq:Requires: %{?scl_prefix}runtime%{?_sclreq}%{?_isa}} %if "%{?packager}" == "Remi Collet" && 0%{!?scl:1} && 0%{?rhel} -%if "%{php_version}" > "7.2" -Obsoletes: php72u-%{pecl_name} <= %{version} -%endif %if "%{php_version}" > "7.3" Obsoletes: php73-%{pecl_name} <= %{version} %endif @@ -73,12 +79,6 @@ Obsoletes: php80-%{pecl_name} <= %{version} %endif %endif -%if 0%{?fedora} < 20 && 0%{?rhel} < 7 -# Filter shared private -%{?filter_provides_in: %filter_provides_in %{_libdir}/.*\.so$} -%{?filter_setup} -%endif - %description This extension allows Brotli compression. @@ -178,7 +178,17 @@ cd NTS : Minimal load test for NTS extension %{__php} --no-php-ini \ --define extension=%{buildroot}%{php_extdir}/%{pecl_name}.so \ - --modules | grep %{pecl_name} + --modules | grep '^%{pecl_name}$' + +%if "%{php_version}" > "7.0" +: Check that apcu is aware of brotli serializer +%{__php} --no-php-ini \ + --define extension=apcu.so \ + --define apc.enabled=1 \ + --define apc.enable_cli=1 \ + --define extension=%{buildroot}%{php_extdir}/%{pecl_name}.so \ + --ri apcu | grep '%{pecl_name}' +%endif : Upstream test suite for NTS extension TEST_PHP_EXECUTABLE=%{__php} \ @@ -191,11 +201,7 @@ cd ../ZTS : Minimal load test for ZTS extension %{__ztsphp} --no-php-ini \ --define extension=%{buildroot}%{php_ztsextdir}/%{pecl_name}.so \ - --modules | grep %{pecl_name} - -# TODO: need investigation -# EL6 / i386 / ZTS only -rm tests/streams_003.phpt + --modules | grep '^%{pecl_name}$' : Upstream test suite for ZTS extension TEST_PHP_EXECUTABLE=%{__ztsphp} \ @@ -220,6 +226,10 @@ REPORT_EXIT_STATUS=1 \ %changelog +* Fri Jan 15 2021 Remi Collet <remi@remirepo.net> - 0.12.0-1 +- update to 0.12.0 +- enable apcu serializer with PHP 7+ + * Wed Sep 30 2020 Remi Collet <remi@remirepo.net> - 0.11.1-3 - rebuild for PHP 8.0.0RC1 |